[Freeswitch-users] Call UDP -> TLS

Chusov Alexsandr chusov.alexsandr at gmail.com
Wed Mar 27 21:54:28 MSK 2013


For test replace FreeSWITCH witch Opensips for register.
Phone -> TLS -> Opensips - > UDP -> Opensips
Work fine.

172.20.0.24.5060 > 172.20.0.22.5060: [udp sum ok] SIP, length: 919
    REGISTER sip:172.20.0.22:5060 SIP/2.0
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK4529.c9ec9a7.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK512348322;rport=5060
    From: <sip:1001 at 172.20.0.24>;tag=319008323
    To: <sip:1001 at 172.20.0.24>
    Call-ID: 1014532685-5060-1 at BHC.CA.A.CA
    CSeq: 2011 REGISTER
    Contact: <sip:1001 at 172.20.0.20:5060
>;reg-id=1;+sip.instance="<urn:uuid:00000000-0000-1000-8000-000B823DB6B2>"
    Authorization: Digest username="1001", realm="172.20.0.24",
nonce="51533e2a000000218d8794b71cd2825d45bcad006b247f2a",
uri="sip:172.20.0.24", response="b18f3fbbede44642c33564bffce9c1ea",
algorithm=MD5
    Max-Forwards: 30
    User-Agent: Grandstream GXP1405 1.0.5.10
    Supported: path
    Expires: 300
    Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO,
REFER, UPDATE, MESSAGE
    Content-Length: 0
    Path: <sip:172.20.0.24;lr;received=sip:172.20.0.20:5060>
    X-AUTH-IP: 172.20.0.20


172.20.0.22.5060 > 172.20.0.24.5060: [bad udp cksum 16dc!] SIP, length: 517
    SIP/2.0 200 OK
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK4529.c9ec9a7.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK512348322;rport=5060
    From: <sip:1001 at 172.20.0.24>;tag=319008323
    To: <sip:1001 at 172.20.0.24>;tag=64e8f587865022a9970237a3f630ac12.72d7
    Call-ID: 1014532685-5060-1 at BHC.CA.A.CA
    CSeq: 2011 REGISTER
    Contact: <sip:1001 at 172.20.0.20:5060>;expires=300
    Path: <sip:172.20.0.24;lr;received=sip:172.20.0.20:5060>
    Server: OpenSIPS (1.9.0-notls (x86_64/linux))
    Content-Length: 0


Call from 1000 to 1001

172.20.0.24.5060 > 172.20.0.22.5060: [udp sum ok] SIP, length: 1223
    INVITE sip:1000 at 172.20.0.22:5060 SIP/2.0
    Record-Route: <sip:172.20.0.24;lr;ftag=256750377;did=a69.7eedcea5>
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK9cef.fef718b6.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK69130358;rport=5060
    From: "1001" <sip:1001 at 172.20.0.24>;tag=256750377
    To: <sip:1000 at 172.20.0.24>
    Call-ID: 1487412933-5060-4 at BHC.CA.A.CA
    CSeq: 30 INVITE
    Contact: "1001" <sip:1001 at 172.20.0.20:5060>
    Max-Forwards: 30
    User-Agent: Grandstream GXP1405 1.0.5.10
    Privacy: none
    P-Preferred-Identity: "1001" <sip:1001 at 172.20.0.24>
    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:   400
    X-AUTH-IP: 172.20.0.20

    v=0
    o=1001 8000 8000 IN IP4 172.20.0.20
    s=SIP Call
    c=IN IP4 172.20.0.20
    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

172.20.0.22.5060 > 172.20.0.24.5060: [bad udp cksum bb07!] SIP, length: 380
    SIP/2.0 100 Giving a try
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK9cef.fef718b6.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK69130358;rport=5060
    From: "1001" <sip:1001 at 172.20.0.24>;tag=256750377
    To: <sip:1000 at 172.20.0.24>
    Call-ID: 1487412933-5060-4 at BHC.CA.A.CA
    CSeq: 30 INVITE
    Server: OpenSIPS (1.9.0-notls (x86_64/linux))
    Content-Length: 0

172.20.0.22.5060 > 172.20.0.24.5060: SIP, length: 1472
    INVITE sip:1000 at 172.20.0.16:5060;transport=tls;transport=tls SIP/2.0
    Record-Route: <sip:172.20.0.22;lr;did=a69.1fbc0244>
    Record-Route: <sip:172.20.0.24;lr;ftag=256750377;did=a69.7eedcea5>
    Via: SIP/2.0/UDP 172.20.0.22:5060;branch=z9hG4bK9cef.1674f7f1.0
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK9cef.fef718b6.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK69130358;rport=5060
    Route: <sip:172.20.0.24;r2=on;lr;received=sip:172.20.0.16:36572
>,<sip:172.20.0.24:5061;transport=tls;r2=on;lr>
    From: "1001" <sip:1001 at 172.20.0.24>;tag=256750377
    To: <sip:1000 at 172.20.0.24>
    Call-ID: 1487412933-5060-4 at BHC.CA.A.CA
    CSeq: 30 INVITE
    Contact: "1001" <sip:1001 at 172.20.0.20:5060>
    Max-Forwards: 29
    User-Agent: Grandstream GXP1405 1.0.5.10
    Privacy: none
    P-Preferred-Identity: "1001" <sip:1001 at 172.20.0.24>
    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:   400
    X-AUTH-IP: 172.20.0.20

    v=0
    o=1001 8000 8000 IN IP4 172.20.0.20
    s=SIP Call
    c=IN IP4 172.20.0.20
    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:[|sip]

172.20.0.24.5060 > 172.20.0.22.5060: [udp sum ok] SIP, length: 398
    SIP/2.0 100 Giving a try
    Via: SIP/2.0/UDP 172.20.0.22:5060;branch=z9hG4bK9cef.1674f7f1.0
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK9cef.fef718b6.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK69130358;rport=5060
    From: "1001" <sip:1001 at 172.20.0.24>;tag=256750377
    To: <sip:1000 at 172.20.0.24>
    Call-ID: 1487412933-5060-4 at BHC.CA.A.CA
    CSeq: 30 INVITE
    Content-Length: 0

172.20.0.24.5060 > 172.20.0.22.5060: [udp sum ok] SIP, length: 942
    SIP/2.0 180 Ringing
    Via: SIP/2.0/UDP 172.20.0.22:5060;branch=z9hG4bK9cef.1674f7f1.0
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK9cef.fef718b6.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK69130358;rport=5060
    Record-Route: <sip:172.20.0.24:5061
;transport=tls;r2=on;lr;ftag=256750377;did=a69.8eedcea5>
    Record-Route: <sip:172.20.0.24;r2=on;lr;ftag=256750377;did=a69.8eedcea5>
    Record-Route: <sip:172.20.0.22;lr;did=a69.1fbc0244>
    Record-Route: <sip:172.20.0.24;lr;ftag=256750377;did=a69.7eedcea5>
    From: "1001" <sip:1001 at 172.20.0.24>;tag=256750377
    To: <sip:1000 at 172.20.0.24>;tag=1572316537
    Call-ID: 1487412933-5060-4 at BHC.CA.A.CA
    CSeq: 30 INVITE
    Contact: <sip:1000 at 172.20.0.16:36572;transport=tls>
    Supported: replaces, path, timer
    User-Agent: Grandstream GXP2120 1.0.5.14
    Allow-Events: talk, hold
    Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO,
REFER, UPDATE, MESSAGE
    Content-Length: 0

172.20.0.22.5060 > 172.20.0.24.5060: [bad udp cksum b82a!] SIP, length: 877
    SIP/2.0 180 Ringing
    Via: SIP/2.0/UDP 172.20.0.24;branch=z9hG4bK9cef.fef718b6.0
    Via: SIP/2.0/UDP 172.20.0.20:5060
;received=172.20.0.20;branch=z9hG4bK69130358;rport=5060
    Record-Route: <sip:172.20.0.24:5061
;transport=tls;r2=on;lr;ftag=256750377;did=a69.8eedcea5>
    Record-Route: <sip:172.20.0.24;r2=on;lr;ftag=256750377;did=a69.8eedcea5>
    Record-Route: <sip:172.20.0.22;lr;did=a69.1fbc0244>
    Record-Route: <sip:172.20.0.24;lr;ftag=256750377;did=a69.7eedcea5>
    From: "1001" <sip:1001 at 172.20.0.24>;tag=256750377
    To: <sip:1000 at 172.20.0.24>;tag=1572316537
    Call-ID: 1487412933-5060-4 at BHC.CA.A.CA
    CSeq: 30 INVITE
    Contact: <sip:1000 at 172.20.0.16:36572;transport=tls>
    Supported: replaces, path, timer
    User-Agent: Grandstream GXP2120 1.0.5.14
    Allow-Events: talk, hold
    Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO,
REFER, UPDATE, MESSAGE
    Content-Length: 0




2013/3/26 Chusov Alexsandr <chusov.alexsandr at gmail.com>

>
> 2013/3/26 Michael Collins <msc at freeswitch.org>
>
>> showed specifically has "transport=tls
>
>
>
> I wrote in the mailing list  Bogan  response:
>
>
> Hi Alexsandr,
>
> Well, the problem is more complex a bit. I see you configured OpenSIPs
> to add PATH header to REGISTER before sending it to FS. The address in
> PATH has UDP transport, so FS (if supports PATH) should send the calls
> back to OpenSIPS by using the address from PATH (with UDP). The contact
> in register has TLS transport (and you fwd it to FS as it is), but it
> should not be used directly by FS because of the presence and priority
> of PATH hdr.
>
> So, my only explanation is that FS does not support / not configured to
> handle PATH, so that it uses the address from contact, which is TLS.
>
> Regards,
>
> Bogdan-Andrei Iancu
> OpenSIPS Founder and Developerhttp://www.opensips-solutions.com
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20130327/39a8987d/attachment-0001.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list