[OpenSIPS-Users] I need some info while setiing sethostport on opensips config .

Sasmita Panda spanda at 3clogic.com
Fri Jul 26 11:25:41 UTC 2024


Hi , Thanks for the reply .
Rather than configuration change , I have done through  dynamic routing .

 In the dr_gateway table I have added socket information *udp:x.x.x.x:5060*
mysql> select * from dr_gateways;
+----+------+------+---------------------------------------+-------+------------+-------+------------+-------+-----------------------+-------------+
| id | gwid | type | address                               | strip |
pri_prefix | attrs | probe_mode | state | socket                |
description |
+----+------+------+---------------------------------------+-------+------------+-------+------------+-------+-----------------------+-------------+
|  1 | gw4  |    3 | fs.3c.com:6080 |     0 | NULL       | NULL  |
 0 |     0 | udp:192.168.0.69:5060 | NULL        |
+----+------+------+---------------------------------------+-------+------------+-------+------------+-------+-----------------------+-------------+

I only have a single Invite on a single session on this leg . There is no
Re-Invite at all  . Will I need to set record_route_preset on this case as
well ?

*Thanks & Regards*
*Sasmita Panda*
*Senior Network Testing and Software Engineer*
*3CLogic , ph:07827611765*


On Wed, Jul 24, 2024 at 7:06 PM Ben Newlin <Ben.Newlin at genesys.com> wrote:

> Sasmita,
>
>
>
> You need to be using $socket_out. [1]
>
>
>
> By default, OpenSIPS will use the receiving socket as the sending socket.
> This means if you receive the message on TLS and do not change $socket_out
> then the message will be sent out the TLS socket.
>
>
>
> Additionally, unless you are using B2BUA or maybe topology_hiding you will
> likely need to “remember” this protocol transition by adding a double
> Record-Route [2] to the message. You may also need to change any
> “transport” params that exist in the Request-URI and possibly the Contact
> header.
>
>
>
> [1] https://www.opensips.org/Documentation/Script-CoreVar-3-2#toc86
>
> [2] https://opensips.org/docs/modules/3.2.x/rr.html
>
>
>
> Ben Newlin
>
>
>
> *From: *Users <users-bounces at lists.opensips.org> on behalf of Sasmita
> Panda <spanda at 3clogic.com>
> *Date: *Wednesday, July 24, 2024 at 1:54 AM
> *To: *OpenSIPS users mailling list <users at lists.opensips.org>
> *Subject: *[OpenSIPS-Users] I need some info while setiing sethostport on
> opensips config .
>
> * EXTERNAL EMAIL - Please use caution with links and attachments *
>
>
> ------------------------------
>
> Hi All ,
>
>
>
> I am using openisp version : 3.2
>
>
>
> I have an opensips config on which I was listening on UDP port only and
> hence using sethostport to route calls to a particular destination . like
> below .
>
>
>
>           if(is_from_gw() || ($rp=~"5505"))
>                    {
>                   sethostport("freeswitch-test.xyz.com:6080");
>                    route(inbound);
>                     exit;
>                    }
>
>
>
> Now I have to accept a call on TLS and send that to some other destination
> on UDP . I have enabled the tls module and also the dependent modules like
> tls_openssl,  tls_mgm .
>
>
>
> socket=udp:192.168.0.y:5060
> socket=tls:192.168.0.y:5061
> socket=tcp:192.168.0.y:5060
>
>           if(is_from_gw() || ($rp=~"5505"))
>                    {
>                   sethostport("freeswitch-test.xyz.com:6080");
>                    route(inbound);
>                     exit;
>                    }
>
>
>
> This above configuration is not working . I am getting "477 Send Failed "
>
>
>
> *Thanks & Regards*
>
> *Sasmita Panda*
>
> *Senior Network Testing and Software Engineer*
>
> *3CLogic , ph:07827611765*
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20240726/2ccbf63d/attachment-0001.html>


More information about the Users mailing list