Update cheatsheets

This commit is contained in:
ivuorinen
2024-02-21 11:19:49 +00:00
parent 4e88a1b42f
commit 3d653cc7e6
4803 changed files with 127002 additions and 0 deletions

25
linux/cryptsetup Normal file
View File

@@ -0,0 +1,25 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# cryptsetup
> Manage plain dm-crypt and LUKS (Linux Unified Key Setup) encrypted volumes.
> More information: <https://gitlab.com/cryptsetup/cryptsetup/>.
- Initialize a LUKS volume (overwrites all data on the partition):
`cryptsetup luksFormat {{/dev/sda1}}`
- Open a LUKS volume and create a decrypted mapping at `/dev/mapper/target`:
`cryptsetup luksOpen {{/dev/sda1}} {{target}}`
- Remove an existing mapping:
`cryptsetup luksClose {{target}}`
- Change the LUKS volume's passphrase:
`cryptsetup luksChangeKey {{/dev/sda1}}`