<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Cryptoloop on Michael’s Domain</title><link>https://jeltsch.org/en/tags/cryptoloop/</link><description>Recent content in Cryptoloop on Michael’s Domain</description><generator>Hugo</generator><language>en-us</language><copyright>Copyright © 2002 - 2026 Michael Jeltsch.</copyright><lastBuildDate>Fri, 24 Jul 2026 00:18:18 +0300</lastBuildDate><atom:link href="https://jeltsch.org/en/tags/cryptoloop/index.xml" rel="self" type="application/rss+xml"/><item><title>cryptsetup</title><link>https://jeltsch.org/en/cryptsetup/</link><pubDate>Sun, 25 Jan 2009 00:00:00 +0000</pubDate><guid>https://jeltsch.org/en/cryptsetup/</guid><description>&lt;p&gt;I switched already quite a while ago from the old cryptoloop technology to the newer cryptsetup technology. However, I still forget how to manually create and mount encrypted volumes, because I do this rarely. Here are the commands:&lt;code&gt;cryptsetup create cryptovolume /dev/mapper/logical_volumemount /dev/mapper/cryptovolume /mountpoint&lt;/code&gt;In this case I mapped a logical volume, but of course you can map physical volumes, too:&lt;code&gt;cryptsetup create cryptovolume /dev/sdb1mount /dev/mapper/cryptovolume /mountpoint&lt;/code&gt;&lt;/p&gt;</description></item><item><title>Mounting disk image files and encrypted filesystems/partitions</title><link>https://jeltsch.org/en/mounting_disk_image_files_and_encrypted_filesystems_partitions/</link><pubDate>Sat, 26 May 2007 00:00:00 +0000</pubDate><guid>https://jeltsch.org/en/mounting_disk_image_files_and_encrypted_filesystems_partitions/</guid><description>&lt;p&gt;To dump a disk (or a partition) into a file, you use the following command:&lt;code&gt;dd if=/dev/hda3 of=file.bin&lt;/code&gt;This command writes the complete data on the hda3 partition into the file file.bin.To mount the filesystem that is in the file, you need to create a loopback device:&lt;code&gt;losetup /dev/loop0 file.bin&lt;/code&gt;Now you can mount the filesystem as usual:&lt;code&gt;mount -r -t filesystemtype /dev/loop0 /mnt/mountpoint&lt;/code&gt;Apparently, one can combine the last two commands into one:&lt;code&gt;mount -t filesystemtype -o loop ./file.bin /mnt/mountpoint&lt;/code&gt;If you want to encrypt the data on a file, that contains a whole filesystem, it is getting a bit more complicated:&lt;code&gt;sudo mkdir /mnt/secure (create mount point for the filesystem)dd if=/dev/zero of=path/to/file bs=1k count=409600 (create an empty file with 400 MB size) sudo /sbin/losetup -e xor /dev/loop0 path/to/file/sbin/mkfs -t ext2 /dev/loop0 409600 (format the device as ext2)sudo mount -t ext2 /dev/loop0 /mnt/secure (mount the device file)cd /mnt/securechown username . (change the owner of the top level directory of the filesystem)&lt;/code&gt;If you want to unmount the filesystem:&lt;code&gt;sudo umount /dev/loop0&lt;/code&gt;If you want to get rid of the filesystem, you have to un-associate it from the loop device 0: &lt;code&gt;/sbin/losetup -d /dev/loop0&lt;/code&gt;For some reason RedHat 9 doesn&amp;rsquo;t come with DES support, so for the time being (until I patch the kernel or move to Suse Linux) I am using the faster, but much weaker xor encryption.Suse 9 comes with inbuilt strong encryption and offers already during the installation the possibility to create an encrypted partition. Suse 9 asks during booting for the passphrase to mount the encrypted filesystem. The boot process stops and waits for 2 minutes before continuing if you don&amp;rsquo;t type in the password. In order to reduce this time, you can edit the file /etc/init.d/boot.crypto. Change in the following line 120 to e.g. 10:&lt;code&gt;:${TIMEOUT:=120}&lt;/code&gt;If you have missed your chance to type in the passphrase during boot time, you can mount the encrypted partition as follows:&lt;code&gt;/sbin/losetup -e twofish /dev/loop0 /dev/hda7 mount /dev/loop0 /media/conf&lt;/code&gt;BTW: The information about encrypted filesystems resides in /etc/cryptotab.&lt;/p&gt;</description></item><item><title>Mouting of encrypted partitions under SuSE 9.3 (losetup, cryptotab, twofish256, twofishSL92)</title><link>https://jeltsch.org/en/mouting_of_encrypted_partitions_under_suse_9_3_losetup_cryptotab_twofish256_twofishsl92/</link><pubDate>Wed, 04 Apr 2007 00:00:00 +0000</pubDate><guid>https://jeltsch.org/en/mouting_of_encrypted_partitions_under_suse_9_3_losetup_cryptotab_twofish256_twofishsl92/</guid><description>&lt;p&gt;I have one encrypted partition that was created under SuSE 9.2. After a fresh install of 9.3 (not an update) the mounting of that partition during bootup failed. I could, however, still mount it manually later using another loopdevice. To fix this, I had to change the encryption algorithm in /etc/cryptotab from twofish256 to twofishSL92. 
 &lt;a href="http://suse-linux-faq.koehntopp.de/q/q-suse93-cryptofs.html" target="_blank" rel="noopener noreferrer nofollow"&gt;More detailed information&amp;nbsp;






 
 
 
 &lt;svg class="svg-inline--fa fas fa-up-right-from-square fa-2xs" fill="currentColor" aria-hidden="true" role="img" viewBox="0 0 512 512" overflow="visible"&gt;&lt;use href="#fas-up-right-from-square"&gt;&lt;/use&gt;&lt;/svg&gt;&lt;/a&gt;
.&lt;/p&gt;</description></item></channel></rss>