Automatic WordPress updates, security releases included, are turned off

tx0/php:wp-auto-update-disabledstrictwarningsecurity/configurationdepth fastsecurity, cwe-1104

What it finds

Automatic WordPress updates, security releases included, are turned off

Example from the rule's tests
<?phpdefine('AUTOMATIC_UPDATER_DISABLED', true);tx0 reports: AUTOMATIC_UPDATER_DISABLED turns off automatic updatesdefine('WP_AUTO_UPDATE_CORE', false);tx0 reports: WP_AUTO_UPDATE_CORE turns off automatic updatesdefine('WP_AUTO_UPDATE_CORE', 'minor');define('WP_AUTO_UPDATE_CORE', true);define('AUTOMATIC_UPDATER_DISABLED', false);
Highlighted lines are the ones tx0 reports, with its message under each; the other lines are left alone.

Turn it on, off or suppress it

The rule runs from the strict tier up. To turn it on in a lower tier, give it a level in tx0.toml:

tx0.toml
[rules]
"tx0/php:wp-auto-update-disabled" = "warning"

To keep one finding, suppress it with a reason. tx0 suppress ID --reason "..." writes the comment on the line before the code:

// tx0: ignore[tx0/php:wp-auto-update-disabled] reason="..."

tx0 explain tx0/php:wp-auto-update-disabled shows the same in the terminal. Found a false positive? Report it.