simple-ping

command module
v0.0.0-...-63ff7ac Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 21, 2021 License: CC0-1.0 Imports: 9 Imported by: 0

README

Icmp client

A very simplified IPv4 ping clone written in Golang for Linux systems.

How it works

  • It implements the IPv4 protocol and the ECHO and ECHO REPLY message formats of the ICMP protocol.

  • It accepts IPv4 addresses and domain names, such as google.com, microsoft.com, etc.

  • It uses a default packet size of 84 bytes (IPv4 (20 bytes) + ICMP[headers (8 bytes) + [data + padding] (56 bytes)]).

  • The data field contains a struct timeval with the current timestamp.

Build

To build this software, you will need root priviledges. The root priviledges are necessary because of the use of raw sockets that require a special capability called: CAP_NET_RAW.

In your terminal type: sudo make.

Input

Currently, the accepted parameters are:

  • -domain=<ipv4 address|domain name address>

  • -requests=<amount of requests>. Default is 2 requests

Screenshot

Usage

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL