Command reference / DNS resolution

Resolve a hostname into a usable IPv4 address.

The hping resolve subcommand provides a compact way to ask the DNS system for a hostname’s IPv4 address. If the supplied value is already an address, it can pass that value through unchanged.

Hping resolve

What the command does

hping resolve hostname translates a host name into its IPv4 address through the system’s DNS facilities. Conceptually, it is a small wrapper around the host-resolution function commonly exposed as gethostname().

This makes the command useful when a later packet test expects an IPv4 destination. A value that is already formatted as an IPv4 address does not need another lookup and may simply be returned as supplied.

resolver-session — example
$ hping resolve example.net
198.51.100.24

$ hping resolve 203.0.113.7
203.0.113.7

Interpreting the result

The returned address reflects the resolver configuration and network conditions available to the machine running the command. Hostnames can have multiple records, answers can change over time, and local caches or policy controls can affect the result.

Use a controlled scopeResolve names and perform subsequent packet tests only for systems you own or are explicitly authorized to assess. Avoid placing private hostnames, credentials, or sensitive resolver output in shared documentation.
Reference page · reviewed 06 Oct 2026
← Return to Tping documentation

Help improve the technical record.

Send corrections or compatibility observations without including credentials, private captures, or confidential network details.

Contact Tping