<xsd:element name="variable">
<xsd:annotation>
<xsd:documentation>A variable element is a reference to some value that can be used by tests to compare against. One of the main benefits of variables is that they allow tests to be compared to user-defined policy. For example, an OVAL test might check to see if a password is at least a certain number of characters, but this number depends upon the individual policy of the user. To solve this, the test for password length can be written to refer to a variable element. This variable element refers to an external value (linked by the id) that can be passed in by the user when the OVAL definition is evaluated. The required id attribute uniquely identifies each variable. It is of the form var-#. The three letter code 'var' is followed by an unspecified number of digits, for example 'var-123'. The required datatype attribute specifies the type of value to expect in the external source. The required source attribute determines where the value of the variable was be found, either from some external source or as a constant declaration. The required comment attribute provides a short description of the variable.
</xsd:documentation>
<xsd:appinfo>
<cardinality>1-n</cardinality>
<attributes>id, [version], datatype, source, comment</attributes>
<content>none</content>
<parent_elements>variables</parent_elements>
<child_elements>[value]</child_elements>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:sequence>
<xsd:element ref="oval_results:value" minOccurs="0" maxOccurs="1" />
</xsd:sequence>
<xsd:attribute name="id" type="oval_results:varid" use="required" />
<xsd:attribute name="version" type="oval_results:versionType" use="optional" default="1" />
<xsd:attribute name="datatype" type="oval_results:datatypes" use="required" />
<xsd:attribute name="source" type="oval_results:variable_source" use="required" />
<xsd:attribute name="comment" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
|