[asterisk-users] Asterisk proxying a REFER

Luca Pradovera luca.pradovera at gmail.com
Mon May 4 10:15:44 CDT 2015


--
Luca Pradovera
luca.pradovera at gmail.com


Hello,
sorry, I managed to lose the reply amidst the traffic.

What we have here is our application server APP with leg A in AsyncAGI in an Adhearsion application, which after some magic dials leg B on the office PBX through a configured peer.

Leg B then decides that user C knows more about the subject, and initiates a blind transfer to C’s phone using the desk phone that sends a REFER request.
When leg B is hung up as part of the REFER going through, Adhearsion receives a Hangup and terminates the call.

There is not much else going on there, our original idea was to put a B2BUA on the APP server and to have that “swallow” refers so Adhearsion and the APP Asterisk never see it.

Thanks!

Luca


> On Apr 28, 2015, at 19:00, asterisk-users-request at lists.digium.com wrote:
> 
> Send asterisk-users mailing list submissions to
> 	asterisk-users at lists.digium.com
> 
> To subscribe or unsubscribe via the World Wide Web, visit
> 	http://lists.digium.com/mailman/listinfo/asterisk-users
> or, via email, send a message with subject or body 'help' to
> 	asterisk-users-request at lists.digium.com
> 
> You can reach the person managing the list at
> 	asterisk-users-owner at lists.digium.com
> 
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of asterisk-users digest..."
> 
> 
> Today's Topics:
> 
>   1. Re: Asterisk proxying a REFER (Matthew Jordan)
>   2. hi list need your help (????? ??????)
>   3. Re: adding area code (Motty Cruz)
> 
> 
> ----------------------------------------------------------------------
> 
> Message: 1
> Date: Tue, 28 Apr 2015 07:27:29 -0500
> From: Matthew Jordan <mjordan at digium.com>
> To: Asterisk Users Mailing List - Non-Commercial Discussion
> 	<asterisk-users at lists.digium.com>
> Subject: Re: [asterisk-users] Asterisk proxying a REFER
> Message-ID:
> 	<CAN2PU+6UYLYFDXnt-XZztBz++8gGmKfdYwHRr84F93OzosV=WQ at mail.gmail.com>
> Content-Type: text/plain; charset=UTF-8
> 
> On Mon, Apr 27, 2015 at 10:36 AM, Luca Pradovera
> <luca.pradovera at gmail.com> wrote:
>> Hello,
>> we are using Asterisk with Adhearsion as our application server, with
>> another Asterisk box acting as the office PBX, where all office phones are
>> registered.
>> 
>> A REFER to transfer calls within the office results in the Adhearsion
>> application call being dropped, because the leg between the PBX and the app
>> server is terminated by the PBX following the REFER.
>> Is there a way to configure Asterisk 11 to proxy a refer across a bridge
>> instead of following it, so the application server can follow it instead?
>> 
> 
> Hey Luca -
> 
> Unfortunately, there is not a simple or easy configuration setting
> that tells Asterisk to proxy the REFER request through. Generally,
> Asterisk doesn't like proxying anything.
> 
> There may still be another way to handle this issue, depending on the
> setup. Can you provide a bit more information about the channels on
> the PBX/Adhearsion server, who sends the REFER request, and what
> happens explicitly in the scenario?
> 
> Matt
> 
> --
> Matthew Jordan
> Digium, Inc. | Director of Technology
> 445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
> Check us out at: http://digium.com & http://asterisk.org
> 
> 
> 
> ------------------------------
> 
> Message: 2
> Date: Tue, 28 Apr 2015 17:19:46 +0300
> From: ????? ?????? <satskiy.a at gmail.com>
> To: Asterisk Users Mailing List - Non-Commercial Discussion
> 	<asterisk-users at lists.digium.com>
> Subject: [asterisk-users] hi list need your help
> Message-ID:
> 	<CAFgS45v=t-qkfkTypJhj5YijWOh+D5pQY2JXF3w8YN9iR+B5mg at mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
> 
> facing problem with  originating  webrtc calls
> 
> 
> 1-when iam  doing call from webrtc iget ice working
> <--- SIP read from WS:91.196.158.205:1466 --->
> INVITE sip:0669197533 at 77.91.132.9 SIP/2.0
> Via: SIP/2.0/WS 7cvtd9ihs2e8.invalid;branch=z9hG4bK8749315
> Max-Forwards: 69
> To: <sip:0669197533 at 77.91.132.9>
> From: "Anton" <sip:1065 at 77.91.132.9>;tag=5i21qaop43
> Call-ID: ocq4hu8eol3kijsgvt6b
> CSeq: 1465 INVITE
> Authorization: Digest algorithm=MD5, username="1065", realm="77.91.132.9",
> nonce="5152b137", uri="sip:0669197533 at 77.91.132.9",
> response="446883f3c97a49ea7a9a554a1ba31b6a"
> X-Can-Renegotiate: true
> Contact: <sip:0momhddj at 7cvtd9ihs2e8.invalid;transport=ws;ob>
> Content-Type: application/sdp
> Session-Expires: 90
> Allow: INVITE,ACK,CANCEL,BYE,UPDATE,MESSAGE,OPTIONS
> Supported: timer,ice,outbound
> User-Agent: JsSIP 0.6.26
> Content-Length: 2554
> 
> v=0
> o=- 4785391175048354014 2 IN IP4 127.0.0.1
> s=-
> t=0 0
> a=group:BUNDLE audio video
> a=msid-semantic: WMS cC3clldcCIxZyWm8eHpKdycUakfANCZmV8Br
> m=audio 2313 RTP/SAVPF 111 103 104 9 0 8 106 105 13 126
> c=IN IP4 192.168.88.26
> a=rtcp:2313 IN IP4 192.168.88.26
> a=candidate:97470069 1 udp 2122260223 192.168.88.26 2313 typ host
> generation 0
> a=candidate:97470069 2 udp 2122260223 192.168.88.26 2313 typ host
> generation 0
> a=candidate:1263319685 1 tcp 1518280447 192.168.88.26 0 typ host tcptype
> active generation 0
> a=candidate:1263319685 2 tcp 1518280447 192.168.88.26 0 typ host tcptype
> active generation 0
> a=ice-ufrag:8nMZ7w8bHdBBoY1a
> a=ice-pwd:CFh1JMRfcT5BoH7aoKQuDgDR
> a=fingerprint:sha-256
> 6D:5A:B7:7C:8E:1F:2A:F2:8C:DB:49:E4:8D:8F:BE:A0:84:AF:21:E2:A1:D7:DC:29:B1:EE:C3:0C:2C:AF:6C:04
> a=setup:actpass
> a=mid:audio
> a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
> a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
> a=sendrecv
> a=rtcp-mux
> a=rtpmap:111 opus/48000/2
> a=fmtp:111 minptime=10; useinbandfec=1
> a=rtpmap:103 ISAC/16000
> a=rtpmap:104 ISAC/32000
> a=rtpmap:9 G722/8000
> a=rtpmap:0 PCMU/8000
> a=rtpmap:8 PCMA/8000
> a=rtpmap:106 CN/32000
> a=rtpmap:105 CN/16000
> a=rtpmap:13 CN/8000
> a=rtpmap:126 telephone-event/8000
> a=maxptime:60
> a=ssrc:3696151487 cname:jXfPZ33h32Mx9liw
> a=ssrc:3696151487 msid:cC3clldcCIxZyWm8eHpKdycUakfANCZmV8Br
> 8a2acec3-8511-4d36-9b51-05b8752c2ddd
> a=ssrc:3696151487 mslabel:cC3clldcCIxZyWm8eHpKdycUakfANCZmV8Br
> a=ssrc:3696151487 label:8a2acec3-8511-4d36-9b51-05b8752c2ddd
> m=video 2313 RTP/SAVPF 100 116 117 96
> c=IN IP4 192.168.88.26
> a=rtcp:2313 IN IP4 192.168.88.26
> a=candidate:97470069 1 udp 2122260223 192.168.88.26 2313 typ host
> generation 0
> a=candidate:97470069 2 udp 2122260223 192.168.88.26 2313 typ host
> generation 0
> a=candidate:1263319685 1 tcp 1518280447 192.168.88.26 0 typ host tcptype
> active generation 0
> a=candidate:1263319685 2 tcp 1518280447 192.168.88.26 0 typ host tcptype
> active generation 0
> a=ice-ufrag:8nMZ7w8bHdBBoY1a
> a=ice-pwd:CFh1JMRfcT5BoH7aoKQuDgDR
> a=fingerprint:sha-256
> 6D:5A:B7:7C:8E:1F:2A:F2:8C:DB:49:E4:8D:8F:BE:A0:84:AF:21:E2:A1:D7:DC:29:B1:EE:C3:0C:2C:AF:6C:04
> a=setup:actpass
> a=mid:video
> a=extmap:2 urn:ietf:params:rtp-hdrext:toffset
> a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
> a=recvonly
> a=rtcp-mux
> a=rtpmap:100 VP8/90000
> a=rtcp-fb:100 ccm fir
> a=rtcp-fb:100 nack
> a=rtcp-fb:100 nack pli
> a=rtcp-fb:100 goog-remb
> a=rtpmap:116 red/90000
> a=rtpmap:117 ulpfec/90000
> a=rtpmap:96 rtx/90000
> a=fmtp:96 apt=100
> 
> 2-BUT when i do channel originate sip/GOROD/XXXXX extension 1065 at office
>    -- Executing [1065 at office:1] Dial("SIP/GOROD-00000004", "SIP/1065") in
> new stack
>  == Using SIP RTP CoS mark 5
> [Apr 28 14:07:47] ERROR[4006][C-00000032]: netsock2.c:269
> ast_sockaddr_resolve: getaddrinfo("7cvtd9ihs2e8.invalid", "(null)", ...):
> Name or service not known
> [Apr 28 14:07:47] WARNING[4006][C-00000032]: chan_sip.c:15869
> __set_address_from_contact: Invalid host name in Contact: (can't resolve in
> DNS) : '7cvtd9ihs2e8.invalid'
> [Apr 28 14:07:47] ERROR[4006][C-00000032]: netsock2.c:98
> ast_sockaddr_stringify_fmt: getnameinfo(): ai_family not supported
> Audio is at 16476
> Adding codec 100003 (ulaw) to SDP
> Adding codec 100002 (gsm) to SDP
> Adding codec 100004 (alaw) to SDP
> Adding codec 100017 (testlaw) to SDP
> Adding non-codec 0x1 (telephone-event) to SDP
> Reliably Transmitting (NAT) to 91.196.158.205:1466:
> INVITE sip:0momhddj at 7cvtd9ihs2e8.invalid;transport=ws SIP/2.0
> Via: SIP/2.0/WS 77.91.132.9:5060;branch=z9hG4bK3f293d79;rport
> Max-Forwards: 70
> From: "asterisk" <sip:asterisk at 77.91.132.9>;tag=as78119d2b
> To: <sip:0momhddj at 7cvtd9ihs2e8.invalid;transport=ws>
> Contact: <sip:asterisk at 77.91.132.9:5060;transport=WS>
> Call-ID: 17a96e0848cdd7d226d3665a36c65c77 at 77.91.132.9:5060
> CSeq: 102 INVITE
> User-Agent: Asterisk PBX 11.15.0
> Date: Tue, 28 Apr 2015 11:07:47 GMT
> Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO,
> PUBLISH, MESSAGE
> Supported: replaces, timer
> Content-Type: application/sdp
> Content-Length: 437
> 
> v=0
> o=root 1122885298 1122885298 IN IP4 77.91.132.9
> s=Asterisk PBX 11.15.0
> c=IN IP4 77.91.132.9
> t=0 0
> m=audio 16476 RTP/SAVPF 0 3 8 101
> a=rtpmap:0 PCMU/8000
> a=rtpmap:3 GSM/8000
> a=rtpmap:8 PCMA/8000
> a=rtpmap:101 telephone-event/8000
> a=fmtp:101 0-16
> a=ptime:20
> a=connection:new
> a=setup:actpass
> a=fingerprint:SHA-256
> CC:82:C8:04:1F:DC:FE:B7:56:27:26:FF:18:CD:BB:71:99:B8:97:F9:81:2B:08:74:72:67:3B:A9:88:5F:00:34
> a=sendrecv
> 
> thats why i got Failed to set remote offer sdp: Called with SDP without
> ice-ufrag and ice-pwd
> 
> Waiting for your advice  ---thanks
> 
> 
> 
> 
> --
> Best regards
> Antony
> ??? (066) 919-75-33
> ??? (063) 656-43-40
> satskiy.a at gmail.com <mail%3Asatskiy.a at gmail.com>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20150428/4f152d16/attachment-0001.html>
> 
> ------------------------------
> 
> Message: 3
> Date: Tue, 28 Apr 2015 07:21:12 -0700
> From: Motty Cruz <motty.cruz at gmail.com>
> To: Asterisk Users Mailing List - Non-Commercial Discussion
> 	<asterisk-users at lists.digium.com>
> Subject: Re: [asterisk-users] adding area code
> Message-ID: <553F9758.5080907 at gmail.com>
> Content-Type: text/plain; charset="windows-1252"; Format="flowed"
> 
> this code worked for me,
> 
> here is what I did and worked for me:
> 
> exten => 1381+NXXXXXX,1,Set(CALLERID(number)=3817383444)
> 
> exten => 1+NXXNXXXXXX,2,Dial(SIP/SIP-Provider/${EXTEN:1},80)
> 
> 
> Thanks for you help!
> 
> On 04/27/2015 02:56 PM, Matt Riddell wrote:
>> 
>>> On 27Apr, 2015, at 16:39, Motty Cruz <motty.cruz at gmail.com
>>> <mailto:motty.cruz at gmail.com>> wrote:
>>> 
>>> forgot to mentioned I am running Asterisk 1.8.22.0 on CentOS.
>>> 
>>> Thanks,
>>> 
>>> 
>>> On 04/27/2015 02:38 PM, Motty Cruz wrote:
>>>> here is what I have:
>>>> 
>>>> exten => _9XXXXXXX,1,Set(l_HomeAreaCode=381)
>>>> 
>>>> exten => _9XXXXXXX,n,Set(dialnumber=${l_HomeAreaCode}${EXTEN:-1})
>>>> 
>>>> exten => _9XXXXXXX,n,Dial(SIP/SIP-Provider/${dialnumber},80)
>>>> 
>>>> not having success;
>>>> 
>>>> "Got SIP reponse 503" Service Unavailable?
>> 
>> Can you send us the console output when you make the call?
>> 
>> --
>> Cheers,
>> 
>> Matt Riddell
>> _______________________________________________
>> 
>> http://www.venturevoip.com/news.php (Daily Asterisk News)
>> http://www.venturevoip.com/pabx_on_disk.php (PABX on a Disk)
>> http://www.venturevoip.com/exchange.php (Full ITSP Solution)
>> http://www.venturevoip.com/cc.php (Call Centre Solutions)
>> 
>> 
>> 
> 
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20150428/7cc94c2f/attachment-0001.html>
> 
> ------------------------------
> 
> _______________________________________________
> --Bandwidth and Colocation Provided by http://www.api-digital.com--
> 
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users
> 
> End of asterisk-users Digest, Vol 129, Issue 32
> ***********************************************

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20150504/9c516748/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 496 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20150504/9c516748/attachment.pgp>


More information about the asterisk-users mailing list