Generates the same image from the same source

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Generates the same image from the same source

Renato
Hi,

I have made a custom linux distribution to use inside my company.  The
system basic relys on 10 squashfs that are mounted and "merged" using
aufs acording to the person who is loggin.

I have noticed that mksquashfs doesn't generates the same image (I
mean, the content is the same, but the image signature is not) for the
same source.

Just a simple example to explain what I mean:

cd /tmp
mkdir test
echo "Hello world" >test/file.txt
mksquashfs test test1.img
sleep 2s
mksquashfs test test2.img
sha1sum test1.img test2.img

sha1sum will tell that test1 and test2 have different signatures.

But if I run the same  command without the sleep (aka, the two
mksquashfs on the same second), then the images get the same
signature.

Looks lime mksquashfs uses time() function to add some salt to the image.

I couldn't find any parameter to disable it.

Is it possible?

Thanks

------------------------------------------------------------------------------
_______________________________________________
Squashfs-announce mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/squashfs-announce