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

Issue: Incorrect port matching #200

Closed
alec-anikin opened this issue Sep 5, 2018 · 3 comments
Closed

Issue: Incorrect port matching #200

alec-anikin opened this issue Sep 5, 2018 · 3 comments

Comments

@alec-anikin
Copy link

Hi!
Regex from PortUtil.UrlDetailsRegex doesn't work for urls like "http://0.0.0.0:5000"
It should be ^(?<proto>\w+)://[^/]+?:(?<port>\d+)/?

@StefH StefH changed the title Incorrect port matching Issue: Incorrect port matching Sep 6, 2018
@StefH
Copy link
Collaborator

StefH commented Sep 11, 2018

Hello @alec-anikin, thanks for reporting.

However, maybe updating the regex even further to ^((?<proto>\w+)://)(?<host>[^/]+?):(?<port>\d+)\/?$ is even better?

For https://0.0.0.0:5000 , this matches like:
afbeelding

And for https://localhost:5000 , this matches like:
afbeelding

@StefH
Copy link
Collaborator

StefH commented Sep 17, 2018

Hi @alec-anikin ; what do you think?

StefH added a commit that referenced this issue Sep 20, 2018
@StefH
Copy link
Collaborator

StefH commented Sep 20, 2018

Will be fixed in PR

@StefH StefH closed this as completed Sep 20, 2018
StefH added a commit that referenced this issue Sep 22, 2018
* Lower priority from Proxy mappings

* Fix codefactor

* extra tests

* #205

* Fix test for linux

* `c:\temp\x.json` fix

* Extra tests

* more tests

* more tests

* codefactor

* #200

* refactor

* refactor

* tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants