Describe the bug
OVAL signals deprecation to content authors through a sch:report, so that validating a definition using a deprecated test emits a warning while still passing. The convention is established and used correctly in places, for example apache-def:httpd_test:
<sch:rule context="apache-def:httpd_test">
<sch:report test="true()">DEPRECATED TEST: <sch:value-of select="name()"/> ID: <sch:value-of select="@id"/></sch:report>
</sch:rule>
114 elements carrying oval:deprecated_info across 20 schemas have no such report. Content using them validates silently, so authors get no signal that they are building on a deprecated test.
Replication Steps
- Extract and compile the Schematron for any schema below.
- Validate a document using one of its deprecated tests, for example
win-def:activedirectory_test.
- No
svrl:successful-report is produced, so no deprecation warning reaches the author.
Expected behavior
Every element declaring oval:deprecated_info is matched by a rule with a sch:report, so validation surfaces the deprecation.
Content
| Schema |
Missing reports |
windows |
20 |
sharepoint |
15 |
solaris |
13 |
android |
13 |
asa |
9 |
unix |
5 |
macos |
5 |
hpux |
5 |
ios |
4 |
junos |
3 |
iosxe |
3 |
esx |
3 |
catos |
3 |
apple-ios |
3 |
aix |
3 |
pixos |
2 |
linux |
2 |
netconf |
1 |
independent |
1 |
freebsd |
1 |
Several of these platforms are deprecated in full (Android, Apple iOS, CatOS, ESX, FreeBSD, HP-UX), so every test they offer should be reporting.
A single union-context rule per schema covers all of its deprecated elements compactly:
<sch:pattern id="win-def_declared_deprecations">
<sch:rule context="win-def:activedirectory_test | win-def:auditeventpolicy_test | ...">
<sch:report test="true()">DEPRECATED ELEMENT: <sch:value-of select="name()"/> ID: <sch:value-of select="@id"/></sch:report>
</sch:rule>
</sch:pattern>
Care is needed to list only elements that are themselves deprecated. An element whose child entity carries the deprecated_info should not be reported, or ordinary content using that element gets a spurious warning.
OVAL details
- Schema: all 20 listed above
Describe the bug
OVAL signals deprecation to content authors through a
sch:report, so that validating a definition using a deprecated test emits a warning while still passing. The convention is established and used correctly in places, for exampleapache-def:httpd_test:114 elements carrying
oval:deprecated_infoacross 20 schemas have no such report. Content using them validates silently, so authors get no signal that they are building on a deprecated test.Replication Steps
win-def:activedirectory_test.svrl:successful-reportis produced, so no deprecation warning reaches the author.Expected behavior
Every element declaring
oval:deprecated_infois matched by a rule with asch:report, so validation surfaces the deprecation.Content
windowssharepointsolarisandroidasaunixmacoshpuxiosjunosiosxeesxcatosapple-iosaixpixoslinuxnetconfindependentfreebsdSeveral of these platforms are deprecated in full (Android, Apple iOS, CatOS, ESX, FreeBSD, HP-UX), so every test they offer should be reporting.
A single union-context rule per schema covers all of its deprecated elements compactly:
Care is needed to list only elements that are themselves deprecated. An element whose child entity carries the
deprecated_infoshould not be reported, or ordinary content using that element gets a spurious warning.OVAL details