XFS information leak during crash

From: Jan Kasprzak
Date: Wed Nov 02 2005 - 16:27:20 EST


Hello, world!\n

I have found that after the system crash (e.h. a hard reset or a power
failure) XFS corrupts files which have been written to just before the crash:
The result is that those files contain data from random blocks on the
disk (e.g. from previously deleted files). This can have security/privacy
implications - users can see the contents of other users' old files.

I have even written a test program, which creates/rewrites
files with known contents in a given directory. After the hard
reset while running this program some of the files contain blocks
with "random" data (i.e. not the original data and not the new data
either). Does XFS support a something like ext3's "data=ordered" mount
option? Otherwise it is pretty unusable on multi-user systems.

This is on 2.6.11.10 and 2.6.14 running on x86_64 and i386 SMP
configurations. I may test it on UP if there is an interest.

The quick-hack-style test program can be found at
http://www.fi.muni.cz/~kas/progs/xfsrewrite.c

-Yenya

--
| Jan "Yenya" Kasprzak <kas at {fi.muni.cz - work | yenya.net - private}> |
| GPG: ID 1024/D3498839 Fingerprint 0D99A7FB206605D7 8B35FCDE05B18A5E |
| http://www.fi.muni.cz/~kas/ Journal: http://www.fi.muni.cz/~kas/blog/ |
> Specs are a basis for _talking_about_ things. But they are _not_ a basis <
> for implementing software. --Linus Torvalds <
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/