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

ping3 does not support IPv6 #64

Open
amorozenko-ua opened this issue Sep 26, 2022 · 2 comments
Open

ping3 does not support IPv6 #64

amorozenko-ua opened this issue Sep 26, 2022 · 2 comments

Comments

@amorozenko-ua
Copy link

According socket function documentation ( used by send_one_ping call) IPv6 support can be simply added by using getaddrinfo.

socket.gethostbyname(hostname)

    Translate a host name to IPv4 address format. The IPv4 address is returned as a string, such as '100.50.200.5'. If the host name is an IPv4 address itself it is returned unchanged. See [gethostbyname_ex()](https://docs.python.org/3/library/socket.html#socket.gethostbyname_ex) for a more complete interface. [gethostbyname()](https://docs.python.org/3/library/socket.html#socket.gethostbyname) does not support IPv6 name resolution, and [getaddrinfo()](https://docs.python.org/3/library/socket.html#socket.getaddrinfo) should be used instead for IPv4/v6 dual stack support.

Checksum calculations could be different for ipV6 packets - but potentially this might be investigated.
Exists probability that IPv6 support can be easily added to ping3 module.

@kyan001
Copy link
Owner

kyan001 commented Sep 26, 2022

Hi @amorozenko-ua

Thanks for the information, I will look into this and see what I can do.

@jason19970210
Copy link

I am wondering for this !!
tks

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

3 participants