id: CVE-2020-5777

info:
  name: Magento Mass Importer  <0.7.24 - Remote Auth Bypass
  author: dwisiswant0
  severity: critical
  description: Magento Mass Importer (aka MAGMI) versions prior to 0.7.24 are vulnerable to a remote authentication bypass due to allowing default credentials in the event there is a database connection failure.
  impact: |
    An attacker can bypass authentication and gain unauthorized access to the Magento Mass Importer plugin.
  remediation: |
    Upgrade to version 0.7.24 or later to fix the authentication bypass vulnerability.
  reference:
    - https://github.com/dweeves/magmi-git/blob/18bd9ec905c90bfc9eaed0c2bf2d3525002e33b9/magmi/inc/magmi_auth.php#L35
    - https://nvd.nist.gov/vuln/detail/CVE-2020-5777
    - https://www.tenable.com/security/research/tra-2020-51
    - https://github.com/404notf0und/CVE-Flow
    - https://github.com/ARPSyndicate/cvemon
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
    cvss-score: 9.8
    cve-id: CVE-2020-5777
    cwe-id: CWE-287
    epss-score: 0.90604
    epss-percentile: 0.99595
    cpe: cpe:2.3:a:magmi_project:magmi:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    vendor: magmi_project
    product: magmi
    shodan-query:
      - http.component:"Magento"
      - http.component:"magento"
  tags: cve,cve2020,plugin,tenable,magmi,magento,auth,bypass,magmi_project

http:
  - raw:
      - |
        GET /index.php/catalogsearch/advanced/result/?name=e HTTP/1.1
        Host: {{Hostname}}
        Connection: close

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - "Too many connections"

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