id: jupyter-notebook

info:
  name: Jupyter Notebook Login Panel - Detect
  author: hakimkt,arafatansari
  severity: info
  description: |
    Jupyter Notebook login panel was detected.
  reference:
    - https://www.exploit-db.com/ghdb/7970
  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
  metadata:
    max-request: 4
    shodan-query: http.html:"JupyterHub"
  tags: edb,panel,jupyter,notebook,exposure

http:
  - method: GET
    path:
      - "{{BaseURL}}/jupyter/login"
      - "{{BaseURL}}/jupyter/lab"
      - "{{BaseURL}}/jupyter/hub/lti/launch"
      - "{{BaseURL}}/hub/login"

    stop-at-first-match: true
    host-redirects: true
    max-redirects: 2

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - '/jupyter/static/base/images/logo.png'
          - '/jupyter/hub/logo'
          - 'Select items to perform actions on them.'
          - 'JupyterHub'
        condition: or

      - type: status
        status:
          - 200
# digest: 4a0a00473045022100f4228d1217daf22f95fe1c2d35fb94ffc284bb1544a73478158b09a7c949ed260220746ab20350d22ac0d5c88c2ba2cdf29bf7dab654dd0625913dd09d6c3f4762a1:922c64590222798bb761d5b6d8e72950