WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED CONFIGURATION CHANGED
115396
Constructing the KURL from base + fragment ref is problematic for data: URI
https://bugs.webkit.org/show_bug.cgi?id=115396
Summary
Constructing the KURL from base + fragment ref is problematic for data: URI
Ryosuke Niwa
Reported
2013-04-30 00:30:24 PDT
We should consider merging
https://chromium.googlesource.com/chromium/blink/+/2274b648033402fc691536b45daf8b00486dc72a
Constructing the KURL from base + fragment ref is problematic for data: URI, as it is not a hierarchical scheme and relative resolution fails. Luckily, this is avoidable: the only reason for constructing a KURL is to compare against the document URL, but the comparison ignores the fragment anyway (equalIgnoringFragmentIdentifier). This is equivalent to a base-only comparison, which is the approach proposed in this patch. No test: the issue only triggers when the document url is data: URI based, and DRT doesn't seem to support opening such a scheme directly. Current baseURI vs. document URL validation is covered by existing tests. (For background on why we perform such validation in the first place, see
https://bugs.webkit.org/show_bug.cgi?id=63283
https://bugzilla.mozilla.org/show_bug.cgi?id=308590
)
Attachments
Add attachment
proposed patch, testcase, etc.
Ahmad Saleem
Comment 1
2022-08-27 01:12:28 PDT
I am not sure whether this is needed or not but this is where current Webkit GitHub code is:
https://github.com/WebKit/WebKit/blob/19c49cf8315e01cec9894d2233f7179e60e9664a/Source/WebCore/svg/SVGURIReference.cpp#L72
Plus there was no test case to test new behaviour, hence also why I am not sure whether this is needed or not. I will leave it for others to confirm. Thanks!
Ryosuke Niwa
Comment 2
2022-08-27 01:15:32 PDT
We've rewritten our URL implementation since then so I doubt this patch is worth considering of a merge at this point.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug