freeswitch can't receive b-leg dtmf during calling to an agent of callcenter for at least 60 seconds - freeswitch

As the title says, I have a problem of getting dtmf digits from b-leg. When I call a queue in callcenter, the two legs can be bridged. But It doesn't have any reaction when I press '*7' on my b-leg telephone.
Here is the dialplan:
<extension name="Queue90">
<condition field="destination_number" expression="^90$">
<action application="bind_meta_app" data="7 ab s execute_extension::att_xfer XML features"/>
<action application="callcenter" data="90"/>
</condition>
</extension>
And, here is the console log:
2021-10-28 10:44:19.553594 [NOTICE] switch_channel.c:1118 New Channel sofia/internal/8001#10.75.6.77 [f3285184-3798-11ec-a026-fd0671809b3f]
2021-10-28 10:44:19.553594 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/8001#10.75.6.77) Running State Change CS_NEW (Cur 1 Tot 3)
2021-10-28 10:44:19.553594 [DEBUG] sofia.c:10279 sofia/internal/8001#10.75.6.77 receiving invite from 10.30.4.11:5060 version: 1.10.3 -release 64bit
2021-10-28 10:44:19.553594 [DEBUG] sofia.c:10373 verifying acl "domains" for ip/port 10.30.4.11:0.
2021-10-28 10:44:19.553594 [DEBUG] switch_core_state_machine.c:604 (sofia/internal/8001#10.75.6.77) State NEW
2021-10-28 10:44:19.573586 [DEBUG] sofia.c:2434 detaching session f3285184-3798-11ec-a026-fd0671809b3f
freeswitch#pbx>
2021-10-28 10:44:19.593597 [DEBUG] sofia.c:2544 Re-attaching to session f3285184-3798-11ec-a026-fd0671809b3f
2021-10-28 10:44:19.613595 [DEBUG] sofia.c:10279 sofia/internal/8001#10.75.6.77 receiving invite from 10.30.4.11:5060 version: 1.10.3 -release 64bit
2021-10-28 10:44:19.613595 [DEBUG] sofia.c:10373 verifying acl "domains" for ip/port 10.30.4.11:0.
2021-10-28 10:44:19.613595 [NOTICE] mod_python.c:213 Invoking py module: user_manage
2021-10-28 10:44:19.613595 [DEBUG] mod_python.c:305 Call python script
2021-10-28 10:44:19.633586 [DEBUG] mod_python.c:308 Finished calling python script
2021-10-28 10:44:19.633586 [DEBUG] sofia.c:7325 Channel sofia/internal/8001#10.75.6.77 entering state [received][100]
2021-10-28 10:44:19.633586 [DEBUG] sofia.c:7335 Remote SDP:
v=0
o=8001 8000 8000 IN IP4 10.30.4.11
s=SIP Call
c=IN IP4 10.30.4.11
t=0 0
m=audio 5004 RTP/AVP 0 8 9 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:9 G722/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:20
2021-10-28 10:44:19.633586 [DEBUG] sofia.c:7738 (sofia/internal/8001#10.75.6.77) State Change CS_NEW -> CS_INIT
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/8001#10.75.6.77) Running State Change CS_INIT (Cur 1 Tot 3)
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:628 (sofia/internal/8001#10.75.6.77) State INIT
2021-10-28 10:44:19.633586 [DEBUG] mod_sofia.c:93 sofia/internal/8001#10.75.6.77 SOFIA INIT
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:40 sofia/internal/8001#10.75.6.77 Standard INIT
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:48 (sofia/internal/8001#10.75.6.77) State Change CS_INIT -> CS_ROUTING
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:628 (sofia/internal/8001#10.75.6.77) State INIT going to sleep
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/8001#10.75.6.77) Running State Change CS_ROUTING (Cur 1 Tot 3)
2021-10-28 10:44:19.633586 [DEBUG] switch_channel.c:2332 (sofia/internal/8001#10.75.6.77) Callstate Change DOWN -> RINGING
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:644 (sofia/internal/8001#10.75.6.77) State ROUTING
2021-10-28 10:44:19.633586 [DEBUG] mod_sofia.c:154 sofia/internal/8001#10.75.6.77 SOFIA ROUTING
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:236 sofia/internal/8001#10.75.6.77 Standard ROUTING
2021-10-28 10:44:19.633586 [INFO] mod_dialplan_xml.c:637 Processing xxx <8001>->90 in context default
Dialplan: sofia/internal/8001#10.75.6.77 parsing [default->Queue90] continue=false
Dialplan: sofia/internal/8001#10.75.6.77 Regex (PASS) [Queue90] destination_number(90) =~ /^90$/ break=on-false
Dialplan: sofia/internal/8001#10.75.6.77 Action bind_meta_app(7 b s execute_extension::att_xfer XML features)
Dialplan: sofia/internal/8001#10.75.6.77 Action callcenter(90)
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:287 (sofia/internal/8001#10.75.6.77) State Change CS_ROUTING -> CS_EXECUTE
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:644 (sofia/internal/8001#10.75.6.77) State ROUTING going to sleep
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/8001#10.75.6.77) Running State Change CS_EXECUTE (Cur 1 Tot 3)
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:651 (sofia/internal/8001#10.75.6.77) State EXECUTE
2021-10-28 10:44:19.633586 [DEBUG] mod_sofia.c:209 sofia/internal/8001#10.75.6.77 SOFIA EXECUTE
2021-10-28 10:44:19.633586 [DEBUG] switch_core_state_machine.c:329 sofia/internal/8001#10.75.6.77 Standard EXECUTE
EXECUTE [depth=0] sofia/internal/8001#10.75.6.77 bind_meta_app(7 b s execute_extension::att_xfer XML features)
2021-10-28 10:44:19.633586 [INFO] switch_ivr_async.c:4457 Bound B-Leg: *7 execute_extension::att_xfer XML features
2021-10-28 10:44:19.633586 [DEBUG] switch_core_session.c:2722 Application callcenter Requires media! pre_answering channel sofia/internal/8001#10.75.6.77
2021-10-28 10:44:19.633586 [INFO] switch_core_session.c:2724 Sending early media
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[opus:116:48000:20:0:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[G722:9:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[PCMU:0:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5647 Audio Codec Compare [PCMU:0:8000:20:64000:1] ++++ is saved as a match
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[PCMA:8:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[opus:116:48000:20:0:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[G722:9:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[PCMU:0:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[PCMA:8:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5647 Audio Codec Compare [PCMA:8:8000:20:64000:1] ++++ is saved as a match
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[opus:116:48000:20:0:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[G722:9:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5647 Audio Codec Compare [G722:9:8000:20:64000:1] ++++ is saved as a match
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[PCMU:0:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[PCMA:8:8000:20:64000:1]
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5508 Set telephone-event payload to 101#8000
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:3837 Set Codec sofia/internal/8001#10.75.6.77 PCMU/8000 20 ms 160 samples 64000 bits 1 channels
2021-10-28 10:44:19.633586 [DEBUG] switch_core_codec.c:111 sofia/internal/8001#10.75.6.77 Original read codec set to PCMU:0
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5851 Set telephone-event payload to 101#8000
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:5909 sofia/internal/8001#10.75.6.77 Set 2833 dtmf send payload to 101 recv payload to 101
2021-10-28 10:44:19.633586 [DEBUG] switch_core_media.c:8661 AUDIO RTP [sofia/internal/8001#10.75.6.77] 10.75.6.77 port 30308 -> 10.30.4.11 port 5004 codec: 0 ms: 20
2021-10-28 10:44:19.633586 [DEBUG] switch_rtp.c:4413 Starting timer [soft] 160 bytes per 20ms
2021-10-28 10:44:19.653601 [DEBUG] switch_core_media.c:8975 sofia/internal/8001#10.75.6.77 Set 2833 dtmf send payload to 101
2021-10-28 10:44:19.653601 [DEBUG] switch_core_media.c:8982 sofia/internal/8001#10.75.6.77 Set 2833 dtmf receive payload to 101
2021-10-28 10:44:19.653601 [DEBUG] switch_core_media.c:9005 sofia/internal/8001#10.75.6.77 Set rtp dtmf delay to 40
2021-10-28 10:44:19.653601 [NOTICE] sofia_media.c:92 Pre-Answer sofia/internal/8001#10.75.6.77!
2021-10-28 10:44:19.653601 [DEBUG] switch_channel.c:3565 (sofia/internal/8001#10.75.6.77) Callstate Change RINGING -> EARLY
2021-10-28 10:44:19.653601 [DEBUG] switch_core_media.c:8643 Audio params are unchanged for sofia/internal/8001#10.75.6.77.
2021-10-28 10:44:19.653601 [DEBUG] mod_sofia.c:2593 Ring SDP:
v=0
o=FreeSWITCH 1635358751 1635358752 IN IP4 10.75.6.77
s=FreeSWITCH
c=IN IP4 10.75.6.77
t=0 0
m=audio 30308 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv
EXECUTE [depth=0] sofia/internal/8001#10.75.6.77 callcenter(90)
2021-10-28 10:44:19.653601 [DEBUG] sofia.c:7325 Channel sofia/internal/8001#10.75.6.77 entering state [early][183]
2021-10-28 10:44:19.653601 [DEBUG] switch_core_media.c:8643 Audio params are unchanged for sofia/internal/8001#10.75.6.77.
2021-10-28 10:44:19.653601 [DEBUG] mod_sofia.c:898 Local SDP sofia/internal/8001#10.75.6.77:
v=0
o=FreeSWITCH 1635358751 1635358753 IN IP4 10.75.6.77
s=FreeSWITCH
c=IN IP4 10.75.6.77
t=0 0
m=audio 30308 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv
2021-10-28 10:44:19.653601 [NOTICE] mod_callcenter.c:3020 Channel [sofia/internal/8001#10.75.6.77] has been answered
2021-10-28 10:44:19.653601 [DEBUG] switch_channel.c:3865 (sofia/internal/8001#10.75.6.77) Callstate Change EARLY -> ACTIVE
2021-10-28 10:44:19.653601 [DEBUG] sofia.c:7325 Channel sofia/internal/8001#10.75.6.77 entering state [completed][200]
2021-10-28 10:44:19.653601 [DEBUG] mod_callcenter.c:3111 Member xxx <8001> joining queue 90
2021-10-28 10:44:19.653601 [DEBUG] mod_callcenter.c:3375 Queue has 1 waiting calls.
2021-10-28 10:44:19.653601 [DEBUG] switch_ivr_play_say.c:1488 Codec Activated L16#8000hz 1 channels 20ms
freeswitch#pbx>
2021-10-28 10:44:19.673591 [DEBUG] mod_callcenter.c:1180 Updated Agent 5001 set state = Receiving
2021-10-28 10:44:19.673591 [DEBUG] mod_callcenter.c:1753 Setting outbound caller_id_name to: xxx
2021-10-28 10:44:19.673591 [DEBUG] switch_ivr_originate.c:2242 Parsing global variables
2021-10-28 10:44:19.673591 [DEBUG] switch_ivr_originate.c:2804 Parsing session specific variables
2021-10-28 10:44:19.673591 [NOTICE] mod_python.c:213 Invoking py module: user_manage
2021-10-28 10:44:19.673591 [DEBUG] mod_python.c:305 Call python script
2021-10-28 10:44:19.693596 [DEBUG] mod_python.c:308 Finished calling python script
2021-10-28 10:44:19.693596 [DEBUG] switch_ivr_originate.c:2242 Parsing global variables
2021-10-28 10:44:19.693596 [NOTICE] switch_channel.c:1118 New Channel sofia/internal/5001#10.30.0.15:5068 [f33da75a-3798-11ec-a02f-fd0671809b3f]
2021-10-28 10:44:19.693596 [DEBUG] mod_sofia.c:5089 (sofia/internal/5001#10.30.0.15:5068) State Change CS_NEW -> CS_INIT
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_INIT (Cur 2 Tot 4)
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:628 (sofia/internal/5001#10.30.0.15:5068) State INIT
2021-10-28 10:44:19.693596 [DEBUG] mod_sofia.c:93 sofia/internal/5001#10.30.0.15:5068 SOFIA INIT
2021-10-28 10:44:19.693596 [DEBUG] sofia_glue.c:1587 sip:5001#10.30.0.15:5068 Setting proxy route to sofia/internal/5001#10.30.0.15:5068
2021-10-28 10:44:19.693596 [DEBUG] sofia_glue.c:1618 sofia/internal/5001#10.30.0.15:5068 sending invite version: 1.10.3 -release 64bit
Local SDP:
v=0
o=FreeSWITCH 1635364719 1635364720 IN IP4 10.75.6.77
s=FreeSWITCH
c=IN IP4 10.75.6.77
t=0 0
m=audio 24340 RTP/AVP 102 9 0 8 105 101
a=rtpmap:102 opus/48000/2
a=fmtp:102 useinbandfec=1; maxaveragebitrate=30000; maxplaybackrate=48000; ptime=20; minptime=10; maxptime=40
a=rtpmap:9 G722/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:105 telephone-event/48000
a=fmtp:105 0-16
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv
m=video 25832 RTP/AVP 103 104
b=AS:3072
a=rtpmap:103 H264/90000
a=rtpmap:104 VP8/90000
a=sendrecv
a=rtcp-fb:103 ccm fir
a=rtcp-fb:103 ccm tmmbr
a=rtcp-fb:103 nack
a=rtcp-fb:103 nack pli
a=rtcp-fb:104 ccm fir
a=rtcp-fb:104 ccm tmmbr
a=rtcp-fb:104 nack
a=rtcp-fb:104 nack pli
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:40 sofia/internal/5001#10.30.0.15:5068 Standard INIT
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:48 (sofia/internal/5001#10.30.0.15:5068) State Change CS_INIT -> CS_ROUTING
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:628 (sofia/internal/5001#10.30.0.15:5068) State INIT going to sleep
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_ROUTING (Cur 2 Tot 4)
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:644 (sofia/internal/5001#10.30.0.15:5068) State ROUTING
2021-10-28 10:44:19.693596 [DEBUG] mod_sofia.c:154 sofia/internal/5001#10.30.0.15:5068 SOFIA ROUTING
2021-10-28 10:44:19.693596 [DEBUG] switch_ivr_originate.c:67 (sofia/internal/5001#10.30.0.15:5068) State Change CS_ROUTING -> CS_CONSUME_MEDIA
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:644 (sofia/internal/5001#10.30.0.15:5068) State ROUTING going to sleep
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_CONSUME_MEDIA (Cur 2 Tot 4)
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:663 (sofia/internal/5001#10.30.0.15:5068) State CONSUME_MEDIA
2021-10-28 10:44:19.693596 [DEBUG] switch_core_state_machine.c:663 (sofia/internal/5001#10.30.0.15:5068) State CONSUME_MEDIA going to sleep
2021-10-28 10:44:19.693596 [DEBUG] sofia.c:7325 Channel sofia/internal/5001#10.30.0.15:5068 entering state [calling][0]
freeswitch#pbx>
freeswitch#pbx>
2021-10-28 10:44:19.833592 [DEBUG] sofia.c:7325 Channel sofia/internal/5001#10.30.0.15:5068 entering state [proceeding][180]
2021-10-28 10:44:19.833592 [NOTICE] sofia.c:7436 Ring-Ready sofia/internal/5001#10.30.0.15:5068!
2021-10-28 10:44:19.833592 [DEBUG] switch_channel.c:3437 (sofia/internal/5001#10.30.0.15:5068) Callstate Change DOWN -> RINGING
freeswitch#pbx>
freeswitch#pbx>
2021-10-28 10:44:19.973606 [DEBUG] sofia.c:7325 Channel sofia/internal/8001#10.75.6.77 entering state [ready][200]
2021-10-28 10:44:20.253590 [DEBUG] switch_rtp.c:7722 Correct audio ip/port confirmed.
freeswitch#pbx>
2021-10-28 10:44:22.173587 [DEBUG] switch_ivr_play_say.c:1933 done playing file /usr/local/freeswitch/sounds/zhuanjiezhong.wav
2021-10-28 10:44:22.193590 [DEBUG] switch_ivr_play_say.c:1488 Codec Activated L16#8000hz 1 channels 20ms
2021-10-28 10:44:23.053590 [DEBUG] sofia.c:7325 Channel sofia/internal/5001#10.30.0.15:5068 entering state [completing][200]
2021-10-28 10:44:23.053590 [DEBUG] sofia.c:7335 Remote SDP:
v=0
o=5001 8004 8000 IN IP4 10.30.0.15
s=SIP Call
c=IN IP4 10.30.0.15
t=0 0
m=audio 5028 RTP/AVP 0 8 9 105
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:9 G722/8000
a=rtpmap:105 telephone-event/8000
a=fmtp:105 0-15
a=ptime:20
m=video 0 RTP/AVP 103 104
2021-10-28 10:44:23.073610 [DEBUG] sofia.c:7325 Channel sofia/internal/5001#10.30.0.15:5068 entering state [ready][200]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[opus:116:48000:20:0:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[G722:9:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[PCMU:0:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5647 Audio Codec Compare [PCMU:0:8000:20:64000:1] ++++ is saved as a match
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMU:0:8000:20:64000:1]/[PCMA:8:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[opus:116:48000:20:0:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[G722:9:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[PCMU:0:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [PCMA:8:8000:20:64000:1]/[PCMA:8:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5647 Audio Codec Compare [PCMA:8:8000:20:64000:1] ++++ is saved as a match
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[opus:116:48000:20:0:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[G722:9:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5647 Audio Codec Compare [G722:9:8000:20:64000:1] ++++ is saved as a match
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[PCMU:0:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5592 Audio Codec Compare [G722:9:8000:20:64000:1]/[PCMA:8:8000:20:64000:1]
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5508 Set telephone-event payload to 105#8000
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:3837 Set Codec sofia/internal/5001#10.30.0.15:5068 PCMU/8000 20 ms 160 samples 64000 bits 1 channels
2021-10-28 10:44:23.073610 [DEBUG] switch_core_codec.c:111 sofia/internal/5001#10.30.0.15:5068 Original read codec set to PCMU:0
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5851 Set telephone-event payload to 105#8000
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:5909 sofia/internal/5001#10.30.0.15:5068 Set 2833 dtmf send payload to 105 recv payload to 101
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:8661 AUDIO RTP [sofia/internal/5001#10.30.0.15:5068] 10.75.6.77 port 24340 -> 10.30.0.15 port 5028 codec: 0 ms: 20
2021-10-28 10:44:23.073610 [DEBUG] switch_rtp.c:4413 Starting timer [soft] 160 bytes per 20ms
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:8975 sofia/internal/5001#10.30.0.15:5068 Set 2833 dtmf send payload to 105
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:8982 sofia/internal/5001#10.30.0.15:5068 Set 2833 dtmf receive payload to 101
2021-10-28 10:44:23.073610 [DEBUG] switch_core_media.c:9005 sofia/internal/5001#10.30.0.15:5068 Set rtp dtmf delay to 40
2021-10-28 10:44:23.073610 [NOTICE] sofia.c:8503 Channel [sofia/internal/5001#10.30.0.15:5068] has been answered
2021-10-28 10:44:23.073610 [DEBUG] switch_channel.c:3865 (sofia/internal/5001#10.30.0.15:5068) Callstate Change RINGING -> ACTIVE
2021-10-28 10:44:23.073610 [DEBUG] switch_ivr_originate.c:3852 Originate Resulted in Success: [sofia/internal/5001#10.30.0.15:5068]
2021-10-28 10:44:23.073610 [DEBUG] switch_ivr_originate.c:3852 Originate Resulted in Success: [sofia/internal/5001#10.30.0.15:5068]
2021-10-28 10:44:23.093582 [DEBUG] switch_ivr_async.c:1351 Record session sample rate: 8000 -> 8000
2021-10-28 10:44:23.093582 [DEBUG] switch_core_media_bug.c:970 Attaching BUG to sofia/internal/8001#10.75.6.77
2021-10-28 10:44:23.093582 [DEBUG] mod_callcenter.c:1965 Agent 5001 answered "xxx" <8001> from queue 90 (Recorded)
2021-10-28 10:44:23.093582 [DEBUG] switch_ivr_bridge.c:2213 (sofia/internal/8001#10.75.6.77) State Change CS_EXECUTE -> CS_HIBERNATE
2021-10-28 10:44:23.093582 [DEBUG] switch_ivr_bridge.c:2215 (sofia/internal/5001#10.30.0.15:5068) State Change CS_CONSUME_MEDIA -> CS_HIBERNATE
2021-10-28 10:44:23.093582 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_HIBERNATE (Cur 2 Tot 4)
2021-10-28 10:44:23.093582 [DEBUG] switch_core_state_machine.c:666 (sofia/internal/5001#10.30.0.15:5068) State HIBERNATE
2021-10-28 10:44:23.093582 [DEBUG] mod_sofia.c:191 sofia/internal/5001#10.30.0.15:5068 SOFIA HIBERNATE
2021-10-28 10:44:23.093582 [DEBUG] switch_ivr_bridge.c:1144 (sofia/internal/5001#10.30.0.15:5068) State Change CS_HIBERNATE -> CS_RESET
2021-10-28 10:44:23.093582 [DEBUG] switch_core_state_machine.c:666 (sofia/internal/5001#10.30.0.15:5068) State HIBERNATE going to sleep
2021-10-28 10:44:23.093582 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_RESET (Cur 2 Tot 4)
2021-10-28 10:44:23.093582 [DEBUG] switch_core_state_machine.c:647 (sofia/internal/5001#10.30.0.15:5068) State RESET
2021-10-28 10:44:23.093582 [DEBUG] mod_sofia.c:172 sofia/internal/5001#10.30.0.15:5068 SOFIA RESET
2021-10-28 10:44:23.093582 [DEBUG] switch_ivr_bridge.c:1129 sofia/internal/5001#10.30.0.15:5068 CUSTOM RESET
2021-10-28 10:44:23.093582 [DEBUG] switch_core_state_machine.c:188 sofia/internal/5001#10.30.0.15:5068 Standard RESET
2021-10-28 10:44:23.093582 [DEBUG] switch_core_state_machine.c:647 (sofia/internal/5001#10.30.0.15:5068) State RESET going to sleep
2021-10-28 10:44:23.093582 [DEBUG] switch_ivr_play_say.c:1933 done playing file /usr/local/freeswitch/sounds/zhuanjiezhong.wav
2021-10-28 10:44:23.093582 [DEBUG] mod_callcenter.c:3283 Member xxx <8001> is answered by an agent in queue 90
2021-10-28 10:44:23.113588 [DEBUG] mod_callcenter.c:3375 Queue has 0 waiting calls.
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:651 (sofia/internal/8001#10.75.6.77) State EXECUTE going to sleep
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/8001#10.75.6.77) Running State Change CS_HIBERNATE (Cur 2 Tot 4)
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:666 (sofia/internal/8001#10.75.6.77) State HIBERNATE
2021-10-28 10:44:23.113588 [DEBUG] mod_sofia.c:191 sofia/internal/8001#10.75.6.77 SOFIA HIBERNATE
2021-10-28 10:44:23.113588 [DEBUG] switch_ivr_bridge.c:1144 (sofia/internal/8001#10.75.6.77) State Change CS_HIBERNATE -> CS_RESET
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:666 (sofia/internal/8001#10.75.6.77) State HIBERNATE going to sleep
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/8001#10.75.6.77) Running State Change CS_RESET (Cur 2 Tot 4)
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:647 (sofia/internal/8001#10.75.6.77) State RESET
2021-10-28 10:44:23.113588 [DEBUG] mod_sofia.c:172 sofia/internal/8001#10.75.6.77 SOFIA RESET
2021-10-28 10:44:23.113588 [DEBUG] switch_ivr_bridge.c:1129 sofia/internal/8001#10.75.6.77 CUSTOM RESET
2021-10-28 10:44:23.113588 [DEBUG] switch_ivr_bridge.c:1136 (sofia/internal/8001#10.75.6.77) State Change CS_RESET -> CS_SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:647 (sofia/internal/8001#10.75.6.77) State RESET going to sleep
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/8001#10.75.6.77) Running State Change CS_SOFT_EXECUTE (Cur 2 Tot 4)
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:657 (sofia/internal/8001#10.75.6.77) State SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] mod_sofia.c:662 SOFIA SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] switch_ivr_bridge.c:1154 sofia/internal/8001#10.75.6.77 CUSTOM SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] switch_ivr_bridge.c:1186 (sofia/internal/5001#10.30.0.15:5068) State Change CS_RESET -> CS_SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_SOFT_EXECUTE (Cur 2 Tot 4)
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:657 (sofia/internal/5001#10.30.0.15:5068) State SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] mod_sofia.c:662 SOFIA SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] switch_ivr_bridge.c:1154 sofia/internal/5001#10.30.0.15:5068 CUSTOM SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:401 sofia/internal/5001#10.30.0.15:5068 Standard SOFT_EXECUTE
2021-10-28 10:44:23.113588 [DEBUG] switch_core_state_machine.c:657 (sofia/internal/5001#10.30.0.15:5068) State SOFT_EXECUTE going to sleep
2021-10-28 10:44:23.133586 [DEBUG] switch_ivr_bridge.c:1683 (sofia/internal/5001#10.30.0.15:5068) State Change CS_SOFT_EXECUTE -> CS_CONSUME_MEDIA
2021-10-28 10:44:23.133586 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_CONSUME_MEDIA (Cur 2 Tot 4)
2021-10-28 10:44:23.133586 [DEBUG] switch_core_state_machine.c:663 (sofia/internal/5001#10.30.0.15:5068) State CONSUME_MEDIA
2021-10-28 10:44:23.133586 [DEBUG] switch_ivr_bridge.c:1058 sofia/internal/5001#10.30.0.15:5068 CUSTOM HOLD
2021-10-28 10:44:23.133586 [DEBUG] switch_core_state_machine.c:663 (sofia/internal/5001#10.30.0.15:5068) State CONSUME_MEDIA going to sleep
2021-10-28 10:44:23.133586 [DEBUG] switch_ivr_bridge.c:1793 (sofia/internal/5001#10.30.0.15:5068) State Change CS_CONSUME_MEDIA -> CS_EXCHANGE_MEDIA
2021-10-28 10:44:23.133586 [DEBUG] switch_core_state_machine.c:585 (sofia/internal/5001#10.30.0.15:5068) Running State Change CS_EXCHANGE_MEDIA (Cur 2 Tot 4)
2021-10-28 10:44:23.133586 [DEBUG] switch_core_state_machine.c:654 (sofia/internal/5001#10.30.0.15:5068) State EXCHANGE_MEDIA
2021-10-28 10:44:23.133586 [DEBUG] mod_sofia.c:656 SOFIA EXCHANGE_MEDIA
2021-10-28 10:44:23.133586 [DEBUG] mod_callcenter.c:2009 Member "xxx" 8001 is bridged to agent 5001
2021-10-28 10:44:23.133586 [DEBUG] switch_ivr_async.c:1640 No silence detection configured; assuming start of speech
2021-10-28 10:44:23.153585 [DEBUG] mod_callcenter.c:1301 Updated tier: Agent 5001 in Queue 90 set state = Active Inbound
2021-10-28 10:44:23.153585 [DEBUG] mod_callcenter.c:1180 Updated Agent 5001 set state = In a queue call
2021-10-28 10:44:23.153585 [DEBUG] switch_core_io.c:448 Setting BUG Codec PCMU:0
2021-10-28 10:44:23.293594 [DEBUG] switch_rtp.c:7722 Correct audio ip/port confirmed.
freeswitch#pbx>
freeswitch#pbx>
freeswitch#pbx>
freeswitch#pbx>
freeswitch#pbx>
2021-10-28 10:45:20.773590 [DEBUG] sofia.c:7325 Channel sofia/internal/5001#10.30.0.15:5068 entering state [calling][0]
2021-10-28 10:45:20.813595 [DEBUG] sofia.c:7325 Channel sofia/internal/5001#10.30.0.15:5068 entering state [completing][200]
2021-10-28 10:45:20.813595 [DEBUG] sofia.c:7335 Remote SDP:
v=0
o=5001 8004 8001 IN IP4 10.30.0.15
s=SIP Call
c=IN IP4 10.30.0.15
t=0 0
m=audio 5028 RTP/AVP 0 8 9 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:9 G722/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:20
m=video 0 RTP/AVP 103
2021-10-28 10:45:20.833591 [DEBUG] sofia.c:7325 Channel sofia/internal/5001#10.30.0.15:5068 entering state [ready][200]
2021-10-28 10:45:26.813594 [DEBUG] switch_rtp.c:7967 RTP RECV DTMF *:1280
2021-10-28 10:45:26.813594 [INFO] switch_channel.c:522 RECV DTMF *:1280
2021-10-28 10:45:27.233594 [DEBUG] switch_rtp.c:7967 RTP RECV DTMF 7:1280
2021-10-28 10:45:27.233594 [INFO] switch_channel.c:522 RECV DTMF 7:1280
2021-10-28 10:45:27.233594 [DEBUG] switch_ivr_async.c:4311 sofia/internal/8001#10.75.6.77 Processing meta digit '7' [execute_extension::att_xfer XML features]
2021-10-28 10:45:27.533627 [DEBUG] switch_ivr.c:632 sofia/internal/8001#10.75.6.77 Command Execute [depth=0] playback(local_stream://moh)
EXECUTE [depth=0] sofia/internal/8001#10.75.6.77 playback(local_stream://moh)
2021-10-28 10:45:27.533627 [DEBUG] switch_ivr.c:632 sofia/internal/5001#10.30.0.15:5068 Command Execute [depth=0] execute_extension(att_xfer XML features)
EXECUTE [depth=0] sofia/internal/5001#10.30.0.15:5068 execute_extension(att_xfer XML features)
But I can capture the dtmf packet from my telephone. It's so weird to me. Can somebody tell me why?

I know how to fix it now.
It's cause by freeswitch set 2833 dtmf send payload to 105 recv payload to 101, but the telephone still send 105 dtmf payload type to freeswitch.
I modified 'rfc2833-pt' in sip_profiles/internal.xml to '105' and it worked for me.

Because DTMF use the RFC-2833, so you should check your sip_profiles/*.xml to find whether you set the rfc2833-pt value also check FreeSWITCH configuration

Related

Nginx With Golang CLI/API tool

I've poured over countless articles online to try to make this work and I'm not able to. I have written a CLI tool in GO and an API server that accepts an HTTPs PUT method call from the CLI and returns values. All data in the request and response are in JSON format. Everything works when the client communicates directly with the API server and I even have it working through Squid in pass-through mode. I am reworking the API server and client to use secure websockets and I found that the way I currently have Squid configured isn't working. So I thought I'd try Nginx instead, since I found an article on proxying ws socket connections using it on IBM's website. Alas, I cannot get simple https working at the moment. I have created a certificate and key pair and they are signed by a parent certificate. In my GO client code I load a new Certificate Pool with the CA certs from the machine and append my self signed CA cert to the CA pool. This is working currently with Squid pass through. When I try to run my client through Nginx though, it doesn't. I modified my GO code to output the request information it is sending to Nginx and when I watch the NGinx logs I see the client connect and the errors shown below. I never see a connection from Nginx to the API server. Also, I'm not doing SSL termination on the Nginx server and I'd have to do a fair bit of code rewriting to make the API server non-SSL to accommodate that.
Here's the Request info my client sends to Nginx:
mycommand single_value
Error: Cannot communicate with API server: Put "https://my_api_server.local:443/uri": Bad Request
REQ HEADERS:
map[Content-Type:[application/json]]
REQ METHOD:
PUT
REQ BODY:
{{"key1":"val1","key2":val2,"key3":val3,"key4":val4}}
The entry I see in the Nginx Access Log is:
28/Dec/2021:15:19:37 -0800 172.16.150.1 "CONNECT my_api_server.local:443 HTTP/1.1" - https://my_api_server.local- -" TLSv1.3 TLS_AES_256_GCM_SHA384 400 173 "-" "-" "-"
The entry for the request in the error log in debug mode shows:
2021/12/28 15:19:37 [debug] 3006#0: epoll: fd:8 ev:0001 d:00007FD46336E010
2021/12/28 15:19:37 [debug] 3006#0: accept on 172.16.150.132:443, ready: 0
2021/12/28 15:19:37 [debug] 3006#0: posix_memalign: 0000557BECD3F1B0:512 #16
2021/12/28 15:19:37 [debug] 3006#0: *2 accept: 172.16.150.1:54656 fd:9
2021/12/28 15:19:37 [debug] 3006#0: *2 event timer add: 9: 60000:22007365
2021/12/28 15:19:37 [debug] 3006#0: *2 reusable connection: 1
2021/12/28 15:19:37 [debug] 3006#0: *2 epoll add event: fd:9 op:1 ev:80002001
2021/12/28 15:19:37 [debug] 3006#0: timer delta: 536667
2021/12/28 15:19:37 [debug] 3006#0: worker cycle
2021/12/28 15:19:37 [debug] 3006#0: epoll timer: 60000
2021/12/28 15:19:37 [debug] 3006#0: epoll: fd:9 ev:0001 d:00007FD46336E1E1
2021/12/28 15:19:37 [debug] 3006#0: *2 http check ssl handshake
2021/12/28 15:19:37 [debug] 3006#0: *2 http recv(): 1
2021/12/28 15:19:37 [debug] 3006#0: *2 https ssl handshake: 0x16
2021/12/28 15:19:37 [debug] 3006#0: *2 tcp_nodelay
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL server name: "https://my_api_server.local:443"
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_do_handshake: -1
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_get_error: 2
2021/12/28 15:19:37 [debug] 3006#0: *2 reusable connection: 0
2021/12/28 15:19:37 [debug] 3006#0: timer delta: 2
2021/12/28 15:19:37 [debug] 3006#0: worker cycle
2021/12/28 15:19:37 [debug] 3006#0: epoll timer: 59998
2021/12/28 15:19:37 [debug] 3006#0: epoll: fd:9 ev:0001 d:00007FD46336E1E1
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL handshake handler: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_do_handshake: 1
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL: TLSv1.3, cipher: "TLS_AES_256_GCM_SHA384 TLSv1.3 Kx=any Au=any Enc=AESGCM(256) Mac=AEAD"
2021/12/28 15:19:37 [debug] 3006#0: *2 reusable connection: 1
2021/12/28 15:19:37 [debug] 3006#0: *2 http wait request handler
2021/12/28 15:19:37 [debug] 3006#0: *2 malloc: 0000557BECD3F3C0:1024
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_read: 127
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_read: -1
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_get_error: 2
2021/12/28 15:19:37 [debug] 3006#0: *2 reusable connection: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 posix_memalign: 0000557BECCE8910:4096 #16
2021/12/28 15:19:37 [debug] 3006#0: *2 http process request line
2021/12/28 15:19:37 [info] 3006#0: *2 client sent invalid request while reading client request line, client: 172.16.150.1, server: my_api_server.local, request: "CONNECT my_api_server.local:443 HTTP/1.1"
2021/12/28 15:19:37 [debug] 3006#0: *2 http finalize request: 400, "?" a:1, c:1
2021/12/28 15:19:37 [debug] 3006#0: *2 event timer del: 9: 22007365
2021/12/28 15:19:37 [debug] 3006#0: *2 http special response: 400, "?"
2021/12/28 15:19:37 [debug] 3006#0: *2 http set discard body
2021/12/28 15:19:37 [debug] 3006#0: *2 xslt filter header
2021/12/28 15:19:37 [debug] 3006#0: *2 HTTP/1.1 400 Bad Request
Server: nginx/1.14.1
Date: Tue, 28 Dec 2021 23:19:37 GMT
Content-Type: text/html
Content-Length: 173
Connection: close
2021/12/28 15:19:37 [debug] 3006#0: *2 write new buf t:1 f:0 0000557BECCE9720, pos 0000557BECCE9720, size: 152 file: 0, size: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 http write filter: l:0 f:0 s:152
2021/12/28 15:19:37 [debug] 3006#0: *2 http output filter "?"
2021/12/28 15:19:37 [debug] 3006#0: *2 http copy filter: "?"
2021/12/28 15:19:37 [debug] 3006#0: *2 image filter
2021/12/28 15:19:37 [debug] 3006#0: *2 xslt filter body
2021/12/28 15:19:37 [debug] 3006#0: *2 http postpone filter "?" 0000557BECCE98F0
2021/12/28 15:19:37 [debug] 3006#0: *2 write old buf t:1 f:0 0000557BECCE9720, pos 0000557BECCE9720, size: 152 file: 0, size: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 posix_memalign: 0000557BECCD4C70:4096 #16
2021/12/28 15:19:37 [debug] 3006#0: *2 write new buf t:0 f:0 0000000000000000, pos 0000557BEBAAB920, size: 120 file: 0, size: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 write new buf t:0 f:0 0000000000000000, pos 0000557BEBAABF00, size: 53 file: 0, size: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 http write filter: l:1 f:0 s:325
2021/12/28 15:19:37 [debug] 3006#0: *2 http write filter limit 0
2021/12/28 15:19:37 [debug] 3006#0: *2 posix_memalign: 0000557BECD45380:512 #16
2021/12/28 15:19:37 [debug] 3006#0: *2 malloc: 0000557BECE01170:16384
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL buf copy: 152
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL buf copy: 120
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL buf copy: 53
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL to write: 325
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_write: 325
2021/12/28 15:19:37 [debug] 3006#0: *2 http write filter 0000000000000000
2021/12/28 15:19:37 [debug] 3006#0: *2 http copy filter: 0 "?"
2021/12/28 15:19:37 [debug] 3006#0: *2 http finalize request: 0, "?" a:1, c:1
2021/12/28 15:19:37 [debug] 3006#0: *2 event timer add: 9: 5000:21952375
2021/12/28 15:19:37 [debug] 3006#0: timer delta: 8
2021/12/28 15:19:37 [debug] 3006#0: worker cycle
2021/12/28 15:19:37 [debug] 3006#0: epoll timer: 5000
2021/12/28 15:19:37 [debug] 3006#0: epoll: fd:9 ev:2011 d:00007FD46336E1E1
2021/12/28 15:19:37 [debug] 3006#0: epoll_wait() error on fd:9 ev:2011
2021/12/28 15:19:37 [debug] 3006#0: *2 http lingering close handler
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_read: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_get_error: 6
2021/12/28 15:19:37 [debug] 3006#0: *2 peer shutdown SSL cleanly
2021/12/28 15:19:37 [debug] 3006#0: *2 lingering read: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 http request count:1 blk:0
2021/12/28 15:19:37 [debug] 3006#0: *2 http close request
2021/12/28 15:19:37 [debug] 3006#0: *2 http log handler
2021/12/28 15:19:37 [debug] 3006#0: *2 free: 0000557BECCE8910, unused: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 free: 0000557BECCD4C70, unused: 3815
2021/12/28 15:19:37 [debug] 3006#0: *2 close http connection: 9
2021/12/28 15:19:37 [debug] 3006#0: *2 SSL_shutdown: 1
2021/12/28 15:19:37 [debug] 3006#0: *2 event timer del: 9: 21952375
2021/12/28 15:19:37 [debug] 3006#0: *2 reusable connection: 0
2021/12/28 15:19:37 [debug] 3006#0: *2 free: 0000557BECE01170
2021/12/28 15:19:37 [debug] 3006#0: *2 free: 0000557BECD3F3C0
2021/12/28 15:19:37 [debug] 3006#0: *2 free: 0000557BECD3F1B0, unused: 48
2021/12/28 15:19:37 [debug] 3006#0: *2 free: 0000557BECD45380, unused: 400
2021/12/28 15:19:37 [debug] 3006#0: timer delta: 1
2021/12/28 15:19:37 [debug] 3006#0: worker cycle
2021/12/28 15:19:37 [debug] 3006#0: epoll timer: -1
and here's my nginx.conf file:
user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log debug;
pid /run/nginx.pid;
# Load dynamic modules. See /usr/share/doc/nginx/README.dynamic.
include /usr/share/nginx/modules/*.conf;
events {
worker_connections 1024;
}
http {
log_format main '$time_local $remote_addr "$request" '
'$request_method $scheme://$host$request_uri $server_protocol" '
'$ssl_protocol $ssl_cipher $status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
# Load modular configuration files from the /etc/nginx/conf.d directory.
# See http://nginx.org/en/docs/ngx_core_module.html#include
# for more information.
include /etc/nginx/conf.d/*.conf;
server {
listen 172.16.150.132:443 ssl http2 default_server;
server_name my_api_server.local;
ssl_certificate /etc/nginx/ssl_certs/my_api_server.local.crt;
ssl_certificate_key /etc/nginx/ssl_certs/my_api_server.local.key;
# ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
ssl_protocols TLSV1.2 TLSV1.3;
ssl_ciphers AESGCM:ALL:!DH:!EXPORT:!RC4:+HIGH:!MEDIUM:!LOW:!aNULL:!eNULL:!MD5;
ssl_prefer_server_ciphers on;
ssl on;
# Load configuration files for the default server block.
# include /etc/nginx/default.d/*.conf;
location / {
resolver 172.16.150.132;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host: $host;
proxy_pass https://my_api_server.local:9751;
# Disable caching
expires -1;
}
}
}
Going off of the concept of SSL_Bump in Squid I tried using the same SSL cert and key as the API server in my Nginx config. Is this right? Please tell me what I'm missing.
I discovered my issue and got everything working. I used PostMan to emulate my client request. I noticed in the Nginx log when I ran the request from PostMan, that Nginx showed the correct Method and URI whereas my client did not.
Before:
172.16.150.1 - - [28/Dec/2021:12:28:38 -0800] "CONNECT my_api_server.local:9751 HTTP/1.1" TLSv1.3 TLS_AES_256_GCM_SHA384 400 173 "-" "-" "-"
After:
29/Dec/2021:13:17:37 -0800 172.16.150.132 "PUT /uri HTTP/1.1" PUT https://my_proxy_server.local/uri HTTP/1.1" TLSv1.3 TLS_AES_256_GCM_SHA384 200 9822 "-" "Go-http-client/1.1" "-"
I disabled all the proxy configs for my client and simply told it to make the request to Nginx and everything works now. Something about the way I'm defining my proxy settings in my client is wrong, but since there will always be a proxy server in front of my API server, I can leave that out and just point the client at the Nginx server.
I was also able to confirm that the setup works whether I terminate SSL at the Nginx server or pass it all the way through to my API server.
I need to read through the use of the GO http.ProxyURL functionality and understand it better.

spring boot maven docker image issue

I have used the spring boot plugin to build images before, however I am seeing strange behaviour. Essentially the process has stalled. It's been going for over an hour and I am not sure why.
I ran: mvn spring-boot:build-image -Dspring-boot.build-image.imageName=bootiful/demo
here is the output to the point where it has progressed no further:
[INFO] --- spring-boot-maven-plugin:2.4.1:build-image (default-cli) # liquidity-system ---
[INFO] Building image 'docker.io/bootiful/demo:latest'
[INFO]
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 100%
[INFO] > Pulled builder image 'paketobuildpacks/builder#sha256:4b91576bbf90ee67ccb6a178a345bc5266e4f9eac62d8df580d66ea70ff54e47'
[INFO] > Pulling run image 'docker.io/paketobuildpacks/run:base-cnb' 100%
[INFO] > Pulled run image 'paketobuildpacks/run#sha256:7c0092c534e1646fc80d1578fb9cf0ab925af2ad95a7469edf681539cba44c56'
[INFO] > Executing lifecycle version v0.10.1
[INFO] > Using build cache volume 'pack-cache-cc2912ef7439.build'
[INFO]
[INFO] > Running creator
My internet connection is up. Environment is:
Macos 11.1
java 14
maven 3.6.3
docker desktop 3.0.3
spring boot 2.4.1
Edit: Added verbose output
[INFO] --- spring-boot-maven-plugin:2.4.1:build-image (default-cli) # liquidity-system ---
[DEBUG] Configuring mojo org.springframework.boot:spring-boot-maven-plugin:2.4.1:build-image from plugin realm ClassRealm[plugin>org.springframework.boot:spring-boot-maven-plugin:2.4.1, parent: jdk.internal.loader.ClassLoaders$AppClassLoader#55054057]
[DEBUG] Configuring mojo 'org.springframework.boot:spring-boot-maven-plugin:2.4.1:build-image' with basic configurator -->
[DEBUG] (f) classifier = exec
[DEBUG] (f) excludeDevtools = true
[DEBUG] (f) excludes = []
[DEBUG] (f) finalName = liquidity-system-2.1-SNAPSHOT
[DEBUG] (f) imageName = bootiful/demo
[DEBUG] (f) includeSystemScope = false
[DEBUG] (f) includes = []
[DEBUG] (f) mainClass = com.liquidity.LiquidityApplication
[DEBUG] (f) project = MavenProject: com.liquidity:liquidity-system:2.1-SNAPSHOT # /Users/liquidity-system/pom.xml
[DEBUG] (f) session = org.apache.maven.execution.MavenSession#1d0a61c8
[DEBUG] (f) skip = false
[DEBUG] (f) sourceDirectory = /Users/liquidity-system/target
[DEBUG] -- end configuration --
[INFO] Building image 'docker.io/bootiful/demo:latest'
[INFO]
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Opening connection {}->docker://localhost:2376
[DEBUG] Connecting to localhost/127.0.0.1:2376
[DEBUG] Connection established
[DEBUG] Executing request POST /v1.24/images/create?fromImage=docker.io%2Fpaketobuildpacks%2Fbuilder%3Abase HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-0 >> POST /v1.24/images/create?fromImage=docker.io%2Fpaketobuildpacks%2Fbuilder%3Abase HTTP/1.1
[DEBUG] http-outgoing-0 >> Content-Length: 0
[DEBUG] http-outgoing-0 >> Host: localhost
[DEBUG] http-outgoing-0 >> Connection: Keep-Alive
[DEBUG] http-outgoing-0 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-0 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-0 << HTTP/1.1 200 OK
[DEBUG] http-outgoing-0 << Api-Version: 1.41
[DEBUG] http-outgoing-0 << Content-Type: application/json
[DEBUG] http-outgoing-0 << Date: Tue, 12 Jan 2021 07:14:52 GMT
[DEBUG] http-outgoing-0 << Docker-Experimental: false
[DEBUG] http-outgoing-0 << Ostype: linux
[DEBUG] http-outgoing-0 << Server: Docker/20.10.2 (linux)
[DEBUG] http-outgoing-0 << Transfer-Encoding: chunked
[DEBUG] Connection can be kept alive indefinitely
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 0%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 1%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 1%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 2%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 2%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 3%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 4%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 5%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 5%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 6%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 10%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 10%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 11%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 11%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 12%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 12%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 13%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 14%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 15%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 16%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 16%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 17%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 17%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 19%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 20%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 21%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 22%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 24%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 26%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 28%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 29%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 30%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 34%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 39%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 44%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 51%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 59%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 65%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 70%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 76%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 81%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 83%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 87%
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 89%
[DEBUG] Releasing connection
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Executing request GET /v1.24/images/docker.io/paketobuildpacks/builder#sha256:2fbe23a13024af36db7c05b00b58361f4e4aed8eb679519daafd035f653098fb/json HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-0 >> GET /v1.24/images/docker.io/paketobuildpacks/builder#sha256:2fbe23a13024af36db7c05b00b58361f4e4aed8eb679519daafd035f653098fb/json HTTP/1.1
[DEBUG] http-outgoing-0 >> Host: localhost
[DEBUG] http-outgoing-0 >> Connection: Keep-Alive
[DEBUG] http-outgoing-0 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-0 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-0 << HTTP/1.1 200 OK
[DEBUG] http-outgoing-0 << Api-Version: 1.41
[DEBUG] http-outgoing-0 << Content-Type: application/json
[DEBUG] http-outgoing-0 << Date: Tue, 12 Jan 2021 07:16:23 GMT
[DEBUG] http-outgoing-0 << Docker-Experimental: false
[DEBUG] http-outgoing-0 << Ostype: linux
[DEBUG] http-outgoing-0 << Server: Docker/20.10.2 (linux)
[DEBUG] http-outgoing-0 << Transfer-Encoding: chunked
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] Releasing connection
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Connection can be kept alive indefinitely
[INFO] > Pulling builder image 'docker.io/paketobuildpacks/builder:base' 100%
[INFO] > Pulled builder image 'paketobuildpacks/builder#sha256:2fbe23a13024af36db7c05b00b58361f4e4aed8eb679519daafd035f653098fb'
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Executing request POST /v1.24/images/create?fromImage=docker.io%2Fpaketobuildpacks%2Frun%3Abase-cnb HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-0 >> POST /v1.24/images/create?fromImage=docker.io%2Fpaketobuildpacks%2Frun%3Abase-cnb HTTP/1.1
[DEBUG] http-outgoing-0 >> Content-Length: 0
[DEBUG] http-outgoing-0 >> Host: localhost
[DEBUG] http-outgoing-0 >> Connection: Keep-Alive
[DEBUG] http-outgoing-0 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-0 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-0 << HTTP/1.1 200 OK
[DEBUG] http-outgoing-0 << Api-Version: 1.41
[DEBUG] http-outgoing-0 << Content-Type: application/json
[DEBUG] http-outgoing-0 << Date: Tue, 12 Jan 2021 07:16:29 GMT
[DEBUG] http-outgoing-0 << Docker-Experimental: false
[DEBUG] http-outgoing-0 << Ostype: linux
[DEBUG] http-outgoing-0 << Server: Docker/20.10.2 (linux)
[DEBUG] http-outgoing-0 << Transfer-Encoding: chunked
[DEBUG] Connection can be kept alive indefinitely
[INFO] > Pulling run image 'docker.io/paketobuildpacks/run:base-cnb' 7%
[INFO] > Pulling run image 'docker.io/paketobuildpacks/run:base-cnb' 23%
[INFO] > Pulling run image 'docker.io/paketobuildpacks/run:base-cnb' 25%
[INFO] > Pulling run image 'docker.io/paketobuildpacks/run:base-cnb' 31%
[DEBUG] Releasing connection
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Executing request GET /v1.24/images/docker.io/paketobuildpacks/run#sha256:0cb3de382afbd5da1e01515f55ab017011ac4d76c77fabb44006f0d0546b2722/json HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-0 >> GET /v1.24/images/docker.io/paketobuildpacks/run#sha256:0cb3de382afbd5da1e01515f55ab017011ac4d76c77fabb44006f0d0546b2722/json HTTP/1.1
[DEBUG] http-outgoing-0 >> Host: localhost
[DEBUG] http-outgoing-0 >> Connection: Keep-Alive
[DEBUG] http-outgoing-0 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-0 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-0 << HTTP/1.1 200 OK
[DEBUG] http-outgoing-0 << Api-Version: 1.41
[DEBUG] http-outgoing-0 << Content-Type: application/json
[DEBUG] http-outgoing-0 << Date: Tue, 12 Jan 2021 07:16:38 GMT
[DEBUG] http-outgoing-0 << Docker-Experimental: false
[DEBUG] http-outgoing-0 << Ostype: linux
[DEBUG] http-outgoing-0 << Server: Docker/20.10.2 (linux)
[DEBUG] http-outgoing-0 << Transfer-Encoding: chunked
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] Releasing connection
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Connection can be kept alive indefinitely
[INFO] > Pulling run image 'docker.io/paketobuildpacks/run:base-cnb' 100%
[INFO] > Pulled run image 'paketobuildpacks/run#sha256:0cb3de382afbd5da1e01515f55ab017011ac4d76c77fabb44006f0d0546b2722'
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Executing request POST /v1.24/images/load HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-0 >> POST /v1.24/images/load HTTP/1.1
[DEBUG] http-outgoing-0 >> Transfer-Encoding: chunked
[DEBUG] http-outgoing-0 >> Content-Type: application/x-tar
[DEBUG] http-outgoing-0 >> Host: localhost
[DEBUG] http-outgoing-0 >> Connection: Keep-Alive
[DEBUG] http-outgoing-0 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-0 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-0 << HTTP/1.1 200 OK
[DEBUG] http-outgoing-0 << Api-Version: 1.41
[DEBUG] http-outgoing-0 << Content-Type: application/json
[DEBUG] http-outgoing-0 << Date: Tue, 12 Jan 2021 07:16:38 GMT
[DEBUG] http-outgoing-0 << Docker-Experimental: false
[DEBUG] http-outgoing-0 << Ostype: linux
[DEBUG] http-outgoing-0 << Server: Docker/20.10.2 (linux)
[DEBUG] http-outgoing-0 << Transfer-Encoding: chunked
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] Releasing connection
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Connection can be kept alive indefinitely
[INFO] > Executing lifecycle version v0.10.1
[INFO] > Using build cache volume 'pack-cache-cc2912ef7439.build'
[INFO]
[INFO] > Running creator
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Executing request POST /v1.24/containers/create HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-0 >> POST /v1.24/containers/create HTTP/1.1
[DEBUG] http-outgoing-0 >> Content-Length: 693
[DEBUG] http-outgoing-0 >> Content-Type: application/json
[DEBUG] http-outgoing-0 >> Host: localhost
[DEBUG] http-outgoing-0 >> Connection: Keep-Alive
[DEBUG] http-outgoing-0 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-0 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-0 << HTTP/1.1 201 Created
[DEBUG] http-outgoing-0 << Api-Version: 1.41
[DEBUG] http-outgoing-0 << Content-Type: application/json
[DEBUG] http-outgoing-0 << Date: Tue, 12 Jan 2021 07:16:39 GMT
[DEBUG] http-outgoing-0 << Docker-Experimental: false
[DEBUG] http-outgoing-0 << Ostype: linux
[DEBUG] http-outgoing-0 << Server: Docker/20.10.2 (linux)
[DEBUG] http-outgoing-0 << Transfer-Encoding: chunked
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] Releasing connection
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-0: set socket timeout to 0
[DEBUG] Executing request PUT /v1.24/containers/7b5260745e434e201a1a29e29dd0b396e8862a858e18d669d92b08f0fa0e4e6b/archive?path=%2Fworkspace HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-0 >> PUT /v1.24/containers/7b5260745e434e201a1a29e29dd0b396e8862a858e18d669d92b08f0fa0e4e6b/archive?path=%2Fworkspace HTTP/1.1
[DEBUG] http-outgoing-0 >> Transfer-Encoding: chunked
[DEBUG] http-outgoing-0 >> Content-Type: application/x-tar
[DEBUG] http-outgoing-0 >> Host: localhost
[DEBUG] http-outgoing-0 >> Connection: Keep-Alive
[DEBUG] http-outgoing-0 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-0 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-0: Close connection
[DEBUG] http-outgoing-0: Shutdown connection
[DEBUG] Connection discarded
[DEBUG] Releasing connection [Not bound]
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-1: set socket timeout to 0
[DEBUG] Opening connection {}->docker://localhost:2376
[DEBUG] Connecting to localhost/127.0.0.1:2376
[DEBUG] Connection established
[DEBUG] Executing request DELETE /v1.24/volumes/pack-layers-dydykjjknl?force=1 HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-1 >> DELETE /v1.24/volumes/pack-layers-dydykjjknl?force=1 HTTP/1.1
[DEBUG] http-outgoing-1 >> Host: localhost
[DEBUG] http-outgoing-1 >> Connection: Keep-Alive
[DEBUG] http-outgoing-1 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-1 >> Accept-Encoding: gzip,deflate
[DEBUG] http-outgoing-1 << HTTP/1.1 409 Conflict
[DEBUG] http-outgoing-1 << Api-Version: 1.41
[DEBUG] http-outgoing-1 << Content-Type: application/json
[DEBUG] http-outgoing-1 << Date: Tue, 12 Jan 2021 07:16:39 GMT
[DEBUG] http-outgoing-1 << Docker-Experimental: false
[DEBUG] http-outgoing-1 << Ostype: linux
[DEBUG] http-outgoing-1 << Server: Docker/20.10.2 (linux)
[DEBUG] http-outgoing-1 << Transfer-Encoding: chunked
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] Releasing connection
[DEBUG] http-outgoing-1: set socket timeout to 0
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] CookieSpec selected: default
[DEBUG] Auth cache not set in the context
[DEBUG] Get connection for route {}->docker://localhost:2376
[DEBUG] http-outgoing-1: set socket timeout to 0
[DEBUG] Executing request DELETE /v1.24/images/pack.local/builder/bngnnuyzva:latest?force=1 HTTP/1.1
[DEBUG] Target auth state: UNCHALLENGED
[DEBUG] Proxy auth state: UNCHALLENGED
[DEBUG] http-outgoing-1 >> DELETE /v1.24/images/pack.local/builder/bngnnuyzva:latest?force=1 HTTP/1.1
[DEBUG] http-outgoing-1 >> Host: localhost
[DEBUG] http-outgoing-1 >> Connection: Keep-Alive
[DEBUG] http-outgoing-1 >> User-Agent: Apache-HttpClient/4.5.13 (Java/15.0.1)
[DEBUG] http-outgoing-1 >> Accept-Encoding: gzip,deflate
The issue turned out to be that there <classifier> was set in another area where the spring boot maven plugin was defined. Removing the classifier resolved the problem

my asterisk send bye for incoming call. sip debug info attached

After the provider was changed cisco model, the asterisk dont carry their incomming calls.
My asterisk ("my_ip") answered BYE for their incoming.
can someone aske me why? (atached data)
<--- SIP read from UDP:<<incoming_ip>>:5060 --->
INVITE sip:<<our_in_phone>>#B2B-EKB-Sung:5060;user=phone SIP/2.0
Via: SIP/2.0/UDP <<incoming_ip>>:5060;branch=z9hG4bKnndg8g009o0b66poa600.1
Allow: INVITE,ACK,CANCEL,BYE,INFO,PRACK,UPDATE,OPTIONS,REGISTER,REFER,SUBSCRIBE,MESSAGE,PUBLISH
Call-ID: 461f392oriy4qgcdk#172.16.5.3
Contact: "<<incomin_mobile>>" <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;transport=udp>
CSeq: 250 INVITE
Expires: 3600
From: "<<incomin_mobile>>" <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;cpc=ordinary>;tag=hgdjlmovjl
To: "<<our_in_phone>>" <sip:<<our_in_phone>>#<<our_ip>>:5060;user=phone>
Max-Forwards: 69
Privacy: none
Content-Length: 243
Content-Type: application/sdp
v=0
o=- 1212881 2288486 IN IP4 <<incoming_ip>>
s=-
c=IN IP4 <<incoming_ip>>
b=AS:64
t=0 0
m=audio 19062 RTP/AVP 8 0 101
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=ptime:20
a=sendrecv
<------------->
--- (13 headers 13 lines) ---
Sending to <<incoming_ip>>:5060 (no NAT)
Using INVITE request as basis request - 461f392oriy4qgcdk#172.16.5.3
Found peer 'utk' for '<<incomin_mobile>>' from <<incoming_ip>>:5060
Found RTP audio format 8
Found RTP audio format 0
Found RTP audio format 101
Found audio description format PCMA for ID 8
Found audio description format PCMU for ID 0
Found audio description format telephone-event for ID 101
Capabilities: us - (alaw), peer - audio=(ulaw|alaw)/video=(nothing)/text=(nothing), combined - (alaw)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1 (telephone-event|), combined - 0x1 (telephone-event|)
Peer audio RTP is at port <<incoming_ip>>:19062
Looking for <<our_in_phone>> in IN (domain B2B-EKB-Sung)
list_route: hop: <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;transport=udp>
<--- Transmitting (no NAT) to <<incoming_ip>>:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP <<incoming_ip>>:5060;branch=z9hG4bKnndg8g009o0b66poa600.1;received=<<incoming_ip>>
From: "<<incomin_mobile>>" <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;cpc=ordinary>;tag=hgdjlmovjl
To: "<<our_in_phone>>" <sip:<<our_in_phone>>#<<our_ip>>:5060;user=phone>
Call-ID: 461f392oriy4qgcdk#172.16.5.3
CSeq: 250 INVITE
Server: sunshamil#yandex.ru
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Contact: <sip:<<our_in_phone>>#<<our_ip>>:5060>
Content-Length: 0
<------------>
Audio is at 10050
Adding codec 100004 (alaw) to SDP
Adding non-codec 0x1 (telephone-event) to SDP
<--- Reliably Transmitting (no NAT) to <<incoming_ip>>:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP <<incoming_ip>>:5060;branch=z9hG4bKnndg8g009o0b66poa600.1;received=<<incoming_ip>>
From: "<<incomin_mobile>>" <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;cpc=ordinary>;tag=hgdjlmovjl
To: "<<our_in_phone>>" <sip:<<our_in_phone>>#<<our_ip>>:5060;user=phone>;tag=as3662657b
Call-ID: 461f392oriy4qgcdk#172.16.5.3
CSeq: 250 INVITE
Server: sunshamil#yandex.ru
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Contact: <sip:<<our_in_phone>>#<<our_ip>>:5060>
Content-Type: application/sdp
Content-Length: 235
v=0
o=root 2100145274 2100145274 IN IP4 <<our_ip>>
s=Asterisk PBX 11.2.1
c=IN IP4 <<our_ip>>
t=0 0
m=audio 10050 RTP/AVP 8 101
a=rtpmap:8 PCMA/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv
<------------>
Did not get well whit packet on the end have 'Bye' content. Or maybe its a merged packet
<--- SIP read from UDP:<<incoming_ip>>:5060 --->
ACK sip:<<our_in_phone>>#<<our_ip>>:5060 SIP/2.0
Via: SIP/2.0/UDP <<incoming_ip>>:5060;branch=z9hG4bKsf83b130a8q0c35do500.1
Call-ID: 461f392oriy4qgcdk#172.16.5.3
CSeq: 250 ACK
From: "<<incomin_mobile>>" <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;cpc=ordinary>;tag=hgdjlmovjl
To: "<<our_in_phone>>" <sip:<<our_in_phone>>#<<our_ip>>:5060;user=phone>;tag=as3662657b
Max-Forwards: 69
Content-Length: 0
<------------->
--- (8 headers 0 lines) ---
Scheduling destruction of SIP dialog '461f392oriy4qgcdk#172.16.5.3' in 32000 ms (Method: ACK)
set_destination: Parsing <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;transport=udp> for address/port to send to
set_destination: set destination to <<incoming_ip>>:5060
Reliably Transmitting (no NAT) to <<incoming_ip>>:5060:
BYE sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;transport=udp SIP/2.0
Via: SIP/2.0/UDP <<our_ip>>:5060;branch=z9hG4bK1853b292
Max-Forwards: 70
From: "<<our_in_phone>>" <sip:<<our_in_phone>>#<<our_ip>>:5060;user=phone>;tag=as3662657b
To: "<<incomin_mobile>>" <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;cpc=ordinary>;tag=hgdjlmovjl
Call-ID: 461f392oriy4qgcdk#172.16.5.3
CSeq: 102 BYE
User-Agent: sunshamil#yandex.ru
X-Asterisk-HangupCause: Normal Clearing
X-Asterisk-HangupCauseCode: 16
Content-Length: 0
---
If me understood this correct then our asterisk answer 'BYE' for incoming:
<--- SIP read from UDP:<<incoming_ip>>:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP <<our_ip>>:5060;branch=z9hG4bK1853b292
From: "<<our_in_phone>>" <sip:<<our_in_phone>>#<<our_ip>>:5060;user=phone>;tag=as3662657b
To: "<<incomin_mobile>>" <sip:<<incomin_mobile>>#<<incoming_ip>>:5060;user=phone;cpc=ordinary>;tag=hgdjlmovjl
Call-ID: 461f392oriy4qgcdk#172.16.5.3
CSeq: 102 BYE
Content-Length: 0
solved
it was my mistake, 'bye' was come from agi script , coz new cisco was not in allowed list.

How to get the audio and video from a WebRTC stream using ffmpeg on server

I am trying to get the audio and video from a WebRTC stream and handle it (transcode or dump) with ffmpeg on ubuntu server. I have naively expected it to simply interpret the sdp offered by WebRTC, but was mistaken. I suspect ffmpeg is not capable of signaling back the answer sdp and it is must be done manually. Here is an offer sdp:
v=0
o=Mozilla-SIPUA-33.1 3662 0 IN IP4 0.0.0.0
s=SIP Call
t=0 0
a=ice-ufrag:5e0a74d1
a=ice-pwd:7446c0eb445117d0018ca2afc5f3ca54
a=fingerprint:sha-256 76:1B:19:CE:3F:41:C5:4D:64:E6:FD:72:D2:FC:42:E1:98:D4:0F:2B:73:AE:C7:F4:2C:73:2C:E7:9E:DC:6A:EB
m=audio 23063 RTP/SAVPF 109 0 8 101
c=IN IP4 188.253.146.208
a=rtpmap:109 opus/48000/2
a=ptime:20
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendrecv
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=setup:actpass
a=candidate:0 1 UDP 2128609535 192.168.1.100 4130 typ host
a=candidate:1 1 UDP 1692467199 188.253.146.208 23063 typ srflx raddr 192.168.1.100 rport 4130
a=candidate:0 2 UDP 2128609534 192.168.1.100 4131 typ host
a=candidate:1 2 UDP 1692467198 188.253.146.208 23064 typ srflx raddr 192.168.1.100 rport 4131
a=rtcp-mux
m=video 23065 RTP/SAVPF 120 126 97
c=IN IP4 188.253.146.208
a=rtpmap:120 VP8/90000
a=rtpmap:126 H264/90000
a=fmtp:126 profile-level-id=42e01f;packetization-mode=1
a=rtpmap:97 H264/90000
a=fmtp:97 profile-level-id=42e01f
a=sendrecv
a=rtcp-fb:120 nack
a=rtcp-fb:120 nack pli
a=rtcp-fb:120 ccm fir
a=rtcp-fb:126 nack
a=rtcp-fb:126 nack pli
a=rtcp-fb:126 ccm fir
a=rtcp-fb:97 nack
a=rtcp-fb:97 nack pli
a=rtcp-fb:97 ccm fir
a=setup:actpass
a=candidate:0 1 UDP 2128609535 192.168.1.100 4132 typ host
a=candidate:1 1 UDP 1692467199 188.253.146.208 23065 typ srflx raddr 192.168.1.100 rport 4132
a=candidate:0 2 UDP 2128609534 192.168.1.100 4133 typ host
a=candidate:1 2 UDP 1692467198 188.253.146.208 23066 typ srflx raddr 192.168.1.100 rport 4133
a=rtcp-mux
Is anybody have succeeded in it? Thanks.
Not possible without "something" in between the stream source (peer) and ffmpeg; until and unless ffmpeg starts working with DTLS and you know the hash information for the peer (obviously this could be in the SDP). So in summary, ffmpeg would need DTLS and ICE support. An alternative would be to use GStreamer with plugins.

Asterisk to asterisk call: 403 Forbidden

I have 2 servers with Asterisks on them: 192.168.241.98 and 192.168.243.112.
There is a valid registration on the first:
register => wagateway:qwerty#192.168.243.112:5060
CLI output:
CLI> sip show registry
Host dnsmgr Username Refresh State Reg.Time
192.168.243.112:5060 N wagateway 105 Registered Wed, 26 Jun 2013 16:42:42
And peers on 243.112 are just fine:
CLI> sip show peers
Name/username Host Dyn Forcerport ACL Port Status Description
wacaller/wacaller 192.168.242.235 D a 5062 OK (13 ms)
wagateway/s 192.168.241.98 D a 5060 OK (1 ms)
extensions.conf on 243.112:
[watest]
exten => 123123123,1,NoOp()
exten => 123123123,n,Dial(SIP/wagateway)
exten => 123123123,n,Hangup()
sip.conf on 243.112:
[wacaller]
type=friend
secret=qwerty
host=dynamic
context=watest
qualify=yes
allow=ulaw
allow=alaw
[wagateway]
type=friend
secret=qwerty
fromuser=wagateway
host=dynamic
context=watest
qualify=yes
allow=ulaw
allow=alaw
Now I try to call 123123123 from wacaller's Grandstream phone.
243.112 CLI says:
[Jun 27 09:27:54] WARNING[20447][C-0000000b]: chan_sip.c:23213 handle_response_invite: Received response: "Forbidden" from '"WACaller" <sip:wagateway#192.168.243.112>;tag=as30b27eae'
Sip debug on 243.112:
<--- SIP read from UDP:192.168.242.235:5062 --->
INVITE sip:123123123#192.168.243.112 SIP/2.0
Via: SIP/2.0/UDP 192.168.242.235:5062;branch=z9hG4bK97733114;rport
From: "WACaller" <sip:wacaller#192.168.243.112>;tag=1014197566
To: <sip:123123123#192.168.243.112>
Call-ID: 298833112-5062-25#BJC.BGI.CEC.CDF
CSeq: 240 INVITE
Contact: "WACaller" <sip:wacaller#192.168.242.235:5062>
Max-Forwards: 70
User-Agent: Grandstream GXP1400 1.0.4.13
Privacy: none
P-Preferred-Identity: "WACaller" <sip:wacaller#192.168.243.112>
Supported: replaces, path, timer
Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
Content-Type: application/sdp
Accept: application/sdp, application/dtmf-relay
Content-Length: 412
v=0
o=wacaller 8000 8000 IN IP4 192.168.242.235
s=SIP Call
c=IN IP4 192.168.242.235
t=0 0
m=audio 5004 RTP/AVP 0 8 4 18 9 97 2 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:9 G722/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:2 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
<------------->
--- (16 headers 19 lines) ---
Sending to 192.168.242.235:5062 (no NAT)
Sending to 192.168.242.235:5062 (no NAT)
Using INVITE request as basis request - 298833112-5062-25#BJC.BGI.CEC.CDF
Found peer 'wacaller' for 'wacaller' from 192.168.242.235:5062
<--- Reliably Transmitting (no NAT) to 192.168.242.235:5062 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 192.168.242.235:5062;branch=z9hG4bK97733114;received=192.168.242.235;rport=5062
From: "WACaller" <sip:wacaller#192.168.243.112>;tag=1014197566
To: <sip:123123123#192.168.243.112>;tag=as5a3de236
Call-ID: 298833112-5062-25#BJC.BGI.CEC.CDF
CSeq: 240 INVITE
Server: Asterisk PBX SVN-trunk-r385782
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="4f84bef0"
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog '298833112-5062-25#BJC.BGI.CEC.CDF' in 6400 ms (Method: INVITE)
<--- SIP read from UDP:192.168.242.235:5062 --->
ACK sip:123123123#192.168.243.112 SIP/2.0
Via: SIP/2.0/UDP 192.168.242.235:5062;branch=z9hG4bK97733114;rport
From: "WACaller" <sip:wacaller#192.168.243.112>;tag=1014197566
To: <sip:123123123#192.168.243.112>;tag=as5a3de236
Call-ID: 298833112-5062-25#BJC.BGI.CEC.CDF
CSeq: 240 ACK
Content-Length: 0
<------------->
--- (7 headers 0 lines) ---
<--- SIP read from UDP:192.168.242.235:5062 --->
INVITE sip:123123123#192.168.243.112 SIP/2.0
Via: SIP/2.0/UDP 192.168.242.235:5062;branch=z9hG4bK1881861609;rport
From: "WACaller" <sip:wacaller#192.168.243.112>;tag=1014197566
To: <sip:123123123#192.168.243.112>
Call-ID: 298833112-5062-25#BJC.BGI.CEC.CDF
CSeq: 241 INVITE
Contact: "WACaller" <sip:wacaller#192.168.242.235:5062>
Authorization: Digest username="wacaller", realm="asterisk", nonce="4f84bef0", uri="sip:123123123#192.168.243.112", response="53cdb5b8c1822c80870faab15a6dc6d2", algorithm=MD5
Max-Forwards: 70
User-Agent: Grandstream GXP1400 1.0.4.13
Privacy: none
P-Preferred-Identity: "WACaller" <sip:wacaller#192.168.243.112>
Supported: replaces, path, timer
Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE, MESSAGE
Content-Type: application/sdp
Accept: application/sdp, application/dtmf-relay
Content-Length: 412
v=0
o=wacaller 8000 8000 IN IP4 192.168.242.235
s=SIP Call
c=IN IP4 192.168.242.235
t=0 0
m=audio 5004 RTP/AVP 0 8 4 18 9 97 2 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:9 G722/8000
a=rtpmap:97 iLBC/8000
a=fmtp:97 mode=30
a=rtpmap:2 G726-32/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
<------------->
--- (17 headers 19 lines) ---
Sending to 192.168.242.235:5062 (no NAT)
Using INVITE request as basis request - 298833112-5062-25#BJC.BGI.CEC.CDF
Found peer 'wacaller' for 'wacaller' from 192.168.242.235:5062
Found RTP audio format 0
Found RTP audio format 8
Found RTP audio format 4
Found RTP audio format 18
Found RTP audio format 9
Found RTP audio format 97
Found RTP audio format 2
Found RTP audio format 101
Found audio description format PCMU for ID 0
Found audio description format PCMA for ID 8
Found audio description format G723 for ID 4
Found audio description format G729 for ID 18
Found audio description format G722 for ID 9
Found audio description format iLBC for ID 97
Found audio description format G726-32 for ID 2
Found audio description format telephone-event for ID 101
Capabilities: us - (gsm|ulaw|alaw|h263|testlaw), peer - audio=(g723|ulaw|alaw|g726|g729|ilbc|g722)/video=(nothing)/text=(nothing), combined - (ulaw|alaw)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1 (telephone-event|), combined - 0x1 (telephone-event|)
Peer audio RTP is at port 192.168.242.235:5004
Looking for 123123123 in watest (domain 192.168.243.112)
list_route: route/path hop: <sip:wacaller#192.168.242.235:5062>
<--- Transmitting (no NAT) to 192.168.242.235:5062 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 192.168.242.235:5062;branch=z9hG4bK1881861609;received=192.168.242.235;rport=5062
From: "WACaller" <sip:wacaller#192.168.243.112>;tag=1014197566
To: <sip:123123123#192.168.243.112>
Call-ID: 298833112-5062-25#BJC.BGI.CEC.CDF
CSeq: 241 INVITE
Server: Asterisk PBX SVN-trunk-r385782
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Session-Expires: 1800;refresher=uas
Contact: <sip:123123123#192.168.243.112:5060>
Content-Length: 0
<------------>
Audio is at 17372
Adding codec 100003 (ulaw) to SDP
Adding codec 100004 (alaw) to SDP
Adding codec 100002 (gsm) to SDP
Adding codec 100017 (testlaw) to SDP
Adding non-codec 0x1 (telephone-event) to SDP
Reliably Transmitting (NAT) to 192.168.241.98:5060:
INVITE sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK67b16b32;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as3f5f372a
To: <sip:s#192.168.241.98:5060>
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 758899861bee35980dadd87912ef805a#192.168.243.112:5060
CSeq: 102 INVITE
User-Agent: Asterisk PBX SVN-trunk-r385782
Date: Wed, 26 Jun 2013 08:31:48 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 326
v=0
o=root 2059284449 2059284449 IN IP4 192.168.243.112
s=Asterisk PBX SVN-trunk-r385782
c=IN IP4 192.168.243.112
t=0 0
m=audio 17372 RTP/AVP 0 8 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv
---
<--- SIP read from UDP:192.168.241.98:5060 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK67b16b32;received=192.168.243.112;rport=5060
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as3f5f372a
To: <sip:s#192.168.241.98:5060>;tag=as22eeeac0
Call-ID: 758899861bee35980dadd87912ef805a#192.168.243.112:5060
CSeq: 102 INVITE
Server: Asterisk PBX 1.8.12.0
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="603b4bbf"
Content-Length: 0
<------------->
--- (11 headers 0 lines) ---
Transmitting (NAT) to 192.168.241.98:5060:
ACK sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK67b16b32;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as3f5f372a
To: <sip:s#192.168.241.98:5060>;tag=as22eeeac0
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 758899861bee35980dadd87912ef805a#192.168.243.112:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX SVN-trunk-r385782
Content-Length: 0
---
Audio is at 17372
Adding codec 100003 (ulaw) to SDP
Adding codec 100004 (alaw) to SDP
Adding codec 100002 (gsm) to SDP
Adding codec 100017 (testlaw) to SDP
Adding non-codec 0x1 (telephone-event) to SDP
Reliably Transmitting (NAT) to 192.168.241.98:5060:
INVITE sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK6cd34725;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as3f5f372a
To: <sip:s#192.168.241.98:5060>
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 758899861bee35980dadd87912ef805a#192.168.243.112:5060
CSeq: 103 INVITE
User-Agent: Asterisk PBX SVN-trunk-r385782
Authorization: Digest username="s", realm="asterisk", algorithm=MD5, uri="sip:s#192.168.241.98:5060", nonce="603b4bbf", response="059cae207fb81fb76ea9061f71258895"
Date: Wed, 26 Jun 2013 08:31:48 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 326
v=0
o=root 2059284449 2059284450 IN IP4 192.168.243.112
s=Asterisk PBX SVN-trunk-r385782
c=IN IP4 192.168.243.112
t=0 0
m=audio 17372 RTP/AVP 0 8 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv
---
<--- SIP read from UDP:192.168.241.98:5060 --->
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK6cd34725;received=192.168.243.112;rport=5060
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as3f5f372a
To: <sip:s#192.168.241.98:5060>;tag=as22eeeac0
Call-ID: 758899861bee35980dadd87912ef805a#192.168.243.112:5060
CSeq: 103 INVITE
Server: Asterisk PBX 1.8.12.0
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Length: 0
<------------->
--- (10 headers 0 lines) ---
Transmitting (NAT) to 192.168.241.98:5060:
ACK sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK6cd34725;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as3f5f372a
To: <sip:s#192.168.241.98:5060>;tag=as22eeeac0
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 758899861bee35980dadd87912ef805a#192.168.243.112:5060
CSeq: 103 ACK
User-Agent: Asterisk PBX SVN-trunk-r385782
Content-Length: 0
---
[Jun 26 16:31:48] WARNING[20447][C-0000000a]: chan_sip.c:23213 handle_response_invite: Received response: "Forbidden" from '"WACaller" <sip:wagateway#192.168.243.112>;tag=as3f5f372a'
Scheduling destruction of SIP dialog '758899861bee35980dadd87912ef805a#192.168.243.112:5060' in 6400 ms (Method: INVITE)
Scheduling destruction of SIP dialog '298833112-5062-25#BJC.BGI.CEC.CDF' in 6400 ms (Method: INVITE)
Sip debug on destination server:
<--- SIP read from UDP:192.168.243.112:5060 --->
INVITE sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK3159e4b1;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as30b27eae
To: <sip:s#192.168.241.98:5060>
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
CSeq: 102 INVITE
User-Agent: Asterisk PBX SVN-trunk-r385782
Date: Thu, 27 Jun 2013 01:27:54 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 326
v=0
o=root 1301894386 1301894386 IN IP4 192.168.243.112
s=Asterisk PBX SVN-trunk-r385782
c=IN IP4 192.168.243.112
t=0 0
m=audio 15838 RTP/AVP 0 8 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv
<------------->
--- (14 headers 14 lines) ---
Sending to 192.168.243.112:5060 (NAT)
Using INVITE request as basis request - 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
Found peer 'wagateway' for 'wagateway' from 192.168.243.112:5060
<--- Reliably Transmitting (no NAT) to 192.168.243.112:5060 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK3159e4b1;received=192.168.243.112;rport=5060
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as30b27eae
To: <sip:s#192.168.241.98:5060>;tag=as671c0824
Call-ID: 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
CSeq: 102 INVITE
Server: Asterisk PBX 1.8.12.0
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="0b63a660"
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog '5dc37059030845ca3d974c513993876d#192.168.243.112:5060' in 32000 ms (Method: INVITE)
<--- SIP read from UDP:192.168.243.112:5060 --->
ACK sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK3159e4b1;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as30b27eae
To: <sip:s#192.168.241.98:5060>;tag=as671c0824
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX SVN-trunk-r385782
Content-Length: 0
<------------->
--- (10 headers 0 lines) ---
<--- SIP read from UDP:192.168.243.112:5060 --->
INVITE sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK40e56655;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as30b27eae
To: <sip:s#192.168.241.98:5060>
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
CSeq: 103 INVITE
User-Agent: Asterisk PBX SVN-trunk-r385782
Authorization: Digest username="s", realm="asterisk", algorithm=MD5, uri="sip:s#192.168.241.98:5060", nonce="0b63a660", response="537f37fe2fb8d0fd40733cb190ea70c8"
Date: Thu, 27 Jun 2013 01:27:54 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 326
v=0
o=root 1301894386 1301894387 IN IP4 192.168.243.112
s=Asterisk PBX SVN-trunk-r385782
c=IN IP4 192.168.243.112
t=0 0
m=audio 15838 RTP/AVP 0 8 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=silenceSupp:off - - - -
a=ptime:20
a=sendrecv
<------------->
--- (15 headers 14 lines) ---
Sending to 192.168.243.112:5060 (no NAT)
Using INVITE request as basis request - 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
Found peer 'wagateway' for 'wagateway' from 192.168.243.112:5060
<--- Reliably Transmitting (no NAT) to 192.168.243.112:5060 --->
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK40e56655;received=192.168.243.112;rport=5060
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as30b27eae
To: <sip:s#192.168.241.98:5060>;tag=as671c0824
Call-ID: 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
CSeq: 103 INVITE
Server: Asterisk PBX 1.8.12.0
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog '5dc37059030845ca3d974c513993876d#192.168.243.112:5060' in 32000 ms (Method: INVITE)
<--- SIP read from UDP:192.168.243.112:5060 --->
ACK sip:s#192.168.241.98:5060 SIP/2.0
Via: SIP/2.0/UDP 192.168.243.112:5060;branch=z9hG4bK40e56655;rport
Max-Forwards: 70
From: "WACaller" <sip:wagateway#192.168.243.112>;tag=as30b27eae
To: <sip:s#192.168.241.98:5060>;tag=as671c0824
Contact: <sip:wagateway#192.168.243.112:5060>
Call-ID: 5dc37059030845ca3d974c513993876d#192.168.243.112:5060
CSeq: 103 ACK
User-Agent: Asterisk PBX SVN-trunk-r385782
Content-Length: 0
<------------->
--- (10 headers 0 lines) ---
dev-ast*CLI> sip set debug off
SIP Debugging Disabled
Any help?
Another problem that you have is a loop, you send the call to your gateway, and when the call come to your gateway you send again to the gateway, this is the why are you getting a forbidden, when you dial SIP/wagateway (on wagateway) the you dont have the extensions, your call way is client ---> gateway ---> gateway , try to change you extension to watest to something like below
[watest]
exten => 123123123,1,NoOp(Call comming from ${CALLERID(all)})
exten => 123123123,n,Answer()
exten => 123123123,n,PlayBack(tt-monkeys)
exten => 123123123,n,Hangup()
Comparing to one of my Asterisk-to-Asterisk SIP trunks...
It looks like what I use is the defaultuser= parameter in my sip.conf as opposed to fromuser=
From the original sip.conf that comes with a make samples -- defaultuser is described as "Authentication user for outbound proxies". While it's not a proxy in this case, I believe this is the parameter that will be used when making this SIP request.
That being said -- you may also consider using the iax protocol when you have the convenience of setting up a trunk between two asterisk servers. It standards for "Inter-Asterisk eXchange", and I find it to be simpler to use. And especially simpler doesn't seem to suffer the same ills as SIP does when traversing a NAT.
Here's an example of a SIP trunk I have between two asterisk boxes.
Box A, "New York":
register => newyork:VERYSECRET#192.168.1.21
[tokyo]
nat=yes
type=friend
context=insidecaller
host=192.168.1.21
defaultuser=newyork
secret=VERYSECRET
disallow=all
allow=ulaw
And on Box B, "Tokyo":
[newyork]
directmedia=no
type=friend
secret=VERYSECRET
context=outsidecaller
host=dynamic
disallow=all
allow=ulaw
Note how the defaultuser on Box A's configuration to talk to tokyo (aka Box B) matches the device name [newyork] on Box B's sip.conf
Have you tried with:
exten => 123123123,n,Dial(SIP/wagateway/${EXTEN})
INVITE sip:s#192.168.241.98:5060
You are sending call on s extension in [watest] context (which is by default if you don't specify extension), but s doesn't exists, only 123123123.
edit1:
Ok than add modify [wacaller] add:
type=peer ;instead of friend
insecure=invite,port
nat=yes
let me know if it worked, thanks.
edit2:
try to remove/comment out
;fromuser=wagateway
Check the Grandstream forum, it is most likely phone problem.
edit3:
Problem 99% lies in the fact that you register to one server (192.168.243.112) and invites are sent to wagateway/s(192.168.241.98) different server or IP
The registry string is not the same as the one from invite, and there for you get forbidden message.
this should help out:
;insecure=invite,port
on gateway for caller trunk, if you want to keep this network setup.
Regards

Resources