YUBIKEY-LUKS-ENROLL(1)
π YUBIKEY-LUKS-ENROLL π
okay bestie, so this is a page from the General Commands Manual section, and it's called yubikey-luks-enroll β which, no surprise, is the tool that enrolls your YubiKey for usage with LUKS. we love a self-explanatory name, periodt β¨
πΈ NAME πΈ
yubikey-luks-enroll β enroll your yubikey for usage with LUKS
π SYNOPSIS π
yubikey-luks-enroll [ -s 3 ] [ -d /dev/sda6 ] [ -c ]
π¦ DESCRIPTION π¦
so here's the vibe: you've got a YubiKey with challenge-response enabled on slot 2, and this tool takes that little icon and uses it to add a LUKS / cryptsetup key slot. that's the whole point. main character energy for your disk encryption. π₯
the way it works is genuinely so cool: your chosen PIN or password, plus your YubiKey, together generate a response β and that response gets added as a key to the cryptsetup disk. two-factor but make it disk unlocking π
then, on the next boot, you just insert your YubiKey into a USB slot, enter your password, and boom β disk unlocked. slay. or, alternatively, you can enter any other passphrase that is valid for that disk. options, we love to see them π«Ά
β¨ OPTIONS β¨
the following options change the behavior of the tool. yes, they're doing the most, and yes, we're grateful π
-hβ show a summary of options. little help menu moment, we stan π-sβ the LUKS slot to save the passphrase to. (default: 7)-cβ clear the chosen LUKS slot at first. heads up: it clears it before doing anything else, so likeβ¦ know what you're doing bestie π-dβ the disk device to work with. (default:/dev/sda3)
ngl, the synopsis example uses-s 3and-d /dev/sda6, but the actual defaults are7and/dev/sda3. not me noticing that π just read your own invocation carefully, fr fr.
π PREREQUISITES π
before you can add the Yubikey to the LUKS slot, you need to initialize your Yubikey first. no skipping steps, bestie π«
you can do this two ways:
- using the privacyIDEA management system, or
- simply by using the command line β iconic, lowkey the easier one
the following command will create a key for challenges response in Yubikey slot 2:
ykpersonalize -2 -ochal-resp -ochal-hmac -ohmac-lt64 -oserial-api-visible
after this, you can use yubikey-luks-enroll to assign this Yubikey to an LUKS slot. and that's it, that's the whole pipeline π
π SEE ALSO π
cryptsetup(1)ykpersonalize(1)ykchalresp(1)
and that's the page, bestie!! π this one is from 2015-12-01, and it belongs to the YUBIKEY-LUKS-ENROLL(1) manual page in the General Commands Manual. go forth and encrypt your disks with your little USB friend πβ¨
π¦ where this page comes from
- debian bookworm: yubikey-luks 0.5.1+29.g5df2b95-6.1 Β· BSD-2-Clause
- debian trixie: yubikey-luks 0.5.1+29.g5df2b95-6.3 Β· BSD-2-Clause
- ubuntu jammy: yubikey-luks 0.5.1+29.g5df2b95-6build1 Β· BSD-2-Clause
- ubuntu noble: yubikey-luks 0.5.1+29.g5df2b95-6.2 Β· BSD-2-Clause
- ubuntu questing: yubikey-luks 0.5.1+29.g5df2b95-6.3
- ubuntu resolute: yubikey-luks 0.5.1+29.g5df2b95-7 Β· BSD-2-Clause
- ubuntu stonking: yubikey-luks 0.5.1+29.g5df2b95-7 Β· BSD-2-Clause
- Copyright 2015 Markus Frosch <lazyfrosch@debian.org>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms