SIP protocol structure through an example
(2 of 20)
SIP 407 response from Proxy1 to Alice's UA
and SIP ACK from UA to Proxy1
At Proxy 1:
The proxy core TU sends back a 407 (Proxy Authentication Required) response.
The server transaction enters the "completed" state and passes the 407 response to transport. When ACK (request) is received: passes to "confirmed" state and starts the I timer. When the I timer fires, the server transaction is destroyed.
The server transport:
before sending the response: retrieve IP@ & port from 'sent-by' and "received"
when receiving the (ACK) request: by examining 'sent-by' parameter in top Via header field, matches it to relevant server transaction + adds "received" parameter.
At Initiating UA:
The client transport:
When receiving the response: matches it to the relevant client transaction by examining 'sent-by' parameter in top Via header field
Before sending the (ACK) request: inserts 'sent-by' parameter in Via header field.
When receiving the 407 response, the client transitions to state="completed", passes the response up to the TU, generates an ACK, and passes it to transport. D timer started. When D timer fires, the client transaction is destroyed.
The UAC analyses the response and prepares a new INVITE request.