id: opcache-status-exposure

info:
  name: OPcache Status Page - Detect
  author: pdteam
  severity: medium
  description: OPcache status page was detected.
  reference:
    - https://www.php.net/manual/en/book.opcache.php
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
    cvss-score: 5.3
    cwe-id: CWE-200
  metadata:
    max-request: 3
  tags: config,exposure,status,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/opcache-status/"
      - "{{BaseURL}}/php-opcache-status/"
      - "{{BaseURL}}/opcache-status/opcache.php"

    matchers:
      - type: word
        words:
          - "<th>opcache_enabled</th>"
          - "<th>opcache_hit_rate</th>"
        condition: and
        part: body
# digest: 4a0a00473045022100e5e34bf302b2f81d22be93c50dd94efa0bfb7faa36288c45426fecb021f8ee4c02207f44a0770b2e5419a58225b71d3bb53affde1545a0d2c98a29ad7b0962f9c2df:922c64590222798bb761d5b6d8e72950