Skip to content

Commit

Permalink
Merge pull request #484 from GSA/rev5-ssp-sch-xspec-ipv4-has-non-plac…
Browse files Browse the repository at this point in the history
…eholder

Rev 5 SSP - fix ipv4-has-non-placeholder in Schematron and XSpec
  • Loading branch information
dimitri-zhurkin-vitg authored Aug 30, 2023
2 parents c203f7a + b7bba5c commit 5f12e5c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,6 @@
<param id="ac-1_prm_1">
<label>organization-defined personnel or roles</label>
</param>
<param id="ac-01_odp.01">
<label>personnel or roles</label>
<guideline>
<p>personnel or roles to whom the access control policy is to be disseminated is/are defined;</p>
</guideline>
</param>
<param id="ac-01_odp.02">
<label>personnel or roles</label>
<guideline>
Expand Down
10 changes: 3 additions & 7 deletions src/validations/rules/rev5/ssp.sch
Original file line number Diff line number Diff line change
Expand Up @@ -2309,13 +2309,9 @@
feddoc:documentation-reference="OMB Mandate M-21-07"
id="ipv4-has-non-placeholder"
role="error"
test="
if (oscal:prop[@name eq 'ipv4-address'])
then
(oscal:prop[matches(@value, '0.0.0.0')])
else
(false())"><xsl:value-of
select="oscal:prop[@name = 'asset-id']/@value" /> must have an appropriate IPv4 value.</sch:assert>
test="oscal:prop[@name eq 'ipv4-address']/@value ne '0.0.0.0'">
<xsl:value-of
select="oscal:prop[@name = 'asset-id']/@value" /> must have an appropriate IPv4 value.</sch:assert>
<sch:let
name="IPv6-regex"
value="
Expand Down
4 changes: 2 additions & 2 deletions src/validations/test/rules/rev5/ssp.xspec
Original file line number Diff line number Diff line change
Expand Up @@ -6288,7 +6288,7 @@
xmlns="http://csrc.nist.gov/ns/oscal/1.0">
<prop
name="ipv4-address"
value="0.0.0.0" />
value="10.2.2.2" />
</inventory-item>
</x:context>
<x:expect-not-assert
Expand All @@ -6303,7 +6303,7 @@
xmlns="http://csrc.nist.gov/ns/oscal/1.0">
<prop
name="ipv4-address"
value="10.2.2.2" />
value="0.0.0.0" />
</inventory-item>
</x:context>
<x:expect-assert
Expand Down

0 comments on commit 5f12e5c

Please sign in to comment.