[Users] uac_replace_from() not work for Linksys ATA

Bogdan-Andrei Iancu bogdan at voice-system.ro
Thu Feb 8 13:38:18 CET 2007


Howard,

it looks fine, but you really do not have to alter the from if your GW 
supports RPID hdr. FROM mangling is something very expensive from 
processing point of view and you should avoid it if possible.

you can get rid of the uac_replace_from() - the RPID will be added all 
the time (even if it was not originally present).

regards,
bogdan

Howard Tang wrote:
> Hi Bogdan,
>
> Could you confirm what i have done here is correct please?
>
> route[5] {
>        if (search("From:.*<sip:090[0-9]{5}")) {
>                uac_replace_from("anonymous","sip:anonymous at 1.1.1.1");
>                remove_hf("Remote-Party-ID");
>                append_hf("Remote-Party-ID: \"Anonymous\"
> <sip:anonymous at anonymous.invalid>;party=calling;screen=yes;privacy=full\r\n"); 
>
>
>        rewritehostport("gatewayip:5060");
>        route(1);
>
> }
>
> I have used uac_replace_from just incase sip header not contain rpid.
>
> Regards,
> Howard
>
> On 2/8/07, Bogdan-Andrei Iancu <bogdan at voice-system.ro> wrote:
>> Hi Howard,
>>
>> in this case is simple. If RPID hdr is used you don not have to change
>> the FROM hdr anymore.
>>
>> To replace the RPID hdr, use remove_hf() see textops module to remove
>> the hdr and append_hf() to add a new one.
>>
>> regards,
>> bogdan
>>
>> Howard Tang wrote:
>> > Hi Bogdan,
>> >
>> > After I check the sip message, I think the problem is
>> >
>> > Remote-Party-ID: 1234 
>> <sip:1234 at 111.111.111.111>;screen=yes;party=calling
>> >
>> > I can see the uac_replace_from has changed the From Header, but i
>> > think the problem was caused by the Remote-Party-ID on the Linksys ATA
>> >
>> > Is there a way to change this Remote-Party-ID as well?
>> >
>> > Regards,
>> > Howard
>> >
>> > On 2/7/07, Bogdan-Andrei Iancu <bogdan at voice-system.ro> wrote:
>> >> yes :)
>> >>
>> >> regards,
>> >> bogdan
>> >>
>> >> Howard Tang wrote:
>> >> > HI Bogdan,
>> >> >
>> >> > do you means using " ngrep -t -W byline port 5060 " ?
>> >> >
>> >> > regards,
>> >> > Howard
>> >> >
>> >> >
>> >> > On 2/7/07, Bogdan-Andrei Iancu <bogdan at voice-system.ro> wrote:
>> >> >> Hi Howard,
>> >> >>
>> >> >> could please post the network trace of a non-working call?
>> >> >>
>> >> >> regards,
>> >> >> bogdan
>> >> >>
>> >> >> Howard Tang wrote:
>> >> >> > HI All,
>> >> >> >
>> >> >> > I have a problem with uac_replace_from() function not working 
>> for
>> >> >> > Linksys Unit.
>> >> >> >
>> >> >> > This is what i have in the route[1],
>> >> >> >
>> >> >> > if (search("From:.*<sip:900*")) {
>> >> >> >
>> >> uac_replace_from("anonymous","sip:anonymous at x.x.x.x");
>> >> >> >        }
>> >> >> >
>> >> >> > I have 0900xx as internal sip account, then I have to remove the
>> >> >> > 0900xx callerid before i send the call to PSTN gateway. Because
>> >> 0900xx
>> >> >> > is not a valid number, Mobile phone providers block the call
>> >> because
>> >> >> > of that, as a result, I need to replace the callerid to 
>> anonymous.
>> >> >> >
>> >> >> > I have tested with many other ATA and X-Lite without problem. 
>> The
>> >> >> > problem only ocurrs when i use Linksys ata. I have monitored the
>> >> SIP
>> >> >> > message, the first request will change to anonymous then back to
>> >> the
>> >> >> > original username.
>> >> >> >
>> >> >> > Anyone have an idea on how i can fix this ?
>> >> >> >
>> >> >> >
>> >> >>
>> >> >>
>> >> >
>> >>
>> >>
>> >
>>
>>
>
>





More information about the Users mailing list