# Title: Mailman 1.x > 2.1.23 - Cross Site Scripting (XSS)
# Type: Reflected XSS
# Software: Mailman
# Version: >=1.x <= 2.1.23
# Vendor Homepage: https://www.list.org
# Original link: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-5950
# POC Author: Valerio Alessandroni
# Date: 28/10/2020
# Description: Cross-site scripting (XSS) vulnerability in the web UI in Mailman before 2.1.26 allows remote attackers to inject arbitrary web script or HTML via a user-options URL.
#
# https://127.0.0.1/cgi-bin/mailman/options/[LIST]/[EMAIL][XSS]
# Which [LIST] is a valid list, [EMAIL] is a valid email and [XSS] is the payload
#
# For this POC I used the following payload
# CVE: CVE-2018-5950
"accesskey%3d"x"onclick%3d"alert`XSS`"
# Due the payload is loaded inside an HIDDEN INPUT TYPE, until today the only way to trigger the malicious code is via the accesskey attribute.
# An URL Encoded version of the payload is
# In order to trigger the alert, the victim has to press the following buttons ALT+SHIFT+X
# where X is an arbitrary button inserted as accesskey attribute in the payload.