[OpenAFS-devel] PAGs/tokens/threads

Derrick Brashear shadow@gmail.com
Fri, 7 Aug 2009 08:06:43 -0400


> All the previous items let me to assume that:
>
> I cannot have a PAG associated to a thread (session keyrings
> are shared between threads) and, at the same time I cannot
> have different credentials associated to different threads of the same
> process (tests for this exhibit a strange behavior but I think this is
> true).

True.

> On the other hand request_key (the one used in PagInCred) searches
> for keys in any keyring (in a fixed order, starting from the thread one)
> so if I store a key named "_pag" (as I did) in thread's keyring
> any thread can get a pag and, thus, can have (unshared) credentials.

I'm fairly certain that is also true.

> Can someone tell me if I (completely) misunderstood something ?
>
> If anything before happen to be true I have a question:
> what kind of interface can I provide to request a thread-pag ?

For yourself, or to us?

> In my local tests I hijaked syscall nr. 29 (left free) and it works
> but I have not idea of consequences.
>
> Finally, I am not able to understand why pags are stored in groups too;
> any help ?

Historical. That's how it worked before there were keyrings, and on
other platforms.

Derrick