<?xml version="1.0" encoding="gb2312"?>
<xs:schema targetNamespace="http://www.h3c.com/netconf/config:1.0"
                  elementFormDefault="qualified"
                  xmlns="http://www.h3c.com/netconf/config:1.0"
                  xmlns:base="http://www.h3c.com/netconf/base:1.0"
                  xmlns:netconf ="urn:ietf:params:xml:ns:netconf:base:1.0"
                  xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:import namespace="http://www.h3c.com/netconf/base:1.0" schemaLocation="basetype.xsd"/>
  <xs:import schemaLocation="netconf.xsd" namespace="urn:ietf:params:xml:ns:netconf:base:1.0"/>
  <xs:annotation>
    <xs:documentation>
       PortSec module config definition
    </xs:documentation>
  </xs:annotation>
  <xs:element name="PortSecurity">
    <xs:complexType>
      <xs:choice maxOccurs="unbounded">
        <xs:element name="Common" minOccurs="0">
          <xs:annotation>
            <xs:documentation>PortSec common related paramenters</xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:all>
              <xs:element name="Enable" nillable="true" minOccurs="0">
                <xs:annotation>
                  <xs:documentation>Global PortSec feature.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:simpleContent>
                    <xs:restriction base="base:Boolean"/>
                  </xs:simpleContent>
                </xs:complexType>
              </xs:element>
              <xs:element name="MACMove" nillable="true" minOccurs="0">
                <xs:annotation>
                  <xs:documentation>Allows 802.1X or MAC authenticated users to move between ports on a device.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:simpleContent>
                    <xs:restriction base="base:Boolean"/>
                  </xs:simpleContent>
                </xs:complexType>
              </xs:element>
              <xs:element name="AuthorStrict" nillable="true" minOccurs="0">
                <xs:annotation>
                  <xs:documentation>Allows 802.1X or MAC authenticated users to be online or not while authorizing failed.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:simpleContent>
                    <xs:restriction base="base:Boolean"/>
                  </xs:simpleContent>
                </xs:complexType>
              </xs:element>
              <xs:element name="SecMACAgingInterval" nillable="true" minOccurs="0">
                <xs:annotation>
                  <xs:documentation>Period of secure MAC address aging timer.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:simpleContent>
                    <xs:restriction base="base:UnsignedInteger32">
                      <xs:minInclusive value="0"></xs:minInclusive>
                      <xs:maxInclusive value="129600"></xs:maxInclusive>
                    </xs:restriction>
                  </xs:simpleContent>
                </xs:complexType>
              </xs:element>
              <xs:element name="IntrusionShutdownInterval" nillable="true" minOccurs="0">
                <xs:annotation>
                  <xs:documentation>Period value of Intrusion Protection¡¯s port shutdown timer.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:simpleContent>
                    <xs:restriction base="base:UnsignedInteger32">
                      <xs:minInclusive value="20"></xs:minInclusive>
                      <xs:maxInclusive value="300"></xs:maxInclusive>
                    </xs:restriction>
                  </xs:simpleContent>
                </xs:complexType>
              </xs:element>
            </xs:all>
            <xs:attributeGroup ref="base:TableAttributeGroup"></xs:attributeGroup>
          </xs:complexType>
        </xs:element>
        <xs:element name="OUIList" minOccurs="0">
          <xs:annotation>
            <xs:documentation>PortSec OUIList feature table</xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:choice maxOccurs="unbounded">
              <xs:element name="OUIMAC" minOccurs="0" maxOccurs="unbounded">
                <xs:complexType>
                  <xs:all>
                    <xs:element name="Index" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>The index of a Interface</xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:IfIndex">
                            <xs:minInclusive value="1"></xs:minInclusive>
                            <xs:maxInclusive value="16"></xs:maxInclusive>
                          </xs:restriction>                          
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>                  
                    <xs:element name="Address" nillable="true" type="base:MacAddress" minOccurs="0">
                      <xs:annotation>
                      <xs:documentation>
                        An OUI string of a 48-bit MAC address in the H-H-H format. The system uses only the 24 high-order bits as the OUI value.</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                  </xs:all>
                  <xs:attributeGroup ref="base:RowAttributeGroup"></xs:attributeGroup>
                </xs:complexType>
              </xs:element>
            </xs:choice>
            <xs:attributeGroup ref="base:TableAttributeGroup"></xs:attributeGroup>
          </xs:complexType>
        </xs:element>
        <xs:element name="Interfaces" minOccurs="0">
          <xs:annotation>
            <xs:documentation>PortSec interface's information</xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:choice maxOccurs="unbounded">
              <xs:element name="Interface" minOccurs="0" maxOccurs="unbounded">
                <xs:complexType>
                  <xs:all>
                    <xs:element name="IfIndex" nillable="true" type="base:NameAndIndexUnion" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>The index of a Interface</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                    <xs:element name="AuthenMode" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Authentication Mode:
                          1¡ªnoRestrictions
                          2¡ªautolearn
                          3¡ªmac-authentication
                          4¡ªmac-else-userlogin-secure
                          5¡ªmac-else-userlogin-secure-ext
                          6¡ªsecure
                          7¡ªuserlogin
                          8¡ªuserlogin-secure
                          9¡ªuserlogin-secure-ext
                          10¡ªuserlogin-secure-or-mac
                          11¡ªuserlogin-secure-or-mac-ext
                          12¡ªuserlogin-withoui
                        </xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:UnsignedInteger32">
                            <xs:enumeration value="1"></xs:enumeration>
                            <xs:enumeration value="2"></xs:enumeration>
                            <xs:enumeration value="3"></xs:enumeration>
                            <xs:enumeration value="4"></xs:enumeration>
                            <xs:enumeration value="5"></xs:enumeration>
                            <xs:enumeration value="6"></xs:enumeration>
                            <xs:enumeration value="7"></xs:enumeration>
                            <xs:enumeration value="8"></xs:enumeration>
                            <xs:enumeration value="9"></xs:enumeration>
                            <xs:enumeration value="10"></xs:enumeration>
                            <xs:enumeration value="11"></xs:enumeration>
                            <xs:enumeration value="12"></xs:enumeration>                           
                          </xs:restriction>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="AuthorIgnore" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Ignore server¡¯s authorization information or not to users logging on from the interface.</xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:Boolean"/>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="ProtectionMode" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Protection action while intrusion detected.
                          1¡ªnoaction
                          2¡ªblockusermac
                          3¡ªshutdownport
                          4¡ªshutdownportforatime
                        </xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:UnsignedInteger32">
                            <xs:enumeration value="1"></xs:enumeration>
                            <xs:enumeration value="2"></xs:enumeration>
                            <xs:enumeration value="3"></xs:enumeration>
                            <xs:enumeration value="4"></xs:enumeration>
                          </xs:restriction>                          
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="SecMACAgeMode" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Secure MAC aging mode.
                            0¡ªTimeout 
                            1¡ªInactivity 
                        </xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:UnsignedInteger32">
                          	<xs:enumeration value="0"></xs:enumeration>
                            <xs:enumeration value="1"></xs:enumeration>
                          </xs:restriction>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="SecMACSticky" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Save secure MAC on the interface or not.</xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:Boolean"/>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="SecMACMaxCnt" type="base:UnsignedInteger32" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Max count of secure MAC address on the interface.</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                    <xs:element name="NTKMode" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Need to Know mode.
                          1¡ªNoaction
                          2¡ªntk-withbroadcasts
                          3¡ªntk-withmulticasts
                          4¡ªntkonly
                        </xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:UnsignedInteger32">
                            <xs:enumeration value="1"></xs:enumeration>
                            <xs:enumeration value="2"></xs:enumeration>
                            <xs:enumeration value="3"></xs:enumeration>
                            <xs:enumeration value="4"></xs:enumeration>
                          </xs:restriction>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                  </xs:all>
                  <xs:attributeGroup ref="base:RowAttributeGroup"></xs:attributeGroup>
                </xs:complexType>
              </xs:element>
            </xs:choice>
            <xs:attributeGroup ref="base:TableAttributeGroup"></xs:attributeGroup>
          </xs:complexType>
        </xs:element>
        <xs:element name="InterfaceSecMAC" minOccurs="0">
          <xs:annotation>
            <xs:documentation>PortSec InterfaceSecMAC information</xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:choice maxOccurs="unbounded">
              <xs:element name="SecureMAC" minOccurs="0" maxOccurs="unbounded">
                <xs:complexType>
                  <xs:all>
                    <xs:element name="IfIndex" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>The index of a Interface</xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:IfIndex"/>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="VLANID" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>VLAN ID for this secure MAC address.</xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:IfIndex">
                            <xs:minInclusive value="1"></xs:minInclusive>
                            <xs:maxInclusive value="4094"></xs:maxInclusive>
                          </xs:restriction>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="MAC" nillable="true" type="base:MacAddress" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>Secure MAC address added.</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                    <xs:element name="Sticky" nillable="true" minOccurs="0">
                      <xs:annotation>
                        <xs:documentation>The configured MAC ages or not.</xs:documentation>
                      </xs:annotation>
                      <xs:complexType>
                        <xs:simpleContent>
                          <xs:restriction base="base:Boolean"/>
                        </xs:simpleContent>
                      </xs:complexType>
                    </xs:element>
                  </xs:all>
                  <xs:attributeGroup ref="base:RowAttributeGroup"></xs:attributeGroup>
                </xs:complexType>
              </xs:element>
            </xs:choice>
            <xs:attributeGroup ref="base:TableAttributeGroup"></xs:attributeGroup>
          </xs:complexType>
        </xs:element>
      </xs:choice>
      <xs:attributeGroup ref="base:NodeAttributeGroup"></xs:attributeGroup>
    </xs:complexType>
  </xs:element>
</xs:schema>
