< Home

Configuring the Source Subnet for Portal Authentication

This section provides a sample of configuring the source subnet for Portal authentication using the merge method.

Table 1 Configuring the source subnet for Portal authentication

Operation

XPATH

edit-config:merge

/huawei-nac-portal:portal-access/configure-mode/unified-mode/portal-access-profile/authentication-network

Data Requirements

Table 2 Configuring the source subnet for Portal authentication

Item

Data

Description

name

profile1

Configure the Portal access profile named profile1.

ip

10.1.1.0

Set the IP address to 10.1.1.0.

prefix-length

24

Set the prefix length to 24.

Request Example

<?xml version='1.0' encoding='UTF-8'?>
<rpc message-id="0" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
  <edit-config>
    <target>
      <running/>
    </target>
    <config>
      <hw-nac-portal:portal-access xmlns:hw-nac-portal="urn:huawei:params:xml:ns:yang:huawei-nac-portal">
        <hw-nac-portal:portal-access-profile>
          <hw-nac-portal:name>profile1</hw-nac-portal:name>
          <hw-nac-portal:authentication-network xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0" xc:operation="merge">
            <hw-nac-portal:ip>10.1.1.0</hw-nac-portal:ip>
            <hw-nac-portal:prefix-length>24</hw-nac-portal:prefix-length>
          </hw-nac-portal:authentication-network>
        </hw-nac-portal:portal-access-profile>
      </hw-nac-portal:portal-access>
    </config>
  </edit-config>
</rpc>

Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="0">
 <ok/>
</rpc-reply>

Sample of failed response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="0">
 <rpc-error>
  <error-type>application</error-type>
  <error-tag>operation-failed</error-tag>
  <error-severity>error</error-severity>
  <error-message>parse configuration error.</error-message>
 </rpc-error>
</rpc-reply>
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >