Skip to content

Commit 5701596

Browse files
committed
Block loading for port 10080
https://bugs.webkit.org/show_bug.cgi?id=224432 Reviewed by Alex Christensen. LayoutTests/imported/w3c: * web-platform-tests/fetch/api/request/request-bad-port.any-expected.txt: * web-platform-tests/fetch/api/request/request-bad-port.any.js: * web-platform-tests/fetch/api/request/request-bad-port.any.worker-expected.txt: * web-platform-tests/websockets/Create-blocked-port.any-expected.txt: * web-platform-tests/websockets/Create-blocked-port.any.js: * web-platform-tests/websockets/Create-blocked-port.any.worker-expected.txt: Source/WTF: Follow Chrome and Firefox by blocking port 10080. * wtf/URL.cpp: (WTF::portAllowed): Canonical link: https://commits.webkit.org/236401@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@275831 268f45cc-cd09-0410-ab3c-d52691b4dbfc
1 parent a9ab6ff commit 5701596

9 files changed

Lines changed: 35 additions & 0 deletions

File tree

LayoutTests/imported/w3c/ChangeLog

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
2021-04-12 Youenn Fablet <youenn@apple.com>
2+
3+
Block loading for port 10080
4+
https://bugs.webkit.org/show_bug.cgi?id=224432
5+
6+
Reviewed by Alex Christensen.
7+
8+
* web-platform-tests/fetch/api/request/request-bad-port.any-expected.txt:
9+
* web-platform-tests/fetch/api/request/request-bad-port.any.js:
10+
* web-platform-tests/fetch/api/request/request-bad-port.any.worker-expected.txt:
11+
* web-platform-tests/websockets/Create-blocked-port.any-expected.txt:
12+
* web-platform-tests/websockets/Create-blocked-port.any.js:
13+
* web-platform-tests/websockets/Create-blocked-port.any.worker-expected.txt:
14+
115
2021-04-12 Sam Weinig <weinig@apple.com>
216

317
Update WPT css/css-color tests

LayoutTests/imported/w3c/web-platform-tests/fetch/api/request/request-bad-port.any-expected.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ Blocked access to external URL http://example.com:6667/
7575
Blocked access to external URL http://example.com:6668/
7676
Blocked access to external URL http://example.com:6669/
7777
Blocked access to external URL http://example.com:6697/
78+
Blocked access to external URL http://example.com:10080/
7879

7980
PASS Request on bad port 1 should throw TypeError.
8081
PASS Request on bad port 7 should throw TypeError.
@@ -153,4 +154,5 @@ PASS Request on bad port 6667 should throw TypeError.
153154
PASS Request on bad port 6668 should throw TypeError.
154155
PASS Request on bad port 6669 should throw TypeError.
155156
PASS Request on bad port 6697 should throw TypeError.
157+
PASS Request on bad port 10080 should throw TypeError.
156158

LayoutTests/imported/w3c/web-platform-tests/fetch/api/request/request-bad-port.any.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ var BLOCKED_PORTS_LIST = [
8080
6668, // irc (alternate)
8181
6669, // irc (alternate)
8282
6697, // irc+tls
83+
10080, // amanda
8384
];
8485

8586
BLOCKED_PORTS_LIST.map(function(a){

LayoutTests/imported/w3c/web-platform-tests/fetch/api/request/request-bad-port.any.worker-expected.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ Blocked access to external URL http://example.com:6667/
7575
Blocked access to external URL http://example.com:6668/
7676
Blocked access to external URL http://example.com:6669/
7777
Blocked access to external URL http://example.com:6697/
78+
Blocked access to external URL http://example.com:10080/
7879

7980
PASS Request on bad port 1 should throw TypeError.
8081
PASS Request on bad port 7 should throw TypeError.
@@ -153,4 +154,5 @@ PASS Request on bad port 6667 should throw TypeError.
153154
PASS Request on bad port 6668 should throw TypeError.
154155
PASS Request on bad port 6669 should throw TypeError.
155156
PASS Request on bad port 6697 should throw TypeError.
157+
PASS Request on bad port 10080 should throw TypeError.
156158

LayoutTests/imported/w3c/web-platform-tests/websockets/Create-blocked-port.any-expected.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,4 +77,5 @@ PASS WebSocket blocked port test 6667
7777
PASS WebSocket blocked port test 6668
7878
PASS WebSocket blocked port test 6669
7979
PASS WebSocket blocked port test 6697
80+
PASS WebSocket blocked port test 10080
8081

LayoutTests/imported/w3c/web-platform-tests/websockets/Create-blocked-port.any.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ async_test(t => {
8585
6668, // irc (alternate)
8686
6669, // irc (alternate)
8787
6697, // irc+tls
88+
10080, // amanda
8889
].forEach(blockedPort => {
8990
async_test(t => {
9091
const ws = CreateWebSocketWithBlockedPort(blockedPort)

LayoutTests/imported/w3c/web-platform-tests/websockets/Create-blocked-port.any.worker-expected.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,4 +77,5 @@ PASS WebSocket blocked port test 6667
7777
PASS WebSocket blocked port test 6668
7878
PASS WebSocket blocked port test 6669
7979
PASS WebSocket blocked port test 6697
80+
PASS WebSocket blocked port test 10080
8081

Source/WTF/ChangeLog

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
2021-04-12 Youenn Fablet <youenn@apple.com>
2+
3+
Block loading for port 10080
4+
https://bugs.webkit.org/show_bug.cgi?id=224432
5+
6+
Reviewed by Alex Christensen.
7+
8+
Follow Chrome and Firefox by blocking port 10080.
9+
10+
* wtf/URL.cpp:
11+
(WTF::portAllowed):
12+
113
2021-04-11 Sam Weinig <weinig@apple.com>
214

315
Reduce compile time and binary size cost of enabling proper CSSStyleDeclaration property access behavior

Source/WTF/wtf/URL.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -972,6 +972,7 @@ bool portAllowed(const URL& url)
972972
6669, // Alternate IRC [Apple addition]
973973
6679, // Alternate IRC SSL [Apple addition]
974974
6697, // IRC+SSL [Apple addition]
975+
10080, // amanda
975976
};
976977

977978
// If the port is not in the blocked port list, allow it.

0 commit comments

Comments
 (0)