The caller must be a possesor of the key to set the attributes, so link the destination keyring to the current thread's keyring before instantiation so that after instantiation the timeout can be set. Signed-off-by: Benjamin Coddington <bcodding@xxxxxxxxxx> --- utils/nfsidmap/nfsidmap.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/utils/nfsidmap/nfsidmap.c b/utils/nfsidmap/nfsidmap.c index 4da7f5c..b141f9e 100644 --- a/utils/nfsidmap/nfsidmap.c +++ b/utils/nfsidmap/nfsidmap.c @@ -329,6 +329,9 @@ int main(int argc, char **argv) key, type, value, timeout); } + /* become a possesor of the to-be-instantiated key to set the key's timeout */ + request_key("keyring", DEFAULT_KEYRING, NULL, KEY_SPEC_THREAD_KEYRING); + if (strcmp(type, "uid") == 0) rc = id_lookup(value, key, USER); else if (strcmp(type, "gid") == 0) -- 1.7.1 -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html