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
| ||
|
Date: Wed, 12 Aug 2020 09:55:53 +0200 From: Miklos Szeredi <miklos@...redi.hu> To: David Howells <dhowells@...hat.com> Cc: Linus Torvalds <torvalds@...ux-foundation.org>, linux-fsdevel <linux-fsdevel@...r.kernel.org>, Al Viro <viro@...iv.linux.org.uk>, Karel Zak <kzak@...hat.com>, Jeff Layton <jlayton@...hat.com>, Miklos Szeredi <mszeredi@...hat.com>, Nicolas Dichtel <nicolas.dichtel@...nd.com>, Christian Brauner <christian@...uner.io>, Lennart Poettering <lennart@...ttering.net>, Linux API <linux-api@...r.kernel.org>, Ian Kent <raven@...maw.net>, LSM <linux-security-module@...r.kernel.org>, Linux Kernel Mailing List <linux-kernel@...r.kernel.org> Subject: Re: file metadata via fs API (was: [GIT PULL] Filesystem Information) On Wed, Aug 12, 2020 at 2:05 AM David Howells <dhowells@...hat.com> wrote: > > { > > int fd, attrfd; > > > > fd = open(path, O_PATH); > > attrfd = openat(fd, name, O_ALT); > > close(fd); > > read(attrfd, value, size); > > close(attrfd); > > } > > Please don't go down this path. You're proposing five syscalls - including > creating two file descriptors - to do what fsinfo() does in one. So what? People argued against readfile() for exactly the opposite of reasons, even though that's a lot less specialized than fsinfo(). Worried about performance? Io-uring will allow you to do all those five syscalls (or many more) with just one I/O submission. Thanks, Miklos
Powered by blists - more mailing lists