BORE(1)

NAME
bore - DNS query tool

SYNOPSIS
bore [--encode | --decode | --show-resolvers] [--load] [--dump] [--host host] [--port port] [--timeout timeout] [-x | --reverse] [--class class] [--color when] [@host] [name] [type]

DESCRIPTION
Sends a DNS query and prints the response in zone format.

If no host is given, bore uses your system’s resolvers, which are gathered from GetAdaptersAddresses on Windows, dns_configuration_copy on macOS, or resolv.conf(5) on other Unix-like platforms, falling back on localhost.

Note that your platform’s native name resolution probably supports other sources besides DNS, such as a hosts(5) file or mDNS (Bonjour). bore only uses native resolution for host itself, and otherwise only sends DNS queries, so the results may differ from how your system would resolve a name as a hostname.

By default, bore will follow four steps:

1.  build a query based on the given arguments

2.  send the query to the given host

3.  receive a response from the given host

4.  decode and pretty-print the message

OPTIONS
The following options and positional arguments may be given in any order.

  Positional arguments

@host
    Sends the query to host (see --host).

name [default: .]
    Question name. Names are parsed in zone format, with dots separating labels unless escaped, \000 through \255 to escape an octet, and \x with any non-digit character ‘x’ to escape that character. When --reverse is given, name is required, and should instead be an IPv4 or IPv6 address.

    A trailing dot must be added when querying top-level domains, otherwise they will be treated as a type (and probably fail). Names starting with ‘@’ must be escaped, otherwise they will be treated as a @host.

type [default: A]
    Question type. The default is ‘PTR’ if --reverse is given, or ‘A’ if a name is given, or ‘NS’ otherwise. For unknown types, use ‘TYPE’ followed by the type number, e.g. ‘type65535’.

  Mode options

--encode
    Writes the raw query to stdout, instead of sending it (step 1 only).

--load
    Reads the raw query from stdin, instead of building one (skip step 1).

--dump
    Writes the raw response to stdout, instead of pretty-printing it (skip step 4).

--decode
    Reads a raw message from stdin, then decodes and pretty-prints it (step 4 only).

--show-resolvers
    Prints details about your system’s resolvers, and a list of hosts we would actually send queries to (after taking --host and --port into account), without doing anything else.

  Network options

--host host
    Sends the query to host, instead of your system’s resolvers. If host is a domain name, we use your platform’s native name resolution to turn it into a list of IP addresses.

--port port [default: 53]
    Sends the query to the given port. The default is port 53, or on macOS, the custom port (if any) that each of your system’s resolvers and nameservers is configured to use.

--timeout timeout [seconds; default: 5]
    Give up on waiting for the query after timeout seconds, and if there are more hosts available, try the next one. This timeout spans the whole query attempt, so the query needs to be sent and a response received within that time.

  Building queries

-x | --reverse
    Makes a reverse DNS query, converting name (required) from an IP address to a domain name in ‘in-addr.arpa.’ (IPv4) or ‘ip6.arpa.’ (IPv6).

--class class [default: IN]
    Question class. For unknown classes, use ‘CLASS’ followed by the class number, e.g. ‘class65535’.

  Other options

--color <auto | never | always> [default: auto]
    Controls when to use colours or other text styles. In auto mode, we decide whether or not to use them as follows:

    •   no, if standard output is not a tty (Unix) or console (Windows)

    •   no, if the environment has TERM=dumb (all platforms)

    •   no, if the environment has no TERM (Unix)

    •   yes, otherwise

SEE ALSO
hosts(5), resolv.conf(5)

AUTHORS
bore is written and maintained by Delan Azabani <delan@azabani.com>.