p (5) 200 OK SIP: Protocol Operation If a three-way handshake were in place for this scenario, Laura would not receive an ACK for her 200 OK response, given that Bob gave up some time ago. Thus, she would (correctly) think that the session was not estab- lished. CANCEL CANCEL requests cancel pending transactions. If a SIP server has received an INVITE but not yet returned a final response, it will stop processing the INVITE upon receipt of a CANCEL. If, however, it has already returned a final response for the INVITE, the CANCEL request will have no effect on the transaction. In Figure 5-4, Bob calls Laura and her SIP phone begins ringing, but nobody picks up for a while. Bob decides to hang up. He sends a CANCEL request for his previous INVITE. Upon reception of the CANCEL, Laura's SIP phone stops ringing. The server sends back a 200 OK response for the CANCEL, indicating that it was processed successfully. It is important to remark that after the server has responded to the CANCEL request, it responds to the previous INVITE as well. It sends a "487 Transaction Cancelled" and the client finishes the INVITE three-way handshake by sending an ACK (INVITE-487 Transaction Cancelled-ACK). Therefore, the INVITE three-way handshake is always performed, even when the transaction is cancelled. CANCEL requests are useful when forking proxies (proxies that issue more than one INVITE upon reception of just one INVITE) are in the path. When a forking proxy is performing a parallel search, it tries several loca- tions at once. For example, a forking proxy knows of three possible locations Laura Figure 5-4 Bob cancels his (1) INVITE INVITE. (2) 180 Ringing (3) CANCEL (4) 200 OK (5) 487 Transaction cancelled (6) ACK Chapter 5 where Bob might be reachable: SIP:Bob@131.160.1.112, SIP: Bob. .Johnson@ company.com, and SIP:Bob@university.com. When this proxy receives an INVITE from Laura to Bob, it will try these three locations in parallel (at the same time). The forking proxy sends three INVITES, one to each loca- tion. Bob, who is