This issue has been created
There is 1 update.
 
 
XWiki Platform / cid:jira-generated-image-avatar-8bfff89f-fa84-4bd8-8684-d17e69f2ee3c XWIKI-25170 Open

The Scan Enabled checkbox of the Security Vulnerabilities administration is checked when no value is saved, even if the scan is disabled in xwiki.properties

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-0eb4d332-2f72-4966-bddd-b364e90b5fb9 Manuel Leduc created this issue on 05/Oct/26 10:35
 
Summary: The Scan Enabled checkbox of the Security Vulnerabilities administration is checked when no value is saved, even if the scan is disabled in xwiki.properties
Issue Type: cid:jira-generated-image-avatar-8bfff89f-fa84-4bd8-8684-d17e69f2ee3c Bug
Affects Versions: 15.5-rc-1, 18.7.0
Assignee: Unassigned
Components: Extension - Security
Created: 05/Oct/26 10:35
Priority: cid:jira-generated-image-static-major-2227e653-6b58-46e5-b4a4-5044ad71e632 Major
Reporter: Manuel Leduc
Description:

Steps to reproduce

  1. In xwiki.properties, set extension.security.scan.enabled = false and restart XWiki.
  2. Do not save anything in the "Security Vulnerabilities" section of the global administration.
  3. Open that administration section.

Expected result

The "Scan Enabled" checkbox shows the value that is actually used, so it is unchecked.

Actual result

The "Scan Enabled" checkbox is checked, but the scan is disabled: the log shows Extension security scan disabled. at every scheduled run.

Cause

The configuration only reads the scanEnabled property of XWiki.Extension.Security.Code.Config when a value is saved for it, and falls back to extension.security.scan.enabled from xwiki.properties otherwise. This matches the documentation ("When a value is not filled in the administration UI, the corresponding xwiki.properties value is used"). However, the scanEnabled field is created with a default value of true (in ConfigClassMandatoryInitializer), so when nothing is saved the form displays the field default, not the value in use.

Another consequence: once the section is saved, a checkbox always stores 1 or 0 and can never be "not filled" again. From then on, the xwiki.properties value is ignored with no way to go back from the UI.

Possible fixes: display the effective value when nothing is saved, or use a select with an explicit "default (from xwiki.properties)" option, so that falling back to xwiki.properties can still be expressed from the UI.

Reported on the forum: https://forum.xwiki.org/t/on-extension-security-scan-enabled/18909

 
 

1 update

 
cid:jira-generated-image-avatar-0eb4d332-2f72-4966-bddd-b364e90b5fb9 Changes by Manuel Leduc on 05/Oct/26 10:37
 
Labels: onboarding