{"schemaVersion":3,"id":"CVE-2026-12165","aliases":[],"status":"published","duplicateOf":null,"title":"Contest Gallery <= 30.0.2 - Authenticated (Author+) Privilege Escalation via 'RegistryUserRole' Parameter","description":"The Contest Gallery – Upload & Vote Photos, Media, Sell with PayPal & Stripe plugin for WordPress is vulnerable to Privilege Escalation in all versions up to, and including, 30.0.2 via the `RegistryUserRole` parameter. This is due to the plugin's admin menu being registered at the `edit_posts` capability level — granting Contributor-level users access to the plugin's admin pages and a valid `cg_admin` nonce — while the option-saving handler in `change-options-and-sizes.php` performs no `current_user_can()` capability check beyond `check_admin_referer('cg_admin')`, and the `RegistryUserRole` value is processed only through `sanitize_text_field()` and `htmlentities()` without restriction to an allowlist of permitted role names. This makes it possible for authenticated attackers, with author-level access and above, to overwrite the plugin's stored `RegistryUserRole` option with `administrator`, which the `cg_create_wp_user_from_google_user` function then reads back from the `contest_gal1ery_registry_and_login_options` database table without any allowlist validation and passes directly to `wp_update_user()`, effectively promoting a newly registered Google sign-in account to Administrator.","dates":{"published":"2026-06-17T09:30:59.218Z","modified":"2026-06-17T10:38:40.424Z","reserved":null,"kevAdded":[],"kevDue":[]},"cvss":{"headline":{"score":8.8,"severity":"high","version":"3.1","versionLabel":"v3.1","source":"CVE.org","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","computed":false,"selection":"backend-summary"},"metrics":[{"version":"3.1","versionLabel":"v3.1","source":"CVE.org","score":8.8,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","exploitability":null,"impact":null,"computed":false},{"version":"3.1","versionLabel":"v3.1","source":"NVD","score":8.8,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","exploitability":null,"impact":null,"computed":false},{"version":"3.1","versionLabel":"v3.1","source":"wordfence","score":8.8,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","exploitability":null,"impact":null,"computed":false}]},"epss":{"probability":0.00396,"percentile":0.32647,"severity":"low","asOf":"2026-10-22T00:00:00.000Z","change":{"pp":0,"baselineDate":"2026-09-22T00:00:00.000Z","baselineScore":0.00396},"history":[{"date":"2026-09-14T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-15T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-16T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-17T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-18T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-19T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-20T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-21T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-22T00:00:00.000Z","score":0.00396,"percentile":0.32647}],"last30":[{"date":"2026-09-22T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-20T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-21T00:00:00.000Z","score":0.00396,"percentile":null},{"date":"2026-10-22T00:00:00.000Z","score":0.00396,"percentile":0.32647}]},"kev":{"state":"not-listed","entries":[],"listedCount":0,"totalCatalogs":3,"catalogs":[{"source":"cisa","label":"CISA","listed":false,"entry":null},{"source":"enisa","label":"ENISA","listed":false,"entry":null},{"source":"circl","label":"CIRCL","listed":false,"entry":null}]},"ransomware":{"state":"none-recorded","sources":[]},"exploits":[],"exploitCount":0,"weaknesses":[{"id":"CWE-269","name":"Improper Privilege Management","description":"The product does not properly assign, modify, track, or check privileges for an actor, creating an unintended sphere of control for that actor.","type":"weakness","status":"Draft","abstraction":"Class","likelihoodOfExploit":"Medium","url":"https://cwe.mitre.org/data/definitions/269.html"}],"affected":[{"vendor":"contest-gallery","product":"contest gallery – upload & vote photos, media, sell with paypal & stripe","name":"Contest Gallery – Upload & Vote Photos, Media, Sell with PayPal & Stripe","label":"contest gallery – upload & vote photos, media, sell with paypal & stripe","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≤ 30.0.2","noFixRecorded":false,"fixedIn":null}],"versionsText":"≤ 30.0.2","eol":null,"hubHref":"/vendor/contest-gallery/contest_gallery_-_upload__vote_photos_media_sell_with_paypal__stripe"},{"vendor":"wordpress","product":"contest-gallery","name":"Contest Gallery – Upload & Vote Photos, Media, Sell with PayPal & Stripe","label":"contest-gallery","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≤ 30.0.2 (fixed in 30.0.3)","noFixRecorded":false,"fixedIn":"30.0.3"}],"versionsText":"≤ 30.0.2 (fixed in 30.0.3)","eol":null,"hubHref":null}],"affectedCount":2,"eol":{"hasEol":false,"count":0},"references":[{"url":"https://www.wordfence.com/threat-intel/vulnerabilities/id/69b909da-b1b0-4dab-916c-908511f6556f?source=cve","label":"www.wordfence.com/threat-intel/vulnerabilities/id/69b909da-b1b0-4dab-916c-908511f6556f?source=cve","hostname":"www.wordfence.com","tags":[]},{"url":"https://plugins.trac.wordpress.org/browser/contest-gallery/tags/30.0.2/v10/v10-admin/options/change-options-and-sizes.php#L1242","label":"plugins.trac.wordpress.org/browser/…","hostname":"plugins.trac.wordpress.org","tags":[]},{"url":"https://plugins.trac.wordpress.org/browser/contest-gallery/tags/30.0.2/functions/google/cg-create-wp-user-from-google-user.php#L169","label":"plugins.trac.wordpress.org/browser/…","hostname":"plugins.trac.wordpress.org","tags":[]},{"url":"https://plugins.trac.wordpress.org/browser/contest-gallery/tags/30.0.2/v10/v10-admin/options/change-options-and-sizes.php#L16","label":"plugins.trac.wordpress.org/browser/…","hostname":"plugins.trac.wordpress.org","tags":[]},{"url":"https://plugins.trac.wordpress.org/browser/contest-gallery/tags/30.0.2/index.php#L407","label":"plugins.trac.wordpress.org/browser/contest-gallery/tags/30.0.2/index.php","hostname":"plugins.trac.wordpress.org","tags":[]},{"url":"https://plugins.trac.wordpress.org/changeset?sfp_email=&sfph_mail=&reponame=&old=3571733%40contest-gallery&new=3571733%40contest-gallery&sfp_email=&sfph_mail=","label":"plugins.trac.wordpress.org/changeset","hostname":"plugins.trac.wordpress.org","tags":[]},{"url":"https://www.wordfence.com/threat-intel/vulnerabilities/id/69b909da-b1b0-4dab-916c-908511f6556f","label":"www.wordfence.com/threat-intel/vulnerabilities/id/69b909da-b1b0-4dab-916c-908511f6556f","hostname":"www.wordfence.com","tags":["Vendor Advisory"]}],"lineage":{"upstream":[],"downstream":[],"duplicates":[],"related":[]},"timeline":[{"kind":"published","date":"2026-06-17T09:30:59.218Z","label":"Published","detail":"Vulnerability first disclosed.","source":null},{"kind":"modified","date":"2026-06-17T10:38:40.424Z","label":"Last modified","detail":"Vulnerability information updated.","source":null}],"risk":{"score":35,"level":"medium","profile":"Default","thresholds":{"critical":75,"high":50,"medium":25,"low":10}},"meta":{"dataAsOf":"2026-10-22T17:20:19.063Z","stale":false,"partial":false}}