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

Pinger.New() can only create privileged icmp.PacketConn #12

Open
realnedsanders opened this issue May 31, 2019 · 0 comments
Open

Pinger.New() can only create privileged icmp.PacketConn #12

realnedsanders opened this issue May 31, 2019 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@realnedsanders
Copy link

Pinger.New() runs connectICMP() which runs icmp.ListenPacket(network, address) using static value "ip4:icmp" as network. Per icmp.ListenPacket() def, this only allows usage of privileged endpoints.

ListenPacket listens for incoming ICMP packets addressed to address. See net.Dial for the syntax of address.

For non-privileged datagram-oriented ICMP endpoints, network must be "udp4" or "udp6". The endpoint allows to read, write a few limited ICMP messages such as echo request and echo reply. Currently only Darwin and Linux support this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants