During desired nodes updates the system validates that the provided node settings are valid in order to avoid boot looping issues. If one of the node settings depends on a secure setting, the validation fails even when the secure setting is present and correct.
server/src/main/java/org/elasticsearch/cluster/desirednodes/DesiredNodesSettingsValidator.java
if (node.version().after(Version.CURRENT)) {
            return;
        }
        Settings settings = node.settings();
        
        
        
        if (settings.hasValue(NODE_PROCESSORS_SETTING.getKey())) {
            int minProcessors = node.roundedDownMinProcessors();
            Integer roundedUpMaxProcessors = node.roundedUpMaxProcessors();
            int maxProcessors = roundedUpMaxProcessors == null ? minProcessors : roundedUpMaxProcessors;
            Setting.doubleSetting(
                NODE_PROCESSORS_SETTING.getKey(),
                minProcessors,
                Double.MIN_VALUE,
                maxProcessors,
                Setting.Property.NodeScope
            ).get(settings);
            final Settings.Builder updatedSettings = Settings.builder().put(settings);
            updatedSettings.remove(NODE_PROCESSORS_SETTING.getKey());
            settings = updatedSettings.build();
        }
        clusterSettings.validate(settings, true);
    }
}