WebKit Bugzilla
Attachment 373735 Details for
Bug 199627
: URLParser should reserialize IPv6 addresses that end with a colon
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-199627-20190709110546.patch (text/plain), 3.27 KB, created by
Alex Christensen
on 2019-07-09 11:05:47 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Alex Christensen
Created:
2019-07-09 11:05:47 PDT
Size:
3.27 KB
patch
obsolete
>Subversion Revision: 247246 >diff --git a/Source/WTF/ChangeLog b/Source/WTF/ChangeLog >index 911926796b3dba72ab8273a51f46579fef522bf3..841008433d5a7a01c10a193508d4a0d35b483a21 100644 >--- a/Source/WTF/ChangeLog >+++ b/Source/WTF/ChangeLog >@@ -1,3 +1,17 @@ >+2019-07-09 Alex Christensen <achristensen@webkit.org> >+ >+ URLParser should reserialize IPv6 addresses that end with a colon >+ https://bugs.webkit.org/show_bug.cgi?id=199627 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ When an IPv6 address ends in a colon, the colon should be removed which means the >+ serialized output is different than the input, which the URLParser calls a syntax violation. >+ This matches the URL specification, and I added a unit test that used to assert. >+ >+ * wtf/URLParser.cpp: >+ (WTF::URLParser::parseIPv6Host): >+ > 2019-07-08 Chris Dumez <cdumez@apple.com> > > Use WeakHashSet for WebUserContentControllerProxy::m_processes >diff --git a/Source/WTF/wtf/URLParser.cpp b/Source/WTF/wtf/URLParser.cpp >index cdfc0f82160d5d7985f5d01d19b2449b1d050c73..b9376601d2c8fd9148e35639137179bf3d027a16 100644 >--- a/Source/WTF/wtf/URLParser.cpp >+++ b/Source/WTF/wtf/URLParser.cpp >@@ -2467,6 +2467,8 @@ Optional<URLParser::IPv6Address> URLParser::parseIPv6Host(CodePointIterator<Char > if (piecePointer == 8 || *c != ':') > return WTF::nullopt; > advance(c, hostBegin); >+ if (c.atEnd()) >+ syntaxViolation(hostBegin); > > immediatelyAfterCompress = false; > } >diff --git a/Tools/ChangeLog b/Tools/ChangeLog >index d09b05553bf7e20a71aae9d86a5d74ff1fa63d15..5ba033648bdc915959559f571b396c1c55944bfd 100644 >--- a/Tools/ChangeLog >+++ b/Tools/ChangeLog >@@ -1,3 +1,13 @@ >+2019-07-09 Alex Christensen <achristensen@webkit.org> >+ >+ URLParser should reserialize IPv6 addresses that end with a colon >+ https://bugs.webkit.org/show_bug.cgi?id=199627 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * TestWebKitAPI/Tests/WTF/URLParser.cpp: >+ (TestWebKitAPI::TEST_F): >+ > 2019-07-08 Fujii Hironori <Hironori.Fujii@sony.com> > > JSTestGlobalObject.cpp of bindings-generation-tests is failing for Windows Python >diff --git a/Tools/TestWebKitAPI/Tests/WTF/URLParser.cpp b/Tools/TestWebKitAPI/Tests/WTF/URLParser.cpp >index cbd3f1f449a8635230bb9981b84e1b8e6a8d78ff..06ddefb2b98e12669ff92b6737fead0e0aebe3c0 100644 >--- a/Tools/TestWebKitAPI/Tests/WTF/URLParser.cpp >+++ b/Tools/TestWebKitAPI/Tests/WTF/URLParser.cpp >@@ -353,6 +353,7 @@ TEST_F(WTF_URLParser, Basic) > checkURL("http://[0:f:0:0:f::]:\t123", {"http", "", "", "[0:f:0:0:f::]", 123, "/", "", "", "http://[0:f:0:0:f::]:123/"}); > checkURL("http://[0:f:0:0:f::]:1\t23", {"http", "", "", "[0:f:0:0:f::]", 123, "/", "", "", "http://[0:f:0:0:f::]:123/"}); > checkURL("http://[0:f::f:f:0:0]:/path", {"http", "", "", "[0:f::f:f:0:0]", 0, "/path", "", "", "http://[0:f::f:f:0:0]/path"}); >+ checkURL("a://[::2:]", {"a", "", "", "[::2]", 0, "", "", "", "a://[::2]"}); > checkURL("http://[0:f::f:f:0:0]:", {"http", "", "", "[0:f::f:f:0:0]", 0, "/", "", "", "http://[0:f::f:f:0:0]/"}); > checkURL("http://host:10100/path", {"http", "", "", "host", 10100, "/path", "", "", "http://host:10100/path"}); > checkURL("http://host:/path", {"http", "", "", "host", 0, "/path", "", "", "http://host/path"});
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
beidson
:
review+
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 199627
: 373735