PluginCheck.CodeAnalysis.SettingSanitization.register_settingMissing
Setting is missing a sanitization callback
A registered setting does not define a sanitization callback.
Why It Shows Up
Plugin Check found `register_setting()` without a `sanitize_callback` or equivalent validation strategy.
Why It Matters
Settings can be saved by administrators and then displayed or used later. Without sanitization, invalid or unsafe values can persist.
How to Fix
- Pass a `sanitize_callback` in the `register_setting()` arguments.
- Use built-in sanitizers for simple values and custom callbacks for structured settings.
- Validate allowed values and return a safe default when input is invalid.
Affected Plugins
| Rank | Plugin | Score | Errors | Warnings | Installs | Added | Updated | Top Issue |
|---|---|---|---|---|---|---|---|---|
| #1001 | Block Emails for WooCommerce Checkout | 91 | 4 | 3 | 700 | Setting is missing a sanitization callback | ||
| #1002 | Bootstrap Blocks | 91 | 8 | 30 | 10k+ | Non-prefixed global variable | ||
| #1003 | Admin Taxonomy Filter | 92 | 3 | 3 | 5k+ | Non-prefixed class | ||
| #1004 | Auto SRI | 92 | 4 | 1 | 500 | wp function not compatible with requires wp | ||
| #1005 | Expire Passwords | 92 | 7 | 2 | 500 | Missing Translators Comment | ||
| #1006 | FMTC Affiliate Disclosure | 92 | 5 | 0 | 1k+ | Missing Arg Domain | ||
| #1007 | Version Control for jQuery | 92 | 5 | 1 | 6k+ | Offloaded Content | ||
| #1008 | WOOF by Category | 92 | 3 | 7 | 1k+ | trademarked term | ||
| #1009 | Core Rollback | 93 | 5 | 2 | 10k+ | wp function not compatible with requires wp | ||
| #1010 | DCO Insert Analytics Code | 93 | 2 | 0 | 4k+ | Setting is missing a sanitization callback | ||
| #1011 | No Self Ping | 93 | 2 | 0 | 10k+ | Setting is missing a sanitization callback | ||
| #1012 | Send Emails with Resend | 93 | 3 | 0 | 900 | Setting is missing a sanitization callback | ||
| #1013 | Showcase Payment Options (icons) | 93 | 2 | 3 | 1k+ | trademarked term | ||
| #1014 | Use Administrator Password | 93 | 2 | 4 | 900 | Non-prefixed hook name |