id: jumpserver-panel

info:
  name: JumpServer Login Panel - Detect
  author: lu4nx,righettod
  severity: info
  description: |
    JumpServer Open Source Bastion Host login panel was detected.
  reference:
    - https://www.jumpserver.org/
    - https://github.com/jumpserver/jumpserver
  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:a:fit2cloud:jumpserver:*:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 2
    shodan-query: http.title:'JumpServer'
    zoomeye-query: app="JumpServer Bastion Host"
    product: jumpserver
    vendor: fit2cloud
  tags: panel,jumpserver,login

http:
  - method: GET
    path:
      - "{{BaseURL}}/core/auth/login/"
      - "{{BaseURL}}/users/login/"

    stop-at-first-match: true

    matchers-condition: and
    matchers:
      - type: regex
        part: body
        regex:
          - "(?i)<title>(\n.*)JumpServer Open Source Bastion Host(\n.*)</title>"
          - "(?i)<title>(\n.*)JumpServer 开源堡垒机(\n.*)</title>"
          - "(?i)<title>\n*Jumpserver.*?\n*</title>"
          - "(?i)>Welcome to the Jumpserver.*?</h2>"
        condition: or

      - type: status
        status:
          - 200

    extractors:
      - type: regex
        part: body
        group: 1
        regex:
          - '(?i)&copy;\s+([0-9-]+)'
# digest: 4a0a0047304502207159992bc0248a7ed83525898806bbd98bea1e334a67f5c4c08ee2748992d2b7022100b574731339fcc8540de03a409295b87b84af4a042ca772796ea8ad9b0815670f:922c64590222798bb761d5b6d8e72950