Skip to content

thameera/dns-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dns-go

A DNS client written in Go, similar to dig. Attempts to follow the DNS specification at RFC 1035.

Downloading and building

Requires Go >=1.21.

git clone git@github.com:thameera/dns-go.git
go build .

Running

./dns-go [options...] <name> [type]

The only available option is -v which prints debug output when set.

Supported DNS types are A, AAAA, CNAME, and TXT.

Examples:

./dns-go example.com
example.com		19959	IN	A	93.184.216.34

./dns-go www.facebook.com
www.facebook.com		783	IN	CNAME	star-mini.c10r.facebook.com
star-mini.c10r.facebook.com		39	IN	A	157.240.8.35

./dns-go example.com txt
example.com		21600	IN	TXT
                                                v=spf1 -all
example.com		21600	IN	TXT	 wgyf8z8cgvm2qmxpnbnldrcltvk4xqfn

Running the tests

go test

Some tests use golden files to keep known good outputs. To update the golden files, run:

go test -update

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages