lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <18425.57003.125097.61814@frecb006361.adech.frec.bull.fr>
Date:	Mon, 7 Apr 2008 10:43:23 +0200
From:	Solofo.Ramangalahy@...l.net
To:	linux-ext4@...r.kernel.org
Cc:	Szabolcs Szakacsits <szaka@...s-3g.com>
Subject: [PATCH] ext4: update ctime and mtime for truncate with extents.

ext4: update ctime and mtime for truncate with extents.

From: Solofo Ramangalahy <Solofo.Ramangalahy@...l.net>

The recently announced "Linux POSIX file system test suite"
catched a truncate issue when using extents:
mtime and ctime are not updated when truncate is successful.

This is the single issue catched with "default" ext4 (mkfs and mount
with minimal options).
The testsuite does not report failure with -o noextents.

With the following patch, all tests of the testsuite passes.

Signed-off-by: Solofo Ramangalahy <Solofo.Ramangalahy@...l.net>

---
 fs/ext4/extents.c |    1 +
 1 file changed, 1 insertion(+)

Index: linux-2.6.25-rc8-git5-ext4-52c7a8013ad2c452551a68ff4daab4bacbe28f9d/fs/ext4/extents.c
===================================================================
--- linux-2.6.25-rc8-git5-ext4-52c7a8013ad2c452551a68ff4daab4bacbe28f9d.orig/fs/ext4/extents.c
+++ linux-2.6.25-rc8-git5-ext4-52c7a8013ad2c452551a68ff4daab4bacbe28f9d/fs/ext4/extents.c
@@ -2947,6 +2947,7 @@ out_stop:
 		ext4_orphan_del(handle, inode);
 
 	up_write(&EXT4_I(inode)->i_data_sem);
+	inode->i_mtime = inode->i_ctime = ext4_current_time(inode);
 	ext4_journal_stop(handle);
 }
 
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ