[OpenSIPS-Users] Dealing with duplicate packet's.

2017-10-26 Thread Kevin Stewart via Users

I am having some issues with intermittent packet duplication in the network.

what this looks like currently is
opensips gets 2 identical Invite packets.
opensips processes them returning 2 401's with 2 different nonce values.

opensips then gets 2 Authed Invite packets
processes the first one and invalidates the nonce.
another thread is simultaneously processing the other one and sees the invalid 
nonce and returns a 401.
the first thread forwards the valid invite and 100's to the A party and 
eventual returns a 180 but the A party ignores this because it got a terminal 
response (401) for that invite.


I was wondering is there a mechanism do identify duplicate CSeq numbers in a 
session so we can drop them in opensips?

Yes I am trying to get the source of the duplication identified but it is 
currently breaking authentication and call setup.

Kevin
Kevin Stewart | Senior VOIP Network Engineer
D: +64 9 919 6120E: kevin.stew...@vocusgroup.co.nz
M: +64 21 879 057W: vocusgroup.co.nz
A: Level 4, 191 Queen Street, Auckland 1010

___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] B2BUA not responding to reinvites

2016-06-22 Thread Kevin Stewart
After some stracing of opensips I found that the reinvites where not making it 
to opensips then tracked the issue down to fail2ban :/


solution:

aptitude remove ufw fail2ban

I am going back to hand crafted iptables rules [😊]


thanks for the help.


Kevin


From: users-boun...@lists.opensips.org  on 
behalf of Bogdan-Andrei Iancu 
Sent: Tuesday, 14 June 2016 9:53:53 p.m.
To: OpenSIPS users mailling list; Kevin Stewart
Subject: Re: [OpenSIPS-Users] B2BUA not responding to reinvites

Hello Kevin,

Once the B2B session started, the sequential request will not land to your 
script as they will be captured by B2B before the script (and handled according 
to the XML script).

Still, with debug level 6 you should see various messages from OpenSIPS when 
the B2B would handle the re-INVITE.

Are you sure the re-INVITE is actually reaching OpenSIPS on the right IP and 
port ?

Regards,

Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
http://www.opensips-solutions.com

On 14.06.2016 09:49, Kevin Stewart wrote:
I am trying to implement a simple topology hiding B2BUA with opensips 1.11.5

most things work except that re invites for session expiry are being ignored.

I assume that I am missing something in my config.

the strange thing is that I see no debug to syslog when the Invites come in 
even with debug set to 9.

the basic config is a client on port 5061 (C) inviting the B2BUA on port 
5066(B) with then invites the main server on another host on port 5060(A).
I do not expect and inbount calls from A

C invites B, B invites A all proceeds normally until after 15 minutes A invites 
B and is ignored then sends bye a number of times.
none of the reinvites or byes are reported in the logs.

C then hangs up sending a bye to B, B sends a bye to A and gets 481 Unknown 
Dialog.

below is my config

route{
if ( !mf_process_maxfwd_header("10") )
{
sl_send_reply("483","To Many Hops");
drop();
};

if (is_method("OPTIONS"))
{
#xlog("L_NOTICE", "$ci|end|unsupported method");
sl_send_reply("404", "Not found");
exit;
}

if(is_method("INVITE")){
xlog("L_NOTICE","got invite");
if($sp=="5061"){
xlog("L_NOTICE","got invite 5061");
xlog("L_NOTICE","[$mi] before B2B request\n");
$ru="sip:"+$tU+"@172.22.2.140:5060";
b2b_init_request("top hiding");
xlog("L_INFO","[$mi] after B2B request\n");
}else{
xlog("L_NOTICE","got invite $sp");
xlog("L_INFO","[$mi] not from 5061\n");
}
exit;
}else{
xlog("L_ERR","got request method $rm from $si: $fU, $tU");
sl_send_reply("501", "Not Implemented");
exit;
}
}

Kevin Stewart|  Senior VOIP Network Engineer

D:  +64 9 919 6120E:  
<mailto:kevin.stew...@m2group.co.nz> 
kevin.stew...@m2group.co.nz<mailto:kevin.stew...@m2group.co.nz>

M:  +64 21 879 057W:  
vocus.co.nz<http://vocus.co.nz>

A:  PO Box 108-109, Symonds St, Auckland 1150


[cid:part5.09070902.08000600@opensips.org]<http://www.vocus.co.nz>






Kevin Stewart | Senior VOIP Network Engineer
D: +64 9 919 6120E: kevin.stew...@m2group.co.nz
M: +64 21 879 057W: vocus.co.nz
A: PO Box 108-109, Symonds St, Auckland 1150

___
Users mailing list
Users@lists.opensips.org<mailto:Users@lists.opensips.org>
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] B2BUA not responding to reinvites

2016-06-13 Thread Kevin Stewart
I am trying to implement a simple topology hiding B2BUA with opensips 1.11.5

most things work except that re invites for session expiry are being ignored.

I assume that I am missing something in my config.

the strange thing is that I see no debug to syslog when the Invites come in 
even with debug set to 9.

the basic config is a client on port 5061 (C) inviting the B2BUA on port 
5066(B) with then invites the main server on another host on port 5060(A).
I do not expect and inbount calls from A

C invites B, B invites A  all proceeds normally until after 15 minutes A 
invites B and is ignored then sends bye a number of times.
none of the reinvites or byes are reported in the logs.

C then hangs up sending a bye to B, B sends a bye to A and gets 481 Unknown 
Dialog.

below is my config

route{
if ( !mf_process_maxfwd_header("10") )
{
sl_send_reply("483","To Many Hops");
drop();
};

if (is_method("OPTIONS"))
{
#xlog("L_NOTICE", "$ci|end|unsupported method");
sl_send_reply("404", "Not found");
exit;
}

if(is_method("INVITE")){
xlog("L_NOTICE","got invite");
if($sp=="5061"){
xlog("L_NOTICE","got invite 5061");
xlog("L_NOTICE","[$mi] before B2B request\n");
$ru="sip:"+$tU+"@172.22.2.140:5060";
b2b_init_request("top hiding");
xlog("L_INFO","[$mi] after B2B request\n");
}else{
xlog("L_NOTICE","got invite $sp");
xlog("L_INFO","[$mi] not from 5061\n");
}
exit;
}else{
xlog("L_ERR","got request method $rm from $si: $fU, $tU");
sl_send_reply("501", "Not Implemented");
exit;
}
}
Kevin Stewart | Senior VOIP Network Engineer
D: +64 9 919 6120E: kevin.stew...@m2group.co.nz
M: +64 21 879 057W: vocus.co.nz
A: PO Box 108-109, Symonds St, Auckland 1150

___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users