<xsd:element name="rpminfo_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The rpminfo_state element defines the different information that can be used to evaluate the specified rpm. This includes the architecture, epoch number, and version numbers. Most of this information can be obtained through the rpm function. Please refer to the individual elements in the schema for more details about what each represents.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This is the package name to check.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="rpmstename" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="linux-def:rpminfo_state/linux-def:name">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the name entity of a rpminfo_state should be 'string'</sch:assert>
<sch:assert test="not(@operation) or @operation='equals' or @operation='not equal' or @operation='pattern match'">
<sch:value-of select="../@id" /> - operation attribute for the name entity of a rpminfo_state should be 'equals', 'not equal', or 'pattern match'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="arch" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This is the architecture for which the RPM was built, like : i386, ppc, sparc, noarch. In the case of an apache rpm named httpd-2.0.40-21.11.4.i686.rpm, this value would be i686.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="rpmstearch" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="linux-def:rpminfo_state/linux-def:arch">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the arch entity of a rpminfo_state should be 'string'</sch:assert>
<sch:assert test="not(@operation) or @operation='equals' or @operation='not equal' or @operation='pattern match'">
<sch:value-of select="../@id" /> - operation attribute for the arch entity of a rpminfo_state should be 'equals', 'not equal', or 'pattern match'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="epoch" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This is the epoch number of the RPM, this is used as a kludge for version-release comparisons where the vendor has done some kind of re-numbering or version forking. For a null epoch (or '(none)' as returned by rpm) is equivalent to '0'. This number is not revealed by a normal query of the RPM's information -- you must use a formatted rpm query command to gather this data from the command line, like so. For an already-installed RPM: rpm -q --qf '%{EPOCH}\n' installed_rpm For an RPM file that has not been installed: rpm -qp --qf '%{EPOCH}\n' rpm_file</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="rpmsteepoch" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="linux-def:rpminfo_state/linux-def:epoch">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the epoch entity of a rpminfo_state should be 'string'</sch:assert>
<sch:assert test="not(@operation) or @operation='equals' or @operation='not equal' or @operation='greater than' or @operation='greater than or equal' or @operation='less than' or @operation='less than or equal' or @operation='pattern match'">
<sch:value-of select="../@id" /> - operation attribute for the epoch entity of a rpminfo_state should be 'equals', 'not equal', 'greater than', 'greater than or equal', 'less than', 'less than or equal', or 'pattern match'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="release" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This is the release number of the build, changed by the vendor/builder.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="rpmsterelease" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="linux-def:rpminfo_state/linux-def:release">
<sch:assert test="not(@datatype) or @datatype='string' or @datatype='version'">
<sch:value-of select="../@id" /> - datatype attribute for the release entity of a rpminfo_state should be 'string'</sch:assert>
<sch:assert test="not(@operation) or @operation='equals' or @operation='not equal' or @operation='greater than' or @operation='greater than or equal' or @operation='less than' or @operation='less than or equal' or @operation='pattern match'">
<sch:value-of select="../@id" /> - operation attribute for the release entity of a rpminfo_state should be 'equals', 'not equal', 'greater than', 'greater than or equal', 'less than', 'less than or equal', or 'pattern match'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="version" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This is the version number of the build. In the case of an apache rpm named httpd-2.0.40-21.11.4.i686.rpm, this value would be 21.11.4.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="rpmsteversion" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="linux-def:rpminfo_state/linux-def:version">
<sch:assert test="not(@datatype) or @datatype='string' or @datatype='version'">
<sch:value-of select="../@id" /> - datatype attribute for the version entity of a rpminfo_state should be 'string'</sch:assert>
<sch:assert test="not(@operation) or @operation='equals' or @operation='not equal' or @operation='greater than' or @operation='greater than or equal' or @operation='less than' or @operation='less than or equal' or @operation='pattern match'">
<sch:value-of select="../@id" /> - operation attribute for the version entity of a rpminfo_state should be 'equals', 'not equal', 'greater than', 'greater than or equal', 'less than', 'less than or equal', or 'pattern match'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="evr" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This represents the epoch, version, and release fields as a single version string. It has the form "EPOCH:VERSION-RELEASE". Note that a null epoch (or '(none)' as returned by rpm) is equivalent to '0' and would hence have the form 0:VERSION-RELEASE. Comparisons involving this datatype should follow the algorithm of librpm's rpmvercmp() function.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="rpmsteevr" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="linux-def:rpminfo_state/linux-def:evr">
<sch:assert test="not(@datatype) or @datatype='evr_string'">
<sch:value-of select="../@id" /> - datatype attribute for the evr entity of a rpminfo_state should be 'evr_string'</sch:assert>
<sch:assert test="not(@operation) or @operation='equals' or @operation='not equal' or @operation='greater than' or @operation='greater than or equal' or @operation='less than' or @operation='less than or equal' or @operation='pattern match'">
<sch:value-of select="../@id" /> - operation attribute for the evr entity of a rpminfo_state should be 'equals', 'not equal', 'greater than', 'greater than or equal', 'less than', 'less than or equal', or 'pattern match'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="signature_keyid" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This field contains the 64-bit PGP key ID that the RPM issuer (generally the original operating system vendor) uses to sign the key. Note that the value should NOT contain a hyphen to seperat the higher 32-bits from the lower 32-bits. It should simply be a 16 character hex string. PGP is used to verify the authenticity and integrity of the RPM being considered. Software packages and patches are signed cryptographically to allow administrators to allay concerns that the distribution mechanism has been compromised, whether that mechanism is web site, FTP server, or even a mirror controlled by a hostile party. OVAL uses this field most of all to confirm that the package installed on the system is that shipped by the vendor, since comparing package version numbers against patch announcements is only programmatically valid if the installed package is known to contain the patched code.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="rpmstesignaturekeyid" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="linux-def:rpminfo_state/linux-def:signature_keyid">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the signature_keyid entity of a rpminfo_state should be 'string'</sch:assert>
<sch:assert test="not(@operation) or @operation='equals' or @operation='not equal' or @operation='pattern match'">
<sch:value-of select="../@id" /> - operation attribute for the signature_keyid entity of a rpminfo_state should be 'equals', 'not equal', or 'pattern match'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
|