pjsip logo pjsip.org
Open source SIP stack and media stack for presence, im/instant messaging, and multimedia communication

HOME

SIP/media Features
High Performance SIP
Small Footprint SIP
Symbian Port

FAQ

Documentation

Licensing

Download

Development (Trac)

Projects using pjsip

Mailing List

Open Source Links


About: PJLIB, PJLIB-UTIL, PJSIP, and PJMEDIA are created by: Benny Prijono
<bennylp@pjsip.org>


 

Home --> Documentations --> PJNATH Reference

pj_stun_attr_hdr Struct Reference
[STUN Message Representation and Parsing]


Detailed Description

This structre describes STUN attribute header. Each attribute is TLV encoded, with a 16 bit type, 16 bit length, and variable value. Each STUN attribute ends on a 32 bit boundary:


        0                   1                   2                   3
        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
       +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
       |         Type                  |            Length             |
       +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   

Data Fields

pj_uint16_t type
pj_uint16_t length

Field Documentation

STUN attribute type.

The Length refers to the length of the actual useful content of the Value portion of the attribute, measured in bytes. The value in the Length field refers to the length of the Value part of the attribute prior to padding - i.e., the useful content.


The documentation for this struct was generated from the following file:

 


PJNATH - Open Source NAT traversal helper library supporting STUN, TURN, and ICE
(C)2001-2008 Benny Prijono