id: fortios-panel

info:
  name: FortiOS Admin Login Panel - Detect
  author: canberbamber,Jna1
  severity: info
  description: |
    FortiOS admin login panel was detected.
  reference:
    - https://www.horizon3.ai/fortinet-iocs-cve-2022-40684/
  classification:
    cvss-metrics: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:N
    cwe-id: CWE-200
    cpe: cpe:2.3:o:fortinet:fortios:*:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 1
    vendor: fortinet
    product: fortios
    shodan-query:
      - http.favicon.hash:945408572
      - cpe:"cpe:2.3:o:fortinet:fortios"
      - port:10443 http.favicon.hash:945408572
      - http.html:"/remote/login" "xxxxxxxx"
    fofa-query:
      - body="/remote/login" "xxxxxxxx"
      - icon_hash=945408572
  tags: panel,fortinet,fortios,discovery

http:
  - raw:
      - |
        GET /api/v2/cmdb/system/admin/admin HTTP/1.1
        Host: {{Hostname}}

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - '/remote/login'

      - type: word
        part: header
        words:
          - 'Server: xxxxxxxx-xxxxx'

      - type: status
        status:
          - 403
# digest: 4a0a0047304502207ee850d8b7f92048051139dd5f166b834909f81f62e2264617147fb5cb2f7bf2022100b1e3d647b89c43c5a1310812824ed046ec5999162905c3e23a556e1d371655bc:922c64590222798bb761d5b6d8e72950