id: CVE-2019-4716

info:
  name: IBM Planning Analytics - Authentication Bypass & Remote Code Execution Version Detection
  author: 0x_Akoko
  severity: critical
  description: |
    IBM Planning Analytics versions 2.0.0 through 2.0.8 are vulnerable to a configuration overwrite that allows an unauthenticated user to login as "admin", and then execute code as root or SYSTEM via TM1 scripting.
  impact: |
    Attackers can gain admin access and execute arbitrary code with SYSTEM privileges, leading to full system compromise.
  remediation: |
    Update to the latest version or 2.0.9 or apply the security patches provided by IBM.
  reference:
    - https://www.ibm.com/support/pages/node/1127781
    - https://nvd.nist.gov/vuln/detail/CVE-2019-4716
    - http://packetstormsecurity.com/files/156953/IBM-Cognos-TM1-IBM-Planning-Analytics-Server-Configuration-Overwrite-Code-Execution.html
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
    cvss-score: 9.8
    cve-id: CVE-2019-4716
    cwe-id: CWE-94
    epss-score: 0.86441
    epss-percentile: 0.9971
    cpe: cpe:2.3:a:ibm:planning_analytics:*:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 1
    vendor: ibm
    product: planning_analytics
    shodan-query: title:"Arc for TM1"
  tags: cve,cve2019,ibm,planning_analytics,passive,kev,vkev

http:
  - method: GET
    path:
      - "{{BaseURL}}"

    host-redirects: true
    max-redirects: 2

    matchers:
      - type: dsl
        dsl:
          - 'contains_any(body, "IBM Planning Analytics","IBM Cognos TM1")'
          - "compare_versions(version, '>= 2.0.0') && compare_versions(version, '<= 2.0.8')"
          - 'status_code == 200'
        condition: and

    extractors:
      - type: regex
        part: body
        name: version
        group: 1
        regex:
          - 'var appVersion = "([0-9.]+)";'
# digest: 490a0046304402201ad73250a3d549e892b51cae078c2c14a35faf1dae139bc7fffe48c89e69c3b802204a18a0251a3b5ade8dbb106ad340c749bb69482301d2765953c178154ae10ccf:922c64590222798bb761d5b6d8e72950