cve.bz

CVE-2017-12635 apache couchdb: Improper Privilege Management

9.8 criticalExploitEPSS 99.8%

Critical (9.8) in apache couchdb. EPSS 99.8% estimated probability of exploitation activity in the next 30 days.

On this page
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.

Severity

CVSS 3.0

9.8 critical
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS
99.8% (unchanged from 99.8% a week ago; 99.8% 30 days ago) estimated probability of exploitation activity in the next 30 days; 100th percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CWE
CWE-269 Improper Privilege Management
OWASP Top 10
A06:2025 Insecure Design
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2017-12635 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2017-12635?via=ask-ai-copy and https://cve.bz/cve/CVE-2017-12635?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2017-12635 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the NVD's CPE matches.

ProductAffected
apache:couchdbbefore 1.7.0
apache:couchdb2.0.0
apache:couchdb2.0.0:rc1
apache:couchdb2.0.0:rc2
apache:couchdb2.0.0:rc3
apache:couchdb2.0.0:rc4

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian7couchdb1.2.0-5+deb7u1DLA-1252-1
Ubuntu16.04:LTScouchdbno fix listedUBUNTU-CVE-2017-12635

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu.

Public exploits

GitHub PoC (unverified)

Repositories on GitHub named after this CVE. Nobody has checked them and they are not scanned: some hold a working proof of concept, some nothing useful, and some malware made to look like one. Read the code before you run any of it.

Detection rules

Ways to detect this CVE, not exploit code: the nuclei template that checks a system for it, and the Suricata and Snort rules that name it. A rule set may ship a rule turned off, so check yours by its sid.

  • Nuclei template Apache CouchDB 1.7.0 / 2.x < 2.1.1 - Remote Privilege Escalation
  • Emerging Threats Open ET EXPLOIT Apache CouchDB 1.7.0 / 2.x < 2.1.1 - Remote Privilege Escalation (CVE-2017-12635) sid 2063343
  • Emerging Threats Open ET WEB_SPECIFIC_APPS Apache CouchDB Remote Code Execution 1 sid 2025740
  • Emerging Threats Open ET EXPLOIT Apache CouchDB JSON Remote Privesc Attempt (CVE-2017-12635) sid 2025435

Attack patterns (CAPEC)

  • CAPEC-58 Restful Privilege Elevation Likelihood: High · Severity: High
  • CAPEC-122 Privilege Abuse Likelihood: High · Severity: Medium
  • CAPEC-233 Privilege Escalation

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON