From: "Serge E. Hallyn" <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
To: David Howells <dhowells-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Cc: Linux Containers
<containers-qjLDD68F18O7TbgM5vRIOg@public.gmane.org>,
lkml <linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"Eric W. Biederman"
<ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org>
Subject: Re: [PATCH 4/4] keys: make procfiles per-user-namespace
Date: Wed, 25 Feb 2009 15:03:36 -0600 [thread overview]
Message-ID: <20090225210336.GA20086@us.ibm.com> (raw)
In-Reply-To: <16728.1235565664-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Quoting David Howells (dhowells-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org):
> Serge E. Hallyn <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org> wrote:
>
> > > Hmmm... I wonder if we can do better by making the file position indicate
> > > the key ID rather than being a count of the number of keys read. It might
> > > make this cleaner.
> >
> > file position? as in the result of lseek(fd, 0, SEEK_CUR)?
> >
> > I don't understand what you're suggesting.
>
> Currently the file position on /proc/keys indicates the number of keys that
> have been read. It is incremented by 1 for each key read, irrespective of the
> length of the line that was read for that key.
>
> We could, instead, map file positions to key IDs, and skip any file positions
> that don't actually map to an extant key.
So you want users to be able to mmap the file and lseek to a particular
spot? Is that bc you have users with so many keys that
grep keyid /proc/keys
becomes slow?
Or am I still misunderstanding?
Meanwhile, do you have any objections to these 4 patches? :)
thanks,
-serge
next prev parent reply other threads:[~2009-02-25 21:03 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-09 22:52 [PATCH 1/4] keys: distinguish per-uid keys in different namespaces Serge E. Hallyn
2009-01-09 22:52 ` [PATCH 2/4] keys: consider user namespace in key_permission Serge E. Hallyn
[not found] ` <20090109225208.GA15252-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2009-01-09 22:52 ` [PATCH 3/4] keys: skip keys from another user namespace Serge E. Hallyn
2009-01-09 22:53 ` [PATCH 4/4] keys: make procfiles per-user-namespace Serge E. Hallyn
2009-02-13 11:03 ` David Howells
2009-02-23 20:40 ` Serge E. Hallyn
2009-02-25 12:41 ` David Howells
[not found] ` <16728.1235565664-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-02-25 21:03 ` Serge E. Hallyn [this message]
2009-02-25 23:53 ` David Howells
2009-02-26 3:39 ` Serge E. Hallyn
2009-02-26 21:50 ` Serge E. Hallyn
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=20090225210336.GA20086@us.ibm.com \
--to=serue-r/jw6+rmf7hqt0dzr+alfa@public.gmane.org \
--cc=containers-qjLDD68F18O7TbgM5vRIOg@public.gmane.org \
--cc=dhowells-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.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