2 * Copyright (C) 2006 Andre Noll <maan@tuebingen.mpg.de>
4 * Licensed under the GPL v2. For licencing details see COPYING.
7 /** \file user_list.h exported functions from user_list.c */
10 * Flags for server commands and user permissions.
12 * For each command, zero or more of these flags are ored to define the command
13 * permissions. A user is allowed to run the command if and only if all command
14 * permission flags are set for the user in the server.users config file which
15 * is read at server startup.
17 enum server_command_permissions {
18 NO_PERMISSION_REQUIRED = 0, /** None of the below. */
19 AFS_READ = 1, /** Read-only operation on the AFS database. */
20 AFS_WRITE = 2, /** Read-write operation on the AFS database. */
21 VSS_READ = 4, /** Read-only operation on the virtual streaming system. */
22 VSS_WRITE = 8 /** Read-write operation on the virtual streaming system. */
26 * data needed to authenticate the user
29 /** The position of this user in the list of users. */
30 struct list_head node;
33 /** The public key. */
34 struct asymmetric_key *pubkey;
35 /** The privileges of this user. */
39 void init_user_list(char *user_list_file);
40 struct user *lookup_user(const char *name);