irontec / itsbc

Irontec Tiny SBC. OpenSIPS & RTPEngine based micro SBC with Web Administration
GNU General Public License v3.0
35 stars 27 forks source link

Some phone models answer "Not Found" to the options #9

Closed ralonsom closed 6 years ago

ralonsom commented 6 years ago

After registering several types of phones, we observed that Alcatel terminals, when they receive an option that passes through the TinySBC, answers Not Found

optionsNotFound.zip

ralonsom commented 6 years ago

I've seen that the problem comes in "OPTIONS sip:103@lookup:24123;transport=udp SIP/2.0" alcatel terminals don't like the "lookup", I made a little modification to confirm it:

    if (is_method("OPTIONS")){
        $ru='sip:' + $rU + '@' + $dd + ':' + $dp + ';transport='+ $dP;
        xlog("L_NOTICE", "NOTICE: Change ru to $ru for Alcatel phones \n");
    }

y funciona bien.

cruzccl commented 6 years ago

I think there is a problem in the logic of route 'initialrequest' or the contents of database for given peer.

Could you please paste here the results of the query:

SELECT routing_requests.handleRtp, routing_requests.incomingRtpInterface_id, routing_requests.outgoingRtpInterface_id, routing_requests.redOrigen, routing_requests.nextHopTransport, routing_requests.nextHop, CONCAT(routing_requests.nextHop, ':', routing_requests.nextHopPort) AS destino, CONCAT(routing_requests.nextHopTransport, ':', routing_requests.ipSalida, ':', routing_requests.portSalida) AS ifacesalida FROM routing_requests WHERE ipEntrada='192.168.38.187' AND domain='192.168.38.187' ORDER BY metrica ASC LIMIT 1;

Regards,

ralonsom commented 6 years ago

+-----------+-------------------------+-------------------------+----------------------------+------------------+---------+-------------+-------------------------+ | handleRtp | incomingRtpInterface_id | outgoingRtpInterface_id | redOrigen | nextHopTransport | nextHop | destino | ifacesalida | +-----------+-------------------------+-------------------------+----------------------------+------------------+---------+-------------+-------------------------+ | 0 | 3 | 2 | 192.168.38.0/255.255.255.0 | UDP | lookup | lookup:4060 | UDP:192.168.38.187:4060 | +-----------+-------------------------+-------------------------+----------------------------+------------------+---------+-------------+-------------------------+

cruzccl commented 6 years ago

We think this commit 8c77ff76777453968ef3fe588dd8f6633e0a5cf3 should solve the issue.

Could you please update and test it?

Thanks and regards,

ralonsom commented 6 years ago

Yep, work correctly now