Improper privilege management in Apache CouchDB
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Privilege escalation
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- No fix listed
Attack profile from CVSS 3.0 · NVD. Fix status from CNA. Impact type from CWE-269.
Summary
Due to differences in the Erlang-based JSON parser and JavaScript-based JSON parser, it is possible in Apache CouchDB before 1.7.0 and 2.x before 2.1.1 to submit _users documents with duplicate keys for 'roles' used for access control within the database, including the special case '_admin' role, that denotes administrative users. In combination with CVE-2017-12636 (Remote Code Execution), this can be used to give non-admin users access to arbitrary shell commands on the server as the database system user. The JSON parser differences result in behaviour that if two 'roles' keys are available in the JSON, the second one will be used for authorising the document write, but the first 'roles' key is used for subsequent authorization for the newly created user. By design, users can not assign themselves roles. The vulnerability allows non-admin users to give themselves admin privileges.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| Apache | Apache CouchDB | 1.2.0 to 1.6.1; 2.0.0 to 2.1.0 | — | No fix listed | CNA |
- Apache CouchDB VendorApache Affected 1.2.0 to 1.6.1; 2.0.0 to 2.1.0 Fixed in — No fix listed CNA
CPE configurations NVD · 6
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:apache:couchdb:*:*:*:*:*:*:*:* | before 1.7.0 | Vulnerable | Apache |
| cpe:2.3:a:apache:couchdb:2.0.0:*:*:*:*:*:*:* | 2.0.0 | Vulnerable | Apache |
| cpe:2.3:a:apache:couchdb:2.0.0:rc1:*:*:*:*:*:* | 2.0.0 rc1 | Vulnerable | Apache |
| cpe:2.3:a:apache:couchdb:2.0.0:rc2:*:*:*:*:*:* | 2.0.0 rc2 | Vulnerable | Apache |
| cpe:2.3:a:apache:couchdb:2.0.0:rc3:*:*:*:*:*:* | 2.0.0 rc3 | Vulnerable | Apache |
| cpe:2.3:a:apache:couchdb:2.0.0:rc4:*:*:*:*:*:* | 2.0.0 rc4 | Vulnerable | Apache |
- cpe:2.3:a:apache:couchdb:*:*:*:*:*:*:*:* Versions before 1.7.0 Vulnerable ·Apache
- cpe:2.3:a:apache:couchdb:2.0.0:*:*:*:*:*:*:* Versions 2.0.0 Vulnerable ·Apache
- cpe:2.3:a:apache:couchdb:2.0.0:rc1:*:*:*:*:*:* Versions 2.0.0 rc1 Vulnerable ·Apache
- cpe:2.3:a:apache:couchdb:2.0.0:rc2:*:*:*:*:*:* Versions 2.0.0 rc2 Vulnerable ·Apache
- cpe:2.3:a:apache:couchdb:2.0.0:rc3:*:*:*:*:*:* Versions 2.0.0 rc3 Vulnerable ·Apache
- cpe:2.3:a:apache:couchdb:2.0.0:rc4:*:*:*:*:*:* Versions 2.0.0 rc4 Vulnerable ·Apache
Remediation
No fixed version listed by the sources yet.
Fixed in the same release
Records fixed by the same vendor advisory or release, as the CNA lists them.
- Advisory ·
Apache CouchDB — GLSA-201711-16
2 records Highest priority Priority CRITICAL 1 CRITICAL, 1 HIGH
Other records, highest priority first
- TI-2017-09361 OS command injection in Apache CouchDBPriority HIGH 74
Vendor assessments
Timeline
- 2026-10-02 Threatist record created from CVE-2017-12635
- 2026-10-03 Alias added: GHSA-f3p2-qqmm-jg8f
References
More Apache Couchdb vulnerabilities
- TI-2022-08521 Remote Code Execution Vulnerability in Packaging KEVCVSS 3.1CRITICAL 9.8
- TI-2017-09361 OS command injection in Apache CouchDB CVSS 3.0HIGH 7.2
- TI-2020-01879 Missing authentication in Apache CouchDB CVSS 3.1CRITICAL 9.8
- TI-2018-05784 Improper input validation in Apache CouchDB CVSS 3.0HIGH 7.2
- TI-2018-08426 CouchDB administrative users before 2.2.0 can configure the database server via HTTP(S). CVSS 3.0HIGH 7.2
- TI-2014-02145 Apache CouchDB 1.5.0 and earlier allows remote attackers to cause a denial of service… CVSS 2.0MEDIUM 5.0
Sources
- CVE-2017-12635 · CVE Program
- CVE-2017-12635 · NVD
- FIRST EPSS
- GHSA-f3p2-qqmm-jg8f · GitHub Advisory Database · CC BY 4.0
- CVE-2017-12635 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences