< Home

portal auth-network

Function

The portal auth-network command configures a source subnet for Portal authentication.

The undo portal auth-network command restores the default source subnet for Portal authentication.

By default, the source subnet for Portal authentication is 0.0.0.0/0, indicating that users in all subnets must pass Portal authentication.

Format

portal auth-network network-address { mask-length | mask-address }

undo portal auth-network { network-address { mask-length | mask-address } | all }

Parameters

Parameter Description Value

network-address

Specifies the IP address of the source subnet for Portal authentication.

The value is in dotted decimal notation.

mask-length

Specifies the mask length.

The value is an integer that ranges from 1 to 32.

mask-address

Specifies the mask of the source subnet for Portal authentication.

The value is in dotted decimal notation.

all

Deletes all Portal authentication subnets.

-

Views

GE interface view, MultiGE interface viewXGE interface view, 25GE interface view, 40GE interface view, 100GE interface view, Eth-Trunk, interface view, VLANIF interface view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

After the source subnet for Portal authentication is configured, only user packets from the source subnet can trigger Portal authentication. If an unauthenticated user is not on the source subnet for Portal authentication, the device discards the user's packets that do not match Portal authentication free rules.

The command cannot be run on Layer 2 interfaces.

The portal auth-network command takes effect only for Layer 3 Portal authentication. In Layer 2 authentication, users on all network segments must be authenticated.

Prerequisites

Before running this command on an interfaces, ensure that the Portal service template is bound to the interface.

Example

# Set the source subnet for Portal authentication to 192.168.1.0/24 on VLANIF10.
<HUAWEI> system-view
[HUAWEI] web-auth-server huawei
[HUAWEI-web-auth-server-huawei] server-ip 10.1.1.1
[HUAWEI-web-auth-server-huawei] quit
[HUAWEI] interface vlanif 10
[HUAWEI-Vlanif10] web-auth-server huawei layer3
[HUAWEI-Vlanif10] portal auth-network 192.168.1.0 24
# Set the source subnet for Portal authentication to 192.168.1.0/24 on Layer 3 interface GE0/0/1.
<HUAWEI> system-view
[HUAWEI] web-auth-server huawei
[HUAWEI-web-auth-server-huawei] server-ip 10.1.1.1
[HUAWEI-web-auth-server-huawei] quit
[HUAWEI] interface gigabitethernet0/0/1
[HUAWEI-GigabitEthernet0/0/1] undo portswitch
[HUAWEI-GigabitEthernet0/0/1] web-auth-server huawei layer3
[HUAWEI-GigabitEthernet0/0/1] portal auth-network 192.168.1.0 24
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >