dns_ip6_qualify(3)
π dns_ip6_qualify β from the Library Functions Manual, bestie π
okay so picture this: you're in <libowfat/dns.h, it's giving resolver era, and you need a name qualified AND its IPv6 addresses looked up. that's literally this function's whole job. slay. π
β¨ NAME β¨
dns_ip6_qualify β qualify a name and look up IPv6 addresses π¦
πΈ SYNTAX πΈ
#include <libowfat/dns.h>
int dns_ip6_qualify(stralloc* out,stralloc* fqdn,
const stralloc* udn);
π« DESCRIPTION π«
so here's the vibe: dns_ip6_qualify takes the name udn, feeds it through qualification, and then looks up 16-byte IPv6 addresses for whatever comes out the other side. no cap. π₯
here's what it does with all of that:
- it puts the fully qualified domain name into
fqdn - it puts the concatenation of the IP addresses into
out - it returns
0
and if the domain doesn't exist in DNS, or it just has no IP addresses at all? out will be empty. it's giving ghosted. π
ngl the cute part is this: dns_ip6_qualify also looks up 4-byte IPv4 addresses and converts them into IPv4-mapped IPv6 addresses (::ffff:1.2.3.4) so that IPv6 apps get easy backwards compatibility. iconic behaviour, honestly. π
but bestie, listen β if dns_ip6_qualify has trouble with the qualification, or has trouble with DNS, or just runs out of memory, it returns -1 and sets errno appropriately. and here's the spicy bit: it may or may not change out and fqdn. so don't be out here assuming they're untouched, fr fr. π
β οΈ heads up:-1means something went wrong, andout/fqdnare in a maybe state. checkerrno, don't trust the buffers blindly. π
π QUALIFICATION π
for the full qualification lore, go read:
http://cr.yp.to/djbdns/qualification.html
π SEE ALSO π
and that's the whole page, bestie π«Ά straight from the Library Functions Manual, filed under dns_ip6_qualify(3) β no date on this one, she's timeless like that. go qualify something. πβ¨
π¦ where this page comes from
- alpine 3.24: libowfat-doc 0.34-r0 Β· GPL-2.0-only
- debian bookworm: libowfat-dev 0.32-4 Β· GPL-2.0-only
- debian trixie: libowfat-dev 0.32-5 Β· GPL-2.0-only
- nixos 26.05: libowfat 0.34
- nixpkgs unstable: libowfat 0.34
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- opensuse-leap 16.0: libowfat-devel 0.33-bp160.1.11 Β· GPL-2.0-only
- ubuntu noble: libowfat-dev 0.32-4.1build1 Β· GPL-2.0-only
- ubuntu questing: libowfat-dev 0.32-5
- ubuntu resolute: libowfat-dev 0.34-2 Β· GPL-2.0-only
- ubuntu stonking: libowfat-dev 0.34-2 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms