radius-server format-attribute

Function

The radius-server format-attribute nas-port command configures the format of the NAS-Port attribute.

The undo radius-server format-attribute nas-port command deletes the configured attribute format.

The radius-server format-attribute calling-station-id command selects a calling-station-ID attribute format that a specified vendor defines.

The undo radius-server format-attribute calling-station-id command deletes the configured calling-station-ID attribute format.

By default, no vendor ID is specified for the encapsulation format of the Calling-Station-Id attribute. Indicates encapsulating the nas-port attribute in Huawei's default format. For details about the default format, see Usage Guidelines.

This command is supported only on the NetEngine 8000 F1A.

Format

radius-server format-attribute nas-port format-string

radius-server format-attribute calling-station-id vendor vendor-id [ include option82 ] [ version1 ]

undo radius-server format-attribute nas-port

undo radius-server format-attribute calling-station-id

Parameters

Parameter Description Value
format-string

Specifies the format.

The rule for specifying format-string is as follows:

Format 1:

  • The keywords s, t, p, o, and i stand for slot, subslot, port, out-vlan (qinqvlan)/vpi, and inner-vlan (user-vlan)/vci respectively. The keywords n and z are used as paddings. The keyword n indicates 1 and the keyword z indicates 0.
  • The keywords s, t, p, o, i, n, and z must be followed by numbers, and the numbers must range from 1 to 32. The keywords s, t, p, o, and i can be present in the format string only once.
  • The keywords s, t, p, o, i, n, and z must range from 1 to 9.
  • n and z can be present multiple times at any position. They are followed by numbers. For example, n12 indicates that this position is filled by twelve 1s, and z12 indicates that this position is filled by twelve 0s.
  • The character string must contain 32 bits.
  • The format string must start with s, t, p, o, i, n, or z and end with a number.
  • If no VLAN exists, you can add n or z before 0 or i to indicate whether this position is filled by 0s or 1s. That is, n and z can be followed by numbers or o/i in this case.
  • To specify the format string, determine the interface type, and then determine the encapsulation type of the interface. If the format string does not contain 0 or i, the NAS-Port attribute does not contain the QinQ VLAN or user VLAN field. If the format string contains 0 and i but no outer VLAN exists, the outer VLAN field is filled by 0s. If i is added before 0 or i, this field is filled by 1s when no outer VLAN or inner VLAN exists.

Format 2: m32, indicating the 32 least significant bits of a user MAC address.

The value is a string of 1 to 32 characters.

format-attribute

Indicates the format of Turkey version.

-

vendor vendor-id

Specifies the ID of a supplier.

The value is an integer ranging from 1 to 65535. Currently, only 2352, 2636, and 9 are supported.

option82

Adds the Option 82 information that begins with a number sign (#) after the vendor ID of RedBack.

The version1 keyword takes effect only when vendor-id is set to 2352.

-

version1

The Calling-Station-Id attribute is encapsulated based on the Redback-specific version1 format. In this case, the interface ID is in the slot ID/port number format, and does not include a sub-slot ID.

Version1 takes effect only when the value of vendor-id is 2352.

-

nas-port

No. 5 RADIUS attribute.

-

Views

RADIUS server group view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
radius write

Usage Guidelines

When the device is connected to a non-Huawei device, run the radius-server format-attribute nas-port command to allow the device to configure the format of the NAS-Port attribute.

To allow the device to communicate with a non-Huawei RADIUS server, run the radius-server format-attribute calling-station-id command to select a calling-station-ID attribute format that the specified vendor defines.

Example

# Configure the format of the NAS-Port attribute to s2t2p6no10ni12. That is, the NAS-Port attribute consists of a 2-bit slot field, a 2-bit subslot field, a 6-bit port field, a 10-bit outer VLAN field, and a 12-bit inner VLAN field. If the outer VLAN does not exist, this field is filled by ten 1s. Therefore, the NAS-port attribute contains 32 bits.
<HUAWEI> system-view
[~HUAWEI] radius-server group group1
[*HUAWEI-radius-group1] commit
[~HUAWEI-radius-group1] radius-server format-attribute nas-port s2t2p6no10ni12
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >