<?xml version="1.0" encoding="utf-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:oval="http://oval.mitre.org/XMLSchema/oval-common-5" xmlns:oval-def="http://oval.mitre.org/XMLSchema/oval-definitions-5" xmlns:sp-def="http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint" xmlns:sch="http://purl.oclc.org/dsdl/schematron" targetNamespace="http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint"
      elementFormDefault="qualified" version="5.10">
      <xsd:import namespace="http://oval.mitre.org/XMLSchema/oval-definitions-5" schemaLocation="oval-definitions-schema.xsd"/>
      <xsd:annotation>
            <xsd:documentation>The following is a description of the elements, types, and attributes that compose the SharePoint specific tests found in Open Vulnerability and Assessment Language (OVAL). Each test is an extension of the standard test element defined in the Core Definition Schema. Through extension, each test inherits a set of elements and attributes that are shared amongst all
                  OVAL tests. Each test 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 Definition Schema is not outlined
                  here.</xsd:documentation>
            <xsd:documentation>The SharePoint Component Schema is based on the SharePoint Object Model (Windows SharePoint Services 3.0)</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>SharePoint Definition</schema>
                  <version>5.10</version>
                  <date>9/14/2011 8:58:23 AM</date>
                  <terms_of_use>Copyright (c) 2002-2011, 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:ns prefix="oval-def" uri="http://oval.mitre.org/XMLSchema/oval-definitions-5"/>
                  <sch:ns prefix="sp-def" uri="http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint"/>
                  <sch:ns prefix="xsi" uri="http://www.w3.org/2001/XMLSchema-instance"/>
            </xsd:appinfo>
      </xsd:annotation>
      <!-- =============================================================================== -->
      <!-- ===========================  SPWEBAPPLICATION TEST   ========================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spwebapplication_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spwebapplication test is used to check the properties or permission settings of a SharePoint web application. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a spwebapplication_object and the optional state element
                        specifies the data to check.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spwebapplication_test</oval:test>
                              <oval:object>spwebapplication_object</oval:object>
                              <oval:state>spwebapplication_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spwebapplication_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_webapptst">
                              <sch:rule context="sp-def:spwebapplication_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spwebapplication_object/@id"><sch:value-of select="../@id"/> - the object child element of a spwebapplication_test must reference an spwebapplication_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spwebapplication_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spwebapplication_state/@id"><sch:value-of select="../@id"/> - the state child element of a spwebapplication_test must reference an spwebapplication_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spwebapplication_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spwebapplication_object element is used by a spwebapplication test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again,
                        please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spwebapplication object consists of a webapplicationurl used to define a specific web application. See the defintion of the SPWebApplication class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spwebapplication_object_verify_filter_state">
                              <sch:rule context="sp-def:spwebapplication_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spwebapplication_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spwebapplication_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="webapplicationurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The webapplicationurl element defines the SPWebApplication to evaluate specific security settings or permissions.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spwebapplication_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The spwebapplication_state element defines security settings and permissions that can be checked for a specified SPWebApplications.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="webapplicationurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The webapplicationurl element identifies a Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="allowparttopartcommunication" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the allowparttopartcommunication is enabled it allows users to create connections between Web parts.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="allowaccesstowebpartcatalog" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the allowaccesstowebpartcatalog is enabled it allows users access to the online Web part gallery.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="blockedfileextention" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The blockedfileextention element identifies one or more file extensions that should be blocked from the deployment.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="defaultquotatemplate" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The defaultquotatemplate element identifies the default quota template set for the web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="externalworkflowparticipantsenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the externalworkflowparticipantsenabled is enabled then users are allowed to participate in workflows.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="recyclebinenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the recyclebinenabled is enabled it will be easy to restore deleted files.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="automaticallydeleteunusedsitecollections" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the automaticallydeleteunusedsitecollections is disabled, sites will not be automatically deleted.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="selfservicesitecreationenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the selfservicesitecreationenabled is enabled users will be allowed to create and manager their own top-level Web sites .</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="secondstagerecyclebinquota" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The secondstagerecyclebinquota is the quota for the second stage recyle bin</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="recyclebinretentionperiod" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The recyclebinretentionperiod is the retention period for the recyle bin</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="outboundmailserverinstance" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The outboundmailserverinstance element identifies the string name of the SMPT server.  Note that there is a small naming inconsistency here.  The SharePoint SDK calls this 'outboundmailserviceinstance'.  </xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="outboundmailsenderaddress" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The outboundmailsenderaddress element identifies the address that the mail is being send from.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="outboundmailreplytoaddress" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The outboundmailreplytoaddress element identifies the address that the mail should be replied to.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="secvalexpires" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the secvalexpires is enabled then the form will expire after the security validation time (timeout) .</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="timeout" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The timeout is the amount of time before security validation expires in seconds.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="isadministrationwebapplication" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If this is true, the web application to which this test refers is the Central Administration web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="applicationpoolname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The applicationpoolname element identifies the web applications application pool name.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="applicationpoolusername" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The applicationpoolusername element identifies the web applications application pool username.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="openitems" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the openitems is enabled the permission to view the source of documents with server-side file handlers is available to use for this web application..</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="addlistitems" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the addlistitems is enabled the permission to add items to lists, add documents to document libraries, and add Web discussion comments is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="approveitems" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If approveitems is enabled the permission to approve a minor version of a list item or document is available to use for this the Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="deletelistitems" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the deletelistitems is enabled the permission to delete items from a list, documents from a document library, and Web discussion comments in documents is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="deleteversions" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the deleteversions is enabled the permission to delete past versions of a list item or document is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="editlistitems" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the editlistitems is enabled the permission to edit items in lists, edit documents in document libraries, edit Web discussion comments in documents, and customize Web Part Pages in document libraries is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="managelists" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the managelists is enabled the permission to create and delete lists, add or remove columns in a list, and add or remove public views of a list is available to use for this the Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="viewversions" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the viewversions is enabled the permission to view past versions of a list item or document is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="viewlistitems" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the viewlistitems is enabled the permission to view items in lists, documents in document libraries, and view Web discussion commentsis available is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="cancelcheckout" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the cancelcheckout is enabled the permission to discard or check in a document which is checked out to another user is available to use for this the Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="createalerts" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the createalerts is enabled the permission to Create e-mail alerts is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="viewformpages" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the viewformpages is enabled the permission to view forms, views, and application pages, and enumerate lists is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="viewpages" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the viewpages is enabled the permission to view pages in a Web site is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="addandcustomizepages" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If addandcustomizepages is enabled the permission to add, change, or delete HTML pages or Web Part Pages, and edit the Web site using a Windows SharePoint Services–compatible editor is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="applystylesheets" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the applystylesheets is enabled the permission to Apply a style sheet (.css file) to the Web site is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="applythemeandborder" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the applythemeanborder is enabled the permission to apply a theme or borders to the entire Web site is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="browsedirectories" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the browsedirectories is enabled the permission to enumerate files and folders in a Web site using Microsoft Office SharePoint Designer and WebDAV interfaces is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="browseuserinfo" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the browseuserinfo is enabled the permission to view information about users of the Web site is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="creategroups" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the creategroups is enabled the permission to create a group of users that can be used anywhere within the site collection is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="createsscsite" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the createsscsite is enabled the permission to create a Web site using Self-Service Site Creation is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="editmyuserinfo" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the editmyuserinfo is enabled the permission to allows a user to change his or her user information, such as adding a picture is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="enumeratepermissions" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If enumeratepermissions is enabled the permission to enumerate permissions on the Web site, list, folder, document, or list itemis is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="managealerts" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the managealerts is enabled the permission to manage alerts for all users of the Web site is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="managepermissions" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the managepermissions is enabled the permission to create and change permission levels on the Web site and assign permissions to users and groups is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="managesubwebs" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the managesubwebs is enabled the permission to create subsites such as team sites, Meeting Workspace sites, and Document Workspace sites is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="manageweb" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the manageweb is enabled the permission to perform all administration tasks for the Web site as well as manage content is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="open" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If open is enabled the permission to allow users to open a Web site, list, or folder to access items inside that containeris available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="useclientintegration" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the useclientintegration is enabled the permission to use features that launch client applications; otherwise, users must work on documents locally and upload changesis is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="useremoteapis" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the useremoteapis is enabled the permission to use SOAP, WebDAV, or Microsoft Office SharePoint Designer interfaces to access the Web siteis available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="viewusagedata" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the viewusagedata is enabled the permission to view reports on Web site usage in documents is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="managepersonalviews" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the managepersonalviews is enabled the permission to Create, change, and delete personal views of lists is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="adddelprivatewebparts" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the adddelprivatewebparts is enabled the permission to add or remove personal Web Parts on a Web Part Page is available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="updatepersonalwebparts" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the updatepersonalwebparts is enabled the permission to update Web Parts to display personalized informationis available to use for this Web application.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPGROUP TEST   =================================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spgroup_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spgroup test is used to check the group properties for site collections. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references an spwebapplication_object and the optional state element specifies the data to
                        check.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spgroup_test</oval:test>
                              <oval:object>spgroup_object</oval:object>
                              <oval:state>spgroup_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spgroup_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_grptst">
                              <sch:rule context="sp-def:spgroup_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spgroup_object/@id"><sch:value-of select="../@id"/> - the object child element of a spgroup_test must reference a spgroup_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spgroup_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spgroup_state/@id"><sch:value-of select="../@id"/> - the state child element of a spgroup_test must reference a spgroup_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spgroup_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spgroup_object element is used by a spgroup test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer to
                        the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spgroup object consists of a sitecollectionurl used to define a specific site collection. See the defintion of the SPGroup class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spgroup_object_verify_filter_state">
                              <sch:rule context="sp-def:spgroup_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spgroup_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spgroup_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="sitecollectionurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The sitecollectionurl element defines the Site Colection to evaluate specific group settings.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spgroup_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The spgroup_state element defines settings for groups in a site collections.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="sitecollectionurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The sitecollectionurl element identifies a Site Collection.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="gname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name element identifies a Group name.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="autoacceptrequesttojoinleave" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the autoacceptrequesttojoinleave is enabled it allows users to automatically join groups.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="allowmemberseditmembership" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the allowmemberseditmembership is enabled than all group memebers will be allowed to edit the membership of a group..</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="onlyallowmembersviewmembership" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the onlyallowmembersviewmembership is enabled it allows users to automatically join groups.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPWEB TEST   ===================================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spweb_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spweb test is used to check the properties for site collections. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references an spwebapplication_object and the optional state element specifies the data to check.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spweb_test</oval:test>
                              <oval:object>spweb_object</oval:object>
                              <oval:state>spweb_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spweb_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_webtst">
                              <sch:rule context="sp-def:spweb_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spweb_object/@id"><sch:value-of select="../@id"/> - the object child element of a spweb_test must reference an spweb_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spweb_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spweb_state/@id"><sch:value-of select="../@id"/> - the state child element of a spweb_test must reference an spweb_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spweb_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spweb_object element is used by a spweb test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer to the
                        description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spweb object consists of a webcollection url and sitecollection url used to define a specific web apoplication and a specific site collection. See the defintion of the SPWeb class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spweb_object_verify_filter_state">
                              <sch:rule context="sp-def:spweb_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spweb_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spweb_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="webcollectionurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The webcollectionurl element defines the web application to evaluate specific web settings.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element name="sitecollectionurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The sitecollectionurl element defines the site collection to evaluate specific web settings.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spweb_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The spweb_state element defines settings for a site collection.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="webcollectionurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The webcollurl element identifies a Site Collection.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="sitecollectionurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name element identifies a site collection url.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="secondarysitecolladmin" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The secondarysitecolladmin element identifies a secondary site collection admin.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="secondsitecolladminenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>A boolean that represents if the secondarysitecolladmin is enabled.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="allowanonymousaccess" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the allowanonymousaccess is enabled users will be allowed to create and manager their own top-level Web sites .</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPLIST TEST   ==================================== -->
      <!-- =============================================================================== -->
      <xsd:element name="splist_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The splist test is used to check the properties of lists associated with a SharePoint site or site collection. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references an splist_object and the optional state element specifies the data
                        to check.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>splist_test</oval:test>
                              <oval:object>splist_object</oval:object>
                              <oval:state>splist_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">splist_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_listtst">
                              <sch:rule context="sp-def:splist_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:splist_object/@id"><sch:value-of select="../@id"/> - the object child element of a splist_test must reference an splist_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:splist_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:splist_state/@id"><sch:value-of select="../@id"/> - the state child element of a splist_test must reference an splist_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="splist_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The splist_object element is used by a splist test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer to the
                        description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An splist object consists of a spsiteurl used to define a specific site in a site collection that various security related configuration items need to be checked. See the defintion of the SPList class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_splist_object_verify_filter_state">
                              <sch:rule context="sp-def:splist_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:splist_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='splist_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="spsiteurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The spsiteurl element defines the Sharepoint website being specified ...</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="splist_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The splist_state element defines the different information that can be used to evaluate the specified Sharepoint sites....</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="spsiteurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The spsiteurl element identifies an Sharepoint site to test for.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="irmenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the irmenabled option is enabled, documents are protected whenever they leave the control of the Sharepoint system.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="enableversioning" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the enableversioning option is enabled, backup copies of documents are kept and managed by the Sharepoint system.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="nocrawl" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>If the nocrawl option is enabled, the site is excluded from crawls that Sharepoint does when it indexes sites.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPANTIVIRUSSETTINGS TEST   ======================= -->
      <!-- =============================================================================== -->
      <xsd:element name="spantivirussettings_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spantivirussettings test is used to check the settings for antivirus software associated with a SharePoint deployment.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spantivirussettings_test</oval:test>
                              <oval:object>spantivirussettings_object</oval:object>
                              <oval:state>spantivirussettings_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spantivirussettings_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_avstst">
                              <sch:rule context="sp-def:spantivirussettings_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spantivirussettings_object/@id"><sch:value-of select="../@id"/> - the object child element of a spantivirussettings_test must reference an spantivirussettings_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spantivirussettings_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spantivirussettings_state/@id"><sch:value-of select="../@id"/> - the state child element of a spantivirussettings_test must reference an spantivirussettings_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spantivirussettings_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spantivirussettings_object element is used by a spantivirussettings test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic.
                        Again, please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spantivirussettings object consists of a spwebservicename used to define a specific webservice in a farm that various security related configuration items need to be checked and an spfarmname which denotes the farm of which the spwebservice is a part. See the defintion of the SPAntiVirusSettings class in the SharePoint object model documentation.
                  </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spantivirussettings_object_verify_filter_state">
                              <sch:rule context="sp-def:spantivirussettings_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spantivirussettings_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spantivirussettings_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="spwebservicename" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The spwebservicename element denotes the web service for which antivirus settings will be checked.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element name="spfarmname" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The spfarmname element denotes the farm on which a web service to be queried resides.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spantivirussettings_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The spantivirus_state element defines the different information that can be used to evaluate the specified Sharepoint sites....</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="spwebservicename" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The spwebservicename denotes the name of a SharePoint web service to be tested or * (the default) to test all web services.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="spfarmname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The spfarmname denotes the name of the farm on which the Sharepoint webservice resides or the local farm (default).</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="allowdownload" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether infected documents can be downloaded on the SharePoint system.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="cleaningenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether the virus scanner should attempt to cure files that are infected.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="downloadscanenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whetehr files are scanned for viruses when they are downloaded.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="numberofthreads" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The number of threads that the antivirus scanner can use to scan documents for viruses.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="skipsearchcrawl" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether to skip scanning for viruses during a search crawl.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="timeout" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Denotes the amount of time before the virus scanner times out in seconds.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="uploadscanenabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether files are scanned when they are uploaded.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="vendorupdatecount" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Denotes the current increment of the number of times the vendor has been updated.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPSITEADMINISTRATION TEST   ====================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spsiteadministration_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spsiteadministration test is used to check the properties of a site. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references an spwebapplication_object and the optional state element specifies the data to
                        check.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spsiteadministration_test</oval:test>
                              <oval:object>spsiteadministration_object</oval:object>
                              <oval:state>spsiteadministration_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spsiteadministration_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_siteadmintst">
                              <sch:rule context="sp-def:spsiteadministration_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spsiteadministration_object/@id"><sch:value-of select="../@id"/> - the object child element of a spsiteadministration_test must reference an spsiteadministration_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spsiteadministration_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spsiteadministration_state/@id"><sch:value-of select="../@id"/> - the state child element of a spsiteadministration_test must reference an spsiteadministration_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spsiteadministration_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spsiteadministration_object element is used by a spsiteadministration test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set
                        logic. Again, please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spsiteadministration object consists of a webapplicationurl used to define a specific web application. The collected data is available via the SPQuota class, which can be found via the SPSite object.  See the defintions of the SPSite and the SPQuota classes in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spsiteadministration_object_verify_filter_state">
                              <sch:rule context="sp-def:spsiteadministration_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spsiteadministration_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spsiteadministration_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="sitecollectionurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The sitecollectionurl element defines the site to evaluate.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spsiteadministration_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The spspsiteadministration_state element defines security settings and permissions that can be checked for a specified SPSite.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="sitecollectionurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The sitecollectionurl element identifies a site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="storagemaxlevel" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The storagemaxlevel is the maximum storage allowed for the site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="storagewarninglevel" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>When the storagewarninglevel is reached a site collection receive advance notice before available storage is expended.s.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPSITE TEST   ==================================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spsite_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spsite test is used to check the properties of a site. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references an spwebapplication_object and the optional state element specifies the data to check.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spsite_test</oval:test>
                              <oval:object>spsite_object</oval:object>
                              <oval:state>spsite_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spsite_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_sitetst">
                              <sch:rule context="sp-def:spsite_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spsite_object/@id"><sch:value-of select="../@id"/> - the object child element of a spsite_test must reference an spsite_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spsite_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spsite_state/@id"><sch:value-of select="../@id"/> - the state child element of a spsite_test must reference an spsite_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spsite_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spsite_object element is used by a spsiteadministration test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again,
                        please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spsite object consists of a sitecollectionurl used to define a specific web application. See the defintion of the SPSite class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spsite_object_verify_filter_state">
                              <sch:rule context="sp-def:spsite_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spsite_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spsite_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="sitecollectionurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The sitecollectionurl element defines the site to evaluate.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spsite_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The spsite_state element defines security settings and permissions that can be checked for a specified SPSite.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="sitecollectionurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The sitecollectionurl element identifies a site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="quotaname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The quota name is the name of quota template for a site collection.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="url" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URL is the full URL to the root Web site of the site collection, including host name, port number, and path.</xsd:documentation>
                                                <xsd:appinfo>
                                                      <oval:deprecated_info>
                                                            <oval:version>5.10</oval:version>
                                                            <oval:reason>The 'url' entity has been deprecated as it has been identified as redundant since the 'sitecollectionurl' is the same URL.</oval:reason>
                                                            <oval:comment>See the defintion of the SPSite class in the SharePoint object model documentation.</oval:comment>
                                                      </oval:deprecated_info>
                                                      <sch:pattern id="sp_def_spsite_state_url_dep">
                                                            <sch:rule context="oval-def:oval_definitions/oval-def:states/sp-def:spsite_state/sp-def:url">
                                                                  <sch:report test="true()">DEPRECATED ENTITY IN: sp-def:spsite_state </sch:report>
                                                            </sch:rule>
                                                      </sch:pattern>
                                                </xsd:appinfo>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPCRAWLRULE TEST   =============================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spcrawlrule_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spcrawlrule test is used to check the configuration or rules associated with the SharePoint system's built-in indexer and the sites or documents that will be indexed.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spcrawlrule_test</oval:test>
                              <oval:object>spcrawlrule_object</oval:object>
                              <oval:state>spcrawlrule_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spcrawlrule_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_crtst">
                              <sch:rule context="sp-def:spcrawlrule_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spcrawlrule_object/@id"><sch:value-of select="../@id"/> - the object child element of a spcrawlrule_test must reference an spcrawlrule_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spcrawlrule_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spcrawlrule_state/@id"><sch:value-of select="../@id"/> - the state child element of a spcrawlrule_test must reference an spcrawlrule_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spcrawlrule_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spcrawlrule_object element is used by a spcrawlrule test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spcrawlrule object consists of a spsiteurl used to define a specific resource (eg. website or document) on a server that can be indexed by the SharePoint indexer. See the defintion of the CrawlRule class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spcrawlrule_object_verify_filter_state">
                              <sch:rule context="sp-def:spcrawlrule_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spcrawlrule_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spcrawlrule_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="spsiteurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The spsiteurl element denotes the resource on the SharePoint server (eg. a site or document) for which indexing settings will be checked.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spcrawlrule_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The spcrawlrule state element defines the various properties of the SharePoint indexer that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="spsiteurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The spsiteurl denotes the URL of a website or resource whose indexing properties should be tested.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="crawlashttp" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether the crawler should crawl content from a hierarchical content source, such as HTTP content.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="enabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether a particular crawl rule is enabled.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="followcomplexurls" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether the indexer should crawl websites that contain the question mark (?) character.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="path" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The path to which a particular crawl rule applies.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="priority" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The priority setting for a particular crawl rule.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="suppressindexing" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether the crawler should exclude the content of items that this rule applies to from the content index.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="accountname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>A string containing the account name for the crawl rule.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPJOBDEFINITION TEST   =========================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spjobdefinition_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spjobdefinition test is used to check the status of the various properties associated with scheduled jobs in the SharePoint system.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spjobdefinition_test</oval:test>
                              <oval:object>spjobdefinition_object</oval:object>
                              <oval:state>spjobdefinition_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spjobdefinition_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <oval:deprecated_info>
                              <oval:version>5.10</oval:version>
                              <oval:reason>Replaced by the spjobdefinition510_test. This test does not uniquely identify a single job definition. A new test was created to use displaynames, which are unique. See the spjobdefinition510_test.</oval:reason>
                              <oval:comment>This test has been deprecated and will be removed in version 6.0 of the language.</oval:comment>
                        </oval:deprecated_info>
                        <sch:pattern id="sp-def_spjobdefinition_test_dep">
                              <sch:rule context="sp-def:spjobdefinition_test">
                                    <sch:report test="true()">DEPRECATED TEST: <sch:value-of select="name()"/> ID: <sch:value-of select="@id"/></sch:report>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_jobdeftst">
                              <sch:rule context="sp-def:spjobdefinition_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spjobdefinition_object/@id"><sch:value-of select="../@id"/> - the object child element of a spjobdefinition_test must reference an spjobdefinition_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spjobdefinition_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spjobdefinition_state/@id"><sch:value-of select="../@id"/> - the state child element of a spjobdefinition_test must reference an spjobdefinition_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spjobdefinition_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spjobdefinition_object element is used by a spjobdefinition test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spjobdefinition_object consists of a webappuri used to define a specific web application for which job checks should be done.  See the defintion of the SPJobDefinition class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <oval:deprecated_info>
                              <oval:version>5.10</oval:version>
                              <oval:reason>Replaced by the spjobdefinition510_object. This test does not uniquely identify a single job definition. A new object was created to use displaynames, which are unique. See the spjobdefinition510_object.</oval:reason>
                              <oval:comment>This test has been deprecated and will be removed in version 6.0 of the language.</oval:comment>
                        </oval:deprecated_info>
                        <sch:pattern id="sp-def_spjobdefinition_object_dep">
                              <sch:rule context="sp-def:spjobdefinition_object">
                                    <sch:report test="true()">DEPRECATED TEST: <sch:value-of select="name()"/> ID: <sch:value-of select="@id"/></sch:report>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spjobdefinition_object_verify_filter_state">
                              <sch:rule context="sp-def:spjobdefinition_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spjobdefinition_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spjobdefinition_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="webappuri" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The URI that represents the web application for which jobs should be checked.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spjobdefinition_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of a Sharepoint job that can be checked.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:deprecated_info>
                              <oval:version>5.10</oval:version>
                              <oval:reason>Replaced by the spjobdefinition510_state. This state does not uniquely identify a single job definition. A new state was created to use displaynames, which are unique. See the spjobdefinition510_state.</oval:reason>
                              <oval:comment>This test has been deprecated and will be removed in version 6.0 of the language.</oval:comment>
                        </oval:deprecated_info>
                        <sch:pattern id="sp-def_spjobdefinition_state_dep">
                              <sch:rule context="sp-def:spjobdefinition_state">
                                    <sch:report test="true()">DEPRECATED TEST: <sch:value-of select="name()"/> ID: <sch:value-of select="@id"/></sch:report>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="webappuri" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URI that represents the web application for which jobs should be checked.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="displayname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the job as displayed in the SharePoint Central Administration site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="isdisabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Determines whether or not the job definition is enabled.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="retry" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Determines whether the job definition should be retried if it ends abnormally.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="title" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The title of a job as displayed in the SharePoint Central Administration site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPJOBDEFINITION TEST(5.10)   ===================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spjobdefinition510_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spjobdefinition test is used to check the status of the various properties associated with scheduled jobs in the SharePoint system.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spjobdefinition510_test</oval:test>
                              <oval:object>spjobdefinition510_object</oval:object>
                              <oval:state>spjobdefinition510_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spjobdefinition510_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_jobdef510tst">
                              <sch:rule context="sp-def:spjobdefinition510_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spjobdefinition510_object/@id"><sch:value-of select="../@id"/> - the object child element of a spjobdefinition510_test must reference an spjobdefinition510_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spjobdefinition510_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spjobdefinition510_state/@id"><sch:value-of select="../@id"/> - the state child element of a spjobdefinition510_test must reference an spjobdefinition510_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType" />
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spjobdefinition510_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spjobdefinition510_object element is used by a spjobdefinition test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spjobdefinition510_object consists of a webappuri and displayname used to define a specific web application for which job checks should be done. See the defintion of the SPJobDefinition class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spjobdefinition510_object_verify_filter_state">
                              <sch:rule context="sp-def:spjobdefinition510_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spjobdefinition510_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spjobdefinition510_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="webappuri" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The URI that represents the web application for which jobs should be checked.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element name="displayname" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The name of the job as displayed in the SharePoint Central Administration site.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spjobdefinition510_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of a Sharepoint job that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="webappuri" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URI that represents the web application for which jobs should be checked.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="displayname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the job as displayed in the SharePoint Central Administration site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="isdisabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Determines whether or not the job definition is enabled.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="retry" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Determines whether the job definition should be retried if it ends abnormally.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="title" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The title of a job as displayed in the SharePoint Central Administration site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  BESTBET TEST   =================================== -->
      <!-- =============================================================================== -->
      <xsd:element name="bestbet_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The bestbet test is used to get all the best bets associated with a site.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>bestbet_test</oval:test>
                              <oval:object>bestbet_object</oval:object>
                              <oval:state>bestbet_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">bestbet_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_bbtst">
                              <sch:rule context="sp-def:bestbet_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:bestbet_object/@id"><sch:value-of select="../@id"/> - the object child element of a bestbet_test must reference an bestbet_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:bestbet_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:bestbet_state/@id"><sch:value-of select="../@id"/> - the state child element of a bestbet_test must reference an bestbet_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="bestbet_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The bestbet_object element is used by a bestbet test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer to
                        the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An bestbet object consists of a sitecollectionurl used to define a specific site and a bestbeturl used to define a specific best bet. See the defintion of the BestBet class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_bestbet_object_verify_filter_state">
                              <sch:rule context="sp-def:bestbet_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:bestbet_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='bestbet_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="sitecollectionurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The URL that represents the site collection.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element name="bestbeturl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The URL that represents the best bet.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="bestbet_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of a Best Bet that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="sitecollectionurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URL that represents the site collection.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="bestbeturl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the job as displayed in the SharePoint Central Administration site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="title" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The title of a best bet.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="description" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Thedescription of a best bet..</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  INFOPOLICYCOLLECTION TEST   ====================== -->
      <!-- =============================================================================== -->
      <xsd:element name="infopolicycoll_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The policycoll test is used to get all the Information Policies associated with a site.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>infopolicycoll_test</oval:test>
                              <oval:object>infopolicycoll_object</oval:object>
                              <oval:state>infopolicycoll_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">infopolicycoll_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_infopolicycolltst">
                              <sch:rule context="sp-def:policycoll_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:policycoll_object/@id"><sch:value-of select="../@id"/> - the object child element of a policycoll_test must reference an policycoll_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:policycoll_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:policycoll_state/@id"><sch:value-of select="../@id"/> - the state child element of a policycoll_test must reference an policycoll_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="infopolicycoll_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The infopolicycoll_object element is used by a policycoll test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please
                        refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>A infopolicycoll object consists of a sitecollectionurl used to define a specific site and an id used to define a specific information policy. See the defintion of the Policy class and policycollection class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_infopolicycoll_object_verify_filter_state">
                              <sch:rule context="sp-def:infopolicycoll_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:infopolicycoll_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='infopolicycoll_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="sitecollectionurl" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The URL that represents the site collection.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element name="id" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The id that represents the Information Policy.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="infopolicycoll_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of the Information Policy that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="sitecollectionurl" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URL that represents the site collection.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="id" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The id of the Information Policy.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the Information Policy.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="description" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The description of an Information Policy..</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="longdescription" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The long description of an Information Policy..</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPDIAGNOSTICSSERVICE TEST   ====================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spdiagnosticsservice_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spdiagnosticsservice test is used to check the diagnostic properties associated with a Sharepoint system.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spdiagnosticsservice_test</oval:test>
                              <oval:object>spdiagnosticsservice_object</oval:object>
                              <oval:state>spdiagnosticsservice_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spdiagnosticsservice_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_diagnosticsservicetest">
                              <sch:rule context="sp-def:spdiagnosticsservice_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spdiagnosticsservice_object/@id"><sch:value-of select="../@id"/> - the object child element of an spdiagnosticsservice_test must reference an spdiagnosticsservice_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spdiagnosticsservice_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spdiagnosticsservice_state/@id"><sch:value-of select="../@id"/> - the state child element of an spdiagnosticsservice_test must reference an spdiagnosticsservice_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spdiagnosticsservice_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spdiagnosticsservice_object element is used by an spdiagnosticsservice test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set
                        logic. Again, please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spdiagnosticsservice object consists of a farmname used to define a specific Sharepoint farm for which diagnostics properties should be checked. See the defintion of the SPDiagnosticsService class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spdiagnosticsservice_object_verify_filter_state">
                              <sch:rule context="sp-def:spdiagnosticsservice_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spdiagnosticsservice_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spdiagnosticsservice_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="farmname" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The farm whose diagnostic capabilities should be checked. Use .* for all farms or SPFarm.Local for the local farm.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spdiagnosticsservice_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of a diagnostics service that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="farmname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The farm whose diagnostic capabilities should be checked.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="displayname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the diagnostic service as shown in the Sharepoint Central Administration site.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="logcutinterval" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The number of minutes to capture events to a single log file. This value lies in the range 0 to 1440. The default value is 30.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="loglocation" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The path to the file system directory where log files are created and stored.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="logstokeep" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The value that indicates the number of log files to create. This lies in the range 0 to 1024 with a default of 96.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="required" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The required property specifies whether an instance of the spdiagnosticsservice must be running on the farm.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="typename" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The friendly name for the service as displayed in the Central Administration and in logs. This should be "Windows Sharepoint Diagnostics Service" by default.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPDIAGNOSTICSLEVEL TEST   ======================== -->
      <!-- =============================================================================== -->
      <xsd:element name="spdiagnosticslevel_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The spdiagnosticslevel_test is used to check the status of the logging features associated with a Sharepoint deployment.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>spdiagnosticslevel_test</oval:test>
                              <oval:object>spdiagnosticslevel_object</oval:object>
                              <oval:state>spdiagnosticslevel_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">spdiagnosticslevel_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_diagnostics_level_test">
                              <sch:rule context="sp-def:spdiagnosticslevel_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:spdiagnosticslevel_object/@id"><sch:value-of select="../@id"/> - the object child element of an spdiagnosticslevel_test must reference an spdiagnosticslevel_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:spdiagnosticslevel_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:spdiagnosticslevel_state/@id"><sch:value-of select="../@id"/> - the state child element of an spdiagnosticslevel_test must reference an spdiagnosticslevel_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spdiagnosticslevel_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The spdiagnosticslevel_object element is used by an spdiagnosticslevel test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic.  Again, please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An spdiagnosticslevel object consists of a farmname used to define a specific Sharepoint farm for which policy properties should be checked. See the defintion of the SPWebApplication class in the SharePoint object model documentation. See the defintion of the IDiagnosticsLevel Interface in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_spdiagnosticslevel_object_verify_filter_state">
                              <sch:rule context="sp-def:spdiagnosticslevel_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:spdiagnosticslevel_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='spdiagnosticslevel_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="farmname" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The farm whose diagnostics levels should be checked. Use .* for all farms or SPFarm.Local for the local farm.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="spdiagnosticslevel_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of a Diagnostics level that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="farmname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the farm for which diagnostics level properties should be checked.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="eventseverity" type="sp-def:EntityStateEventSeverityType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The event severity setting for a particular diagnostic level category.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="hidden" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether the trace log category is hidden in the Windows Sharepoint Services Central Administration interface.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="levelid" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>A string that represents the ID of the trace log category. This is its English language name.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="levelname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the trace log category. This represents the localized name for the category.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="traceseverity" type="sp-def:EntityStateTraceSeverityType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The trace severity setting for a particular diagnostic level category.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPPOLICYFEATURE TEST   =========================== -->
      <!-- =============================================================================== -->
      <xsd:element name="sppolicyfeature_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The sppolicyfeature test enables one to check the attributes associated with policies and policy features on the Sharepoint deployment.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>sppolicyfeature_test</oval:test>
                              <oval:object>sppolicyfeature_object</oval:object>
                              <oval:state>sppolicyfeature_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">sppolicyfeature_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_policyfeature_test">
                              <sch:rule context="sp-def:sppolicyfeature_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:sppolicyfeature_object/@id"><sch:value-of select="../@id"/> - the object child element of an sppolicyfeature_test must reference an sppolicyfeature_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:sppolicyfeature_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:sppolicyfeature_state/@id"><sch:value-of select="../@id"/> - the state child element of an sppolicyfeature_test must reference an sppolicyfeature_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="sppolicyfeature_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The sppolicyfeature_object element is used by an sppolicyfeature test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again,
                        please refer to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An sppolicyfeature object consists of a farmname used to define a specific Sharepoint farm for which policy feature properties should be checked. See the defintion of the PolicyFeature class in the SharePoint object model documentation. </xsd:documentation>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_sppolicyfeature_object_verify_filter_state">
                              <sch:rule context="sp-def:sppolicyfeature_object//oval-def:filter">
                                    <sch:let name="parent_object" value="ancestor::sp-def:sppolicyfeature_object"/>
                                    <sch:let name="parent_object_id" value="$parent_object/@id"/>
                                    <sch:let name="state_ref" value="."/>
                                    <sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
                                    <sch:let name="state_name" value="local-name($reffed_state)"/>
                                    <sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
                                    <sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#sharepoint') and ($state_name='sppolicyfeature_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="farmname" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The farm whose policy features should be checked. Use .* for all farms or SPFarm.Local for the local farm.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="sppolicyfeature_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of a policy feature that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="farmname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The farm whose policy features should be checked. Use .* for all farms or SPFarm.Local for the local farm.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="configpage" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URL to a web control used to edit policy instance-level settings.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="defaultcustomdata" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The default values for any policy instance-level settings for a policy feature.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="description" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The short description of the policy feature and of the service it provides.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="globalconfigpage" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URL to a web control used to edit server farm-level settings for this policy feature.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="globalcustomdata" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The default settings for any server farm-level settings for this policy feature.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="group" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The policy feature group to which a policy feature belongs.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name to display in the Microsoft Office Sharepoint Server 2007 interface for an information policy feature.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="publisher" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The name of the creator of the policy feature as it is displayed in the Microsoft Office Sharepoint Server 2007 user interface.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="state" type="sp-def:EntityStatePolicyFeatureStateType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether the policy feature is hidden or visible.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =============================================================================== -->
      <!-- ===========================  SPPOLICY TEST   ================================== -->
      <!-- =============================================================================== -->
      <xsd:element name="sppolicy_test" substitutionGroup="oval-def:test">
            <xsd:annotation>
                  <xsd:documentation>The sppolicy test enables one to check the attributes of the policies associated with a particular URL Zone in a Sharepoint system.</xsd:documentation>
                  <xsd:appinfo>
                        <oval:element_mapping>
                              <oval:test>sppolicy_test</oval:test>
                              <oval:object>sppolicy_object</oval:object>
                              <oval:state>sppolicy_state</oval:state>
                              <oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#sharepoint">sppolicy_item</oval:item>
                        </oval:element_mapping>
                  </xsd:appinfo>
                  <xsd:appinfo>
                        <sch:pattern id="sp-def_policy_test">
                              <sch:rule context="sp-def:sppolicy_test/sp-def:object">
                                    <sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/sp-def:sppolicy_object/@id"><sch:value-of select="../@id"/> - the object child element of an sppolicy_test must reference an sppolicy_object</sch:assert>
                              </sch:rule>
                              <sch:rule context="sp-def:sppolicy_test/sp-def:state">
                                    <sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/sp-def:sppolicy_state/@id"><sch:value-of select="../@id"/> - the state child element of an sppolicy_test must reference an sppolicy_state</sch:assert>
                              </sch:rule>
                        </sch:pattern>
                  </xsd:appinfo>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:TestType">
                              <xsd:sequence>
                                    <xsd:element name="object" type="oval-def:ObjectRefType"/>
                                    <xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="1"/>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="sppolicy_object" substitutionGroup="oval-def:object">
            <xsd:annotation>
                  <xsd:documentation>The sppolicy_object element is used by an sppolicy test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information. The common set element allows complex objects to be created using filters and set logic. Again, please refer
                        to the description of the set element in the oval-definitions-schema.</xsd:documentation>
                  <xsd:documentation>An sppolicy object consists of a webappuri and a URL Zone used to define a specific Sharepoint web application and zone for which policy properties should be checked. See the defintion of the SPPolicy class and the sppolicyroletype in the SharePoint object model documentation. </xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:ObjectType">
                              <xsd:sequence>
                                    <xsd:choice>
                                          <xsd:element ref="oval-def:set"/>
                                          <xsd:sequence>
                                                <xsd:element name="webappuri" type="oval-def:EntityObjectStringType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The URI that represents the web application for which policies should be checked.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                                <xsd:element name="urlzone" type="sp-def:EntityObjectUrlZoneType">
                                                      <xsd:annotation>
                                                            <xsd:documentation>The zone for which policies should be checked.</xsd:documentation>
                                                      </xsd:annotation>
                                                </xsd:element>
                                          </xsd:sequence>
                                    </xsd:choice>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <xsd:element name="sppolicy_state" substitutionGroup="oval-def:state">
            <xsd:annotation>
                  <xsd:documentation>The various properties of a policy that can be checked.</xsd:documentation>
            </xsd:annotation>
            <xsd:complexType>
                  <xsd:complexContent>
                        <xsd:extension base="oval-def:StateType">
                              <xsd:sequence>
                                    <xsd:element name="webappuri" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The URI that represents the web application for which policies should be checked.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="urlzone" type="sp-def:EntityStateUrlZoneType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The zone for which policies should be checked.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="displayname" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The user or group display name for a policy. This defaults to the user name if the display name cannot be resolved through Active Directory.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="issystemuser" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>Specifies whether the user identified by a particular policy is visible only as a System account within the Windows Sharepoint Services user interface.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="username" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The user name of the user or group that is associated with policy.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                                    <xsd:element name="policyroletype" type="sp-def:EntityStatePolicyRoleType" minOccurs="0" maxOccurs="1">
                                          <xsd:annotation>
                                                <xsd:documentation>The policy role type to apply globally in a Sharepoint web application to a user or group.</xsd:documentation>
                                          </xsd:annotation>
                                    </xsd:element>
                              </xsd:sequence>
                        </xsd:extension>
                  </xsd:complexContent>
            </xsd:complexType>
      </xsd:element>
      <!-- =================================================================================================================================== -->
      <!-- ====================================================TYPES========================================================================== -->
      <!-- =================================================================================================================================== -->
      <xsd:complexType name="EntityObjectUrlZoneType">
            <xsd:annotation>
                  <xsd:documentation>The EntityObjectUrlZoneType restricts a string value to a set of values that describe the different IIS Url Zones. The empty string is also allowed to support empty element associated with error conditions.</xsd:documentation>
            </xsd:annotation>
            <xsd:simpleContent>
                  <xsd:restriction base="oval-def:EntityObjectStringType">
                        <xsd:enumeration value="Custom"/>
                        <xsd:enumeration value="Default"/>
                        <xsd:enumeration value="Extranet"/>
                        <xsd:enumeration value="Intranet"/>
                        <xsd:enumeration value="Internet"/>
                        <xsd:enumeration value="">
                              <xsd:annotation>
                                    <xsd:documentation>The empty string value is permitted here to allow for empty elements associated with variable references.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                  </xsd:restriction>
            </xsd:simpleContent>
      </xsd:complexType>
      <xsd:complexType name="EntityStateEventSeverityType">
            <xsd:annotation>
                  <xsd:documentation>The EntityStateEventSeverityType restricts a string value to a set of values that describe the different states that can be configured for a diagnostics level event severity level property of the diagnostics service.</xsd:documentation>
            </xsd:annotation>
            <xsd:simpleContent>
                  <xsd:restriction base="oval-def:EntityStateStringType">
                        <xsd:enumeration value="Error"/>
                        <xsd:enumeration value="ErrorCritical"/>
                        <xsd:enumeration value="ErrorSecurityBreach"/>
                        <xsd:enumeration value="ErrorServiceUnavailable"/>
                        <xsd:enumeration value="FailureAudit"/>
                        <xsd:enumeration value="Information"/>
                        <xsd:enumeration value="None"/>
                        <xsd:enumeration value="Success"/>
                        <xsd:enumeration value="SuccessAudit"/>
                        <xsd:enumeration value="Warning"/>
                        <xsd:enumeration value="">
                              <xsd:annotation>
                                    <xsd:documentation>The empty string value is permitted here to allow for empty elements associated with variable references.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                  </xsd:restriction>
            </xsd:simpleContent>
      </xsd:complexType>
      <xsd:complexType name="EntityStateTraceSeverityType">
            <xsd:annotation>
                  <xsd:documentation>The EntityStateTraceSeverityType restricts a string value to a set of values that describe the different states that can be configured for a diagnostics level trace severity level property of the diagnostics service.</xsd:documentation>
            </xsd:annotation>
            <xsd:simpleContent>
                  <xsd:restriction base="oval-def:EntityStateStringType">
                        <xsd:enumeration value="High"/>
                        <xsd:enumeration value="Medium"/>
                        <xsd:enumeration value="Monitorable"/>
                        <xsd:enumeration value="None"/>
                        <xsd:enumeration value="Unexpected"/>
                        <xsd:enumeration value="Verbose"/>
                        <xsd:enumeration value="">
                              <xsd:annotation>
                                    <xsd:documentation>The empty string value is permitted here to allow for empty elements associated with variable references.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                  </xsd:restriction>
            </xsd:simpleContent>
      </xsd:complexType>
      <xsd:complexType name="EntityStatePolicyRoleType">
            <xsd:annotation>
                  <xsd:documentation>The EntityStatePolicyRoleType restricts a string value to a set of values that describe the different Policy settings for Access Control that are available for users.</xsd:documentation>
            </xsd:annotation>
            <xsd:simpleContent>
                  <xsd:restriction base="oval-def:EntityStateStringType">
                        <xsd:enumeration value="DenyAll">
                              <xsd:annotation>
                                    <xsd:documentation>Deny all rights.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                        <xsd:enumeration value="DenyWrite">
                              <xsd:annotation>
                                    <xsd:documentation>Deny write permissions.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                        <xsd:enumeration value="FullControl">
                              <xsd:annotation>
                                    <xsd:documentation>Grant full control.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                        <xsd:enumeration value="FullRead">
                              <xsd:annotation>
                                    <xsd:documentation>Grant full read permissions.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                        <xsd:enumeration value="None">
                              <xsd:annotation>
                                    <xsd:documentation>No role type assigned.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                        <xsd:enumeration value="">
                              <xsd:annotation>
                                    <xsd:documentation>The empty string value is permitted here to allow for empty elements associated with variable references.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                  </xsd:restriction>
            </xsd:simpleContent>
      </xsd:complexType>
      <xsd:complexType name="EntityStatePolicyFeatureStateType">
            <xsd:annotation>
                  <xsd:documentation>The EntityStatePolicyRoleType restricts a string value to a set of values that describe the different policy feature states that can be configured for a policy feature.</xsd:documentation>
            </xsd:annotation>
            <xsd:simpleContent>
                  <xsd:restriction base="oval-def:EntityStateStringType">
                        <xsd:enumeration value="Hidden">
                              <xsd:annotation>
                                    <xsd:documentation>Specifies that the policy feature is hidden from the Sharepoint Central Administration user interface.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                        <xsd:enumeration value="Visible">
                              <xsd:annotation>
                                    <xsd:documentation>Specifies that the policy feature is visible from the Sharepoint Central Administration user interface.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                        <xsd:enumeration value="">
                              <xsd:annotation>
                                    <xsd:documentation>The empty string value is permitted here to allow for empty elements associated with variable references.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                  </xsd:restriction>
            </xsd:simpleContent>
      </xsd:complexType>
      <xsd:complexType name="EntityStateUrlZoneType">
            <xsd:annotation>
                  <xsd:documentation>The EntityStateUrlZoneType restricts a string value to a set of values that describe the different IIS Url Zones.</xsd:documentation>
            </xsd:annotation>
            <xsd:simpleContent>
                  <xsd:restriction base="oval-def:EntityStateStringType">
                        <xsd:enumeration value="Custom"/>
                        <xsd:enumeration value="Default"/>
                        <xsd:enumeration value="Extranet"/>
                        <xsd:enumeration value="Intranet"/>
                        <xsd:enumeration value="Internet"/>
                        <xsd:enumeration value="">
                              <xsd:annotation>
                                    <xsd:documentation>The empty string value is permitted here to allow for empty elements associated with variable references.</xsd:documentation>
                              </xsd:annotation>
                        </xsd:enumeration>
                  </xsd:restriction>
            </xsd:simpleContent>
      </xsd:complexType>
</xsd:schema>
