Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 RFC4028 Session Timer in the Session Initiation Protocol Speaker : Ying Shun Lin Adviser : Quincy Wu.

Similar presentations


Presentation on theme: "1 RFC4028 Session Timer in the Session Initiation Protocol Speaker : Ying Shun Lin Adviser : Quincy Wu."— Presentation transcript:

1 1 RFC4028 Session Timer in the Session Initiation Protocol Speaker : Ying Shun Lin Adviser : Quincy Wu

2 2 Outline Introduction Session-Expires Header field Definition Min-SE Header field Definition 422-Response Code Definition UAC / Proxy / UAS Behavior Security Considerations Example call Flow

3 3 Introduction (1/3) SIP does not define a keepalive mechanism for the sessions it establishes UAC INVITE 100 Trying BYE call stateful proxy will retain state for the call

4 4 Introduction (2/3) This extension defines a keepalive mechanism for SIPSIP sessions. UAs send periodic (re-INVITE or UPDATE) requests (referred to as session refresh requests) to keep the session alive. If a session refresh request is not received before the interval passes , the session is considered terminated. Both UAs are supposed to send a BYE , and call stateful proxies can remove any state for the call.

5 5 Introduction (3/3) Two new header fields (Session-Expires and Min-SE) and a new response code (422) are defined - Session-Expires : conveys the duration of the session - Min-SE : conveys the minimum allowed value for the session expiration. - 422 response : indicates that the session timer duration was too small.

6 6 Define some terms Session Interval Session Expiration Session Refresh Request Initial Session Refresh Request Subsequent Session Refresh Request Refresh

7 7 Session-Expires Header Field Definition placed only in requests ( INVITE or UPDATE), as well as in any 2xx response to request. MUST be prepared to handle Session-Expires header field values of any duration greater than 90 ; 1800 seconds (30 minutes) is RECOMMENDED. insert the Session-Expires header field SHOULD NOT choose values of less than 30 minutes. Session-Expires:1800;refresher=uac

8 8 Min-SE Header Field Definition used in an request (INVITE or UPDATE) , it indicates the smallest value of the session interval that can be used for that session. MUST NOT be less than 90 seconds - When the header field is not present, its default value for is 90 seconds. MUST NOT be used in responses except for those with a 422 response code. Min-SE:90

9 9 422 Response Code Definition Session Interval Too Small - generated by a UAS or proxy when a request contains a Session-Expires header field with a duration below the minimum timer for the server. MUST contain a Min-SE header field with the minimum timer for that server.

10 10 Session-Expire & Min-SE Header Fields

11 11 UAC Behavior Generating an Initial Session Refresh Request Processing a 2xx Response Processing a 422 Response Generating Subsequent Session Refresh Requests

12 12 UAC /Proxy Behavior UAC proxy INVITE Supported :timer Session Expires: XX ; refresher = ‘ uac` Min-SE: XX Require: timer Supported: timer Session-Expires : ; refresher= 422 200 Session Interval Too Small Min-SE :

13 13 UAC Behavior UAC INVITE proxy If a UAC knows that its peer supports the UPDATE method RECOMMENDED that UPDATE be used instead of a re-INVITE Supported :timer Session Expires: XX ; refresher = ‘ uac/uas ’ Min-SE: XX 422 Min-SE : xx

14 14 Proxy Behavior The proxy processing rules require the proxy to remember information between the request and response, ruling out stateless proxies. - Processing of Requests - Processing of Responses - Session Expiration

15 15 Proxy Behavior (Request) call failure Supported :timer Session Expires: (small) INVITE Session Expires: XX Min-SE: XX Session Expires: XX Min-SE: XX INVITE Proxy 1 Proxy 2

16 16 UAS did not support the session timer Proxy Behavior (Response) UAS ( proxy remembers UAC did not support ) There is no session expiration for this session (proxy remembers that the UAC did support the session timer ) Session-Expires ( from the forwarded request ) refresher :`uac` Session Expires

17 17 UAS Behavior UAS Supported :timer Session Expires: Min-SE : INVITE 422 Min-SE: proxy 200 ok Session Expires: Min-SE:

18 18 UAS Behavior UAC supports?Refresher parameter in request refresher parameter in response Nnoneuas NuacNA NuasNA Ynoneuas or uac Yuac Yuas

19 19 Security Considerations(1/3) Inside Attacks Case 1: a rogue UAC that wishes to force a UAS to generate refreshes at a rapid rate - The UAS or any proxy that objects to this low timer will reject the request with a 422, thereby preventing the attack.

20 20 Security Considerations(2/3) Case2: rogue UAS that wishes to force a UAC to generate refreshes at a rapid rate. - UAC copy the current session interval into the Session-Expires header field in the request. The proxies will reject this request and provide a Min-SE with a higher minimum, which the UAC will then use.

21 21 Security Considerations(3/3) Outside Attacks - An element that can observe and modify a request or response in transit can force rapid session refreshes. - proxies that record-route and request session timer SHOULD record-route with a SIPS URI. A UA that inserts a Session-Expires header into a request or response SHOULD include a Contact URI that is a SIPS URI.

22 22 Example Call Flow Alice Proxy P1 Proxy P2 Bob (1)INVITE SE:90 (2)422 MSE:3600 (3)ACK (4)INVITE SE:3600 MSE:3600 (1) INVITE sips:bob@biloxi.example.com SIP/2.0 Via: SIP/2.0/TLS pc33.atlanta.example.com;branch=z9hG4bKnashds8 Supported: timer Session-Expires: 90 Max-Forwards: 70 To: Bob From: Alice ;tag=1928301774 Call-ID: a84b4c76e66710 CSeq: 314159 INVITE Contact: Content-Type: application/sdp Content-Length: 142 (2) SIP/2.0 422 Session Interval Too Small Via: SIP/2.0/TLS pc33.atlanta.example.com;branch=z9hG4bKnashds8 ;received=192.0.2.1 Min-SE: 3600 To: Bob ;tag=9a8kz From: Alice ;tag=1928301774 Call-ID: a84b4c76e66710 CSeq: 314159 INVITE (4) INVITE sips:bob@biloxi.example.com SIP/2.0 Via: SIP/2.0/TLS pc33.atlanta.example.com;branch=z9hG4bKnashds9 Supported: timer Session-Expires: 3600 Min-SE: 3600 Max-Forwards: 70 To: Bob From: Alice ;tag=1928301774 Call-ID: a84b4c76e66710 CSeq: 314160 INVITE Contact: Content-Type: application/sdp Content-Length: 142

23 23 Example Call Flow Alice Proxy P1 Proxy P2 Bob (5)INVITE SE:3600 MSE:3600 (6)422 MSE:4000 (7)ACK (8)422 MSE:4000 (9)ACK (10)INVITE SE:4000 MSE:4000 (10) INVITE sips:bob@biloxi.example.com SIP/2.0 Via: SIP/2.0/TLS pc33.atlanta.example.com;branch=z9hG4bKnashds10 Supported: timer Session-Expires: 4000 Min-SE: 4000 Max-Forwards: 70 To: Bob From: Alice ;tag=1928301774 Call-ID: a84b4c76e66710 CSeq: 314161 INVITE Contact: Content-Type: application/sdp Content-Length: 142

24 24 Example Call Flow Alice Proxy P1 Proxy P2 Bob (11)INVITE SE:4000 MSE:4000 (12)INVITE SE:4000 MSE:4000 (13)200OK SE:4000 (14)200OK SE:4000 (15)200OK SE:4000 (16)ACK (17)ACK (15) SIP/2.0 200 OK Via: SIP/2.0/TLS pc33.atlanta.example.com;branch=z9hG4bKnashds10 ;received=192.0.2.1 Require: timer Supported: timer Record-Route: sips:p1.atlanta.example.com Session-Expires: 4000;refresher=uac To: Bob ;tag=9as888nd From: Alice ;tag=1928301774 Call-ID: a84b4c76e66710 CSeq: 314161 INVITE Contact: Content-Type: application/sdp Content-Length: 142

25 25 Example Call Flow Alice Proxy P1 Proxy P2 Bob (18)UPDATE SE:4000 (19)UPDATE SE:4000 (20)200OK SE:4000 (21)200OK SE:4000 (22)BYE (23)BYE (24)408 (Request Timeout) (18) UPDATE sips:bob@192.0.2.4 SIP/2.0 Via: SIP/2.0/TLS pc33.atlanta.example.com;branch=z9hG4bKnashds12 Route: sips:p1.atlanta.example.com Supported: timer Session-Expires: 4000;refresher=uac Max-Forwards: 70 To: Bob ;tag=9as888nd From: Alice ;tag=1928301774 Call-ID: a84b4c76e66710 CSeq: 314162 UPDATE Contact:


Download ppt "1 RFC4028 Session Timer in the Session Initiation Protocol Speaker : Ying Shun Lin Adviser : Quincy Wu."

Similar presentations


Ads by Google