Forum Discussion
avi_krivorot_73
Nimbostratus
Feb 02, 2007Modifying SIP VIA header
Hi,
When we get a SIP INVITE from someone, the F5 always appends something to the reply message (TRYING) in the VIA header, see example:
Original INVITE:
Via: SIP/2.0/UDP 208.71.172.16:5060;branch=z9hG4bK-76ff6f00ffffff10ff000018ff2fff20
Reply TRYING:
Via: SIP/2.0/UDP 208.71.172.16:5060;branch=z9hG4bK-76ff6f00ffffff10ff000018ff2fff20;received=208.71.172.12
I need to strip the extra information ";received=208.71.172.12".
I noticed there is an iRule function for this. Does anyone know how this is done?
- Dave_Wiley
Nimbostratus
You could just do a findstr on the UDP::Payload for the "received" text and remove it from the packet. - avi_krivorot_73
Nimbostratus
thanks for the information, although this packet is still part of the sip signaling, not the payload. Can i still use the UDP::Payload? - Tao_Liu_90341Historic F5 AccountFirst of all, string ";received=xxx" was added by the server behind F5 box, NOT Bigip.
rule xxx { when SERVER_DATA { if {[regexp -indices {(;received=[0-9.]+)} [UDP::payload] location] == 1} { set offset [lindex $location 0] set len [expr [lindex $location 1] - [lindex $location 0] + 1] UDP::payload replace $offset $len "" } } }
- Al_Walter_10251
Nimbostratus
What version of code are you running? Here is what I get if I tried your sample: - avi_krivorot_73
Nimbostratus
I am running 9.4. I'm not sure if your version supports this.
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects