Code: Select all
IUSE="crypt nls static pam selinux"Code: Select all
CRYPT_PATCH_P="${P}-cryptoapi-losetup"
SELINUX_PATCH="util-linux-2.12-selinux.diff.bz2"
DESCRIPTION="Various useful Linux utilities"
SRC_URI="mirror://kernel/linux/utils/${PN}/${P}.tar.gz
ftp://ftp.cwi.nl/pub/aeb/${PN}/${P}.tar.gz
crypt? ( mirror://gentoo/${CRYPT_PATCH_P}.patch.bz2 )"
HOMEPAGE="http://www.kernel.org/pub/linux/utils/util-linux/"
Yep, i think you are correct, so i have gone ahead and manually patched and installed it. Got a quick question though, at present i have the following entry in grub.conf:hulk2nd wrote:i'm nearly sure that is not the needed patch. you can try that easily: emerge util-linux and then type losetup. keep the output in your mind or on another console and then install util-linux after the tutorial (by hand) and type losetup. if the one installed by hand gives you another output (a few more options and a few more lines) then it is still needed to install it by hand. otherwise use the one from the portage tree.
greets,
hulk
Code: Select all
title Gentoo Testing (2.6.1-mm5)
root (hd0,0)
kernel (hd0,0)/boot/2.6.1-mm5 root=/dev/hde3 vga=792
Code: Select all
title=Gentoo/GNU Linux 1.4 Encrypted ROOT
root (hd0,0)
kernel (hd0,0)/bzImage root=/dev/ram0 init=/linuxrc rootfstype=minix
initrd=/initrd.gzCode: Select all
title Gentoo Testing Encrypted (2.6.1-mm5)
root (hd0,0)
kernel (hd0,0)/2.6.1-mm5 root=/dev/ram0 init=/linuxrc rootfstype=minix
initrd=/initrd.gz
Ok, cheers. I don't use genkernel but i manualy compile it, and then rename it to the kernel version and patch level, hence the name of it. I think i have it sorted, i shal probably know by tommorrow.hulk2nd wrote:i think you can leave the kernel part as it is. i assume you use genkernel? i have no experience with that, but if you compile your kernel on your own, it is always kernel (hd0,0)/bzImage or kernel (hd0,0)/boot/bzImage. it does not make any difference if you have the /boot in the line or not.
so, i think it is ok the way it is already. changes according to the place of your kernel are not needed for the whole encryption thing.
greets,
hulk
Code: Select all
I/O error
30623+1 records in
30623+1 records out...
i don't remember that i/o error ...kritip wrote:Code: Select all
I/O error 30623+1 records in 30623+1 records out...
Very odd, i poseted a big reply yesterday and it is nowhere to be seen!! Perhaps i hit preview and then closed the browser!!???hulk2nd wrote:i don't remember that i/o error ...kritip wrote:Code: Select all
I/O error 30623+1 records in 30623+1 records out...
in fact it doesn't look very well. i'm very sorry about that, i have no idea what to do ...
hope you backupped the important data ...
sorry
build-initrd.sh will be in your /tmp/enc/loop-AES-v2.0d/ directory, or whever you exxtracted it.franklin wrote:Have you look the file /etc/conf.d/crypto-loop?
Could I have more info about it, since the link to it is down.
And, where can I find build-initrd.sh?

I belive it is not any type of journalled file system, just certain ones, depending on how they write data to the disk. I believe that Reiserfs and XFS are OK in the way they order the data in their default configuration, but i do not have any references to hand, so don't solely rely on my information. I persoanlly tried it with Reiserfs 3.6 and succesfully encrytpted, used, and then decryted my root partition.franklin wrote:Since it is not recommended to use a journaling filesystem, I would like to know what type of filesystem you use on your encrypted root partition.
Thx for the info, I will try it with Reiserfskritip wrote:I belive it is not any type of journalled file system, just certain ones, depending on how they write data to the disk. I believe that Reiserfs and XFS are OK in the way they order the data in their default configuration, but i do not have any references to hand, so don't solely rely on my information. I persoanlly tried it with Reiserfs 3.6 and succesfully encrytpted, used, and then decryted my root partition.franklin wrote:Since it is not recommended to use a journaling filesystem, I would like to know what type of filesystem you use on your encrypted root partition.
Kristian

What this means is that you can have a journalling file system on a loop device that's backed by a device, such as /dev/hda1 or /dev/sda1, but it is not recommended to have a journalling file system on a file backed loop device, such as one you create by typing this in.2.2. Use of journaling file systems on loop device
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Don't use a journaling file system on top of file backed loop device, unless
underlying file system is journaled and guarantees data=ordered or
data=journal. Device backed loop device can be used with journaling file
systems as device backed loops guarantee that writes reach disk platters in
order required by journaling file system (write caching must be disabled on
the disk drive, of course). With file backed loop devices, correct write
ordering may extend only to page cache (which resides in RAM) of underlying
file system. VM can write such pages to disk in any order it wishes, and
thus break write order expectation of journaling file system.
Code: Select all
dd if=/dev/zero of=loop.img bs=1k count=65536
losetup -e AES128 -S XXXXXX -T /dev/loop1 loop.img
mke2fs /dev/loop1
mount -t ext2 /dev/loop1 /mnt/loop
Code: Select all
cd /usr/src
cp /usr/portage/distfiles/patches-2.4.22-hardened.tar.bz2 ./
tar -xjvpf patches*.bz2
wget http://aleron.dl.sourceforge.net/sourceforge/loop-aes/loop-AES-v2.0e.tar.bz2
tar -xjvpf loop-A*.bz2
cd linux
patch -Rp1 -i ../2.4.22-hardened/70_crypto*.patch # Remove the patch
patch -Np1 -i ../loop-A*/kernel-2.4.24.diff # Apply the new patch
rm -rf ../*.bz2 ../2.4.22-hardened ../loop*
make menuconfig