Skip to content
This repository was archived by the owner on Oct 8, 2021. It is now read-only.
This repository was archived by the owner on Oct 8, 2021. It is now read-only.

IPv6 address URL parsing fails #2362

Closed
Closed
@bkoenig

Description

@bkoenig

If you use jQuery Mobile with an IPv6 address in the URL, e.g.

http://[3fff:cafe:babe::]:443/foo

then it won't work at all because URL parsing fails. I fixed the hostname part of the urlParseRE to make it work.

Currently it reads
([^:\/#\?]+)
At first disallow [ and ] in hostnames:
([^\[\]:\/#\?]+)
Then add the special IPv6 case as an alternative:
([^\[\]:\/#\?]+|[[0-9a-fA-F:]+])

Please review.

Thank you and best regards
Björn

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions