HP-UX C SIP Stack Programmer's Guide (Novembery 2007)
98 HP-UX C SIP Stack Programmer’s Guide
Transaction API
PROXY TRANSACTION
C
ONTROL
The Transaction API contains a set of functions dedicated to the implementation
of a Proxy server. Using these functions, you can proxy requests and responses
between two UAs.
RvSipTransactionSetKeyFromMsg()
Initializes the transaction key from a given message. The following fields will
be set in the transaction:
To and From (including tags)
Call-ID
CSeq step
Before calling this function you should call
RvSipTranscMgrCreateTransaction() to create a new transaction. This function
will normally be used by proxy implementations. Before a proxy server can
proxy a request it should:
1. Create a new client transaction with
RvSipTranscMgrCreateTransaction().
2. Get the received message from the server transaction using the
RvSipTransactionGetReceivedMsg() function.
3. Set the transaction key using the
RvSipTransactionSetKeyFromMsg() function. The proxy can
then use the initialized client transaction to proxy the request.
RvSipTransactionRequestMsg()
Use this function to send a prepared Request message to the remote party. Proxy
implementations will use this function in order to proxy a received request. The
request is sent according to the Request-URI found in the message. The
application is responsible for setting the correct Request-URI in the message
and for applying the Record-Route rules when necessary.
Note This function cannot be used for sending a CANCEL request.