LUKS management functions.
Adds new password to LUKS format. Each format can have up to 8 separate passwords and any of them can be used to open(decrypt) the format.
Any existing passphrase must be provided to add a new one. This proves the caller is authorized to add new passphrase (because it already knows one) and also this 'old' passphrase is used to retrieve encryption keys. This 'old' passphrase is not removed nor replaced when adding new passphrase!
Parameters: |
|
---|
Closes clear-text block device previously opened by open_luks().
Parameters: | fmt (LMIInstance/LMI_EncryptionFormat or string) -- The LUKS format to close. |
---|
Format given device with LUKS encryption format. All data on the device will be deleted! Encryption key and algorithm will be chosen automatically.
Parameters: |
|
---|---|
Return type: | LMIInstance/LMI_EncryptionFormat |
Delete passphrase from LUKS format.
Parameters: |
|
---|
Return clear-text device for given LUKS format. The format must be already opened by open_luks().
Parameters: | fmt (LMIInstance/LMI_EncryptionFormat or string) -- The LUKS format to inspect. |
---|---|
Return type: | LMIInstance/LMI_LUKSStorageExtent |
Returns: | Block device with clear-text data or None, if the LUKS format is not open. |
Retrieve list of all encrypted devices.
Return type: | list of LMIInstance/LMI_EncryptionFormat. |
---|
Each LUKS format can have up to 8 passphrases. Any of these passphrases can be used to decrypt the format and create clear-text device.
This function returns number of passphrases in given LUKS format.
Parameters: | fmt (LMIInstance/LMI_EncryptionFormat or string) -- The LUKS format to inspect. |
---|---|
Return type: | int |
Returns: | Number of used passphrases. |
Open encrypted LUKS format and expose it as a clear-text block device.
Parameters: |
|
---|---|
Return type: | LMIInstance/LMI_LUKSStorageExtent |
Returns: | The block device with clear-text data. |