Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: force hostname to lowercase #1443

Merged
merged 1 commit into from
Jun 20, 2022

Conversation

erisu
Copy link
Member

@erisu erisu commented Jun 20, 2022

Motivation and Context

Fixes #1426

Per comment #1426 (comment)

There might be an underlining issue within the Android WebView and how it is not honouring the domain name incase sensitive specification.

Description

As workaround, this PR will force the user defined hostname to lowercase with the .toLowerCase() method.

Testing

  • cordova build
  • cordova run

Also tested use cases where upper-case string could have been provided while we force lowercase.

Html

<a href="https://ABCDEFG/another-page.html">ANOTHER PAGE</a>

Javascript

window.location = "https://ABCDEFG/another-page.html";

Checklist

  • I've run the tests to see all new and existing tests pass
  • I added automated test coverage as appropriate for this change
  • If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct keyword to close issues using keywords)
  • I've updated the documentation if necessary

@erisu erisu added this to the 11.0.0 milestone Jun 20, 2022
@erisu erisu requested a review from breautek June 20, 2022 06:17
@codecov-commenter
Copy link

codecov-commenter commented Jun 20, 2022

Codecov Report

Merging #1443 (1f74ae8) into master (68a9a31) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #1443   +/-   ##
=======================================
  Coverage   75.96%   75.96%           
=======================================
  Files          21       21           
  Lines        1677     1677           
=======================================
  Hits         1274     1274           
  Misses        403      403           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 68a9a31...1f74ae8. Read the comment docs.

@erisu erisu merged commit 4916e1d into apache:master Jun 20, 2022
@erisu erisu deleted the fix/force-hostname-lowercase branch June 20, 2022 14:26
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.

Setting preference hostname causes ERR_NAME_NOT_RESOLVED
3 participants