Forum Discussion
symtex_22198
Nimbostratus
Jul 23, 2009modify SIP contact header param
Hi,
we are using a location server which basically gets SIP invites from a SIP proxy then sends 302 redirect messages.
I have been trying to modify the IP address paramet...
symtex_22198
Nimbostratus
Jan 08, 2010today I tried to modify my irule to insert the ip address of the client instead of the IP address being statically configured in the irule
I got the following error, this is strange I thought it would be supported:
Jan 7 14:05:17 tmm tmm[1995]: 01220001:3: TCL error: SIP_SG_Redirect - Error: No clientside connection established (line 20) invoked from within "IP::client_addr"
here is the irule as it is now:
when SIP_RESPONSE {
Check for 302 responses
if {[SIP::response code] == 302}{
Parse the Contact header value "16601003" using scan
% scan {"16601003"} {%[^<]%[^@]@%[^:]:%s} a b c d
4
% puts "$a $b $c $d"
"16601003"
if {[scan [SIP::header value "Contact"] {%[^<]%[^@]@%[^:]:%s} a b c d] == 4}{
parsed 4 strings into a b c d
log local0. "Parsed [SIP::header value "Contact"] into $a, $b, $c $d"
Remove existing Contact header
SIP::header remove "Contact"
Insert new Contact header with 172.24.106.70 set as a static IP address
On January 07 2010 I modified the script to enter the client source IP address instead
of statically setting the SIP server's IP address
SIP::header insert "Contact" "${b}@[IP::client_addr]>"
log local0. "Inserting new Contact header: ${b}@[IP::client_addr]>"
}
}
}
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