found free loop device:
losetup -f
encryption with losetup:
insmod loop.o
insmod des.o
insmod cryptoloop.o
dd if=/dev/urandom of=crypto.img bs=1M count=50
losetup -e blowfish /dev/loop0 crypto.img
mkfs -t ext2 /dev/loop0
losetup -d /dev/loop0 # delete
mount -o encryption=aes256 crypto.img crypto_home
encryption with bind drive:
losetup -e aes256 /dev/loop0 /dev/sda1
losetup -d /dev/loop0
mount -o encryption=aes256 /dev/sda1 crypto_home
resizing the image:
dd if=/dev/urandom bs=1M count=20 >> crypto.img
losetup -e aes256 /dev/loop0 crypto.img
ext2resize /dev/loop0
encrypt/decrypt with openssl:
openssl enc -aes-256-cbc -salt -in password.txt -out password.txt.enc
openssl enc -d -aes-256-cbc -in password.txt.enc -out password.txt
echo "put /bla/bl/das.log.gz /bls/bl2/dies.log.bz2" >> $TFTPSCRIPT
tftp $TFTPSRV < $TFTPSCRIPT
uuencode $FWLOG/old/$BLA.log.gz $BLA.log.gz | mail -s "FWEXPORT $EXPORTNAME.log.gz" $MAILRECPT
Keine Kommentare:
Kommentar veröffentlichen