Skip to content

Conversation

annevk
Copy link
Member

@annevk annevk commented Oct 28, 2016

This reverts commit 47d2089.

See whatwg/url#87 for discussion.


This change is Reviewable

@wpt-pr-bot
Copy link
Collaborator

Reviewers for this pull request are: @Sebmaster, @domenic, @frewsxcv, @mikewest, @rubys, @sideshowbarker, @smola, @tomalec, @xiaojunwu, and @zcorpan.

@annevk
Copy link
Member Author

annevk commented Oct 31, 2016

Note that Firefox already WONTFIXED their corresponding bug (and therefore agrees with this change) and Safari advocated for it. We don't really know what the other browsers will do unfortunately.

@annevk
Copy link
Member Author

annevk commented Nov 1, 2016

I suggest we keep this open for now given that Google is not okay with going in this direction.

@annevk annevk force-pushed the annevk/don't-decode-arbitrary-%2e branch from 2e64b13 to d179f7e Compare December 29, 2016 14:20
@annevk
Copy link
Member Author

annevk commented Dec 29, 2016

I suggest we land this per whatwg/url#87 (comment) since what's currently defined isn't really implemented anywhere.

annevk added a commit to whatwg/url that referenced this pull request Dec 29, 2016
This basically reverts bee5ad8 as it
did not end up shipping in Firefox and the tentative conclusion is that
percent-decoding in URLs while parsing creates more trouble than it’s
worth.

We’ll still handle %2e when it’s part of a single-dot or double-dot
path segment.

Tests: web-platform-tests/wpt#4104.

Closes #87.
@domenic
Copy link
Member

domenic commented Dec 29, 2016

After updating whatwg-url per https://github.com/whatwg/url/pull/156/files the following tests additionally fail:

  1) Web platform tests setters pathname <view-source+http://example.net/home?lang=fr#nav>.pathname = "\a\%2E\b\%2e.\c" \ is *not* a segment delimiter for non-'special' URLs:

      AssertionError: 'view-source+http://example.net/\\a\\%2E\\b\\%2e.\\c?lang=fr#nav' == 'view-source+http://example.net/\\a\\.\\b\\..\\c?lang=fr#nav'
      + expected - actual

      -view-source+http://example.net/\a\%2E\b\%2e.\c?lang=fr#nav
      +view-source+http://example.net/\a\.\b\..\c?lang=fr#nav
  2) Web platform tests setters pathname <http://example.net>.pathname = "%2e%2E%c3%89té" Bytes already percent-encoded are left as-is, except %2E.:

      AssertionError: 'http://example.net/%2e%2E%c3%89t%C3%A9' == 'http://example.net/..%c3%89t%C3%A9'
      + expected - actual

      -http://example.net/%2e%2E%c3%89t%C3%A9
      +http://example.net/..%c3%89t%C3%A9

@annevk annevk merged commit d93247d into master Jan 3, 2017
@annevk annevk deleted the annevk/don't-decode-arbitrary-%2e branch January 3, 2017 17:49
annevk added a commit to whatwg/url that referenced this pull request Jan 3, 2017
This basically reverts bee5ad8 as it
did not end up shipping in Firefox and the tentative conclusion is that
percent-decoding in URLs while parsing creates more trouble than it’s
worth.

We’ll still handle %2e when it’s part of a single-dot or double-dot
path segment.

Tests: web-platform-tests/wpt#4104.

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

Successfully merging this pull request may close these issues.

5 participants