Skip to content

Simple DNS Client & Library in pure Nim

License

Notifications You must be signed in to change notification settings

Menduist/dnsclient.nim

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dnsclient

Simple DNS Client and library in pure Nim

Installation

$ nimble install dnsclient

Usage

This is a hybird repo, contains a command line DNS client and library for DNS query. For now, only some simple records are supported, but adding new records is very simple.

Feel free to make PR or raise an issue as your need!

CLI

$ dnsclient TXT txt.example.huy.im

Library

import dnsclient

let client = newDNSClient()
let resp = client.sendQuery("txt.example.huy.im", TXT)
assert resp.answers[0].kind == TXT
let rr = TXTRecord(resp.answers[0])
assert rr.data == "dnsclient.nim"

About

Simple DNS Client & Library in pure Nim

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Nim 100.0%