On Nov 26, 2004 at 15:42, E. Versaevel erik@infopact.nl wrote:
A bit further, I've fired up the xlog module and added a few debug lines, I'm using the following peace of config file:
[cut] xlog("L_CRIT", "Incomming sip packet\n\t\tTime [%Tf]\n\t\tMethod <%rm>\n\t\tr-uri <%ru>\n\t\tTo uri <%tu>\n\t\tSource
[...]
Contact: <"1234"
sip:1234@192.168.0.64:5061> 0(29075) Rewritten Contact header, it now is: <"1234" sip:1234@192.168.0.64:5061> [/cut]
As you can see the contact HF is not being rewritten although I did call the fix_contact() function.
The contact will be re-written when the message will be sent (you can't see the modified version with xlog, you will see it only if you dump the packet on the wire).
Anyway the contact has nothing to do with the replies going to another ip. The replies go always to the source ip of the request. The only exceptions is if you set reply_to_via to 1, in which case the reply will go to the host part of the Via header.
Are you sure you are not seeing some unrelated replies, or you have some strange DNAT rules on your sip proxy or firewall?
Andrei