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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 15 Feb 2019 01:57:39 +0000
From:   Hans van Kranenburg <Hans.van.Kranenburg@...dix.com>
To:     Omar Sandoval <osandov@...ndov.com>,
        "linux-fsdevel@...r.kernel.org" <linux-fsdevel@...r.kernel.org>,
        Al Viro <viro@...iv.linux.org.uk>
CC:     "kernel-team@...com" <kernel-team@...com>,
        "linux-api@...r.kernel.org" <linux-api@...r.kernel.org>,
        "linux-btrfs@...r.kernel.org" <linux-btrfs@...r.kernel.org>,
        "linux-ext4@...r.kernel.org" <linux-ext4@...r.kernel.org>,
        "linux-f2fs-devel@...ts.sourceforge.net" 
        <linux-f2fs-devel@...ts.sourceforge.net>,
        "linux-xfs@...r.kernel.org" <linux-xfs@...r.kernel.org>
Subject: Re: [RFC PATCH 0/6] Allow setting file birth time with utimensat()

Hi,

On 2/14/19 11:00 AM, Omar Sandoval wrote:
> From: Omar Sandoval <osandov@...com>
> 
> Since statx was added in 4.11, userspace has had an interface for
> reading btime (file creation time), but no way to set it. This RFC patch
> series adds support for changing btime with utimensat(). Patch 1 adds
> the VFS infrastructure, patch 2 adds the support to utimensat() with a
> new flag, and the rest of the patches add filesystem support; I excluded
> CIFS for now because I don't have a CIFS setup to test it on.
> 
> Updating btime is useful for at least a couple of use cases:
> 
> - Backup/restore programs (my motivation for this feature is btrfs send)

Can you give an example of such usefulness? What's the thing you run
into that you can't do without having this?

You guys are having a technical discussion about 'implementation or the
interface' in this thread, while I'm wondering what I'm missing as btrfs
send/receive user by not having this. I never needed it in my use cases.

There's two levels of use case hidden in the above line. So, I don't
mean why btrfs send/receive is useful (it is, for quick efficient
replication of changes) but, what's an important usecase for btime on
top of that?

> - File servers which interoperate with operating systems that allow
>   updating file creation time, including Mac OS [1] and Windows [2]
> 
> I've also included a man page patch, xfs_io support, and an xfstest.
> 
> Thoughts on the implementation or the interface?
> 
> Thanks!
> 
> 1: https://developer.apple.com/library/archive/documentation/System/Conceptual/ManPages_iPhoneOS/man2/setattrlist.2.html
> 2: https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-setfiletime
> 
> Omar Sandoval (6):
>   fs: add btime to struct iattr
>   fs: add AT_UTIME_BTIME for utimensat()
>   Btrfs: add support for setting btime
>   ext4: add support for setting btime
>   f2fs: add support for setting btime
>   xfs: add support for setting btime
> 
>  fs/attr.c                      |  6 +++
>  fs/btrfs/inode.c               |  2 +
>  fs/btrfs/super.c               |  4 +-
>  fs/ext4/inode.c                | 15 +++++-
>  fs/ext4/super.c                |  2 +-
>  fs/f2fs/file.c                 | 19 ++++++--
>  fs/f2fs/super.c                |  2 +-
>  fs/utimes.c                    | 86 +++++++++++++++++++++-------------
>  fs/xfs/libxfs/xfs_format.h     |  2 +-
>  fs/xfs/libxfs/xfs_log_format.h |  2 +-
>  fs/xfs/xfs_iops.c              | 11 ++++-
>  fs/xfs/xfs_super.c             |  2 +-
>  include/linux/fs.h             |  4 ++
>  include/uapi/linux/fcntl.h     |  2 +
>  14 files changed, 111 insertions(+), 48 deletions(-)
> 


-- 
Hans van Kranenburg

Powered by blists - more mailing lists