Skip to content
Laskyr

Plugins · code-snippets · data as of 2026-11-01

Is Code Snippets safe? Known vulnerabilities and latest version

No known unpatched vulnerabilities in the latest version (4.0.0)

As of 2026-11-01. 8 issues are on record for older versions; version 3.10.0 or newer fixes all of them that state a fix.

Latest version
4.0.0
Last updated
2026-10-21
Active installs
1+ million
Known issues on record
8
Unpatched in latest
0
Tested up to WP
7.1.4 · PHP 7.4+

Manage custom WordPress code in one dashboard. Create PHP and HTML snippets, preview code, track snippet totals and reuse code across sites. — by Code Snippets Pro

What to do

  1. Update to the latest version (4.0.0). Anything older than 3.10.0 has at least one known issue listed below. Dashboard → Updates, or Plugins → “update now”.
  2. If you cannot update right away, deactivate it until you can.
  3. Turn on auto-updates for it: Plugins → “Enable auto-updates” on its row.
  4. If you ran a vulnerable version and something looks off (spam pages, strange admins, redirects), run the free scan.

With WP-CLI: wp plugin get code-snippets --field=version shows what you run; wp plugin update code-snippets updates it.

Check your version

Known vulnerabilities

8 on record, newest first. “Affected” is the version range the source gives; “fixed in” is the version the source names, or (marked *) the first wordpress.org release after the last affected version.

low 3.3 CVE-2026-106095 · published 2026-10-09

Missing authorization check in Code Snippets (older than 3.10.0)

Affected
older than 3.10.0
Fixed in
3.10.0
Access needed (per CVSS)
Needs an admin-level account
Range from
CVE record (the advisory publisher) · score by CISA ADP
Details from the advisory

The Code Snippets WordPress plugin before 3.10.0 does not perform a capability check on one of its snippet-management actions and derives the network scope of the targeted snippet from the request instead of from the stored record, allowing an administrator of a single subsite on a multisite network to activate, deactivate and reprioritise network-scoped snippets that run across every site in the network.

NVD CVE-2026-106095WPScan advisory

medium 6.8 CVE-2026-106097 · published 2026-10-09

SQL injection in Code Snippets (older than 3.10.0)

Affected
older than 3.10.0
Fixed in
3.10.0
Access needed (per CVSS)
Needs an admin-level account
Range from
CVE record (the advisory publisher) · score by CISA ADP
Details from the advisory

The Code Snippets WordPress plugin before 3.10.0 does not sanitise and escape a user-supplied parameter before using it in a SQL query in some of its snippet-migration import endpoints, which are accessible to any user holding site-administration capabilities; on a WordPress Multisite network those belong to subsite Administrators, allowing a subsite Administrator who is not a network Super Admin to perform UNION-based SQL injection against shared network tables and disclose network-wide data such as other users' password hashes.

NVD CVE-2026-106097WPScan advisory

medium 4.3 CVE-2026-1785 · published 2026-02-06

Cross-site request forgery (CSRF) in Code Snippets (3.9.4 and older)

Affected
3.9.4 and older
Fixed in
3.9.5 *
Access needed (per CVSS)
No login needed; someone on the site has to click a link or open a page
Range from
CVE record (the advisory publisher) · score by Wordfence
Details from the advisory

The Code Snippets plugin for WordPress is vulnerable to Cross-Site Request Forgery in all versions up to, and including, 3.9.4. This is due to missing nonce validation on the cloud snippet download and update actions in the Cloud_Search_List_Table class. This makes it possible for unauthenticated attackers to force logged-in administrators to download or update cloud snippets without their consent via a crafted request, granted they can trick an administrator into visiting a malicious page.

NVD CVE-2026-1785Wordfence advisorygithub.comPlugin source

high 8.0 CVE-2025-13035 · published 2025-11-19

Remote code execution in Code Snippets (3.9.1 and older)

Affected
3.9.1 and older
Fixed in
3.9.2 *
Access needed (per CVSS)
Needs a low-level account (e.g. subscriber); someone on the site has to click a link or open a page
Range from
CVE record (the advisory publisher) · score by Wordfence
Details from the advisory

The Code Snippets plugin for WordPress is vulnerable to PHP Code Injection in all versions up to, and including, 3.9.1. This is due to the plugin's use of extract() on attacker-controlled shortcode attributes within the `evaluate_shortcode_from_flat_file` method, which can be used to overwrite the `$filepath` variable and subsequently passed to require_once. This makes it possible for authenticated attackers, with Contributor-level access and above, to execute arbitrary PHP code on the server via the `[code_snippet]` shortcode using PHP filter chains granted they can trick an administrator into enabling the "Enable file-based execution" setting and creating at least one active Content snippet.

NVD CVE-2025-13035Wordfence advisoryCode change (fix)Plugin source

high 8.8 CVE-2023-47666 · published 2023-11-18

Cross-site request forgery (CSRF) in Code Snippets (3.5.0 and older)

Affected
3.5.0 and older
Fixed in
3.6.0
Access needed (per CVSS)
No login needed; someone on the site has to click a link or open a page
Range from
CVE record (the advisory publisher) · score by NVD
Details from the advisory

Cross-Site Request Forgery (CSRF) vulnerability in Code Snippets Pro Code Snippets.This issue affects Code Snippets: from n/a through 3.5.0.

NVD CVE-2023-47666Patchstack advisory

medium 6.1 CVE-2022-25617 · published 2022-05-18

Reflected cross-site scripting (XSS) in Code Snippets (2.14.3 and older)

Affected
2.14.3 and older
Fixed in
2.14.4 *
Access needed (per CVSS)
No login needed; someone on the site has to click a link or open a page
Range from
CVE record (the advisory publisher) · score by NVD
Details from the advisory

Reflected Cross-Site Scripting (XSS) vulnerability in Code Snippets plugin <= 2.14.3 at WordPress via &orderby vulnerable parameter.

NVD CVE-2022-25617Patchstack advisorywordpress.org

medium 6.1 CVE-2021-25008 · published 2022-01-24

Reflected cross-site scripting (XSS) in Code Snippets (older than 2.14.3)

Affected
older than 2.14.3
Fixed in
2.14.3
Access needed (per CVSS)
No login needed; someone on the site has to click a link or open a page
Range from
NVD analysis · score by NVD
Details from the advisory

The Code Snippets WordPress plugin before 2.14.3 does not escape the snippets-safe-mode parameter before outputting it back in attributes, leading to a Reflected Cross-Site Scripting issue

NVD CVE-2021-25008WPScan advisory

high 8.8 CVE-2020-8417 · published 2020-01-28

Cross-site request forgery (CSRF) in Code Snippets (older than 2.14.0)

Affected
older than 2.14.0
Fixed in
2.14.0
Access needed (per CVSS)
No login needed; someone on the site has to click a link or open a page
Range from
NVD analysis · score by NVD
Details from the advisory

The Code Snippets plugin before 2.14.0 for WordPress allows CSRF because of the lack of a Referer check on the import menu.

NVD CVE-2020-8417wordpress.orgwpvulndb.com

Recent activity

Where this data comes from

Badge for your site or docs (states facts with a date, not a verdict):
Code Snippets vulnerability status badge
<a href="https://laskyr.com/plugins/code-snippets"><img src="https://laskyr.com/plugins/code-snippets/badge.svg" alt="Code Snippets vulnerability status"></a>

← Check another plugin · Free hacked-site scan

Site hacked? Get help now
Run free scan Fix it now ($499) Send a message

First hour checklist

If the site was just hacked, read the emergency kit before you delete files. The page is free. Email is optional.

Read the emergency kit