From: David Howells <dhowells@warthog.cambridge.redhat.com>
To: Jan Harkes <jaharkes@cs.cmu.edu>
Cc: David Howells <dhowells@cambridge.redhat.com>,
Linus Torvalds <torvalds@transmeta.com>,
linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org,
openafs-devel@openafs.org
Subject: Re: [PATCH] in-core AFS multiplexor and PAG support
Date: Tue, 13 May 2003 19:53:22 +0100 [thread overview]
Message-ID: <9828.1052852002@warthog.warthog> (raw)
In-Reply-To: <20030513182950.GB30766@delft.aura.cs.cmu.edu>
> On Tue, May 13, 2003 at 06:42:49PM +0100, David Howells wrote:
> > I have a further suggestion for some new system calls specifically for
> > managing tokens. I'd like to add the following:
> >
> > (1) settok(const char *fs, const char *key, size_t size, const void *data)
> >
> > Present data to the named filesystem as being the authentication
> > token for the specified key (eg: an AFS cell). If accepted, this
> > token should be stored in the PAG to which the calling process
> > belongs.
>
> Tokens are very filesystem specific, with Coda the kernel really doesn't
> know in which 'realm' any object is located. So it will always just pass
> the PAG to the cache manager which will associate the right token to
> access the file.
OTOH, since settok wouldn't modify the PAG ring directly, but would rather
jump through a vector in the file_system_type object, it could deside to
confer with userspace and possibly not add a token at all.
Of course then the other calls would also have to vector through the
file_system_type object rather than affecting the PAG directly, but I'm happy
to do that.
> A minimal kernel implementation really only has a single newpag()
> systemcall and internal 'getpag()' that can be used by filesystems. All
> the token handling can be done by a (possibly filesystem specific)
> userspace daemon that is given a (pag,realm/key) tuple and returns a
> token.
>
> But ofcourse Coda is a 99% userspace implementation, so I'm already
> assuming that there are one or more userspace daemons.
This would just be a "standardised" way of communicating authentication info
to a filesystem. What the filesystem then did with it would be up to that
filesystem. Storing a token in a PAG or attached to a struct file would then
just be one option.
> > (2) gettok(const char *fs, const char *key, size_t size, void *buffer)
> >
> > Get a copy of an authentication token.
>
> Not sure what the use of this is for userspace. I can see how your
> kernel module would use it.
OpenAFS has it, but I'm not sure what uses it.
> btw. is the 'size_t size' the size of the key, or the size of the buffer?
Actually the buffer size. I was assuming the key would be a NUL terminated
string, but it's probably best not to assume that, and I should add an extra
argument for the key size.
Filesystem name can remain a NUL terminated string as I'd have to search the
file_system_type structures.
> > (4) cleartoks(const char *fs)
>
> Isn't this simply deltok(fs, NULL)?
Probably.
David
next parent reply other threads:[~2003-05-13 18:53 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20030513182950.GB30766@delft.aura.cs.cmu.edu>
2003-05-13 18:53 ` David Howells [this message]
2003-05-13 20:19 ` Re: [PATCH] in-core AFS multiplexor and PAG support Derrick J Brashear
2003-05-13 22:51 ` Booker Bense
2003-05-13 15:39 David Howells
2003-05-13 15:52 ` Linus Torvalds
2003-05-13 15:44 ` Alan Cox
2003-05-13 16:52 ` Jan Harkes
2003-05-13 16:57 ` Linus Torvalds
2003-05-13 16:39 ` Alan Cox
2003-05-13 16:05 ` David Howells
2003-05-13 16:47 ` Linus Torvalds
2003-05-13 17:20 ` Jan Harkes
2003-05-13 18:21 ` David Howells
2003-05-17 12:30 ` Pavel Machek
2003-05-13 17:23 ` Trond Myklebust
2003-05-15 11:41 ` Ingo Oeser
2003-05-13 17:42 ` David Howells
2003-05-13 16:03 ` Christoph Hellwig
2003-05-13 16:12 ` David Howells
2003-05-13 20:23 ` Christoph Hellwig
2003-05-13 16:39 ` Jeff Garzik
2003-05-13 16:57 ` David Howells
-- strict thread matches above, loose matches on Subject: below --
2003-05-13 15:34 David Howells
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=9828.1052852002@warthog.warthog \
--to=dhowells@warthog.cambridge.redhat.com \
--cc=dhowells@cambridge.redhat.com \
--cc=jaharkes@cs.cmu.edu \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=openafs-devel@openafs.org \
--cc=torvalds@transmeta.com \
/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