id: couchdb-adminparty

info:
  name: CouchDB Admin Default - Detect
  author: organiccrap
  severity: high
  description: CouchDB is susceptible to requests in the context of an admin user.
  reference:
    - https://docs.couchdb.org/en/stable/intro/security.html#authentication-database
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
    cvss-score: 7.5
    cwe-id: CWE-200
  metadata:
    max-request: 1
  tags: couchdb,vuln

http:
  - method: GET
    path:
      - '{{BaseURL}}/_users/_all_docs'

    matchers-condition: and
    matchers:
      - type: word
        words:
          - CouchDB/
          - Erlang OTP/
        part: header
        condition: and

      - type: word
        words:
          - total_rows
          - offset
        part: body
        condition: and
# digest: 490a00463044022003c46cd765de10afe97f9c835168d77ae6f03fef1b470a0b7f05aac560841c2302205ffb8552de5c6e5d469bd08ab267be7519f165488e7278d0d9b462ae5c74ef9f:922c64590222798bb761d5b6d8e72950