id: teamcity-login-panel

info:
  name: TeamCity Login Panel - Detect
  author: princechaddha
  severity: info
  description: TeamCity login panel was detected.
  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:jetbrains:teamcity:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    product: teamcity
    shodan-query: http.component:"TeamCity"
    vendor: jetbrains
    verified: true
  tags: panel,teamcity,jetbrains,detect

http:
  - method: GET
    path:
      - "{{BaseURL}}/login.html"

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - "<title>Log in to TeamCity &mdash; TeamCity</title>"

      - type: status
        status:
          - 200

    extractors:
      - type: regex
        part: body
        group: 1
        name: version
        regex:
          - "Version</span> ([0-9.]+)"

      - type: regex
        part: body
        group: 1
        name: build
        regex:
          - "Version</span> [0-9.]+ \\(build (.*)\\)</span>"
# digest: 490a00463044022079a575e1470aacf813862ac4f585d54468612c4a0f92b32e08ce6d94fe5be71502203d0c47e1fd7925776631492df901873233004fc9c4d7d288f28a957250a355ac:922c64590222798bb761d5b6d8e72950