[OpenSIPS-Users] SUSPECT: Rewrite From Header In CANCEL forwarded packet

Marc Leurent marc.leurent at vtx-telecom.ch
Fri Mar 13 10:57:03 CET 2009


Good Morning,
I'am using a loadbalanced platform with dispatcher module. When a packet is 
sent from a Gateway to a peer, I rewrite the From Header which contains the 
IP of the gateway in order to put the proxy domain because some Hardphones 
like
Thomson ST2030 will keep the domain in call history to be able to call back a 
person. If the UA use the direct IP of the gateway, the call will failed, it 
has to go through the proxy! So I would like to rewrite From header coming 
from gateways

It's working for INVITE, OPTIONS,... in main route, but CANCEL packets are not 
rewritten and UA sent back a message saying transaction does not exists 
because From header is different from INVITE!

I have put this in main route:

if (ds_is_from_list()) {        # Returns true if the current request comes 
from a host from the dispatcher-list
         xlog("L_INFO", "Rewriting From Domain in $rm $(hdr(From))");
       #subst('/^From:(.*)@xxx.xxx.xxx.[0-9]+(.*)$/From:
\1 at xxx-dev.xxx.xx\2/ig');
}

Have you got any idea how to rewrite CANCEL packet?
I have tried to put the same thing in failure route but it does not work.

Thanks

Best Regards

-- 
-- --
Marc LEURENT
Ingénieur VoIP

DECKPOINT SA
Une société du groupe VTX Telecom
================================================================
Rue Eugène-Marziano 15 - 1227 Les Acacias
http://www.vtx.ch - marc.leurent at vtx-telecom.ch
----------------------------------------------------------------
VTX, votre partenaire telecom proche de vous !
================================================================



More information about the Users mailing list