Comment 3 for bug 518582

Revision history for this message
Kees Cook (kees) wrote :

I cannot reproduce this with a simple loop-back filesystem:

sudo -s
cd /tmp
dd if=/dev/zero of=test.ext4 bs=1 count=1 seek=1G
mkfs.ext4 -F test.ext4
mkdir -p /mnt/test
mount -o loop text.ext4 /mnt/test
echo $(seq $(hexdump -s 0x410 -n 2 -e '"%d\n"' test.ext4) - 9336 ) | (cd /mnt/test; xargs touch)
umount /mnt/test

$ blkid -p text.ext4
test.ext4: UUID="e6c2eb3d-91ca-42bd-8f09-ff118c9f47c1" TYPE="ext4"
$ hexdump -s 0x410 -n 2 -e '"%d\n"' test.ext4
9336

In reading the blkid source, I think the minix filesystem superblock magic is located at 0x110 not 0x410. However, this bug shows blkid reading 0x110 ("minix: magic sboff=16, kboff=1") kboff=1 == 0x100, sboff=16 == 0x10