Phil,
Why would you have to deal with the To tag?
I've had to do this very often and simply using textops to transform the headers precisely as you describe has always worked. Just use regex to conserve all the tags and other extended fields that appear in the To and From URIs.
-- Alex
On Thu, 29 Nov 2007, Phil D'Amore wrote:
Hi Everyone...
I'm looking for some advice. Let's say I have a To: header in an initial INVITE:
To: Bob sip:8005551212@sip.example.com
Due to carrier requirements, it really needs to be:
To: Bob sip:+18005551212@sip.example.com
I'm not asking how to do it. I know I can use some textops functions to make this happen. I also know that doing this might break something.
The uac module already nicely handles the From: header in a way that doesn't break things. I thought about extending this to handle To:, but I worried that the Record-Route header might get too long for some UAs if I wind up having to change both headers. The To tag must also be dealt with somehow, which I think might make it harder to do than From.
Using a 302 response is not an option for me, and I'm really trying to avoid getting a B2BUA involved with this right now. Moving from openser 1.1.1 to 1.3 is enough for me without changing my architecture ;). I'm wondering what would be the best way given what openser can do right now (1.3) to re-write that header that doesn't break anything. I'm not adverse to writing some code to make it happen if that is what is needed.
Any ideas?
Thanks, Phil
Users mailing list Users@lists.openser.org http://lists.openser.org/cgi-bin/mailman/listinfo/users
-- Alex Balashov Evariste Systems Web : http://www.evaristesys.com/ Tel : +1-678-954-0670 Direct : +1-678-954-0671