Data Security: Cryptsetup
Cryptsetup
according to the MAN page:
cryptsetup - manage plain dm-crypt and LUKS encrypted volumes
..cryptsetup is used to conveniently setup dm-crypt managed device-mapper mappings. These include plain dm-crypt volumes and LUKS volumes. The difference is that LUKS uses a metadata header and can hence offer more features than plain dm-crypt...
• Installing
Cryptsetup:
sudo apt install cryptsetup ***SETUP***
• Creating a container: dd if=/dev/urandom of=~/my_encrypted_drive.dd bs=1M count=256 • Format it:
sudo cryptsetup luksFormat ~/my_encrypted_drive.dd • Opening it:
sudo cryptsetup luksOpen ~/my_encrypted_drive.dd my_drive my_drive will appear in /dev/mapper/.
• Create a filesystem within it:
mkfs -t ext4 /dev/mapper/my_drive • Mount the container:
sudo mount -t ext4 /dev/mapper/my_drive ~/mnt/ ***Consequence run***
sudo cryptsetup luksOpen ~/my_encrypted_drive.dd my_drive sudo mount -t ext4 /dev/mapper/my_drive~/mnt/ • Unmounting:
sudo umount ~/mnt/ sudo cryptsetup luksClose my_drive • Changing Password/Passphrase:
sudo cryptsetup luksChangeKey my_encrypted_drive.dd • for more usage and help:
cryptsetup --help man cryptsetup Read more at Cryptsetup Homepage and Wikipedia .
note:
device =>
my_encrypted_drive.dd
Disclaimer