<?xml version="1.0"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:oval-sc="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5" xmlns:ios-sc="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#ios" xmlns:sch="http://purl.oclc.org/dsdl/schematron" targetNamespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#ios" elementFormDefault="qualified" version="5.4">
     <xsd:import namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5" schemaLocation="oval-system-characteristics-schema.xsd"/>
     <xsd:annotation>
          <xsd:documentation>The following is a description of the elements, types, and attributes that compose the IOS specific system characteristic items found in Open Vulnerability and Assessment Language (OVAL). Each item is an extension of the standard item element defined in the Core System Characteristic Schema. Through extension, each item inherits a set of elements and attributes that are shared amongst all OVAL Items. Each item is described in detail and should provide the information necessary to understand what each element and attribute represents. This document is intended for developers and assumes some familiarity with XML. A high level description of the interaction between the different tests and their relationship to the Core System Characteristic Schema is not outlined here.</xsd:documentation>
          <xsd:documentation>The OVAL Schema is maintained by The Mitre Corporation and developed by the public OVAL Community. For more information, including how to get involved in the project and how to submit change requests, please visit the OVAL website at http://oval.mitre.org.</xsd:documentation>
          <xsd:appinfo>
               <schema>IOS System Characteristics</schema>
               <version>5.4</version>
               <date>4/1/2008 10:41:42 AM</date>
                <terms_of_use>Copyright (c) 2002-2008, The MITRE Corporation. All rights reserved.  The contents of this file are subject to the terms of the OVAL License located at http://oval.mitre.org/oval/about/termsofuse.html. See the OVAL License for the specific language governing permissions and limitations for use of this schema.  When distributing copies of the OVAL Schema, this license header must be included.</terms_of_use>
                <sch:title>schematron validation of the Cisco IOS portion of an OVAL System Characteristics file</sch:title>
               <sch:ns prefix="oval-sc" uri="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5"/>
               <sch:ns prefix="ios-sc" uri="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#ios"/>
          </xsd:appinfo>
     </xsd:annotation>
     <!-- =============================================================================== -->
     <!-- ========================  IOS GLOBAL ITEM   =================================== -->
     <!-- =============================================================================== -->
     <xsd:element name="global_item" substitutionGroup="oval-sc:item">
          <xsd:annotation>
               <xsd:documentation>Sotres information about the existence of a particular line in the ios config file under the global context</xsd:documentation>
          </xsd:annotation>
          <xsd:complexType>
               <xsd:complexContent>
                    <xsd:extension base="oval-sc:ItemType">
                         <xsd:sequence>
                              <xsd:element name="global_command" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="globalitemglobal_command">
                                                  <sch:rule context="ios-sc:global_item/ios-sc:global_command">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the global_command entity of a global_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                         </xsd:sequence>
                    </xsd:extension>
               </xsd:complexContent>
          </xsd:complexType>
     </xsd:element>
     <!-- =============================================================================== -->
     <!-- ========================  IOS INTERFACE ITEM  ================================= -->
     <!-- =============================================================================== -->
     <xsd:element name="interface_item" substitutionGroup="oval-sc:item">
          <xsd:annotation>
               <xsd:documentation/>
          </xsd:annotation>
          <xsd:complexType>
               <xsd:complexContent>
                    <xsd:extension base="oval-sc:ItemType">
                         <xsd:sequence>
                              <xsd:element name="name" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosinterfaceitemname">
                                                  <sch:rule context="ios-sc:interface_item/ios-sc:name">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the name entity of a global_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="ip_directed_broadcast_command" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosinterfaceitemip_directed_broadcast_command">
                                                  <sch:rule context="ios-sc:interface_item/ios-sc:ip_directed_broadcast_command">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the ip_directed_broadcast_command entity of a global_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="no_ip_directed_broadcast_command" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosinterfaceitemno_ip_directed_broadcast_command">
                                                  <sch:rule context="ios-sc:interface_item/ios-sc:no_ip_directed_broadcast_command">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the no_ip_directed_broadcast_command entity of a global_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="proxy_arp_command" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosinterfaceitemproxy_arp_command">
                                                  <sch:rule context="ios-sc:interface_item/ios-sc:proxy_arp_command">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the proxy_arp_command entity of a global_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="shutdown_command" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosinterfaceitemshutdown_command">
                                                  <sch:rule context="ios-sc:interface_item/ios-sc:shutdown_command">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the shutdown_command entity of a global_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                         </xsd:sequence>
                    </xsd:extension>
               </xsd:complexContent>
          </xsd:complexType>
     </xsd:element>
     <!-- =============================================================================== -->
     <!-- ============================  IOS LINE ITEM  ================================== -->
     <!-- =============================================================================== -->
     <xsd:element name="line_item" substitutionGroup="oval-sc:item">
          <xsd:annotation>
               <xsd:documentation>Stores the properties of specific lines in the ios config file.</xsd:documentation>
          </xsd:annotation>
          <xsd:complexType>
               <xsd:complexContent>
                    <xsd:extension base="oval-sc:ItemType">
                         <xsd:sequence>
                              <xsd:element name="show_subcommand" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation>The name of the SHOW sub-command.</xsd:documentation>
                                        <xsd:appinfo>
                                             <sch:pattern id="lineitemshow_subcommand">
                                                  <sch:rule context="ios-sc:line_item/ios-sc:show_subcommand">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the show_subcommand entity of a line_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="config_line" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation>The value returned from by the specified SHOW sub-command.</xsd:documentation>
                                        <xsd:appinfo>
                                             <sch:pattern id="lineitemconfig_line">
                                                  <sch:rule context="ios-sc:line_item/ios-sc:config_line">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the config_line entity of a line_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                         </xsd:sequence>
                    </xsd:extension>
               </xsd:complexContent>
          </xsd:complexType>
     </xsd:element>
     <!-- =============================================================================== -->
     <!-- ==========================  IOS SNMP ITEM   =================================== -->
     <!-- =============================================================================== -->
     <xsd:element name="snmp_item" substitutionGroup="oval-sc:item">
          <xsd:annotation>
               <xsd:documentation>Stores results from collecting lines under the global context associated with snmp.</xsd:documentation>
          </xsd:annotation>
          <xsd:complexType>
               <xsd:complexContent>
                    <xsd:extension base="oval-sc:ItemType">
                         <xsd:sequence>
                              <xsd:element name="access_list" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="snmpitemaccess_list">
                                                  <sch:rule context="ios-sc:snmp_item/ios-sc:access_list">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the access_list entity of a snmp_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="community_name" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation/>
                                        <xsd:appinfo>
                                             <sch:pattern id="snmpitemcommunity_name">
                                                  <sch:rule context="ios-sc:snmp_item/ios-sc:community_name">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the community_name entity of a snmp_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                         </xsd:sequence>
                    </xsd:extension>
               </xsd:complexContent>
          </xsd:complexType>
     </xsd:element>
     <!-- =============================================================================== -->
     <!-- ==========================  IOS TCLSH ITEM   =================================== -->
     <!-- =============================================================================== -->
     <xsd:element name="tclsh_item" substitutionGroup="oval-sc:item">
          <xsd:annotation>
               <xsd:documentation>The tclsh item holds information about the availability of tcl on the IOS operating system. It extends the standard ItemType as defined in the oval-system-characteristics schema and one should refer to the ItemType description for more information.</xsd:documentation>
          </xsd:annotation>
          <xsd:complexType>
               <xsd:complexContent>
                    <xsd:extension base="oval-sc:ItemType">
                         <xsd:sequence>
                              <xsd:element name="available" type="oval-sc:EntityItemBoolType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation>This boolean entity describes whether TCLSH is available on the system. A value of true means that TCLSH is available. Per Cisco documentation, the accepted way to see if the device supports tcl functionality is to enter the tcl shell. If the attempt results in a tcl prompt then the device supports tclsh and has it enabled.</xsd:documentation>
                                        <xsd:appinfo>
                                             <sch:pattern id="tclshitemavailable">
                                                  <sch:rule context="ios-sc:tclsh_item/ios-sc:available">
                                                       <sch:assert test="not(@datatype) or @datatype='boolean'">item <sch:value-of select="../@id"/> - datatype attribute for the available entity of a tclsh_item should be 'boolean'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                         </xsd:sequence>
                    </xsd:extension>
               </xsd:complexContent>
          </xsd:complexType>
     </xsd:element>
     <!-- =============================================================================== -->
     <!-- ========================  IOS VERSION ITEM  =================================== -->
     <!-- =============================================================================== -->
     <xsd:element name="version_item" substitutionGroup="oval-sc:item">
          <xsd:annotation>
               <xsd:documentation>The version item holds information about the version of the IOS operating system. It extends the standard ItemType as defined in the oval-system-characteristics schema and one should refer to the ItemType description for more information.</xsd:documentation>
          </xsd:annotation>
          <xsd:complexType>
               <xsd:complexContent>
                    <xsd:extension base="oval-sc:ItemType">
                         <xsd:sequence>
                              <xsd:element name="major_release" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation>The major_release is a combination of train and rebuild information and is used by Cisco advisories to identify major releases.</xsd:documentation>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosversionitemmajor_release">
                                                  <sch:rule context="ios-sc:version_item/ios-sc:major_release">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the major_release entity of a version_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="train_number" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation>The train number is the dotted version that starts a version string. For example the version string 12.2(3)T has a train number of 12.2.</xsd:documentation>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosversionitemtrain_number">
                                                  <sch:rule context="ios-sc:version_item/ios-sc:train_number">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the train_number entity of a version_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="train_identifier" type="ios-sc:EntityItemTrainIdentifierType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation>The train identifier is the type of Train. For example the version string 12.2(3)T has a train identifier of T. Please see the EntityItemTrainIdentifierType for more information about the different train identifiers.</xsd:documentation>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosversionitemtrain_identifier">
                                                  <sch:rule context="ios-sc:version_item/ios-sc:train_identifier">
                                                       <sch:assert test="not(@datatype) or @datatype='string'">item <sch:value-of select="../@id"/> - datatype attribute for the train_identifier entity of a version_item should be 'string'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                              <xsd:element name="version_string" type="oval-sc:EntityItemStringType" minOccurs="0" maxOccurs="1">
                                   <xsd:annotation>
                                        <xsd:documentation>The version entity holds the raw string output of a 'show version' command.</xsd:documentation>
                                        <xsd:appinfo>
                                             <sch:pattern id="iosversionitemversion_string">
                                                  <sch:rule context="ios-sc:version_item/ios-sc:version_string">
                                                       <sch:assert test="not(@datatype) or @datatype='ios_version'">item <sch:value-of select="../@id"/> - datatype attribute for the version_string entity of a version_item should be 'ios_version'</sch:assert>
                                                  </sch:rule>
                                             </sch:pattern>
                                        </xsd:appinfo>
                                   </xsd:annotation>
                              </xsd:element>
                         </xsd:sequence>
                    </xsd:extension>
               </xsd:complexContent>
          </xsd:complexType>
     </xsd:element>
     <!-- =============================================================================== -->
     <!-- =============================================================================== -->
     <!-- =============================================================================== -->
     <xsd:complexType name="EntityItemTrainIdentifierType">
          <xsd:annotation>
               <xsd:documentation>The EntityTrainIdentifierType restricts a string value to a specific set of values that describe the different types of trains in a Cisco IOS release. The empty string is also allowed to support empty emlement associated with error conditions.</xsd:documentation>
          </xsd:annotation>
          <xsd:simpleContent>
               <xsd:restriction base="oval-sc:EntityItemStringType">
                    <xsd:enumeration value="mainline"/>
                    <xsd:enumeration value="T"/>
                    <xsd:enumeration value="S"/>
                    <xsd:enumeration value="E"/>
                    <xsd:enumeration value="B"/>
                    <xsd:enumeration value=""/>
               </xsd:restriction>
          </xsd:simpleContent>
     </xsd:complexType>
</xsd:schema>
