Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port Restriction Policy #354

Closed
njohnst opened this issue Feb 5, 2018 · 4 comments
Closed

Port Restriction Policy #354

njohnst opened this issue Feb 5, 2018 · 4 comments
Assignees

Comments

@njohnst
Copy link
Contributor

njohnst commented Feb 5, 2018

For my use-case I'd like to be able to restrict the range of ports that the ICE gatherer is able to generate local candidates from - I've seen a policy for this in Chrome (Google.Policies.Chrome::WebRtcUdpPortRange).

Would it be possible to add this feature?
I'm not exactly sure where the binaries come from / what is possible via the bindings...

I'd appreciate it if someone could point me in the right direction, I'm willing to implement this myself.

Thank you,
Nicholas

@markandrus
Copy link
Member

I think we could expose this as a non-standard option on RTCConfiguration.

@markandrus markandrus self-assigned this Feb 9, 2018
@njohnst
Copy link
Contributor Author

njohnst commented Feb 16, 2018

I appreciate it. I will look into native webrtc to see where this would be implemented

@njohnst
Copy link
Contributor Author

njohnst commented Feb 27, 2018

Added the feature in a fork - RTCConfiguration option called "customPortRange" that takes a string in the format "<MIN_PORT>-<MAX_PORT>" (e.g. "customPortRange: '1234-2345'")

https://github.com/njohnst/node-webrtc/tree/port-restriction

EDITED:
There is currently no way to use the same UDP port for more than one client, I'm looking at a fix for this

Cheers

@njohnst
Copy link
Contributor Author

njohnst commented Mar 13, 2018

Allowing multiple clients on the same UDP port would require a major rewrite of the native code and is not feasible (AFAIK), thus I've just focused on the port range restriction in my PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants