#include <sofia-sip/su_wait.h>
#include <sofia-sip/url.h>
#include <sofia-sip/sip.h>
#include <sofia-sip/nua_tag.h>
Include dependency graph for nua.h:
enum nua_event_e |
Events.
The NUA event loop calls an event callback function when an application needs to act on something that happened in the Sofia stack. The callback function is registered when nua_create() function call is used to create the NUA stack object.
The prototype of the event callback function is:
void nua_callback_f(nua_event_t event, int status, char const *phrase, nua_t *nua, nua_magic_t *magic, nua_handle_t *nh, nua_hmagic_t *hmagic, sip_t const *sip, tagi_t tags[]);
event | Callback event identification. Always present | |
status | Protocol status code. Always present | |
phrase | Text corresponding to status code. Always present | |
nua | Pointer to NUA stack object. Always present | |
magic | Pointer to callback context from nua_create(). Always present | |
nh | Pointer to operation handle. | |
hmagic | Pointer to callback context from nua_handle(). | |
sip | Parsed incoming message. | |
tags | Tag list containing more information about the state of NUA. |
The events can be divided into the following categories:
nua_i_error |
Error indication.
Will be sent when an internal error happened or an error occurred while responding a request.
| ||||||||||||||||||
nua_i_invite |
Incoming call.
| ||||||||||||||||||
nua_i_cancel |
Incoming INVITE has been cancelled.
Incoming INVITE has been cancelled or no ACK has been received for an accepted call.
| ||||||||||||||||||
nua_i_ack | Response to INVITE has been ACKed. | ||||||||||||||||||
nua_i_fork |
Outgoing call has been forked.
This is sent when an INVITE request is answered with multiple 200 responses.
| ||||||||||||||||||
nua_i_active |
A call has been activated.
This event will be sent after succesful response to the initial INVITE has been received and the media has been activated.
| ||||||||||||||||||
nua_i_terminated |
A call has been terminated.
This event will be sent after a call has been terminated. A call is terminated, when 1) an error response (300..599) is sent to an incoming initial INVITE 2) a reliable response (200..299 or reliable preliminary response) to an incoming initial INVITE is not acknowledged with ACK or PRACK 3) BYE is received or sent
| ||||||||||||||||||
nua_i_state |
Call state has changed.
This event will be sent whenever the call state changes. In addition to basic changes of session status, also SDP O/A negotiation status is included. Note that nua_event_e::nua_i_state also covers call establisment (
| ||||||||||||||||||
nua_i_outbound |
Status from outbound processing.
The REGISTER may be sent explicitly by nua_register() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_i_bye |
Incoming call hangup.
| ||||||||||||||||||
nua_i_options |
Incoming options.
| ||||||||||||||||||
nua_i_refer |
Incoming call transfer.
| ||||||||||||||||||
nua_i_publish |
Incoming PUBLISH.
| ||||||||||||||||||
nua_i_prack | Incoming PRACK. | ||||||||||||||||||
nua_i_info |
Incoming session INFO.
| ||||||||||||||||||
nua_i_update |
Incoming session UPDATE.
| ||||||||||||||||||
nua_i_message |
Incoming MESSAGE.
| ||||||||||||||||||
nua_i_chat |
Incoming chat MESSAGE.
| ||||||||||||||||||
nua_i_subscribe |
Incoming subscription.
Not implemented.
| ||||||||||||||||||
nua_i_subscription |
Incoming subscription to be authorized.
This event is launched by nua_notifier to inform application of the current state of the subscriber and to authorize the subscriber.
| ||||||||||||||||||
nua_i_notify |
Incoming event.
| ||||||||||||||||||
nua_i_method |
Incoming, unknown method.
The extension method must be listed using SIPTAG_ALLOW tag in nua_set_options().
| ||||||||||||||||||
nua_i_media_error |
Offer-answer error indication.
This may be sent after an implicit media operation has failed while processing incoming or outgoing call.
| ||||||||||||||||||
nua_r_set_params | Answer to nua_set_params(). | ||||||||||||||||||
nua_r_get_params |
Answer to nua_get_params() or nua_get_hparams().
| ||||||||||||||||||
nua_r_shutdown |
Answer to nua_shutdown().
Status codes 100 shutdown started
| ||||||||||||||||||
nua_r_notifier |
Answer to nua_notifier().
| ||||||||||||||||||
nua_r_terminate |
Answer to nua_terminate().
| ||||||||||||||||||
nua_r_authorize | Answer to nua_authorize(). | ||||||||||||||||||
nua_r_register |
Answer to outgoing REGISTER.
The REGISTER may be sent explicitly by nua_register() or implicitly by NUA state machines. The status may be 100 even if the real response status returned is different if the REGISTER request has been restarted.
| ||||||||||||||||||
nua_r_unregister |
Answer to outgoing un-REGISTER.
| ||||||||||||||||||
nua_r_invite |
Answer to outgoing INVITE.
The INVITE may be sent explicitly by nua_invite() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_r_cancel | Answer to outgoing CANCEL. | ||||||||||||||||||
nua_r_bye |
Answer to outgoing BYE.
The BYE may be sent explicitly by nua_bye() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_r_options |
Answer to outgoing OPTIONS.
| ||||||||||||||||||
nua_r_refer |
Answer to outgoing REFER.
| ||||||||||||||||||
nua_r_publish |
Answer to outgoing PUBLISH.
The PUBLISH may be sent explicitly by nua_publish() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_r_unpublish |
Answer to outgoing un-PUBLISH.
The PUBLISH may be sent explicitly by nua_publish() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_r_info |
Answer to outgoing INFO.
| ||||||||||||||||||
nua_r_prack | Answer to outgoing PRACK. | ||||||||||||||||||
nua_r_update |
Answer to outgoing UPDATE.
The UPDATE may be sent explicitly by nua_update() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_r_message |
Answer to outgoing MESSAGE.
| ||||||||||||||||||
nua_r_chat |
Answer to outgoing chat message.
| ||||||||||||||||||
nua_r_subscribe |
Answer to outgoing SUBSCRIBE.
The SUBSCRIBE may be sent explicitly by nua_subscribe() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_r_unsubscribe |
Answer to outgoing un-SUBSCRIBE.
| ||||||||||||||||||
nua_r_notify |
Answer to outgoing NOTIFY.
The NOTIFY may be sent explicitly by nua_notify() or implicitly by NUA state machine.
| ||||||||||||||||||
nua_r_method | Answer to unknown outgoing method. |
SOFIAPUBFUN void nua_ack | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Acknowledge a succesfull response to INVITE request.
Acknowledge a successful response to INVITE request with SIP ACK message. This function is need only if NUTAG_AUTOACK() parameter has been cleared.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_authenticate | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Authenticate an operation.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_authorize | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Authorize a subscriber.
After creating a local presence server by nua_notifier(), an incoming subscriber launches nua_i_subscription event. Subscriber can be authorized in this application callback.
NUTAG_SUB() tag NUTAG_SUBSTATE() tag
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_bye | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Hangdown a call.
Hangdown a call using SIP BYE method. Also the media session associated with the call is terminated.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_cancel | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Cancel an INVITE operation.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_chat | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Send a chat message.
A chat channel can be established during call setup using "message" media. An active chat channel is indicated using nua_i_active event containing SOATAG_ACTIVE_CHAT tag. Chat messages can be sent using this channel with nua_chat() function. Currently this is implemented using SIP MESSAGE requests but in future MSRP (message session protocol) will replace it.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN nua_t* nua_create | ( | su_root_t * | root, | |
nua_callback_f | callback, | |||
nua_magic_t * | magic, | |||
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Create a NUA agent.
This function creates a Sofia-SIP User Agent stack object (nua) and initializes its parameters by given tagged values.
root | Pointer to a root object | |
callback | Pointer to event callback function | |
magic | Pointer to callback context | |
tag, value, ... | List of tagged parameters |
!=NULL | a pointer to a NUA stack object | |
NULL | upon an error |
SOFIAPUBFUN nua_handle_t* nua_default | ( | nua_t * | nua | ) |
Obtain default operation handle of the NUA stack object.
A default operation can be used for operations where the ultimate result is not important or can be discarded.
nua | Pointer to NUA stack object |
!=NULL | Pointer to NUA operation handle | |
NULL | No default operation exists |
SOFIAPUBFUN void nua_destroy | ( | nua_t * | nua | ) |
Destroy the NUA stack.
Before calling nua_destroy() the application should call nua_shutdown and wait for successful nua_r_shutdown event. Shuts down and destroys the NUA stack. Ongoing calls, registrations, and subscriptions are left as they are.
nua | Pointer to NUA stack object |
SOFIAPUBFUN void nua_get_hparams | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Get handle parameters.
Application will specify either expilicit list of tags it is interested in, or a filter (at the moment, TAG_ANY()). The values are returned as a list of tags in the nua_r_get_params event.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
nua_get_hparams(nua_default(nua), TAG_ANY())
SOFIAPUBFUN void nua_get_params | ( | nua_t * | nua, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Get NUA parameters.
Get values of NUA parameters in nua_r_get_params event.
nua | Pointer to NUA stack object | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN nua_handle_t* nua_handle | ( | nua_t * | nua, | |
nua_hmagic_t * | hmagic, | |||
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Create an operation handle.
Allocates a new operation handle and associated storage.
nua | Pointer to NUA stack object | |
hmagic | Pointer to callback context | |
tag,value,... | List of tagged parameters |
!=NULL | Pointer to operation handle | |
NULL | Creation failed |
SOFIAPUBFUN void nua_handle_bind | ( | nua_handle_t * | nh, | |
nua_hmagic_t * | hmagic | |||
) |
Bind a callback context to an operation handle.
nh | Pointer to operation handle | |
hmagic | Pointer to callback context |
SOFIAPUBFUN void nua_handle_destroy | ( | nua_handle_t * | nh | ) |
Destroy a handle.
Destroy an operation handle and asks stack to discard resources and ongoing sessions and transactions associated with this handle. For example calls are terminated with BYE request.
nh | Pointer to operation handle |
SOFIAPUBFUN int nua_handle_has_active_call | ( | nua_handle_t const * | nh | ) |
Check if operation handle has an active call.
nh | Pointer to operation handle |
0 | no active call in operation or operation handle is invalid | |
1 | operation has established call or pending call request. |
SOFIAPUBFUN int nua_handle_has_call_on_hold | ( | nua_handle_t const * | nh | ) |
Check if operation handle has a call on hold.
Please note that this status is not affected by remote end putting this end on hold. Remote end can put each media separately on hold and status is reflected on SOATAG_ACTIVE_AUDIO, SOATAG_ACTIVE_VIDEO and SOATAG_ACTIVE_CHAT tag values in nua_i_active event.
nh | Pointer to operation handle |
0 | if no call on hold in operation or operation handle is invalid | |
1 | if operation has call on hold, for example nua_invite() or nua_update() has been called with NUTAG_HOLD() with != 0 argument. |
SOFIAPUBFUN int nua_handle_has_events | ( | nua_handle_t const * | nh | ) |
Check if handle has active event subscriptions (refers sent).
Active subscription can be established either by nua_subscribe or nua_refer() calls.
nh | Pointer to operation handle |
0 | no event subscriptions in operation or operation handle is invalid | |
!=0 | operation has event subscriptions |
SOFIAPUBFUN int nua_handle_has_invite | ( | nua_handle_t const * | nh | ) |
Check if operation handle is used for INVITE.
Check if operation handle has been used with either outgoing or incoming INVITE request.
nh | Pointer to operation handle |
0 | no invite in operation or operation handle is invalid | |
1 | operation has invite |
SOFIAPUBFUN int nua_handle_has_register | ( | nua_handle_t const * | nh | ) |
Check if operation handle has been used with nua_register() or nua_unregister().
nh | Pointer to operation handle |
0 | no active register in operation or operation handle is invalid | |
1 | operation has been used with nua_register() or nua-unregister() |
SOFIAPUBFUN int nua_handle_has_registrations | ( | nua_handle_t const * | nh | ) |
Check if operation handle has active registrations.
Either REGISTER operation is ongoing or NUA stack is expected to refresh in the future.
nh | Pointer to operation handle |
0 | no active registration in operation or operation handle is invalid | |
1 | operation has registration |
SOFIAPUBFUN int nua_handle_has_subscribe | ( | nua_handle_t const * | nh | ) |
Check if operation handle has been used with outgoing SUBSCRIBE of REFER request.
nh | Pointer to operation handle |
0 | no active subscription in operation or operation handle is invalid | |
1 | operation has subscription. |
SOFIAPUBFUN sip_to_t const* nua_handle_local | ( | nua_handle_t const * | nh | ) |
Get the local address (From/To header) of operation handle.
Local address is used as From header in outgoing operations and derived from To: header in incoming operations.
nh | Pointer to operation handle |
NULL | no local address for operation or operation handle invalid | |
!=NULL | pointer to local address for operation |
SOFIAPUBFUN nua_handle_t* nua_handle_ref | ( | nua_handle_t * | nh | ) |
Make a new reference to handle.
SOFIAPUBFUN sip_to_t const* nua_handle_remote | ( | nua_handle_t const * | nh | ) |
Get the remote address (From/To header) of operation handle.
Remote address is used as To header in outgoing operations and derived from From: header in incoming operations.
nh | Pointer to operation handle |
NULL | no remote address for operation or operation handle invalid | |
!=NULL | pointer to remote address for operation |
SOFIAPUBFUN void nua_info | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Send an INFO request.
INFO is used to send call related information like DTMF digit input events. See RFC 2976.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_invite | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Place a call using SIP INVITE method.
By default creates a media session, includes its description as SDP and send the request to the recipient. Upon receiving the response it will active the media session and establish the call.
Incomplete call can be hung-up with nua_cancel(). Completed call can be hung-up with nua_bye().
Optionally
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_message | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Send an instant message.
Send an instant message using SIP MESSAGE method.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_notifier | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Create an event server.
This function create an event server taking care of sending NOTIFY requests and responding to further SUBSCRIBE requests. The event server can accept multiple subscriptions from several sources and takes care for distributing the notifications. Unlike other functions this call only accepts the SIP tags listed below.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_notify | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Send a NOTIFY message.
This function is used when the application implements itself the subscription state machine. The application must provide valid Subscription-State and Event headers using SIP tags.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_options | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Query capabilities from server.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_prack | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Acknowledge a reliable preliminary response to INVITE request.
PRACK is used to acknowledge receipt of 100rel responses. See RFC 3262.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_publish | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Send PUBLISH request to publication server.
Request status will be delivered to the application using nua_r_publish event. When successful the publication will be updated periodically until nua_unpublish() is called or handle is destroyed. Note that the periodic updates and unpublish do not include the original message body nor the Content-Type header. Instead, the periodic update will include the SIP-If-Match header, which was generated from the latest SIP-ETag header received in response to PUBLISH request.
The handle used for publication cannot be used for any other purposes.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_refer | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Transfer a call.
Send a REFER request asking the recipient to transfer the call. The REFER request also establishes a subscription to the "refer" event. The "refer" event will have an "id" parameter, which has the value of CSeq number in the REFER request. After initiating the REFER request, the nua engine sends application a nua_r_refer event with status 100 and tag SIPTAG_EVENT() containing a matching event header.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_register | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Send SIP REGISTER request to the registrar.
Request status will be delivered to the application using nua_r_register event. When successful the registration will be updated periodically.
The handle used for registration cannot be used for any other purposes.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
First, nua_register() will probe for NATs in between UA and registrar. It will send a REGISTER request as usual. Upon receiving the response it checks for the presence of valid "received" and "rport" parameters in the Via header returned by registrar. The presence of NAT is determined from the "received" parameter in a Via header. When a REGISTER request was sent, the stack inserted the source IP address in the Via header: if that is different from the source IP address seen by the registrar, the registrar inserts the source IP address it sees into the "received" parameter.
Please note that an ALG (application-level gateway) modifying the Via headers in outbound requests and again in incoming responses will make the above-described NAT check to fail.
The response to the initial REGISTER should also include feature tags indicating whether registrar supports various SIP extensions: outbound, pref, path, gruu.
Basically, outbound means that instead of registering its contact URI with a particular address-of-record URI, the user-agent registers a transport-level connection. Such a connection is identified on the Contact header field with an instance identifier, application-provided unique string identifying the user-agent instance and a stack-generated numeric index identifying the transport-level connection.
If the outbound extension is supported, NUTAG_OUTBOUND() contains option string "outbound" and the application has provided an instance identifer to the stack with NUTAG_INSTANCE(), the nua_register() will try to use outbound.
If outbound is not supported, nua_register() has to generate a URI that can be used to reach it from outside. It will check for public transport addresses detected by underlying stack with, e.g., STUN, UPnP or SOCKS. If there are public addresses, nua_register() will use them. If there is no public address, it will try to generate a Contact URI from the "received" and "rport" parameters found in the Via header of the response message.
The nua_r_register message will include the contact header and route used in with the registration.
You can disable validation by inserting "no-validate" into NUTAG_OUTBOUND() string.
The keepalive mechanism depends on the network features detected earlier. If outbound extension is used, the STUN keepalives will be used. Otherwise, NUA stack will repeatedly send OPTIONS requests to itself. In order to save bandwidth, it will include Max-Forwards: 0 in the keep-alive requests, however. The keepalive interval is determined by NUTAG_KEEPALIVE() parameter. If the interval is 0, no keepalive messages is sent.
You can disable keepalive OPTIONS by inserting "no-options-keepalive" into NUTAG_OUTBOUND() string. Currently there are no other keepalive mechanisms available.
The value of NUTAG_KEEPALIVE_STREAM(), if specified, is used to indicate the desired transport-layer keepalive interval for stream-based transports like TLS and TCP.
SOFIAPUBFUN void nua_respond | ( | nua_handle_t * | nh, | |
int | status, | |||
char const * | phrase, | |||
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Respond with given status.
The INVITE requests should be responded with nua_intive_respond() function because there might be another request going on besides INVITE.
nh | Pointer to operation handle | |
status | SIP response status (see RFCs of SIP) | |
phrase | free text (default response phrase used if NULL) | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_set_hparams | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Set handle parameters.
nh | Pointer to a NUA handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_set_params | ( | nua_t * | nua, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Set NUA parameters.
nua | Pointer to NUA stack object | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_shutdown | ( | nua_t * | nua | ) |
Shutdown NUA stack.
Ongoing calls are released, registrations unregistered, and subscriptions terminated. If the stack cannot terminate within 30 seconds, it sends the nua_r_shutdown event with status 500.
nua | Pointer to NUA stack object |
SOFIAPUBFUN void nua_subscribe | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Subscribe a SIP event.
Subscribe a SIP event using the SIP SUBSCRIBE request. If the SUBSCRBE is successful a subscription state is established and the subscription is refreshed regularly. The refresh requests will generate nua_r_subscribe events.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_terminate | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Terminate an event server.
Terminate an event server with matching event and content type. The event server was created earlier with nua_notifier() function.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_unpublish | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Send un-PUBLISH request to publication server.
Request status will be delivered to the application using nua_r_unpublish event. The handle used for un-publication cannot be used for any other purposes.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_unregister | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Unregister.
Send a REGISTER request with expiration time 0. This removes the registration from the registrar. If the handle was earlier used with nua_register() the periodic updates will be terminated.
If a SIPTAG_CONTACT_STR() with argument "*" is used, all the registrations will be removed from the registrar otherwise only the contact address belonging to the NUA stack is removed.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_unsubscribe | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Unsubscribe an event.
Unsubscribe an active or pending subscription with SUBSCRIBE request containing Expires: header with value 0. The dialog associated with subscription will be destroyed if there is no other subscriptions or call using this dialog.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |
SOFIAPUBFUN void nua_update | ( | nua_handle_t * | nh, | |
tag_type_t | tag, | |||
tag_value_t | value, | |||
... | ||||
) |
Update a call.
Update a session using SIP UPDATE method. See RFC 3311.
Update method can be used when the session has been established with INVITE. It's mainly used during the session establishment when preconditions are used (RFC 3312). It can be also used during the call if no user input is needed for offer/answer negotiation.
nh | Pointer to operation handle | |
tag,value,... | List of tagged parameters |