[OpenSIPS-Users] B2b module topology hiding

Anca Vamanu anca at opensips.org
Wed May 26 15:27:24 CEST 2010


Hi Douglas,

It seems a bit strange what you have there and I really don't believe 
that it can work. If you send 403 to the b2bua, it will send the 403 
back to the caller.
The normal way to do this is first to pass the request to the Router and 
the router to pass the request back to the SBC and only at this time to 
call b2b_init on the request to hide the topology.

Regards,

-- 
Anca Vamanu
www.voice-system.ro




Douglas Lane wrote:
> Hi Anca,
>
> No problem - I appreciate being told where I've gone wrong.
>
> Ok I've adjusted my script slightly to do the following:
>
> 1) Only issue a proxy auth on INVITE if the src_ip and src_port is not 
> the SBC machine itself
> 2) Once proxy auth is a success, if src_ip and src_port is not the SBC 
> machine itself, call b2b_init_request, then exit
> 3) If src_ip and src_port is the SBC machine, setup t_on_* as well as 
> issue a t_relay(0x05).
>
> My test that I did worked correctly, as the INVITE comes into the SBC, 
> and then the B2B module is called and the initial request is dropped. 
> Then the new INVITE comes into the SBC from itself, and it relayed to 
> the OpenSIPS router server using the t_relay() method. The Router server 
> receives this request (I can see the contact is changed to sbc at 1.2.3.4 
> and the Call-Id is B2b.xxx.xxxxx) and then sends back a 403 (I've 
> programmed it this way), the B2B Acks the 403 to the Router, and then 
> forwards the request to the UAC accordingly.
>
> So it looks like its working - perhaps if you'd be so kind as to confirm 
> if this is the *right* way to do things or elaborate if not.
>
> Thanks again for all the assistance.
>
> Thanks
> Doug
>
> On 2010/05/26 2:43 PM, Anca Vamanu wrote:
>   
>> Douglas Lane wrote:
>>    
>>     
>>> Hi Anca,
>>>
>>> I was wondering about that because I saw the tm:t_uac:next_hop part
>>> pointing to the RURI, and then attempts to lookup the domain and SRV
>>> records.
>>>
>>> I also noticed that my script was sending two 100 trying messages, which
>>> after removing my manual sl_send one, i was still getting a 100 trying
>>> message even though my t_relay has 0x01 flag set.
>>>
>>> Can I assume the following then:
>>> An INVITE from a UAC to the OpenSIPS SBC should only ever call the
>>> b2b_init on replies from the OpenSIPS Router server, as that is the
>>> topology we want to hide.
>>> Calls originating from the OpenSIPS Router server must also call the
>>> b2b_init for topology hiding.
>>>
>>> Or have I missed the boat here?
>>>
>>> Thanks
>>> Doug
>>>
>>>
>>>      
>>>       
>> Sort of like missed it, sorry.
>> I will try to make things clear. b2b_init_request has to be called on
>> initial Invite requests. By calling this function you tell the B2BUA to
>> handle this dialog, to put itself in the middle of the call and
>> establish different dialogs with the two parties of the call. This is
>> the only function and only time that you need to call it to have
>> topology hiding working.
>>
>> If you want to hide the OpenSIPS Router which is staying behind OpenSIPS
>> SBC, then you should call b2b_init when the requests come from the Router.
>>
>> Regards,
>>     



More information about the Users mailing list