mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Adam J. Richter" <adam@yggdrasil.com>
To: linux-kernel@vger.kernel.org
Cc: abramo.bagnara@libero.it, hpa@zytor.com
Subject: Re: futimes()?
Date: Sun, 2 Feb 2003 10:59:18 -0800	[thread overview]
Message-ID: <200302021859.KAA11878@adam.yggdrasil.com> (raw)

>Abramo Bagnara wrote:
>"H. Peter Anvin" wrote:
>> 
>> In the general vein of avoiding security holes by using file
>> descriptors when doing repeated operations on the same filesystem
>> object, I have noticed that there doesn't seem to be a way to set
>> mtime using a file descriptor.  Do we need a futimes() syscall?
>
>Parallel to that, there is the long time needed lutimes() syscall.
>
>Who has never been annoyed that restoring a backup there's no way to
>restore former symlink mtime?

	I wonder if we could have an open flags similar to O_NOFOLLOW
that would allow a symbolic link to be "opened" just so it could
be referred to by f{stat,chown,chmod} so that programs that use this
style handle symbolic links the same way.

	Also, if you want to add another system call for setting stat
information, perhaps we could take the opportunity to reduce the
number of system calls per file being restored by programs like tar by
creating an fsetstat() system call that would take some kind of
extensible flags field so that programs like tar could do their
business in a single system call.  The kernel already seems to do this
internally through inode_operations.setattr.  (sys_chown -->
chown_common --> notify_change --> inode_setattr).  That way it
would be less likely that we'd have to add a new system calls again
if people think of new file attributes.

Adam J. Richter     __     ______________   575 Oroville Road
adam@yggdrasil.com     \ /                  Milpitas, California 95035
+1 408 309-6081         | g g d r a s i l   United States of America
                         "Free Software For The Rest Of Us."

             reply	other threads:[~2003-02-02 18:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-02 18:59 Adam J. Richter [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-02-02  1:53 futimes()? H. Peter Anvin
2003-02-02  8:48 ` futimes()? Abramo Bagnara
2003-02-02 12:07 ` futimes()? Alex Riesen
2003-02-03 19:07   ` futimes()? H. Peter Anvin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200302021859.KAA11878@adam.yggdrasil.com \
    --to=adam@yggdrasil.com \
    --cc=abramo.bagnara@libero.it \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®