1CRYPTSETUP-LUKSREMOVEKEY(8)  Maintenance Commands  CRYPTSETUP-LUKSREMOVEKEY(8)
2
3
4

NAME

6       cryptsetup-luksRemoveKey - remove the supplied passphrase from the LUKS
7       device
8

SYNOPSIS

10       cryptsetup luksRemoveKey [<options>] <device> [<key file with
11       passphrase to be removed>]
12

DESCRIPTION

14       Removes the supplied passphrase from the LUKS device. The passphrase to
15       be removed can be specified interactively, as the positional argument
16       or via --key-file.
17
18       <options> can be [--key-file, --keyfile-offset, --keyfile-size,
19       --header, --disable-locks, --type, --timeout, --verify-passphrase].
20
21       WARNING: If you read the passphrase from stdin (without further
22       argument or with '-' as an argument to --key-file), batch-mode (-q)
23       will be implicitly switched on and no warning will be given when you
24       remove the last remaining passphrase from a LUKS container. Removing
25       the last passphrase makes the LUKS container permanently inaccessible.
26

OPTIONS

28       --type <device-type>
29           Specifies required device type, for more info read BASIC ACTIONS
30           section in cryptsetup(8).
31
32       --verify-passphrase, -y
33           When interactively asking for a passphrase, ask for it twice and
34           complain if both inputs do not match. Ignored on input from file or
35           stdin.
36
37       --key-file, -d name
38           Read the passphrase from file.
39
40           If the name given is "-", then the passphrase will be read from
41           stdin. In this case, reading will not stop at newline characters.
42
43           With LUKS, the passphrase supplied via --key-file is always the
44           existing passphrase requested by a command, except in the case of
45           luksFormat where --key-file is equivalent to the positional key
46           file argument.
47
48           If you want to set a new passphrase via key file, you have to use a
49           positional argument to luksAddKey.
50
51           See section NOTES ON PASSPHRASE PROCESSING in cryptsetup(8) for
52           more information.
53
54       --keyfile-offset value
55           Skip value bytes at the beginning of the key file.
56
57       --keyfile-size, -l value
58           Read a maximum of value bytes from the key file. The default is to
59           read the whole file up to the compiled-in maximum that can be
60           queried with --help. Supplying more data than the compiled-in
61           maximum aborts the operation.
62
63           This option is useful to cut trailing newlines, for example. If
64           --keyfile-offset is also given, the size count starts after the
65           offset.
66
67       --timeout, -t <number of seconds>
68           The number of seconds to wait before timeout on passphrase input
69           via terminal. It is relevant every time a passphrase is asked. It
70           has no effect if used in conjunction with --key-file.
71
72           This option is useful when the system should not stall if the user
73           does not input a passphrase, e.g. during boot. The default is a
74           value of 0 seconds, which means to wait forever.
75
76       --header <device or file storing the LUKS header>
77           Use a detached (separated) metadata device or file where the LUKS
78           header is stored. This option allows one to store ciphertext and
79           LUKS header on different devices.
80
81           For commands that change the LUKS header (e.g. luksAddKey), specify
82           the device or file with the LUKS header directly as the LUKS
83           device.
84
85       --disable-locks
86           Disable lock protection for metadata on disk. This option is valid
87           only for LUKS2 and ignored for other formats.
88
89           WARNING: Do not use this option unless you run cryptsetup in a
90           restricted environment where locking is impossible to perform
91           (where /run directory cannot be used).
92
93       --batch-mode, -q
94           Suppresses all confirmation questions. Use with care!
95
96           If the --verify-passphrase option is not specified, this option
97           also switches off the passphrase verification.
98
99       --debug or --debug-json
100           Run in debug mode with full diagnostic logs. Debug output lines are
101           always prefixed by #.
102
103           If --debug-json is used, additional LUKS2 JSON data structures are
104           printed.
105
106       --version, -V
107           Show the program version.
108
109       --usage
110           Show short option help.
111
112       --help, -?
113           Show help text and default parameters.
114

REPORTING BUGS

116       Report bugs at cryptsetup mailing list <cryptsetup@lists.linux.dev> or
117       in Issues project section
118       <https://gitlab.com/cryptsetup/cryptsetup/-/issues/new>.
119
120       Please attach output of the failed command with --debug option added.
121

SEE ALSO

123       Cryptsetup FAQ
124       <https://gitlab.com/cryptsetup/cryptsetup/wikis/FrequentlyAskedQuestions>
125
126       cryptsetup(8), integritysetup(8) and veritysetup(8)
127

CRYPTSETUP

129       Part of cryptsetup project <https://gitlab.com/cryptsetup/cryptsetup/>.
130
131
132
133cryptsetup 2.5.0                  2022-07-28       CRYPTSETUP-LUKSREMOVEKEY(8)
Impressum