[rsbac] a few problems

Amon Ott rsbac@rsbac.org
Thu Sep 12 16:10:01 2002


--------------Boundary-00=_ESWBSA93FE39MNUQ5UV3
Content-Type: text/plain;
  charset="iso-8859-1"
Content-Transfer-Encoding: 8bit

On Monday, 9. September 2002 09:25, Josh Beagley wrote:
> The first problem I seem to be having is enabling FF flags add_inherited
> and secure_delete on my home directory. I am running rsbac 1.2.0, kernel
> 2.4.19 and the preemptive patch. I get the following error, and and process
> involving file operations hangs:
> 
> Sep  7 02:13:02 Lynx kernel: Assertion failure in ext3_sync_file() at
> fsync.c:55: "ext3_journal_current_handle() == 0"
> Sep  7 02:13:02 Lynx kernel: kernel BUG at fsync.c:55!

This is caused by the RSBAC secure delete code calling fsync, although the 
journal is currently open.

The attached patch avoids fsync for ext3. However, although it seems that the 
zeroed file is synced to disk by the ext3 code, I cannot guarantee the 
overwriting on disk.

This would need some direct testing, e.g. secure deleting on a loop mount or 
floppy disk and grepping for the file contents afterwards. Volunteers?

Amon.
--
http://www.rsbac.org

--------------Boundary-00=_ESWBSA93FE39MNUQ5UV3
Content-Type: text/x-diff;
  charset="iso-8859-1";
  name="adf-ext3.diff"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="adf-ext3.diff"

LS0tIGFkZl9tYWluLmMuc2lrCVRodSBBdWcgMjkgMTA6MDY6MjQgMjAwMgorKysgYWRmX21haW4u
YwlUaHUgU2VwIDEyIDE2OjA0OjA2IDIwMDIKQEAgLTMzLDYgKzMzLDEwIEBACiAjaW5jbHVkZSA8
bGludXgvdHlwZXMuaD4KICNpbmNsdWRlIDxsaW51eC9kY2FjaGUuaD4KICNpbmNsdWRlIDxhc20v
dWFjY2Vzcy5oPgorI2lmIExJTlVYX1ZFUlNJT05fQ09ERSA+IEtFUk5FTF9WRVJTSU9OKDIsNCww
KQorI2luY2x1ZGUgPGxpbnV4L2piZC5oPgorI2luY2x1ZGUgPGxpbnV4L2V4dDNfZnMuaD4KKyNl
bmRpZgogI2VuZGlmIC8qIFNFQ0RFTCAqLwogCiAvKioqKioqKioqKioqKioqKioqKioqKioqKioq
KioqKioqKioqKioqKioqKioqKioqKiAqLwpAQCAtMTk1MSw3ICsxOTU1LDkgQEAKICAgICAgICAg
aWYgKGZpbGUuZl9vcC0+ZnN5bmMpCiAgICAgICAgICAgZXJyID0gZmlsZS5mX29wLT5mc3luYygm
ZmlsZSxkZW50cnlfcCk7CiAgICAgICAgICNlbHNlCi0gICAgICAgIGlmIChmaWxlLmZfb3AtPmZz
eW5jKQorICAgICAgICBpZiAoICAgZmlsZS5mX29wLT5mc3luYworICAgICAgICAgICAgJiYgKGZp
bGUuZl9vcCAhPSAmZXh0M19maWxlX29wZXJhdGlvbnMpCisgICAgICAgICAgICkKICAgICAgICAg
ICBlcnIgPSBmaWxlLmZfb3AtPmZzeW5jKCZmaWxlLGRlbnRyeV9wLDEpOwogICAgICAgICAjZW5k
aWYKICAgICAgICAgICAK

--------------Boundary-00=_ESWBSA93FE39MNUQ5UV3--