-
Notifications
You must be signed in to change notification settings - Fork 8.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix URL sanitizer for long URLs (#16026)
f1aa699 was fundamentally incorrect as it used `IdnToAscii` and `IdnToUnicode` on the entire URL, even though these functions only work on domain names. This commit fixes the issue by using the WinRT `Url` class and its `AbsoluteUri` and `AbsoluteCanonicalUri` getters. The algorithm still works the same way though. Closes #16017 ## Validation Steps Performed * ``"`e]8;;https://www.xn--fcbook-3nf5b.com/`e\test`e]8;;`e\"`` still shows as two URLs in the popup ✅ * Shows the given URI if it's canonical and not an IDN ✅ * Works with >100 char long file:// URIs ✅ (cherry picked from commit 198c11f) Service-Card-Id: 90642844 Service-Version: 1.19
- Loading branch information
Showing
3 changed files
with
48 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters