|
CWB
|
#include <sys/types.h>#include <sys/socket.h>#include <netinet/in.h>Functions | |
| void | add_user_to_list (char *user, char *passwd) |
| void | add_host_to_list (char *ipaddr) |
| void | add_hosts_in_subnet_to_list (char *ipsubnet) |
| void | add_grant_to_last_user (char *corpus) |
| int | check_host (struct in_addr host) |
| returns true if host is in list of allowed hosts More... | |
| int | authenticate_user (char *user, char *passwd) |
| returns true if (user, passwd) pair is in list of allowed users More... | |
| int | check_grant (char *user, char *corpus) |
| returns true if user may access corpus More... | |
| void | show_grants (void) |
| for debugging only More... | |
| void add_grant_to_last_user | ( | char * | corpus | ) |
References cl_malloc(), cl_strdup(), _Grant::corpus, _UserEntry::grants, and _Grant::next.
| void add_host_to_list | ( | char * | ipaddr | ) |
References _HostEntry::accept_any, _HostEntry::address, authorized_hosts, cl_malloc(), cqpmessage(), Error, and _HostEntry::next.
Referenced by add_hosts_in_subnet_to_list(), and main().
| void add_hosts_in_subnet_to_list | ( | char * | ipsubnet | ) |
References add_host_to_list(), cl_free, cl_malloc(), cqpmessage(), and Error.
| void add_user_to_list | ( | char * | user, |
| char * | passwd | ||
| ) |
References authorized_users, cl_malloc(), cl_strdup(), cqpmessage(), Error, find_user(), _UserEntry::grants, _UserEntry::name, _UserEntry::next, and _UserEntry::passwd.
Referenced by main().
| int authenticate_user | ( | char * | user, |
| char * | passwd | ||
| ) |
returns true if (user, passwd) pair is in list of allowed users
References find_user(), _UserEntry::passwd, and user.
Referenced by main().
| int check_grant | ( | char * | user, |
| char * | corpus | ||
| ) |
returns true if user may access corpus
References _Grant::corpus, find_user(), _UserEntry::grants, _Grant::next, and user.
Referenced by main().
| int check_host | ( | struct in_addr | host | ) |
returns true if host is in list of allowed hosts
References _HostEntry::accept_any, _HostEntry::address, and _HostEntry::next.
Referenced by accept_connection().
| void show_grants | ( | void | ) |
for debugging only
References _HostEntry::address, _Grant::corpus, _UserEntry::grants, _UserEntry::name, _Grant::next, _UserEntry::next, _HostEntry::next, _UserEntry::passwd, and user.
1.8.8