Skip to content

Commit 51e7f61

Browse files
authored
Merge pull request #1369 from dehuo0/maint-1.2
Add WRLinux 1019 support
2 parents 39e91cf + 5b97ee3 commit 51e7f61

File tree

2 files changed

+47
-0
lines changed

2 files changed

+47
-0
lines changed

cpe/openscap-cpe-dict.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,4 +210,8 @@
210210
<title xml:lang="en-us">Wind River Linux 8</title>
211211
<check system="http://oval.mitre.org/XMLSchema/oval-definitions-5" href="openscap-cpe-oval.xml">oval:org.open-scap.cpe.wrlinux:def:8</check>
212212
</cpe-item>
213+
<cpe-item name="cpe:/o:windriver:wrlinux:1019">
214+
<title xml:lang="en-us">Wind River Linux 1019</title>
215+
<check system="http://oval.mitre.org/XMLSchema/oval-definitions-5" href="openscap-cpe-oval.xml">oval:org.open-scap.cpe.wrlinux:def:1019</check>
216+
</cpe-item>
213217
</cpe-list>

cpe/openscap-cpe-oval.xml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -638,6 +638,19 @@
638638
<criterion comment="Wind River Linux version is 8." test_ref="oval:org.open-scap.cpe.wrlinux:tst:8" />
639639
</criteria>
640640
</definition>
641+
<definition class="inventory" id="oval:org.open-scap.cpe.wrlinux:def:1019" version="1" >
642+
<metadata>
643+
<title>Wind River Linux 1019</title>
644+
<affected family="unix">
645+
<platform>Wind River Linux 1019</platform>
646+
</affected>
647+
<reference ref_id="cpe:/o:windriver:wrlinux:1019" source="CPE"/>
648+
<description>The operating system installed on the system is Wind River Linux 1019</description>
649+
</metadata>
650+
<criteria>
651+
<criterion comment="Wind River Linux version is 1019." test_ref="oval:org.open-scap.cpe.wrlinux:tst:1019" />
652+
</criteria>
653+
</definition>
641654
</definitions>
642655
<tests>
643656
<rpmverifyfile_test check_existence="at_least_one_exists" id="oval:org.open-scap.cpe.rhel:tst:2" version="1" check="at least one" comment="/etc/redhat-release is provided by redhat-release package"
@@ -897,6 +910,17 @@
897910
<object object_ref="oval:org.open-scap.cpe.wrlinux-release:obj:2"/>
898911
<state state_ref="oval:org.open-scap.cpe.wrlinux-release:ste:8"/>
899912
</textfilecontent54_test>
913+
<textfilecontent54_test
914+
id="oval:org.open-scap.cpe.wrlinux:tst:1019"
915+
check="all"
916+
check_existence="all_exist"
917+
comment="Check /etc/os-release for VERSION 1019 specification."
918+
version="1"
919+
xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent"
920+
>
921+
<object object_ref="oval:org.open-scap.cpe.wrlinux-release:obj:3"/>
922+
<state state_ref="oval:org.open-scap.cpe.wrlinux-release:ste:10"/>
923+
</textfilecontent54_test>
900924
<rpminfo_test check="all" check_existence="only_one_exists" comment="redhat-release-virtualization-host RPM package is installed" id="oval:org.open-scap.cpe.rhevh:tst:1" version="1" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#linux">
901925
<object object_ref="oval:org.open-scap.cpe.rhevh:obj:1" />
902926
</rpminfo_test>
@@ -946,6 +970,17 @@
946970
<pattern operation="pattern match">^VERSION=.([[:digit:]]*)</pattern>
947971
<instance operation="greater than or equal" datatype="int">1</instance>
948972
</textfilecontent54_object>
973+
<textfilecontent54_object
974+
id="oval:org.open-scap.cpe.wrlinux-release:obj:3"
975+
comment="Check VERSION specification in /etc/os-release."
976+
version="1"
977+
xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent"
978+
>
979+
<path>/etc</path>
980+
<filename>os-release</filename>
981+
<pattern operation="pattern match">^VERSION=.(\d*.\d*)</pattern>
982+
<instance operation="greater than or equal" datatype="int">1</instance>
983+
</textfilecontent54_object>
949984
<rpminfo_object id="oval:org.open-scap.cpe.rhevh:obj:1" version="1" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#linux">
950985
<name>redhat-release-virtualization-host</name>
951986
</rpminfo_object>
@@ -1120,6 +1155,14 @@
11201155
>
11211156
<subexpression operation="pattern match">8</subexpression>
11221157
</textfilecontent54_state>
1158+
<textfilecontent54_state
1159+
id="oval:org.open-scap.cpe.wrlinux-release:ste:10"
1160+
comment="Check the /etc/os-release file for VERSION 1019 specification."
1161+
version="1"
1162+
xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent"
1163+
>
1164+
<subexpression operation="pattern match">10.19</subexpression>
1165+
</textfilecontent54_state>
11231166
<textfilecontent54_state id="oval:org.open-scap.cpe.rhevh:ste:2" version="1" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent">
11241167
<subexpression operation="pattern match">7</subexpression>
11251168
</textfilecontent54_state>

0 commit comments

Comments
 (0)