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

Does not take into account other IPs a machine has. #4

Open
ch4dwick opened this issue Apr 6, 2022 · 2 comments
Open

Does not take into account other IPs a machine has. #4

ch4dwick opened this issue Apr 6, 2022 · 2 comments

Comments

@ch4dwick
Copy link

ch4dwick commented Apr 6, 2022

I have the following setup in my local machine:

docker0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        inet 172.17.0.1  netmask 255.255.0.0  broadcast 172.17.255.255
        inet6 fe80::42:d3ff:fef3:bb65  prefixlen 64  scopeid 0x20<link>
        ether 02:42:d3:f3:bb:65  txqueuelen 0  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 3  bytes 306 (306.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

ens4: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1460
        inet 10.148.0.5  netmask 255.255.255.255  broadcast 0.0.0.0
        inet6 fe80::4001:aff:fe94:5  prefixlen 64  scopeid 0x20<link>
        ether 42:01:0a:94:00:05  txqueuelen 1000  (Ethernet)
        RX packets 2897452  bytes 1906694558 (1.9 GB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 2811602  bytes 983938685 (983.9 MB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 129025  bytes 12076299 (12.0 MB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 129025  bytes 12076299 (12.0 MB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

Apparently, this library picked up docker0 as the IP and reported it to my remote system which resulted in it being unreachable.

@joakimunge
Copy link
Owner

Hey @ch4dwick

Thanks for reporting the issue. As of denoland/deno#13475, Deno now has support for fetching networkInterfaces natively, so this module is more than likely to be deprecated.

I'd recommend using that instead!

@ch4dwick
Copy link
Author

ch4dwick commented Apr 7, 2022

Great! Thanks for the update.

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