Is there any way in which i can rewrite the From header efficiently
like i want to change this From header From: "Zeeshan"sip:shani@localhost.localdomain;tag=4a6dec6f to From: "Zeeshan"sip:shani@128.242.111.222:5060;tag=4a6dec6f
how can i do that using subst function ???? please help me thanks in advance regards
Zeeshan
--------------------------------- Check out the all-new Yahoo! Mail beta - Fire up a more powerful email and get things done faster.
Hello Zeeshan,
I don't know if the UAC module is available for SER, but in OpenSER you could try something like this......
if(from_uri=~".*@localhost.localdomain") { uac_replace_from("*$fn* ","sip:*$fU*@128.242.111.222:5060"); };
regards, Andreas
Zeeshan Sajid schrieb:
Is there any way in which i can rewrite the From header efficiently
like i want to change this From header From: "Zeeshan"sip:shani@localhost.localdomain;tag=4a6dec6f to From: "Zeeshan"sip:shani@128.242.111.222:5060;tag=4a6dec6f
how can i do that using subst function ???? please help me thanks in advance regards
Zeeshan
Check out the all-new Yahoo! Mail beta http://us.rd.yahoo.com/evt=43257/*http://advision.webevents.yahoo.com/mailbeta
- Fire up a more powerful email and get things done faster.
Serusers mailing list Serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
Yes, uac is also available for SER. g-)
Andreas Heise wrote:
Hello Zeeshan,
I don't know if the UAC module is available for SER, but in OpenSER you could try something like this......
if(from_uri=~".*@localhost.localdomain") { uac_replace_from("*$fn* ","sip:*$fU*@128.242.111.222:5060"); };
regards, Andreas
Zeeshan Sajid schrieb:
Is there any way in which i can rewrite the From header efficiently
like i want to change this From header From: "Zeeshan"sip:shani@localhost.localdomain;tag=4a6dec6f to From: "Zeeshan"sip:shani@128.242.111.222:5060;tag=4a6dec6f
how can i do that using subst function ???? please help me thanks in advance regards
Zeeshan
Check out the all-new Yahoo! Mail beta http://us.rd.yahoo.com/evt=43257/*http://advision.webevents.yahoo.com/mailbeta
- Fire up a more powerful email and get things done faster.
Serusers mailing list Serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
Serusers mailing list Serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
Andreas Heise wrote:
I don't know if the UAC module is available for SER, but in OpenSER you could try something like this......
if(from_uri=~".*@localhost.localdomain") { uac_replace_from("*$fn* ","sip:*$fU*@128.242.111.222:5060"); };
One should mention that doing this is in violation of RFC 3261. A proxy is not allowed to mess with the From- or To-URI. In practice, you should be carefull with this, still. I don't know what the function mentioned does exactly, but if a voice gateway of a certain well-known provider of networking equipment receives a response with a different From- or To-URI than what it put in the request, it will simply drop your response.[0]
The best answer to the original question IMHO is: Don't do it.
Regards, Martin
[0] Disclaimer: At least it did about two years ago. But SBCs in general are very picky with this kind of stuff.
Martin Hoffmann wrote:
Andreas Heise wrote:
I don't know if the UAC module is available for SER, but in OpenSER you could try something like this......
if(from_uri=~".*@localhost.localdomain") { uac_replace_from("*$fn* ","sip:*$fU*@128.242.111.222:5060"); };
One should mention that doing this is in violation of RFC 3261. A proxy is not allowed to mess with the From- or To-URI. In practice, you should be carefull with this, still. I don't know what the function mentioned does exactly, but if a voice gateway of a certain well-known provider of networking equipment receives a response with a different From- or To-URI than what it put in the request, it will simply drop your response.[0]
That's why there is a dedicated function which puts the original from uri into a Record_route parameter and keeps track of mangling From header. I'm using it in auto mode without problems. (IIRC the cancel still has to be rewritten manually)
Of course a simple regexp wont work.
regards klaus
The best answer to the original question IMHO is: Don't do it.
Regards, Martin
[0] Disclaimer: At least it did about two years ago. But SBCs in general are very picky with this kind of stuff. _______________________________________________ Serusers mailing list Serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers