-
Notifications
You must be signed in to change notification settings - Fork 4
rofl0r/firedns
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
FireDNS Library --------------- (c) 2002 Ian Gulliver, (C) 2011, 2013 rofl0r GNU Public License, Version 2 or 3 at the users choice. with written permission of 2013-12-17 by Ian Gulliver: "I hereby grant a public, irrevocable license to use any and all versions of the firedns library under the terms of the GNU Public License version 2 or version 3, at the option of the user." See GPL for more details. the code written by rofl0r is dual-licensed under LGPL 2.1+, and GPL2+. libfiredns is a library for handling asynchronous DNS requests. It provides a very simple interface for sending requests and parsing reponses, as well as low-timeout blocking functions. libfiredns functions have much lower timeouts than the stock functions and tend to be faster because they send requests to all configured system nameservers at the same time. this version here differs from the original in several ways: 1) doesn't depend on firestring and firemake 2) no global state 3) factored and optimized for small static linkage 4) can be combined with libulz for even smaller static linkage (optional) 5) no dynamic allocation to avoid linking in malloc implementations (the code in firedns_add_servers_from_resolv_conf(), unless USE_LIBULZ is defined, uses FILE* based stdio functions though which cannot be implemented without malloc(). if you want to avoid the dependency, you can add your own servers instead of parsing resolv.conf, for example 8.8.8.8) 6) allows to define the used nameservers manually instead of relying on an existing resolv.conf. when to use it ? - if you feel your libc's DNS implementation is too slow for you, - if you feel your libc's DNS implementation pulls in too much code into static binaries, - if you need additional functionality such as MX records, ... compilation: there are 2 ways to build firedns, - using GNU make just type "make" to compile and "make prefix=/usr/local DESTDIR=test install" to install. if you want to add custom CFLAGS, put them into a file called config.mak for example: CFLAGS += -DUSE_LIBULZ LDFLAGS = -static -lulz # WARNING: currently some stuff of the library (including in the headers) is # only compiled in when -DHAVE_IPV6 is in CFLAGS! # programs linked against firedns require to use the same setting. # if HAVE_IPV6 is used in the one, but not the other, it will crash # (see issue #1). # the library was heavily optimized for minimal linkage (in the order of 1-2KB # added for a program using it), and is designed to be used as source via RcB2. - using RcB2 ( https://github.com/rofl0r/rcb2 ) the code has the necessary RcB2 tags so RcB2 finds all required TUs automatically when pointing it at the main.c file. contact: Quote from original author: If you have questions or comments, you can reach me at [email protected]. whether that email address still works, is another question. for this project, use the github issue tracker for communication.
About
relatively sane looking dns library. forked and splitted source into one C file per function for smaller linkage.
Topics
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published