web-platform-tests / wpt

Test suites for Web platform specs — including WHATWG, W3C, and others
https://web-platform-tests.org/
Other
4.97k stars 3.09k forks source link

Centralize blocked port list #11346

Open annevk opened 6 years ago

annevk commented 6 years ago

fetch/api/request/request-bad-port.html and websockets/Create-blocked-port.any.js both include the list of ports at https://fetch.spec.whatwg.org/#port-blocking. Perhaps we should store this list separately so it can be shared. (The one problem here is that if we store it as JSON and later the blocking logic becomes more complex (e.g., either in a range or in the list), we'll have to revamp the setup again.

Also sharing it with tools/wptserve/wptserve/utils.py is probably not a good idea, but I'm willing to be convinced otherwise.

annevk commented 6 years ago

(Suggested in #11249 by @Ms2ger.)