1sip_get_dialog_staStees(s3iSoInP)Initiation Protocol LibrarysFiupn_cgteito_ndsialog_state(3SIP)
2
3
4

NAME

6       sip_get_dialog_state,  sip_get_dialog_callid, sip_get_dialog_local_tag,
7       sip_get_dialog_remote_tag,    sip_get_dialog_local_uri,    sip_get_dia‐
8       log_remote_uri,      sip_get_dialog_local_contact_uri,     sip_get_dia‐
9       log_remote_target_uri,      sip_get_dialog_route_set,      sip_get_dia‐
10       log_local_cseq,     sip_get_dialog_remote_cseq,    sip_get_dialog_type,
11       sip_get_dialog_method,  sip_is_dialog_secure,  sip_get_dialog_msgcnt  -
12       get dialog attributes
13

SYNOPSIS

15       cc [ flag ... ] file ... -lsip [ library ... ]
16       #include <sip.h>
17
18       int sip_get_dialog_state(sip_dialog_t dialog, int *error);
19
20
21       const sip_str_t *sip_get_dialog_callid(sip_dialog_t dialog,
22            int *error);
23
24
25       const sip_str_t *sip_get_dialog_local_tag(sip_dialog_t dialog,
26            int *error);
27
28
29       const sip_str_t *sip_get_dialog_remote_tag(sip_dialog_t dialog,
30            int *error);
31
32
33       const struct sip_uri *sip_get_dialog_local_uri(sip_dialog_t dialog,
34            int *error);
35
36
37       const struct sip_uri *sip_get_dialog_remote_uri(sip_dialog_t dialog,
38            int *error);
39
40
41       const struct sip_uri *sip_get_dialog_local_contact_uri(
42            sip_dialog_t dialog, int *error);
43
44
45       const struct sip_uri *sip_get_dialog_remote_target_uri(
46            sip_dialog_t dialog, int *error);
47
48
49       const sip_str_t *sip_get_dialog_route_set(sip_dialog_t dialog,
50            int *error);
51
52
53       boolean_t sip_is_dialog_secure(sip_dialog_t dialog,
54            int *error);
55
56
57       uint32_t sip_get_dialog_local_cseq(sip_dialog_t dialog,
58            int *error);
59
60
61       uint32_t sip_get_dialog_remote_cseq(sip_dialog_t dialog,
62            int *error);
63
64
65       int sip_get_dialog_type(sip_dialog_t dialog,int *error);
66
67
68       int sip_get_dialog_method(sip_dialog_t dialog,int *error);
69
70
71       int sip_get_dialog_msgcnt(sip_dialog_t dialog,int *error);
72
73

DESCRIPTION

75       For  functions  that  return  a pointer of type sip_str_t, sip_str_t is
76       supplied by:
77
78         typedef struct sip_str {
79              char *sip_str_ptr;
80              int  sip_str_len;
81         }sip_str_t;
82
83
84
85       The sip_str_ptr parameter points to the start of the returned value and
86       sip_str_len supplies the length of the returned value.
87
88
89       The  sip_get_dialog_state()  returns  the state of the dialog. A dialog
90       can be in one of the following states:
91         SIP_DLG_NEW
92         SIP_DLG_EARLY
93         SIP_DLG_CONFIRMED
94         SIP_DLG_DESTROYED
95
96
97       The sip_get_dialog_callid() function returns the call  ID  value  main‐
98       tained in the dialog.
99
100
101       The  sip_get_dialog_local_tag()  and  sip_get_dialog_remote_tag() func‐
102       tions return the local and remote tag values, maintained in the dialog.
103
104
105       The      sip_get_dialog_local_uri(),       sip_get_dialog_remote_uri(),
106       sip_get_dialog_local_contact_uri(),    and   sip_get_dialog_remote_tar‐
107       get_uri() functions return the local, remote, local contract,  and  the
108       remote target URIs, maintained in the dialog.
109
110
111       The  sip_get_dialog_route_set() function returns the route set, if any,
112       maintained in the dialog.
113
114
115       The sip_get_dialog_local_cseq() and sip_get_dialog_remote_cseq()  func‐
116       tions  return  the local and remote CSEQ numbers maintained in the dia‐
117       log.
118
119
120       The sip_get_dialog_type() function returns one of the following  dialog
121       types, depending on whether it is created by the client or the server.
122
123       SIP_UAC_DIALOG    created by client
124
125
126       SIP_UAS_DIALOG    created by server
127
128
129
130       The  sip_get_dialog_method() function returns the SIP method, INVITE or
131       SUBSCRIBE, of the request that created the dialog.
132
133
134       The sip_is_dialog_secure() function returns B_TRUE  if  the  dialog  is
135       secure and B_FALSE otherwise.
136
137
138       The sip_get_dialog_msgcnt() function returns the number of SIP messages
139       (requests and responses) that were sent and received within the context
140       of the given dialog.
141

RETURN VALUES

143       The  sip_get_dialog_state(),  sip_get_dialog_local_cseq(), sip_get_dia‐
144       log_remote_cseq(), sip_get_dialog_type(), sip_get_dialog_method(),  and
145       sip_get_dialog_msgcnt()  functions return the required value on success
146       and -1 on failure.
147
148
149       The sip_get_dialog_callid(),  sip_get_dialog_local_tag(),  sip_get_dia‐
150       log_remote_tag(),        sip_get_dialog_local_uri(),       sip_get_dia‐
151       log_remote_uri(),   sip_get_dialog_local_contact_uri(),    sip_get_dia‐
152       log_remote_target_uri(),   and   sip_get_dialog_route_set()   functions
153       return the required value on success and NULL on failure.
154
155
156       The value of errno is not changed by these calls in  the  event  of  an
157       error.
158

ERRORS

160       These functions take an error argument.
161
162
163       If the error is non-null, one of the following values is set:
164
165       EINVAL
166
167           The  dialog  is  NULL  or  the  stack  is  not configured to manage
168           dialogs.
169
170
171       ENOTSUP
172
173           The input SIP message cannot be modified.
174
175
176       ENOMEM
177
178           The memory allocation fails when the request/response line  or  the
179           headers in the ACK request are created.
180
181
182
183       On success, the value of the location pointed to by error is set to 0.
184

ATTRIBUTES

186       See attributes(5) for descriptions of the following attributes:
187
188
189
190
191       ┌─────────────────────────────┬─────────────────────────────┐
192       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
193       ├─────────────────────────────┼─────────────────────────────┤
194       │Interface Stability          │Committed                    │
195       ├─────────────────────────────┼─────────────────────────────┤
196       │MT-Level                     │MT-Safe                      │
197       └─────────────────────────────┴─────────────────────────────┘
198

SEE ALSO

200       libsip(3LIB)
201
202
203
204SunOS 5.11                        11 Jan 2008       sip_get_dialog_state(3SIP)
Impressum