fscrypt_add_test_dummy_key(9)
β¨ fscrypt_add_test_dummy_key β¨
okay so bestie, this one is straight out of the Kernel API Manual, section 9 β the page is literally called fscrypt_add_test_dummy_key(9), yes the title is the function name, the kernel does that, we stan a consistent naming convention π
πΈ NAME πΈ
fscrypt_add_test_dummy_key β add the test dummy encryption key π
π SYNOPSIS π
int fscrypt_add_test_dummy_key(struct super_block *sb, struct fscrypt_key_specifier *key_spec);
π«Ά ARGUMENTS π«Ά
sbβ the filesystem instance you're adding the key to, like the whole vibe container πkey_specβ the key specifier of the test dummy encryption key π
π DESCRIPTION π
So what she does: she adds the key for the test_dummy_encryption mount option to the filesystem. periodt.
But here's the iconique part β to prevent misuse of this mount option, a per-boot random key is used instead of a hardcoded one. not me being grateful for that fr fr π₯
And the way that works out is: this makes it so that any encrypted files created using this option won't be accessible after a reboot. gone. deleted. not coming back π so like, don't get attached to your test files, they're giving fleeting main character energy.
no cap, that's the actual design β the key is per-boot and random, so post-reboot access is a no π«
β RETURN β
0 on success, -errno on failure. that's the whole report card π
π SEE ALSO π
Kernel file ./fs/crypto/keyring.c β go read her, she ate π¦
mwah π that's the whole page, sourced from ./fs/crypto and dated October 2026, signed off from the Kernel API Manual by yours truly β happy key-adding bestie πβ¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms