key_revoke(9)
π key_revoke(9) β like, the kernel API manual bestie β¨
okay so this is a page from the Kernel API Manual (key_revoke(9)) and honestly it's a short one but it eats. let's get into it π«Ά
πΈ NAME πΈ
key_revoke β revoke a key. that's it. that's the whole vibe. π
β¨ SYNOPSIS β¨
void key_revoke (struct key *key );
no return value, no drama, it just does the thing. iconic behavior honestly π
π ARGUMENTS π
keyβ the key you're revoking. the one getting yeeted. the main character of this whole operation π¦
π DESCRIPTION π
okay so here's what's actually happening, bestie. key_revoke marks a key as being revoked and then asks the type to free up its resources. so it's like, "hey, this key is done for βοΈ" and then it hands off the cleanup to whoever knows how to clean up that type. teamwork, no cap π€
and then β and this is the part you gotta remember β the revocation timeout is set, and the key and all its links will be automatically garbage collected after key_gc_delay amount of time, if they're not manually dealt with first.
read that again bestie. key_gc_delay. automatic garbage collection. the key AND all its links. if nobody deals with them manually, the kernel will do it for them. so like, you can do it yourself, but the timer is ticking the whole time πβ³
π¦ SEE ALSO π¦
all the siblings, in the kernel file ./security/keys/key.c:
key_alloc(9)key_payload_reserve(9)key_instantiate_and_link(9)key_reject_and_link(9)key_put(9)key_create_or_update(9)key_create(9)key_update(9)key_invalidate(9)generic_key_instantiate(9)register_key_type(9)unregister_key_type(9)
the whole friend group fr fr π
π« and that's the page!! brought to you by ./security/keys, dated October 2026, and it's giving kernel security realness. go revoke responsibly, bestie. mwah πβ¨
π¦ 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