planetarium / libplanet

Blockchain in C#/.NET for on-chain, decentralized gaming
https://docs.libplanet.io/
GNU Lesser General Public License v2.1
506 stars 142 forks source link

`IceServer()` constructor should be able to take multiple credentails #1381

Closed dahlia closed 1 year ago

dahlia commented 3 years ago

Currently, IceServer() constructor can take multiple ICE server URLs, but credential pairs still cannot be multiple. If there are two or more ICE servers and each server require their own distinct name–password pairs, the form of IceServer() constructor cannot utilizes all servers but only one, because other name–password pairs won't be authorized except for one.

The issue could be resolved by taking URLs' own credential fields (e.g., turn://NAME:PASSWORD@netloc) instead of taking one credential pair as a separated parameter.


Nine Chronicles is doing this manually, which is not ideal:

https://github.com/planetarium/NineChronicles.Headless/blob/94202a2560f796cccc89b6580c98f23a2274a20f/Libplanet.Headless/PropertyParser.cs#L14-L17

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions.