Re: [asterisk-users] Asterisk 13.11.2 unable to register on Centos 7 64bit

2016-10-15 Thread motty cruz
Thank you for your help! Centos 7 firewall was enable.

systemctl stop firewalld

issue fixed.

Thanks,


On Thu, Oct 13, 2016 at 3:54 PM, Victor Villarreal 
wrote:

> Ok.
>
> Please, note that 192.168.1.37 (I suspect) is the internal  LAN address Of
> the Polycom hardphone. If this is true, then you have  NAT issues.
>
> The REGISTER message are received by your PBX, but when respond, Asterisk
> send the next SIP message to the IP informed by the phone, that is the
> internal LAN address. The messages do not reach back to the hardphone.
>
> You need to setup a STUN server in the Polycom hardphone settings. Please,
> check the manual. Search in Google some public  STUN server to put in the
> settings.
>
> Last, the idea behind the "sip set debug" command was view the complete
> SIP messages conversation, not search for an error.
>
> On NAT escenarios, remember:
>
> * The NATed phones need to know the public  IP of the NATing router.
> Either by manual setting  or  by STUN protocol.
>
> * Reduce the time between REGISTERs attempt, if the client  have a dynamic
> IP connection.
>
> * Use the "localnet" SIP settings in Asterisk, so the PBX can distingish
> what Network need contacted via NAT and what not.
>
> Cheers.
>
> --
> _
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
>   http://www.asterisk.org/community/astricon-user-conference
>
> New to Asterisk? Start here:
>   https://wiki.asterisk.org/wiki/display/AST/Getting+Started
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>http://lists.digium.com/mailman/listinfo/asterisk-users
>



-- 
Thanks for your support,
Motty
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] SIP on multiple ports

2016-10-15 Thread Jerry Geis
I have SIP (asterisk 11.23.0) running on port 5060 just fine. udp.

I have another SIP trunk thats wants to run on port 5068 (long story).
I have enabled tcpenable=yes in sip.conf and defined port=5068 in my trunk
definition. It does not seem that anything is listening on 5068?

How can I run SIP tcp on port 5068?

 telnet localhost 5068
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
telnet: Unable to connect to remote host: Connection refused

My firewall is set to allow TCP port 5068.

Thanks,

Jerry
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] iptables for SIP talk to other port

2016-10-15 Thread Jerry Geis
>
> Your correct. I forgot to mention that the other end IS using tcp.

So I have in my SIP trunk.
transport=tcp

So correct my iptables line was specifying "-p tcp"

I also set tcpenable=yes in sip.conf

Thanks.

Jerry
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] How can I "lock" a device or extension state to only specific states?

2016-10-15 Thread Sebastian Nielsen
How can I lock a device state so it can only publish AVAILABE, BUSY, or
RINGNING? (Eg, if the device is not BUSY or RINGNING, its AVAILABLE)

 

I have a hint published for a fixed phone and a mobile phone. But if the
mobile phone is out of coverage, off or similar, the queue application will
consider the whole group unavailable.

What I want to check for, is only if the device is BUSY or RINGNING, eg the
device in question is engaged in some sort of call. Then the whole group
should be unavailable when it comes to queues, eg persons in queue has to
wait, because both phones belong to the same person, and the same person
cannot be engaged in 2 calls at once.

 

But if the device is NOT engaged in a call, it should be considered to be
"available", even if the device is offline or not registred, because then
the other device is propably available, and if the "unavailable" device is
that because its offline or not registred, then the person owning it can
obviously not be engaged in the call, and thus its wise to ring the other,
online device.

 

Best regards, Sebastian Nielsen



smime.p7s
Description: S/MIME Cryptographic Signature
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Feature access codes

2016-10-15 Thread Steve Edwards

On Sat, 15 Oct 2016, tux john wrote:

Hi. Kinda new to the area and I would like some help please. I have 
asterisk 11 in my system and I have 10 users and 12 DIDs. One did routed 
to each user and 2 DIDs for faxing. Everything works fine but I do not 
have call transfer between extensions and feature access codes. I have 
read somewhere that enabling call transfer can be a security hole for 
sip attackers.


Are these incoming calls copper or VOIP?

If you only accept copper calls, make sure Asterisk is only listening to 
127.0.0.1 and enforce this policy with another layer dropping any incoming 
SIP packets at the firewall.


If you only intend to accept calls from your ISP, configure Asterisk to 
only accept calls from your ISP, and enforce this policy at the firewall.


If you accept calls from everyone, re-think your definition of 'everyone.' 
It probably does not include Iraq, North Korea, China, Russia, etc. 
Configure Asterisk and your firewall accordingly.


Beyond this, follow 'best practices' (google for sip best practices -- 
John Todd did a list years back, Nerdvittles probably will also be a good 
resource) like long, random user names and passwords, only allow needed 
features to each class of users, etc.


--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
https://www.linkedin.com/in/steve-edwards-4244281

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
 http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
 https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Feature access codes

2016-10-15 Thread tux john
Hi. Kinda new to the area and I would like some help please.  I have asterisk 11 in my system and I have 10 users and 12 DIDs. One did routed to each user and 2 DIDs for faxing. Everything works fine but I do not have call transfer between extensions and feature access codes. I have read somewhere that enabling call transfer can be a security hole for sip attackers.

I would appreciate any help available, please.


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] iptables for SIP talk to other port

2016-10-15 Thread Adam
You're redirecting tcp, sip defaults to udp.
-- 
Sent from my cellphone.

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] iptables for SIP talk to other port

2016-10-15 Thread Administrator TOOTAI

Le 15/10/2016 à 18:17, Jerry Geis a écrit :

I have a host 192.168.1.3 that wants to run SIP on 5068 (long story).
My host is 192.168.10.201.
My host needs to stay on 5060 because of all the other devices I have
connected.

I tried putting port=5068 in my SIP extension definition but that did
not work.

So I thought about using iptables to accomplish this:

iptables -t nat -A PREROUTING  -p tcp --dport 5068-j
REDIRECT --to-port 5060
iptables -t nat -A POSTROUTING -p tcp --dport 5060 -d 192.168.1.3 -j
REDIRECT --to-port 5068


Do I not have the right format of the command?
Anything incoming destined for 5068 redirect to 5060...
Anything going out to 192.168.1.3 and port 5060 redirect to 5068.

Seems like that should have worked?

Thoughts?  sip show peers still says unreachable.


Generally SIP is UDP not TCP. Did you modify your asterisk.conf to TCP ?

--
Daniel

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
 http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
 https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] iptables for SIP talk to other port

2016-10-15 Thread Jerry Geis
I have a host 192.168.1.3 that wants to run SIP on 5068 (long story).
My host is 192.168.10.201.
My host needs to stay on 5060 because of all the other devices I have
connected.

I tried putting port=5068 in my SIP extension definition but that did not
work.

So I thought about using iptables to accomplish this:

iptables -t nat -A PREROUTING  -p tcp --dport 5068-j
REDIRECT --to-port 5060
iptables -t nat -A POSTROUTING -p tcp --dport 5060 -d 192.168.1.3 -j
REDIRECT --to-port 5068


Do I not have the right format of the command?
Anything incoming destined for 5068 redirect to 5060...
Anything going out to 192.168.1.3 and port 5060 redirect to 5068.

Seems like that should have worked?

Thoughts?  sip show peers still says unreachable.

Thanks,

Jerry
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Andre Gronwald

ok, now it is getting weird...
actually i don't see any firewall issues, but i am not able to get a 
call from outside to my sipgate account. in asterisk nothing is visible, 
core set verbose is activated.

sngrep (on my asterisk server) shows me indeed the invite from sipgate!?

What I see via sngrep is the following options-flow:
192.168.3.50:55060 -> 217.10.79.9:5060
217.10.79.9:5060 -> 192.168.3.50:48757 (200 OK)

shouldn't sipgate answer on the same port that the communication 
initiated??? in this case 55060?


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Edilson Amaral
Have you tried setting keepalive(20 seconds) on your sip.conf and on your 
phones ?



  From: Andre Gronwald 
 To: asterisk-users@lists.digium.com 
 Sent: Saturday, October 15, 2016 9:17 AM
 Subject: Re: [asterisk-users] Registered successfully, but after a minute or 
so no SIP messages anymore
   
ok, solved the firewall issue.
A first test call worked fine. Another one now still gets disconnected 
after 32s.

But in FW there are no blocked packets anymore?!

And I don't understand why the registration to the same IP and same Port 
is working, but not later transmission of further SIP packets? that 
doesn't sound logical to me. What do you think?

regards,
andre

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
      http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
      https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


   -- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Andre Gronwald

ok, solved the firewall issue.
A first test call worked fine. Another one now still gets disconnected 
after 32s.


But in FW there are no blocked packets anymore?!

And I don't understand why the registration to the same IP and same Port 
is working, but not later transmission of further SIP packets? that 
doesn't sound logical to me. What do you think?


regards,
andre

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
 http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
 https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Ian Gilmour

Hi,

I don’t see any SIP ACK’s in your trace.

Is the SIP 200 OK reaching the originating caller, or being blocked on 
the way through?


Asterisk will tear down the call after ~30secs of audio playing in both 
directions if it doesn't receive the SIP ACK.


Regards,

Ian


On 15/10/2016 12:05, Andre Gronwald wrote:

hi,
let me explain in detail, what i have configured and what is happening 
now:


1st router w724v (Deutsche Telekom AG):
- port forwarding, everything to destination port 51000-55999 to 
device with ip 192.168.2.50 (interface of 2nd router)

2nd router Bintec RS353j):
- configured NAT, everything to port 51000-55999 to device 
192.168.3.99 (same ports)


other direction is totally open.

I observed that all sip calls are closed exactly after 32s. call is 
disconnected on calling side as well... seems to be a timeout issue.


here i have some debug logs. I see lot of requests from asterisk to 
sipgate.de, which are not answered. but communication is going fine in 
both directions (otherwise registration would not be possible?):



<--- Received SIP request (1302 bytes) from UDP:217.10.79.9:5060 --->
INVITE sip:2636146e0@80.142.13.32:55060 SIP/2.0
Via: SIP/2.0/UDP 
217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 
Record-Route: 
Record-Route: 
From: "02363361779" ;tag=as02fa8fcc
To: 
Call-ID: 370c0afa42c39f3d4ba96d7b0c1e7...@sipgate.de
CSeq: 103 INVITE
Contact: 
max-forwards: 66
supported: replaces
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, 
INFO, PUBLISH, MESSAGE

Content-Type: application/sdp
Content-Length:   394

v=0
o=root 15363811 15363812 IN IP4 192.168.2.1
s=sipgate VoIP GW
c=IN IP4 192.168.2.1
t=0 0
m=audio 7070 RTP/AVP 8 0 3 97 18 112 101
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:3 GSM/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:112 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv

<--- Transmitting SIP response (733 bytes) to UDP:217.10.79.9:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 
217.10.79.9;rport=5060;received=217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 
Record-Route: 
Record-Route: 
Call-ID: 370c0afa42c39f3d4ba96d7b0c1e7...@sipgate.de
From: "09" ;tag=as02fa8fcc
To: 
CSeq: 103 INVITE
Server: FPBX-13.0.188.8(13.11.2)
Content-Length:  0

<--- Transmitting SIP response (1280 bytes) to UDP:217.10.79.9:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 
217.10.79.9;rport=5060;received=217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 
Record-Route: 
Record-Route: 
Call-ID: 370c0afa42c39f3d4ba96d7b0c1e7...@sipgate.de
From: "09" ;tag=as02fa8fcc
To: ;tag=HvcIS2lEIQ9xPKihn9LFHjOtJ2YUNEXf
CSeq: 103 INVITE
Server: FPBX-13.0.188.8(13.11.2)
Contact: 
Allow: OPTIONS, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, 
UPDATE, PRACK, REGISTER, REFER, MESSAGE

Supported: 100rel, timer, replaces, norefersub
Content-Type: application/sdp
Content-Length:   286

v=0
o=- 15363811 15363814 IN IP4 192.168.3.99
s=Asterisk
c=IN IP4 80.142.13.32
t=0 0
m=audio 51822 RTP/AVP 8 3 112 101
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:112 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:150
a=sendrecv

<--- Received SIP request (1302 bytes) from UDP:217.10.79.9:5060 --->
INVITE sip:2636146e0@80.142.13.32:55060 SIP/2.0
Via: SIP/2.0/UDP 
217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 

Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Andre Gronwald

hi,
let me explain in detail, what i have configured and what is happening now:

1st router w724v (Deutsche Telekom AG):
- port forwarding, everything to destination port 51000-55999 to 
device with ip 192.168.2.50 (interface of 2nd router)

2nd router Bintec RS353j):
- configured NAT, everything to port 51000-55999 to device 
192.168.3.99 (same ports)


other direction is totally open.

I observed that all sip calls are closed exactly after 32s. call is 
disconnected on calling side as well... seems to be a timeout issue.


here i have some debug logs. I see lot of requests from asterisk to 
sipgate.de, which are not answered. but communication is going fine in 
both directions (otherwise registration would not be possible?):



<--- Received SIP request (1302 bytes) from UDP:217.10.79.9:5060 --->
INVITE sip:2636146e0@80.142.13.32:55060 SIP/2.0
Via: SIP/2.0/UDP 
217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 
Record-Route: 
Record-Route: 
From: "02363361779" ;tag=as02fa8fcc
To: 
Call-ID: 370c0afa42c39f3d4ba96d7b0c1e7...@sipgate.de
CSeq: 103 INVITE
Contact: 
max-forwards: 66
supported: replaces
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, 
INFO, PUBLISH, MESSAGE

Content-Type: application/sdp
Content-Length:   394

v=0
o=root 15363811 15363812 IN IP4 192.168.2.1
s=sipgate VoIP GW
c=IN IP4 192.168.2.1
t=0 0
m=audio 7070 RTP/AVP 8 0 3 97 18 112 101
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:3 GSM/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:112 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv

<--- Transmitting SIP response (733 bytes) to UDP:217.10.79.9:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 
217.10.79.9;rport=5060;received=217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 
Record-Route: 
Record-Route: 
Call-ID: 370c0afa42c39f3d4ba96d7b0c1e7...@sipgate.de
From: "09" ;tag=as02fa8fcc
To: 
CSeq: 103 INVITE
Server: FPBX-13.0.188.8(13.11.2)
Content-Length:  0

<--- Transmitting SIP response (1280 bytes) to UDP:217.10.79.9:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 
217.10.79.9;rport=5060;received=217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 
Record-Route: 
Record-Route: 
Call-ID: 370c0afa42c39f3d4ba96d7b0c1e7...@sipgate.de
From: "09" ;tag=as02fa8fcc
To: ;tag=HvcIS2lEIQ9xPKihn9LFHjOtJ2YUNEXf
CSeq: 103 INVITE
Server: FPBX-13.0.188.8(13.11.2)
Contact: 
Allow: OPTIONS, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, 
UPDATE, PRACK, REGISTER, REFER, MESSAGE

Supported: 100rel, timer, replaces, norefersub
Content-Type: application/sdp
Content-Length:   286

v=0
o=- 15363811 15363814 IN IP4 192.168.3.99
s=Asterisk
c=IN IP4 80.142.13.32
t=0 0
m=audio 51822 RTP/AVP 8 3 112 101
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:112 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:150
a=sendrecv

<--- Received SIP request (1302 bytes) from UDP:217.10.79.9:5060 --->
INVITE sip:2636146e0@80.142.13.32:55060 SIP/2.0
Via: SIP/2.0/UDP 
217.10.79.9;branch=z9hG4bK56ac.c519528374e3101a61791cf5a0ad1aae.0
Via: SIP/2.0/UDP 
172.20.40.6;branch=z9hG4bK56ac.2ecd3532ae51c927dabcc6e27eaa4cbe.0
Via: SIP/2.0/UDP 
217.10.68.137;branch=z9hG4bK56ac.73e224299594933979fdfb5b036e6563.0

Via: SIP/2.0/UDP 217.10.77.115:5060;branch=z9hG4bK7b31f031
Record-Route: 
Record-Route: 
Record-Route: 
From: "09" ;tag=as02fa8fcc
To: 
Call-ID: 370c0afa42c39f3d4ba96d7b0c1e7...@sipgate.de
CSeq: 103 INVITE
Contact: 
max-forwards: 66
supported: 

Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Andre Gronwald

Thanks Jonathan for your support.

I would like to avoid TLS at the moment  (in general I am a fan of 
secured communication!) because the other provider is not supporting 
TLS. And sipgate is just used for testing.


However I can see the following which is quite interesting:

[2016-10-15 11:20:30] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Reachable. 
RTT: 433.814 msec
[2016-10-15 11:20:30] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Endpoint pjsip_sipgate is now Reachable
[2016-10-15 11:21:22] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Unreachable. 
RTT: 0.000 msec
[2016-10-15 11:21:22] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Endpoint pjsip_sipgate is now Unreachable
[2016-10-15 11:30:30] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Reachable. 
RTT: 439.006 msec
[2016-10-15 11:30:30] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Endpoint pjsip_sipgate is now Reachable
[2016-10-15 11:31:22] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Unreachable. 
RTT: 0.000 msec
[2016-10-15 11:31:22] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Endpoint pjsip_sipgate is now Unreachable
[2016-10-15 11:40:30] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Reachable. 
RTT: 433.426 msec
[2016-10-15 11:40:30] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Endpoint pjsip_sipgate is now Reachable
[2016-10-15 11:41:22] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Unreachable. 
RTT: 0.000 msec
[2016-10-15 11:41:22] VERBOSE[14791] res_pjsip/pjsip_configuration.c: 
Endpoint pjsip_sipgate is now Unreachable


I think that the times are matching exactly the qualify frequency and 
registry expiration - expiration is set to 600s, and qualify frequency 
to 50s. Seems that the qualify requests are not supported (this is the 
case for the other provider as well!). So maybe I should work without 
sip qualify.


Besides this I have another curiousity:
One call:
-- Executing [s@app-announcement-1:3] 
Wait("PJSIP/pjsip_sipgate-0019", "1") in new stack
   > 0x7fabf004bfd0 -- Probation passed - setting RTP source 
address to 217.10.77.109:16248

Another call:
-- Executing [s@app-announcement-1:3] 
Wait("PJSIP/pjsip_sipgate-001a", "1") in new stack
   > 0x7fabf0070bb0 -- Probation passed - setting RTP source 
address to 192.168.2.1:7074


??? 217.10.77.109 is sipgate.de -> ok. 192.168.2.1 is my 
vDSL-access-router ??? Why does the RTP source address changes? that 
must not happen.



And another observation: I am registered to sipgate.de, fine. Incoming 
call is processed,  announcement is played. But when the caller hangs up 
asterisk is not recognizing it. it takes about 16s until the channel is 
closed after hangup?



regards,
andre
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Jonathan H
Hmmm, sorry, I can't think of anything except... why do you need the
STUN server? And are you sure that all the ports in your router
definitely match the ones Asterisk thinks it's using?

Then there is always the SIP-ALG problem with some routers, which some
people have been able to overcome by switching to TLS, and I see that
SIPgate offer TLS.
You could try making a free certificate and going TLS which uses port
5061. No promises, but worth a try as it fixed the issue for a
different poster.

The only other thing I can find while Googling for this, which solved
it for someone else, was related to DNS server issues, but this seems
unlikely (although not impossible).

On 15 October 2016 at 10:07, Andre Gronwald  wrote:
> ping times are fine as well:
>
> [root@freepbx asterisk]# ping sipgate.de
> PING sipgate.de (217.10.79.9) 56(84) bytes of data.
> 64 bytes from sipgate.de (217.10.79.9): icmp_seq=1 ttl=57 time=46.7 ms
> 64 bytes from sipgate.de (217.10.79.9): icmp_seq=2 ttl=57 time=46.4 ms
> 64 bytes from sipgate.de (217.10.79.9): icmp_seq=3 ttl=57 time=46.7 ms
> 64 bytes from sipgate.de (217.10.79.9): icmp_seq=4 ttl=57 time=46.8 ms
> 64 bytes from sipgate.de (217.10.79.9): icmp_seq=5 ttl=57 time=47.1 ms
> 64 bytes from sipgate.de (217.10.79.9): icmp_seq=6 ttl=57 time=46.4 ms
> 64 bytes from sipgate.de (217.10.79.9): icmp_seq=7 ttl=57 time=47.1 ms
> ^C
> --- sipgate.de ping statistics ---
> 7 packets transmitted, 7 received, 0% packet loss, time 6360ms
> rtt min/avg/max/mdev = 46.406/46.809/47.191/0.393 ms
> [root@freepbx asterisk]#
>
>
> this high RTT appears only sometimes.  After removing STUN-server it looks
> better, did two test calls right now, both gone through immediately. At the
> end of the second test call I see:
>
> -- Executing [s@app-announcement-1:5]
> Playback("PJSIP/pjsip_sipgate-0003",
> "custom/araz01/07-polly,noanswer") in new stack
> --  Playing 'custom/araz01.alaw' (language
> 'en')
> -- Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Reachable.
> RTT: 493.094 msec
>   == Endpoint pjsip_sipgate is now Reachable
> --  Playing 'custom/07-polly.slin'
> (language 'en')
> -- Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now
> Unreachable.  RTT: 0.000 msec
>   == Endpoint pjsip_sipgate is now Unreachable
>
>
> Why do I have that loss of registrations?
>
> here my pjsip config for sipgate.de:
>
> freepbx*CLI> pjsip show registration pjsip_sipgate
>
>
> 
> ==
>
>  pjsip_sipgate/sip:sipgate.de:5060   pjsip_sipgate
> Registered
>
>  ParameterName: ParameterValue
>  
>  auth_rejection_permanent : true
>  client_uri   : sip:263614...@sipgate.de:5060
>  contact_user : 2636146e0
>  endpoint :
>  expiration   : 600
>  fatal_retry_interval : 0
>  forbidden_retry_interval : 0
>  line : false
>  max_retries  : 10
>  outbound_auth: pjsip_sipgate
>  outbound_proxy   :
>  retry_interval   : 60
>  server_uri   : sip:sipgate.de:5060
>  support_path : false
>  transport: 0.0.0.0-udp
>
> Remind: Endpoint is currently unreachable, but asterisk shows "Registered".
> Test call fails at this moment.
>
>
> regards,
> andre
>
> --
> _
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
>   http://www.asterisk.org/community/astricon-user-conference
>
> New to Asterisk? Start here:
>   https://wiki.asterisk.org/wiki/display/AST/Getting+Started
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>http://lists.digium.com/mailman/listinfo/asterisk-users

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Andre Gronwald

ping times are fine as well:

[root@freepbx asterisk]# ping sipgate.de
PING sipgate.de (217.10.79.9) 56(84) bytes of data.
64 bytes from sipgate.de (217.10.79.9): icmp_seq=1 ttl=57 time=46.7 ms
64 bytes from sipgate.de (217.10.79.9): icmp_seq=2 ttl=57 time=46.4 ms
64 bytes from sipgate.de (217.10.79.9): icmp_seq=3 ttl=57 time=46.7 ms
64 bytes from sipgate.de (217.10.79.9): icmp_seq=4 ttl=57 time=46.8 ms
64 bytes from sipgate.de (217.10.79.9): icmp_seq=5 ttl=57 time=47.1 ms
64 bytes from sipgate.de (217.10.79.9): icmp_seq=6 ttl=57 time=46.4 ms
64 bytes from sipgate.de (217.10.79.9): icmp_seq=7 ttl=57 time=47.1 ms
^C
--- sipgate.de ping statistics ---
7 packets transmitted, 7 received, 0% packet loss, time 6360ms
rtt min/avg/max/mdev = 46.406/46.809/47.191/0.393 ms
[root@freepbx asterisk]#


this high RTT appears only sometimes.  After removing STUN-server it 
looks better, did two test calls right now, both gone through 
immediately. At the end of the second test call I see:


-- Executing [s@app-announcement-1:5] 
Playback("PJSIP/pjsip_sipgate-0003", 
"custom/araz01/07-polly,noanswer") in new stack
--  Playing 'custom/araz01.alaw' 
(language 'en')
-- Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now 
Reachable.  RTT: 493.094 msec

  == Endpoint pjsip_sipgate is now Reachable
--  Playing 'custom/07-polly.slin' 
(language 'en')
-- Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now 
Unreachable.  RTT: 0.000 msec

*  == Endpoint pjsip_sipgate is now Unreachable*


Why do I have that loss of registrations?

here my pjsip config for sipgate.de:

freepbx*CLI> pjsip show registration pjsip_sipgate

  
  

==

 pjsip_sipgate/sip:sipgate.de:5060 pjsip_sipgate Registered

 ParameterName: ParameterValue
 
 auth_rejection_permanent : true
 client_uri   : sip:263614...@sipgate.de:5060
 contact_user : 2636146e0
 endpoint :
 expiration   : 600
 fatal_retry_interval : 0
 forbidden_retry_interval : 0
 line : false
 max_retries  : 10
 outbound_auth: pjsip_sipgate
 outbound_proxy   :
 retry_interval   : 60
 server_uri   : sip:sipgate.de:5060
 support_path : false
 transport: 0.0.0.0-udp

Remind: Endpoint is currently unreachable, but asterisk shows 
"Registered". Test call fails at this moment.



regards,
andre
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Jonathan H
All other things aside, this stands out immediately:

RTT: 434.393 msec

That's almost half a second round trip for a packet. I'm amazed
anything works at all. For SIP connections, mine are usually about
26ms max, anything above about 35 is bad. Looks like a serious config
issue.

Try pinging and see what you get - my ping times to sipgate.de from
the UK are Best:13.6ms Worst 13.8ms across 100 pings.

I could be wrong, but I'd be surprised if that wasn't causing
problems, at least with audio.


On 15 October 2016 at 09:11, Andre Gronwald  wrote:
> Hi all,
> I have an issue with asterisk 13 and pjsip. I guess it is somehow Firewall
> related, but I'm unsure.
>
> A registration to Sipgate is established successfully:
>
>
>   
> 
> ==
>
>  pjsip_sipgate/sip:sipgate.de:5060   pjsip_sipgate
> Registered
>
>
> Calling the registered number is even successfully shown in asterisk (it is
> a freepbx installation).
> But when doing a second call the number is busy ("provider" busy, I don't
> see anything in asterisk verbose mode).
> Sending a pjsip unregister results in the following messages:
>
> [2016-10-15 10:03:22] WARNING[10162]: res_pjsip_outbound_registration.c:761
> schedule_retry: No response received from 'sip:sipgate.de:5060' on
> registration attempt to 'sip:263614...@sipgate.de:5060', retrying in '60'
> -- Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now Reachable.
> RTT: 434.393 msec
>   == Endpoint pjsip_sipgate is now Reachable
>
> so it is somewhat clear, why i get a busy, because the endpoint is not
> reachable. But WHY is the endpoint not reachable?
>
> Regarding the architecture: I have two routers cascaded, that is
> unfortunately necessary. On the first router (vDSL-access router) I have
> forwarded nearly everything to the second router (Bintec rj 353), where a
> port forwarding for relevant ports (sip and pjsip (udp and tcp), rtp (udp))
> is configured. IF a call goes through, nearly everything is working (audio
> only incoming, but that is another issue).
>
> STUN is configured. FreePBX Firewall is disabled.
>
> Kind regards,
> andre
>
>
>
> --
> _
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
>   http://www.asterisk.org/community/astricon-user-conference
>
> New to Asterisk? Start here:
>   https://wiki.asterisk.org/wiki/display/AST/Getting+Started
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>http://lists.digium.com/mailman/listinfo/asterisk-users

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Andre Gronwald
Very interesting: I have another provider configured, that was not 
reachable as well. I disabled the STUN-server (external STUN server), 
and now the second registration works fine, BUT with the same "error" 
messages (unreachable etc) as the other provider. But in contrast the 
number is always reachable!!!


Is there any explanation for this? I just want to understand... ;-) ... 
and solve it.


regards,
andre

Am 15.10.2016 um 10:11 schrieb Andre Gronwald:


[2016-10-15 10:03:22] WARNING[10162]: 
res_pjsip_outbound_registration.c:761 schedule_retry: No response 
received from 'sip:sipgate.de:5060' on registration attempt to 
'sip:263614...@sipgate.de:5060', retrying in '60'
-- Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now 
Reachable.  RTT: 434.393 msec

  == Endpoint pjsip_sipgate is now Reachable

so it is somewhat clear, why i get a busy, because the endpoint is not 
reachable. But WHY is the endpoint not reachable?


Regarding the architecture: I have two routers cascaded, that is 
unfortunately necessary. On the first router (vDSL-access router) I 
have forwarded nearly everything to the second router (Bintec rj 353), 
where a port forwarding for relevant ports (sip and pjsip (udp and 
tcp), rtp (udp)) is configured. IF a call goes through, nearly 
everything is working (audio only incoming, but that is another issue).


STUN is configured. FreePBX Firewall is disabled.

Kind regards,
andre




-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] Registered successfully, but after a minute or so no SIP messages anymore

2016-10-15 Thread Andre Gronwald

Hi all,
I have an issue with asterisk 13 and pjsip. I guess it is somehow 
Firewall related, but I'm unsure.


A registration to Sipgate is established successfully:


   


==

 pjsip_sipgate/sip:sipgate.de:5060 pjsip_sipgate Registered


Calling the registered number is even successfully shown in asterisk (it 
is a freepbx installation).
But when doing a second call the number is busy ("provider" busy, I 
don't see anything in asterisk verbose mode).

Sending a pjsip unregister results in the following messages:

[2016-10-15 10:03:22] WARNING[10162]: 
res_pjsip_outbound_registration.c:761 schedule_retry: No response 
received from 'sip:sipgate.de:5060' on registration attempt to 
'sip:263614...@sipgate.de:5060', retrying in '60'
-- Contact pjsip_sipgate/sip:263614...@sipgate.de:5060 is now 
Reachable.  RTT: 434.393 msec

  == Endpoint pjsip_sipgate is now Reachable

so it is somewhat clear, why i get a busy, because the endpoint is not 
reachable. But WHY is the endpoint not reachable?


Regarding the architecture: I have two routers cascaded, that is 
unfortunately necessary. On the first router (vDSL-access router) I have 
forwarded nearly everything to the second router (Bintec rj 353), where 
a port forwarding for relevant ports (sip and pjsip (udp and tcp), rtp 
(udp)) is configured. IF a call goes through, nearly everything is 
working (audio only incoming, but that is another issue).


STUN is configured. FreePBX Firewall is disabled.

Kind regards,
andre


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Join the Asterisk Community at the 13th AstriCon, September 27-29, 2016
  http://www.asterisk.org/community/astricon-user-conference

New to Asterisk? Start here:
  https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users