ldns-keygen(1)
β¨ ldns-keygen β bestie, it's a whole DNSSEC key generator β¨
okay so welcome to ldns-keygen(1), a general commands manual page, and honestly? she's iconic. sit down, grab a strawberry π, and let's get you generating key pairs like the main character you are.
π NAME π
ldns-keygen β generate a DNSSEC key pair π
πΈ SYNOPSIS πΈ
ldns-keygen [ OPTION ] DOMAIN
like. that's it. that's the whole vibe check. one domain, some options, go off. π
π¦ DESCRIPTION π¦
so ldns-keygen is the girl who makes a private/public keypair for you. when you run her, she's gonna create 3 files, no more no less:
- a
.keyfile with the public DNSKEY π - a
.privatefile with the private keydata π€« - a
.dsfile with the DS record of the DNSKEY record π
slay.
she can also be used to create symmetric keys (for TSIG, iykyk) β you just pick the right algorithm and she switches modes. the ones that do this:
hmac-md5.sig-alg.reg.inthmac-sha1hmac-sha224hmac-sha256hmac-sha384hmac-sha512
π¨ in that case, no DS record will be created and no .ds file. periodt. don't go looking for it, she didn't make one.
and then, the moment you've been waiting for: ldns-keygen prints the basename for the key files, and it looks like this:
K<name>+<alg>+<id>
no cap, that's the name she hands back to you. π«Ά
β¨ OPTIONS β¨
-a<algorithm>β create a key with this algorithm, bestie. if you literally just writelisthere, she'll give you a list of supported algorithms. several alias names are also accepted (from older versions and other software, we don't judge π), and the list she shows you gives names from the RFC. also? the plain algo number is accepted. yes really. π-b<bits>β use this many bits for the key length. that's it, that's the tea. β-kβ when you give her this, she generates a key signing key. and honestly it's lowkey a one-line change: this just sets the flag field to257instead of256in the DNSKEY RR in the.keyfile. tiny flag, big energy. π-rdeviceβ make ldns-keygen use this file to seed the random generator with. it defaults to/dev/random. keep her fed, she needs the entropy π-sβ she'll create symbolic links named.private(pointing to the new generated private key),.key(pointing to the public DNSKEY) and.ds(pointing to the file containing DS record data). symlink era π-fβ force symlinks to be overwritten if they exist. she's not asking permission, she's just doing it. π-vβ show the version and exit. quick lil peek, then she's out. π§
π AUTHOR π
Written by the ldns team as an example for ldns usage. honestly? they ate. π«Ά
π REPORTING BUGS π
found a bug? not on her watch, but also she needs to know. report bugs to <dns-team@nlnetlabs.nl>. be nice, she's trying her best π
π COPYRIGHT π
Copyright (C) 2005-2008 NLnet Labs. This is free software. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
π¨ bestie read that again: NO warranty. not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. like, at all. she said what she said. π
and that's the page, babe. πβ¨ this was ldns-keygen(1), dated 27 May 2008, from the ldns crew β go forth and generate keys, you absolute legend. π¦ππ
π¦ where this page comes from
- alpine 3.22: ldns-doc 1.8.4-r0 Β· BSD-3-Clause
- alpine 3.23: ldns-doc 1.8.4-r1 Β· BSD-3-Clause
- alpine 3.24: ldns-doc 1.8.4-r1 Β· BSD-3-Clause
- arch rolling: ldns 1.9.2-1 Β· custom:BSD
- debian trixie: ldnsutils 1.8.4-2+b1
- fedora 43: ldns-utils 1.8.4-8.fc43 Β· BSD-3-Clause
- fedora 43: ldns-utils 1.9.2-1.fc43 Β· BSD-3-Clause
- fedora 44: ldns-utils 1.9.0-2.fc44 Β· BSD-3-Clause
- fedora 44: ldns-utils 1.9.2-1.fc44 Β· BSD-3-Clause
- nixos 26.05: ldns 1.9.2
- nixpkgs unstable: ldns 1.9.2
- opensuse-leap 16.0: ldns 1.8.4-160000.3.1 Β· BSD-3-Clause
- opensuse-leap 16.0: ldns 1.8.4-160000.3.1 Β· BSD-3-Clause
- opensuse-leap 16.0: ldns 1.8.4-160000.3.1 Β· BSD-3-Clause
- opensuse-leap 16.0: ldns 1.8.4-160000.3.1 Β· BSD-3-Clause
- ubuntu questing: ldnsutils 1.8.4-2build1
- ubuntu resolute: ldnsutils 1.8.4-2build3
- ubuntu stonking: ldnsutils 1.9.2-1ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms