amazon-kinesis-video-streams-webrtc-sdk-c icon indicating copy to clipboard operation
amazon-kinesis-video-streams-webrtc-sdk-c copied to clipboard

[BUG]The protocal of relay candidate which allocated from iceserver turns:domain:443?transport=tcp show as tcp

Open vc60er opened this issue 3 years ago • 2 comments

Logging

2022-09-09 06:32:28 DEBUG iceAgentLogNewCandidate(): New local ice candidate discovered. Id: acprUI75O. Ip: 120...*:32366. Type: relay. Protocol: tcp.

Describe the bug The protocal of relay candidate which allocated from iceserver turns:domain:443?transport=tcp show as tcp

SDK version number v1.7.3

Open source building If it is a build issue, include 3rd party library version and steps to how you are building it

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior Expected it show as udp

always uses UDP between the server and the peer.
https://www.rfc-editor.org/rfc/rfc5766#section-2.1

Screenshots

Desktop (please complete the following information):

Smartphone (please complete the following information):

Additional context Add any other context about the problem here.

vc60er avatar Sep 09 '22 08:09 vc60er

@vc60er ,

Can you be specific? What is the issue here?

disa6302 avatar Sep 15 '22 18:09 disa6302

@disa6302

2022-09-09 06:32:28 DEBUG   turnConnectionStepState(): Relay address received: 120.92.*.*, port: 32366
2022-09-09 06:32:28 DEBUG   iceAgentLogNewCandidate(): New local ice candidate discovered. Id: acprUI75O. Ip: 120.92.*.*:32366. Type: relay. Protocol: tcp.
{"type": "answer", "sdp": "v=0 
....
a=candidate:2 1 udp 16777215 120.92.*.* 32366 typ relay raddr 0.0.0.0 rport 0 generation 0 network-cost 999
....

Put simply, the protocol in the line 2 of the log above should be udp, not tcp. The reason is, relay addr always uses UDP between the server and the peer, as said in https://www.rfc-editor.org/rfc/rfc5766#section-2.1

The background to this issue is:

  1. I have closed trickle ice on my sdk
  2. And used a turns as one of iceService, which domain is ~~domain~~, the ip is 120.92.*.*,
  3. The sdk allocated a relay candidate from turns,which is 120.92.*.*:32366
  4. The "New local ice candidate" log shows: “New local ice candidate discovered. Id: acprUI75O. Ip: 120.92.*.*:32366. Type: relay. Protocol: tcp.”, the protocal is tcp
  5. The candidate in sdp answer shows: “a=candidate:2 1 udp 16777215 120.92.*.* 32366 typ relay raddr 0.0.0.0 rport 0 generation 0 network-cost 999”, the protocal is udp

I think the protocal shown in "New local ..." is wrong. and the protocol shown in the sdp answer are correct.

vc60er avatar Sep 17 '22 12:09 vc60er

This is a very old issue. We encourage you to check if this is still an issue in the latest release and if you find that this is still a problem, please feel free to open a new one.

github-actions[bot] avatar Mar 18 '23 00:03 github-actions[bot]