id: wp-user-role-editor-fpd

info:
  name: User Role Editor - Full Path Disclosure
  author: theamanrawat
  severity: low
  description: |
    User Role Editor WordPress plugin contains a full path disclosure vulnerability due to improper access restrictions in its source files, allowing unauthenticated attackers to retrieve full server paths and aiding exploitation.
  impact: |
    Attackers can obtain server file paths, aiding in further exploitation of the website.
  reference:
    - https://wordpress.org/plugins/user-role-editor/
  metadata:
    verified: true
    max-requests: 1
    public-www: "/wp-content/plugins/user-role-editor/"
  tags: debug,wordpress,wp,wp-plugin,user-role-editor,fpd

http:
  - method: GET
    path:
      - "{{BaseURL}}/wp-content/plugins/user-role-editor/user-role-editor.php"

    matchers:
      - type: dsl
        dsl:
          - 'status_code == 200'
          - 'contains_all(body, "Fatal error", "undefined function", "user-role-editor")'
        condition: and
# digest: 4b0a00483046022100bb9843d850c5a90a4f517695218c20cd59bd28e533863ff2758c91e2ba3ce743022100a204bc4dccc10e3911caa7a42effd26e499a27b5572fba3657f420fe8860fdce:922c64590222798bb761d5b6d8e72950