[Serusers] How to remove Contact HF in 200 reply for REGISTER

Jan Janak jan at iptel.org
Wed Mar 1 10:40:44 CET 2006


Arek Bekiersz wrote:
> Hi,
> 
> 
> How to disable sending Contact HF in OK send to a successful (i.e.
> authenticated) REGISTER request?

  Use:

  save_noreply("location");
  sl_send_reply("200", "OK");

  This will send 200 OK without Contacts.

     Jan.

> Just use remove_hf() from textops or there is other option?
> 
> I've got stupid UA that behaves badly when working behind NAT. First it
> sends REGISTER without anything (no Contact, Expires). On successful
> authentication SER responds 200 OK with Contact HF, set to public IP,
> exactly how SER sees UA behind NAT (like some_IP:61001).
> Then the stupid UA sends another REGISTER message, this time with
> Contact and Via HF set to this public value (i.e. some_IP:61001).
> 
> It spoils my nathelper/rtpproxy detection of devices behind NAT.
> Of course I can enable it by regexp on User-Agent HF, but his is not an
> option, as plenty of those UAs runs not behind NAT.
> 
> 
> 




More information about the sr-users mailing list