Fedora에서 부팅 드라이브 암호화를 위해 PKCS#11 스마트 카드를 사용하는 방법(35)

Fedora에서 부팅 드라이브 암호화를 위해 PKCS#11 스마트 카드를 사용하는 방법(35)

Fedora Workstation 35에서는 여기를 참조하세요. 시스템 v249

부팅 시 스마트 카드를 사용하여 루트 LUKS 볼륨의 잠금을 해제하려고 했지만 작동하지 않았습니다.

/etc/crypttab mydisk UUID=496e1cd5-712f-44ab-ad02-5fb6f7419af8 none pkcs11-token-uri=auto,luks,discard에 추가했습니다.

내 디스크는 sudo systemd-cryptenroll --pkcs11-token-uri=auto /dev/...를 사용하여 올바르게 등록되었으며 luksDump를 사용하여 슬롯에 넣을 수 있습니다. sudo /usr/lib/systemd/systemd-cryptsetup을 사용할 수 있음을 확인했습니다. pkcs11-uri=auto 없이 MountName /dev/... 마운트

재부팅 시 비밀번호 프롬프트가 나타납니다. 콘솔에는 다음이 표시됩니다.

암호화 설정을 입력하세요. 712f-44ab-ad02-5fb6f7419af8: 디스크 WDS의 비밀번호를 입력하세요...[디스크 모델]:

여기서는 복구 비밀번호만 유효합니다. 스마트 카드를 사용할 수 없으며 비밀번호를 입력할 수 없습니다.

동일한 스마트카드와 동일한 crypttab 방법을 사용하여 다른 드라이브(외장 HDD)의 잠금을 해제했는데 작동합니다(디스크에는 없지만 시작 시에만 설치하려고 할 때 디스크 앱에서 항상 비밀번호를 묻지만 이것은 또 다른 것입니다). 문제) . 이 스마트 카드는 Yubikey를 기반으로 합니다.

여기 발표에 따르면:https://www.phoronix.com/scan.php?pa...lock-encryption그리고 여기 사람들은:https://www.freedesktop.org/[이메일 보호됨] 이 기능이 작동해야 합니다. 나는 문서에서 인용하고 있습니다 :

In order to unlock a volume a password or binary key is required. [email protected] tries to acquire a suitable password or binary key via the following mechanisms, tried in order:

If a key file is explicitly configured (via the third column in /etc/crypttab), a key read from it is used. If a PKCS#11 token, FIDO2 token or TPM2 device is configured (using the pkcs11-uri=, fido2-device=, tpm2-device= options) the key is decrypted before use.

If no key file is configured explicitly this way, a key file is automatically loaded from /etc/cryptsetup-keys.d/volume.key and /run/cryptsetup-keys.d/volume.key, if present. Here too, if a PKCS#11/FIDO2/TPM2 token/device is configured, any key found this way is decrypted before use.

If the try-empty-password option is specified it is then attempted to unlock the volume with an empty password.

The kernel keyring is then checked for a suitable cached password from previous attempts.

Finally, the user is queried for a password, possibly multiple times, unless the headless option is set.

관련 정보