id: rdp-detection

info:
  name: Windows Remote Desktop Protocol - Detect
  author: princechaddha
  severity: info
  description: |
    Windows Remote Desktop Protocol was detected.
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:N
    cwe-id: CWE-200
  metadata:
    verified: true
    max-request: 1
  tags: network,windows,rdp,detect,detection,tcp,discovery
tcp:
  - inputs:
      - data: "0300002a25e00000000000436f6f6b69653a206d737473686173683d746573740d0a010008000b000000"
        type: hex
    read-size: 2048

    host:
      - "{{Hostname}}"
    port: 3389

    matchers:
      - type: word
        name: rdp
        encoding: hex
        words:
          - "030000130ed"

      - type: word
        encoding: hex
        name: win2000/winxp
        words:
          - "0300000b06d00000123400"

      - type: word
        encoding: hex
        name: win2003
        words:
          - "030000130ed000001234000300080002000000"

      - type: word
        encoding: hex
        name: win2008
        words:
          - "030000130ed000001234000200080002000000"

      - type: word
        encoding: hex
        name: win7or2008R2
        words:
          - "030000130ed000001234000209080002000000"

      - type: word
        encoding: hex
        name: win2008R2DC
        words:
          - "030000130ed000001234000201080002000000"

      - type: word
        encoding: hex
        name: win10
        words:
          - "030000130ed00000123400021f080002000000"

      - type: word
        encoding: hex
        name: win2012R2OR8
        words:
          - "030000130ed00000123400020f080002000000"

      - type: word
        encoding: hex
        name: win2012R2
        words:
          - "030000130ed00000123400020f080008000000"

      - type: word
        encoding: hex
        name: win2016
        words:
          - "030000130ed00000123400021f080008000000"
# digest: 490a00463044022051981f3cb2baeb884b203408df6f08ed232b918800b37a071b59a3444c7da7f6022075a16ff38caf38547f7af4ece1884c8d4353ad47cdf2625bb22aee708253ddce:922c64590222798bb761d5b6d8e72950