My experience with #FlashDrives recently has been mixed. I have no problem in encrypting them with #LUKS, using #cryptsetup or with formatting a partition with #Btrfs, for instance, using #gparted and doing other tinkering with #Gnome #disks. But the problem has been with the actual drives themselves. The cheaper ones seem to have quite a few bad sectors, etc. and so they’re not really reliable for medium term storage.
1/2
In case someone else is wondering why linux luks
hard disk encryption is usually within a lvm
container: that way you only need one password to unlock multiple partitions.
(found out the hard way)
So today I tired #mkfs.btrfs and this works. I was using #gparted, which can’t create #encrypted file systems and so I created a blank (cleared) one, used #cryptsetup to create the #encryption on the device, and then created the brtrfs file system.
Зашифрованные флешки и переносные hdd, поддерживаются почти всеми линуксами «из коробки».
Если на windows’ах для работы с флешкой использовалось #VeraCrypt или даже #TrueCrypt, то на linux-системах с этой же флешкой можно и через #cryptsetup работать. Без надобности устанавливать дополнительные приложения, сродни того же VeraCrypt.
Подключить целиком зашифрованную флешку:
sudo cryptsetup open --type tcrypt /dev/sdXY myconfidential
sudo mkdir /mnt/secureflash
sudo mount /dev/mapper/myconfidential /mnt/secureflash
sudo umount /mnt/secureflash
sudo cryptsetup close myconfidential
/mnt/secureflash
./dev/sdXY
числится флешка, то поможет: lsblk -f
или что-то схожее, на вкус и цвет более подходящее.Does someone have a working #nixos setup where they decrypt their drive via #cryptsetup that they access remotely via #tailscale?
That's what I am building for my new working machine.
Also WakeOnLan (via local network though).
:boost_ok: #followerpower
Does someone have a working #nixos setup where they decrypt their drive via #cryptsetup that they access remotely via #tailscale?
That's what I am building for my new working machine.
Also WakeOnLan (via local network though).
:boost_ok: #followerpower
USBのケースに2.5インチHDDを?
?れて初期化しました.
LUKSで暗号化のためにCryptsetupを,透過圧縮,重複排除も使いたいということでBtrFSを利用しました.
[…]
https://matoken.org/blog/2024/11/12/initialize-usb-hdd-with-luks-btrfs/
Восстановление данных с зашифрованного Linux тома с помощью cryptsetup
В этой статье мы разберем восстановление данных с зашифрованного с помощью LUKS тома NAS. Внимание : в самом худшем случае для восстановления данных этим способом потребуется свободное место равное двум объемам зашифрованного раздела. Например, если у вас есть зашифрованный раздел на 1 ТБ, то необходимо иметь 2 ТБ свободного места. В лучшем случае (незначительные повреждения) понадобится один объем свободного дискового пространства. Также обращаем внимание, что вам НУЖНО ЗНАТЬ пароль, который использовался для шифрования тома Для примера мы будем использовать диск от QNAP с зашифрованном разделом. 1. Подключаем диск от QNAP к компьютеру с помощью USB или SATA. После чего нужно любым доступным способом создать образ зашифрованного раздела. Для примера мы будем использовать программу Vолга. Выбираем раздел QNAP и начинаем создание образа. Мы советуем сохранить образ в формате .img (посекторный RAW образ) на любой внешний диск.
https://habr.com/ru/articles/855290/
#Шифрование #luks #cryptsetup #зашифрованный_раздел #восстановление_данных #расшифровка_данных
#Fedora #Kinoite #Anaconda still has the same bug as half a year ago...
https://bugzilla.redhat.com/show_bug.cgi?id=2297460
Doing my "zygote" trick again, small install of Kinoite on a secondary SSD, cloning with #clonezilla, #btrfs resizing and balance, done.
Luckily I dont use that install much, and #cryptsetup allows to change the password.
#Linux just always finds a way!
TIL: If you want to `cryptsetup open` a BitLocker encrypted drive using the recovery key (8 blocks of 6 digits each), make sure to enter it _with_ the dashes between each block of digits, else it won't be recognized.
Dear fellow #linux #cryptsetup users, I need your assistance while I'm trying to encrypt my root partition:
The Arch Linux wiki (https://wiki.archlinux.org/title/Dm-crypt/Device_encryption#Re-encrypting_devices) has some guide to first unmount and then shrink the partition before reencryption, but then it has a header saying "cryptsetup 2.2 using LUKS2 supports online encryption/decryption/reencryption". Does that mean I can skip the unmount and resize, and just run the reencrypt command when the OS is still running on that partition?
Had fun and games trying to unmount my work volume (a LUKS loopback device) today… `cryptsetup` telling me the device was in-use. (But it wasn't!)
As it happens, kernel namespaces can make things appear to be "in use" when they are not, and Gentoo's Portage uses namespaces to isolate the build process from the host system. Kill the build, and you'll be able to unmount and de-activate the encrypted volume.
https://forums.gentoo.org/viewtopic-p-8479896.html?sid=fc640855d942c63b54512d9d7f4e8285#8479896
hey neat, Linux 6.10 improved disk encryption performance on my system by ~42% https://gist.github.com/lucaswerkmeister/965d312193362ccfea6378006ce8cb81
Quick guide on encrypting an external drive. Assuming the drive is at /dev/sda with a /dev/sda1 partition
Set up encrypted volume (-y for verifying the password)
# cryptsetup luksFormat -y -v /dev/sda1
Unlock the encrypted volume and create a mapping to /dev/mapper/DUDE
# cryptsetup luksOpen /dev/sda1 DUDE
Create a file system
# mkfs.ext4 /dev/mapper/DUDE
Mount the partition
# mkdir /mnt/DUDE
# mount /dev/mapper/DUDE /mnt/DUDE