Forum Discussion

Ivo_Brett_39329's avatar
Ivo_Brett_39329
Icon for Nimbostratus rankNimbostratus
Dec 01, 2004

IRules for SIP

Hi,

 

 

Do any of you know if there are iRules that can be developed for the SIP (session initiation protocol). So that rules can be developed as in the following example:

 

 

when SIP_REQUEST {

 

if { [ SIP::uri ] starts_with "@fwd.pulver.com" } {

 

SIP::uri [ findstr [SIP::uri] "@fwd.pulver.com" 7 ]

 

pool sip_pool1

 

}

 

pool sip_pool2

 

}

 

 

This would be fairly cool stuff if it can be done. If not, any ideas if its possible to write an iRules library that can take care of the parsing of Sip messages?

 

 

Thanks,

 

Ivo

 

2 Replies

  • Tao_Liu_90341's avatar
    Tao_Liu_90341
    Historic F5 Account
    ivobrett,

     

     

    This rule is not available but not far away. Before that, it is possible to extract certain field out of SIP message in the case of running over UDP. I don't have sample, but you can scan the first two tokens in the payload. The second one is URI. No guarantee ;-) i.e.

     

     

    when CLIENT_DATA {

     

    scan [UDP::payload] "%s%s" sipmethod sipuri

     

    puts "$sipuri"

     

    }