Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
understanding-SIP.pdf
Скачиваний:
118
Добавлен:
01.03.2016
Размер:
4 Мб
Скачать
☆

112

SIP: Understanding the Session Initiation Protocol

 

 

 

Table 5.1

 

 

 

SIP Response Classes

 

Class

Description

Action

 

1xx

Informational

This indicates the status of the call prior to completion—also

 

known as a provisional response.

 

 

 

 

2xx

Success

The request has succeeded. If it was for an INVITE, ACK should

 

be sent; otherwise, stop the retransmissions of the request.

 

 

 

 

3xx

Redirection

The server has returned possible locations. The client should retry

 

the request at another server.

 

 

 

 

4xx

Client error

The request has failed due to an error by the client. The client may

 

retry the request if it is reformulated according to the response.

 

 

 

 

5xx

Server

The request has failed due to an error by the server. The request

 

failure

may be retried at another server.

 

 

 

6xx

Global

The request has failed. The request should not be tried again at

 

failure

this or other servers.

 

 

5.1 Informational

The informational class of responses, 1xx, is used to indicate call progress. Informational responses are end-to-end responses and may contain message bodies. The exception to this is the 100 Trying response, which is only a hop-by-hop response and may not contain a message body. Any number of informational responses can be sent by a UAS prior to a final response (2xx, 3xx, 4xx, 5xx, or 6xx class response) being sent. The first informational response received by the UAC confirms receipt of the INVITE, and stops retransmission of the INVITE, as shown in Figure 3.7. For this reason, servers returning 100 Trying responses minimize INVITE retransmissions in the network. Further informational responses have no effect on INVITE retransmissions. A stateful proxy receiving a retransmission of an INVITE will resend the last provisional response sent to date. Informational responses are optional—a UAS can send a final response without first sending an informational response. While final responses to an INVITE receive an ACK to confirm receipt, provisional responses are not acknowledged, except when using the PRACK method described in Section 4.1.13.

All provisional responses with the exception of 100 Trying must contain a Contact URI and echo all Record-Route headers received in the request. However, a RFC 2543 implementation will not do this, as it was not mandated in that document.

5.1.1100 Trying

This special case response is only a hop-by-hop request. It is never forwarded and may not contain a message body. A forking proxy must send a 100 Trying response, since the extended search being performed may take a significant amount

SIP Response Messages

113

of time. This response can be generated by either a proxy server or a user agent. It only indicates that some kind of action is being taken to process the call—it does not indicate that the user has been located. A 100 Trying response typically does not contain a To tag and hence does not create an early dialog.

5.1.2180 Ringing

This response is used to indicate that the INVITE has been received by the user agent and alerting is taking place. This response is important in the interworking of telephony protocols, and it is typically mapped to messages such as an ISDN progress or ISUP address complete message (ACM) [2]. When the user agent answers immediately, a 200 OK is sent without a 180 Ringing; this scenario is called the “fast answer” case in telephony.

A UA normally generates its own ring back tone or remote ringing indication, unless an Alert-Info header field is present.

5.1.3181 Call is Being Forwarded

This response is used to indicate that the call has been handed off to another end point. It is sent when the information may be of use to the caller. Also, because a forwarding operation may result in the call taking longer to be answered, this response gives a status for the caller.

5.1.4182 Call Queued

This response is used to indicate that the INVITE has been received and will be processed in a queue. The reason phrase can be used to indicate the estimated wait time or the number of callers in line, as shown in Figure 5.1.

5.1.5183 Session Progress

The 183 Session Progress response indicates that information about the progress of the session (call state) may be present in a message body or media stream. Unlike a 100 Trying response, a 183 is an end-to-end response and establishes a dialog (must contain a To tag and Contact). Unlike a 180, 181, or 182 response, it does not convey any specific information about the status of the INVITE. A typical use of this response is to allow a UAC to hear a ring tone, busy tone, or recorded announcement in calls through a gateway into the PSTN. This is because call progress information is carried in the media stream in the PSTN. A oneway media connection or trunk is established from the calling party’s telephone switch to the called party’s telephone switch in the PSTN prior to the call being answered. In SIP, the media session is established after the call is answered—after a 200 OK and ACK have been exchanged between the UAC and UAS. If a gateway

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]