From 188702ed68f6218a819192699d6b6ec234bc4878 Mon Sep 17 00:00:00 2001 From: Ryan Lahfa Date: Sun, 31 Oct 2021 00:45:18 +0200 Subject: [PATCH] keyctl: add page (#7160) Thanks for your contribution. --- pages/linux/keyctl.md | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 pages/linux/keyctl.md diff --git a/pages/linux/keyctl.md b/pages/linux/keyctl.md new file mode 100644 index 000000000..766c2a681 --- /dev/null +++ b/pages/linux/keyctl.md @@ -0,0 +1,36 @@ +# keyctl + +> Manipulate the Linux kernel keyring. +> More information: . + +- List keys in a specific keyring: + +`keyctl list {{target_keyring}}` + +- List current keys in the user default session: + +`keyctl list {{@us}}` + +- Store a key in a specific keyring: + +`keyctl add {{type_keyring}} {{key_name}} {{key_value}} {{target_keyring}}` + +- Store a key with its value from standard input: + +`echo -n {{key_value}} | keyctl padd {{type_keyring}} {{key_name}} {{target_keyring}}` + +- Put a timeout on a key: + +`keyctl timeout {{key_name}} {{timeout_in_seconds}}` + +- Read a key and format it as a hex-dump if not printable: + +`keyctl read {{key_name}}` + +- Read a key and format as-is: + +`keyctl pipe {{key_name}}` + +- Revoke a key and prevent any further action on it: + +`keyctl revoke {{key_name}}`