Session-Id AVP

Description of AVP




The Session-Id AVP (AVP Code 263) is of type UTF8String and the maximum length is 139 bytes. It is used to identify a specific session. All messages pertaining to a specific session must include only one Session-Id AVP and the same value must be used throughout the life of a session. When present, the Session-Id should appear immediately following the Diameter Header.

The Session-Id must be globally and eternally unique, as it is meant to uniquely identify a user session without reference to any other information, and may be needed to correlate historical authentication information with accounting information. The Session-Id includes a mandatory portion and an implementation-defined portion; a recommended format for the implementation-defined portion is outlined below.
  • <DiameterIdentity><high 32 bits><low 32 bits>[<optional value>]

    • <high 32 bits> and <low 32 bits> are decimal representations of the high and low 32 bits of a monotonically increasing 64-bit value. The 64-bit value is rendered in two parts to simplify formatting by 32-bit processors. At startup, the high 32 bits of the 64-bit value MAY be initialized to the time, and the low 32 bits MAY be initialized to zero. This will for practical purposes eliminate the possibility of overlapping Session-Ids after a reboot, assuming the reboot process takes longer than a second. Alternatively, an implementation may keep track of the increasing value in non-volatile memory.

    • <optional value> is implementation specific but may include a modem's device ID, a layer 2 address, or a timestamp.

The Session-Id AVP is created by the Diameter application initiating the session, which in most cases is done by the client. Note that a Session-Id may be used for both the authorization and accounting commands of a given application.


The Session-Id AVP has a maximum of 127 bytes. This AVP is generated by the PCEF and must be unique on the entire network to avoid misoperation when resources are inconsistent.

On an NetEngine 8000 F, the format is:
  • host-name: the local host name of the NetEngine 8000 F.
  • active-time: the TICK value of the subrack, 32 bits.
  • MID: a fixed value of 1. It is 32 bits.
  • user-ID: the index of a user.

Reference Standards

RFC 3588 clause 8.8

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >