informatique:securite:luksfs

no way to compare when less than two revisions

Différences

Ci-dessous, les différences entre deux révisions de la page.


informatique:securite:luksfs [2016/06/01 16:35] (Version actuelle) – créée bn8
Ligne 1: Ligne 1:
 +====== Luks FS ======
 +
 +===== Formater la partition =====
 +
 +<code bash>pwgen -1 > /root/.luks.pwd
 +# Format partition
 +cryptsetup -q --use-urandom luksFormat /dev/vg/lv /root/.luks.pwd
 +
 +# Creating random keyfile for crypted partition
 +dd if=/dev/urandom of=/root/.luks.key bs=1024 count=4
 +
 +# Setting permission on key/pass files
 +chmod 0500 /root/.luks.pwd /root/.luks.key
 +
 +#Add new key on crypted partition
 +cryptsetup luksAddKey /dev/vg/lv
 +
 +# Active crypted partition
 +cryptsetup luksOpen /dev/vg/lv mylv --key-file /root/.luks.key
 +
 +# Creating Ext4 FS on crypted partition
 +mkfs.ext4 /dev/mapper/mylv
 +</code>
 +
 +===== Monter la partition chiffré =====
 +
 +**Remarque : ** A faire après le //cryptsetup luksOpen//.
 +
 +<code bash>mount /dev/mapper/mylv /mnt/mylv</code>
 +
 +===== Démonter la partition =====
 +
 +<code bash>umount /dev/mapper/mylv
 +cryptsetup close mylv</code>
 +
  
  • informatique/securite/luksfs.txt
  • Dernière modification : 2016/06/01 16:35
  • de bn8