I may be going about this all the wrong way, but I am attemping to change the INVITE string at the begining of the session. In this example my XLite client is connecting to SER which is then forwarding the call to my PSTN gateway, however the INVITE string stays written for the SER IP address.
Here is what I have thus far. The first line was just a test which worked to modify the To: line. I assumed it would also work with the INVITE, or am I going about this all the wrong way?
subst('/^To:.*sip:([0-9]+)@.*$/To:sip:\1@111.111.111.111/');
subst('/^INVITE sip:([0-9]+)@.*$/INVITE sip:\1@111.111.111.111/');
thanks,
-Jed
Hi Jed,
To operate only on RURI, use subst_uri() function. Or in your case try rewritehost(), rewritehostport() or rewriteuser()
Best regards, Marian
Jed Stafford wrote:
I may be going about this all the wrong way, but I am attemping to change the INVITE string at the begining of the session. In this example my XLite client is connecting to SER which is then forwarding the call to my PSTN gateway, however the INVITE string stays written for the SER IP address.
Here is what I have thus far. The first line was just a test which worked to modify the To: line. I assumed it would also work with the INVITE, or am I going about this all the wrong way?
subst('/^To:.*sip:([0-9]+)@.*$/To:sip:\1@111.111.111.111/');
subst('/^INVITE sip:([0-9]+)@.*$/INVITE sip:\1@111.111.111.111/');
thanks,
-Jed
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers