Skip to content
This repository has been archived by the owner on Dec 2, 2022. It is now read-only.

0x kitsune/public ip #281

Closed
wants to merge 2 commits into from

Conversation

0xKitsune
Copy link
Contributor

@0xKitsune 0xKitsune commented Sep 8, 2022

PR for issue #244.

As mentioned in the issue above, I checked out the public-ip crate to find a way to bind to a public IP. I added public-ip=0.2.2 to the cargo.toml.

I removed the usage of search_gateway and replaced it with public_ip::addr() which from the docs: attempts to produce an IP address with all builtin resolvers (best effort). This function will attempt to resolve until the stream is empty and will drop/ignore any resolver errors.

@vorot93
Copy link
Member

vorot93 commented Sep 11, 2022

Thanks for the PR!

I wonder if you could retain search_gateway and use public-ip as a backup for when UPnP fails?

@0xKitsune
Copy link
Contributor Author

I wonder if you could retain search_gateway and use public-ip as a backup for when UPnP fails?

Yes sounds good, I will take a look a this today and update my PR.

@vorot93
Copy link
Member

vorot93 commented Sep 14, 2022

Superseded by #295

@vorot93 vorot93 closed this Sep 14, 2022
@0xKitsune 0xKitsune deleted the 0xKitsune/public-ip branch September 14, 2022 18:07
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