ice icon indicating copy to clipboard operation
ice copied to clipboard

gatherCandidatesLocalUDPMux gathers candidates not on socket

Open 50infivedays opened this issue 3 years ago • 4 comments

Your environment.

  • Version: ice v2.2.2
  • Browser: any version image

What did you expect?

i'm expecting it should only gather candidates on socket

What happened?

it will gather every ip as candiddate , if you have multi ip on your interface , it will make a wrong candidate

50infivedays avatar Mar 29 '22 06:03 50infivedays

@Sean-Der is this a bug? i think it should skip the ip when it is not matched with the socket

50infivedays avatar Mar 29 '22 06:03 50infivedays

@50infivedays that looks like a bug to me!

pion/ice was written with the assumption that every interface will only have one IP, so I bet we have lots of bugs/behaviors that aren't expected.

Sean-Der avatar Mar 29 '22 14:03 Sean-Der

@50infivedays that looks like a bug to me!

pion/ice was written with the assumption that every interface will only have one IP, so I bet we have lots of bugs/behaviors that aren't expected.

will multi-IP on one interface be supported in the future?

50infivedays avatar Mar 30 '22 03:03 50infivedays

I think it is already supported.

There is just another caveat here: pion/ice uses pion/transports vnet.Net to get a list of interfaces and addresses during ice.NewAgent() which remains static for the lifetime of the agent.

No changes of interfaces or addresses will be taken into account.

stv0g avatar Sep 01 '22 10:09 stv0g

Fixed by #483 , gather will collect candidates from Mux's socket now.

cnderrauber avatar Oct 11 '22 08:10 cnderrauber