1sip_branchid(3SIP)Session Initiation Protocol Library Functionssip_branchid(3SIP)
2
3
4

NAME

6       sip_branchid - generate a RFC 3261 complaint branch ID
7

SYNOPSIS

9       cc [ flag ... ] file ... -lsip [ library ... ]
10       #include <sip.h>
11
12       char *sip_branchid(sip_msg_t sip_msg);
13
14

DESCRIPTION

16       The  sip_branchid()  function  can  be used to generate a value for the
17       branch parameter for a VIA header. The returned string is prefixed with
18       z9hG4bK  to conform to RFC 3261. If sip_msg is null or sip_msg does not
19       have a VIA header, a random value is generated. Otherwise, the value is
20       generated  using  the  MD5 hash of the VIA, FROM, CALL-ID, CSEQ headers
21       and the URI from the request line. The caller is responsible for  free‐
22       ing the returned string.
23

RETURN VALUES

25       The  sip_branchid()  function  returns  a string on success and NULL on
26       failure.
27
28
29       The value of errno is not changed by these calls in  the  event  of  an
30       error.
31

ATTRIBUTES

33       See attributes(5) for descriptions of the following attributes:
34
35
36
37
38       ┌─────────────────────────────┬─────────────────────────────┐
39       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
40       ├─────────────────────────────┼─────────────────────────────┤
41       │Interface Stability          │Committed                    │
42       ├─────────────────────────────┼─────────────────────────────┤
43       │MT-Level                     │MT-Safe                      │
44       └─────────────────────────────┴─────────────────────────────┘
45

SEE ALSO

47       libsip(3LIB)
48
49
50
51SunOS 5.11                        25 Jan 2007               sip_branchid(3SIP)
Impressum