[asterisk-dev] Idle Timers and Keep-Alives

2018-01-04 Thread George Joseph
I'm currently working an issue related to both idle timers and keep-alives
and need some feedback...

pjproject has keep-alive timers for connection-oriented transports but at
the time we implemented res_pjsip, you couldn't modify the interval at
runtime, so we implemented our own keep-alives in res_pjsip controlled by
the global keep_alive_interval option.

pjproject also has an idle timer which it set to 600 seconds by default and
is NOT a runtime option.  If no transaction occurs on a transport in that
time, the transport and it's connection are destroyed.   If things like
REGISTERs and SUBSCRIBEs have an expires longer than 600 seconds and no
activity happens during that time, the connection WILL be torn down and the
client will have to re-register or re-subscribe.

Since we can now set pjproject's keep-alive interval, we're thinking we can
get rid of our res_pjsip keep-alives and have the global
keep_alive_interval option control pjproject's.  There's one wrinkle
however...  the res_pjsip keep-alives reset the idle timer whereas the
pjproject keep-alives do not reset the idle timer.

So the questions are...

   1. What should the correct behavior be for whether keep-alives should
   reset the idle timer?
   2. Is the default of 600 seconds OK for the idle timer?
   3. Do we even WANT an idle timer?
   4. Should we spend effort making it configurable at runtime in pjproject?


















-- 
George Joseph
Digium, Inc. | Software Developer
445 Jan Davis Drive NW - Huntsville, AL 35806 - US
Check us out at: www.digium.com & www.asterisk.org
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

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

[asterisk-dev] Asterisk 13.19.0-rc2 Now Available

2018-01-04 Thread Asterisk Development Team
The Asterisk Development Team would like to announce the second
release candidate of Asterisk 13.19.0.
This release candidate is available for immediate download at 
http://downloads.asterisk.org/pub/telephony/asterisk

The release of Asterisk 13.19.0-rc2 resolves several issues reported by the
community and would have not been possible without your participation.

Thank you!

The following issues are resolved in this release candidate:

Bugs fixed in this release:
---
 * ASTERISK-27531 - Compiler optimizations can break module load
  sequence.
  (Reported by abelbeck)
 * ASTERISK-27480 - Security: Authenticated SUBSCRIBE without
  Contact crashes asterisk
  (Reported by Ross Beer)

For a full list of changes in this release candidate, please see the ChangeLog:
http://downloads.asterisk.org/pub/telephony/asterisk/ChangeLog-13.19.0-rc2

Thank you for your continued support of Asterisk!
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

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

[asterisk-dev] Asterisk 15.2.0-rc2 Now Available

2018-01-04 Thread Asterisk Development Team
The Asterisk Development Team would like to announce the second
release candidate of Asterisk 15.2.0.
This release candidate is available for immediate download at 
http://downloads.asterisk.org/pub/telephony/asterisk

The release of Asterisk 15.2.0-rc2 resolves several issues reported by the
community and would have not been possible without your participation.

Thank you!

The following issues are resolved in this release candidate:

Bugs fixed in this release:
---
 * ASTERISK-27531 - Compiler optimizations can break module load
  sequence.
  (Reported by abelbeck)
 * ASTERISK-27480 - Security: Authenticated SUBSCRIBE without
  Contact crashes asterisk
  (Reported by Ross Beer)

For a full list of changes in this release candidate, please see the ChangeLog:
http://downloads.asterisk.org/pub/telephony/asterisk/ChangeLog-15.2.0-rc2

Thank you for your continued support of Asterisk!
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

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

Re: [asterisk-dev] PJSIP Subscription Handler

2018-01-04 Thread Joshua Colp
On Thu, Jan 4, 2018, at 3:56 AM, Simon Hohberg wrote:
> Hi,
> 
> I am trying to implement a PJSIP subscription handler for a custom event 
> where one endpoint sends a subscribe to another endpoint registered on 
> Asterisk.
> I have the basic structure and can receive the subscription from one 
> endpoint in the "new_subscribe" and "subscription_established" callbacks 
> (ast_sip_notifier).
> However, I don't see how I can create a new subscribe that is then send 
> out to the other endpoint.

If you mean having Asterisk set up its own outgoing subscription and act on 
NOTIFY requests, there is currently no API or support for doing such a thing. 
It only supports receiving a subscribe and acting on it.

-- 
Joshua Colp
Digium, Inc. | Senior Software Developer
445 Jan Davis Drive NW - Huntsville, AL 35806 - US
Check us out at: www.digium.com & www.asterisk.org

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

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


Re: [asterisk-dev] Suspected chan_sip regression bug, when re-invite occurs from IPv4 to IPv6 (IPv6 is da-shit! giving us the da-shit!)

2018-01-04 Thread Nir Simionovich
Issue reported as ASTERISK-27545.

On Thu, Jan 4, 2018 at 8:36 AM Nir Simionovich 
wrote:

> Hi All,
>
>   We've recently encountered an interesting bug with Asterisk 13 (the
> version we are testing with), but I believe
> as this is a fairly crazy (although reasonable) test scenario - the issue
> may still be there.
>
>   The scenario is the following:
>
> UAC A  IPv4 + SIP + RTP > Asterisk --- IPv4 + SIP + RTP ---> UA B
>
>   When the following happens, we all know that this is working correctly,
> no problem there. However, during the
> call, the network condition changes, namely in our case: Transit from UAC
> A to Asterisk changes from IPv4 to
> IPv6, thus the following happens:
>
> UAC A  IPv6 + SIP + RTP > Asterisk --- IPv4 + SIP + RTP ---> UA B
>
>   The SDP response in the 200 OK coming back from Asterisk is malformed,
> and contains IPv4 addresses in the
> SDP, although it shouldn't. For example (pay attention to the bolded
> section):
>
> INVITE sip:4015@[2a03:b0c0:1:d0::176b:1001]:5090 SIP/2.0
> Via: SIP/2.0/UDP
> [2001:470:1f06:404:8562:7dba:63c9:3986]:5090;rport;branch=z9hG4bKPj.gYD2Pm-L3SCeUUj8Ne69O7AjM27TNq1
>
> Max-Forwards: 70
> From: 
> sip:4...@xx.dev.greenfieldtech.net;tag=7lAWRIh6cVthKG-XFN-bCRvGnlBRG6Gq
>
> To: sip:6...@xx.dev.greenfieldtech.net;tag=as4b993656
> Contact: 
> Call-ID: RqxyicrI6s6vrih1XJMU-GvHFeo9x3IE
> CSeq: 18030 INVITE
> Allow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, SUBSCRIBE, NOTIFY,
> REFER, MESSAGE, OPTIONS
> Supported: replaces, 100rel, timer, norefersub
> Session-Expires: 1800;refresher=uas
> Min-SE: 90
> Content-Type: application/sdp
> Content-Length: 584
>
> v=0
> o=- 3723897380 3723897382 IN IP4 100.101.10.126
> s=pjmedia
> b=AS:117
> t=0 0
> a=X-nat:0
> m=audio 4002 RTP/AVP 98 97 99 104 3 0 8 9 120 96
> c=IN IP6 2001:470:1f06:404:8562:7dba:63c9:3986
> b=TIAS:96000
> a=rtcp:4003 IN IP6 2001:470:1f06:404:8562:7dba:63c9:3986
> a=sendrecv
> a=rtpmap:98 speex/16000
> a=rtpmap:97 speex/8000
> a=rtpmap:99 speex/32000
> a=rtpmap:104 iLBC/8000
> a=fmtp:104 mode=30
> a=rtpmap:3 GSM/8000
> a=rtpmap:0 PCMU/8000
> a=rtpmap:8 PCMA/8000
> a=rtpmap:9 G722/8000
> a=rtpmap:120 opus/48000/2
> a=fmtp:120 useinbandfec=1
> a=rtpmap:96 telephone-event/8000
> a=fmtp:96 0-16
>
> INVITE sip:4015@[2a03:b0c0:1:d0::176b:1001]:5090 SIP/2.0
> Via: SIP/2.0/UDP
> [2001:470:1f06:404:8562:7dba:63c9:3986]:5090;rport;branch=z9hG4bKPj.gYD2Pm-L3SCeUUj8Ne69O7AjM27TNq1
>
> Max-Forwards: 70
> From: 
> sip:4...@xx.dev.greenfieldtech.net;tag=7lAWRIh6cVthKG-XFN-bCRvGnlBRG6Gq
>
> To: sip:6...@xx.dev.greenfieldtech.net;tag=as4b993656
> Contact: 
> Call-ID: RqxyicrI6s6vrih1XJMU-GvHFeo9x3IE
> CSeq: 18030 INVITE
> Allow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, SUBSCRIBE, NOTIFY,
> REFER, MESSAGE, OPTIONS
> Supported: replaces, 100rel, timer, norefersub
> Session-Expires: 1800;refresher=uas
> Min-SE: 90
> Content-Type: application/sdp
> Content-Length: 584
>
> v=0
> o=- 3723897380 3723897382 IN IP4 100.101.10.126
> s=pjmedia
> b=AS:117
> t=0 0
> a=X-nat:0
> m=audio 4002 RTP/AVP 98 97 99 104 3 0 8 9 120 96
> c=IN IP6 2001:470:1f06:404:8562:7dba:63c9:3986
> b=TIAS:96000
> a=rtcp:4003 IN IP6 2001:470:1f06:404:8562:7dba:63c9:3986
> a=sendrecv
> a=rtpmap:98 speex/16000
> a=rtpmap:97 speex/8000
> a=rtpmap:99 speex/32000
> a=rtpmap:104 iLBC/8000
> a=fmtp:104 mode=30
> a=rtpmap:3 GSM/8000
> a=rtpmap:0 PCMU/8000
> a=rtpmap:8 PCMA/8000
> a=rtpmap:9 G722/8000
> a=rtpmap:120 opus/48000/2
> a=fmtp:120 useinbandfec=1
> a=rtpmap:96 telephone-event/8000
> a=fmtp:96 0-16
>
> SIP/2.0 100 Trying
> Via: SIP/2.0/UDP
> [2001:470:1f06:404:8562:7dba:63c9:3986]:5090;branch=z9hG4bKPj.gYD2Pm-L3SCeUUj8Ne69O7AjM27TNq1;received=2001:470:1f06:404:8562:7dba:63c9:3986;rport=5090
>
> From: 
> sip:4...@xx.dev.greenfieldtech.net;tag=7lAWRIh6cVthKG-XFN-bCRvGnlBRG6Gq
>
> To: sip:6...@xx.dev.greenfieldtech.net;tag=as4b993656
> Call-ID: RqxyicrI6s6vrih1XJMU-GvHFeo9x3IE
> CSeq: 18030 INVITE
> Server: Asterisk PBX 14.7.0-rc2
> Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO,
> PUBLISH, MESSAGE
> Supported: replaces, timer
> Session-Expires: 1800;refresher=uas
> Contact: 
> Content-Length: 0
>
>
>
> *SIP/2.0 200 OK Via: SIP/2.0/UDP
> [2001:470:1f06:404:8562:7dba:63c9:3986]:5090;branch=z9hG4bKPj.gYD2Pm-L3SCeUUj8Ne69O7AjM27TNq1;received=2001:470:1f06:404:8562:7dba:63c9:3986;rport=5090
> From: sip:4015@*xx
> *.dev.greenfieldtech.net
> ;tag=7lAWRIh6cVthKG-XFN-bCRvGnlBRG6Gq To:
> sip:600@*xx
>
>
>
>
>
>
> *.dev.greenfieldtech.net ;tag=as4b993656
> Call-ID: RqxyicrI6s6vrih1XJMU-GvHFeo9x3IE CSeq: 18030 INVITE Server:
> Asterisk PBX 14.7.0-rc2 Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER,
> SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE Supported: replaces, timer
> Session-Expires: 1800;refresher=uas Contact: 
>
>
>
> *.231:5090> Content-Type: application/sdp Require: timer Content-Length:
> 914 *
>
> *v=0 o=root