Skip to content
This repository was archived by the owner on Nov 1, 2023. It is now read-only.

Comments

Ipaddress parse fix to handle X-Forwarded-For with ports#83

Merged
stefanprodan merged 5 commits intostefanprodan:masterfrom
jimmystridh:ipaddress-parse-fix
Dec 8, 2016
Merged

Ipaddress parse fix to handle X-Forwarded-For with ports#83
stefanprodan merged 5 commits intostefanprodan:masterfrom
jimmystridh:ipaddress-parse-fix

Conversation

@jimmystridh
Copy link

I had the same problem as #34 with X-Forwarded-For containing port numbers. This pull request adds add check for port numbers and removes them before using the same parse logic as previously.

It also adds a test project for the parse code.

@stefanprodan
Copy link
Owner

What about Ipv6?

@jimmystridh
Copy link
Author

jimmystridh commented Dec 7, 2016

What about Ipv6?

the simplest test case ::1 would get pretty butchered, yes. Thanks, I'll submit an update!

@stefanprodan
Copy link
Owner

Also IsPrivateIpAddress does not handle Ipv6 I think.

@jimmystridh
Copy link
Author

added ipv6 handling

@stefanprodan stefanprodan merged commit 6ac655f into stefanprodan:master Dec 8, 2016
@stefanprodan
Copy link
Owner

Thanks, your fixes are included on v1.5.2.0 and I've deployed the packages on NuGet.

@jimmystridh jimmystridh deleted the ipaddress-parse-fix branch December 11, 2016 18:31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants