diff options
author | Thomas E. Dickey <dickey@invisible-island.net> | 2004-05-07 01:13:29 -0400 |
---|---|---|
committer | Thomas E. Dickey <dickey@invisible-island.net> | 2004-05-07 01:13:29 -0400 |
commit | d326f24d169154673717129098ff4554a673f178 (patch) | |
tree | 7229f817b10bcdb82f8df2b6af3a3acc792a762d /WWW/Library/Implementation/HTGroup.h | |
parent | 2cd8e80bfe2792ce8999a26b34384598f58e3889 (diff) | |
download | lynx-snapshots-d326f24d169154673717129098ff4554a673f178.tar.gz |
snapshot of project "lynx", label v2-8-6dev_3
Diffstat (limited to 'WWW/Library/Implementation/HTGroup.h')
-rw-r--r-- | WWW/Library/Implementation/HTGroup.h | 93 |
1 files changed, 48 insertions, 45 deletions
diff --git a/WWW/Library/Implementation/HTGroup.h b/WWW/Library/Implementation/HTGroup.h index eee5f46c..cf9cbb19 100644 --- a/WWW/Library/Implementation/HTGroup.h +++ b/WWW/Library/Implementation/HTGroup.h @@ -7,32 +7,30 @@ #include <HTList.h> - typedef HTList GroupDefList; typedef HTList ItemList; typedef struct { - char * group_name; - ItemList * item_list; + char *group_name; + ItemList *item_list; } GroupDef; - /* -** Access Authorization failure reasons -*/ + * Access Authorization failure reasons + */ typedef enum { - HTAA_OK, /* 200 OK */ - HTAA_OK_GATEWAY, /* 200 OK, acting as a gateway */ - HTAA_NO_AUTH, /* 401 Unauthorized, not authenticated */ - HTAA_NOT_MEMBER, /* 401 Unauthorized, not authorized */ - HTAA_IP_MASK, /* 403 Forbidden by IP mask */ - HTAA_BY_RULE, /* 403 Forbidden by rule */ - HTAA_NO_ACL, /* 403 Forbidden, ACL non-existent */ - HTAA_NO_ENTRY, /* 403 Forbidden, no ACL entry */ - HTAA_SETUP_ERROR, /* 403 Forbidden, server setup error */ - HTAA_DOTDOT, /* 403 Forbidden, URL with /../ illegal */ - HTAA_HTBIN, /* 403 Forbidden, /htbin not enabled */ - HTAA_NOT_FOUND /* 404 Not found, or read protected */ + HTAA_OK, /* 200 OK */ + HTAA_OK_GATEWAY, /* 200 OK, acting as a gateway */ + HTAA_NO_AUTH, /* 401 Unauthorized, not authenticated */ + HTAA_NOT_MEMBER, /* 401 Unauthorized, not authorized */ + HTAA_IP_MASK, /* 403 Forbidden by IP mask */ + HTAA_BY_RULE, /* 403 Forbidden by rule */ + HTAA_NO_ACL, /* 403 Forbidden, ACL non-existent */ + HTAA_NO_ENTRY, /* 403 Forbidden, no ACL entry */ + HTAA_SETUP_ERROR, /* 403 Forbidden, server setup error */ + HTAA_DOTDOT, /* 403 Forbidden, URL with /../ illegal */ + HTAA_HTBIN, /* 403 Forbidden, /htbin not enabled */ + HTAA_NOT_FOUND /* 404 Not found, or read protected */ } HTAAFailReasonType; /* @@ -100,7 +98,8 @@ Group definition grammar */ -extern GroupDef *HTAA_parseGroupDef (FILE * fp); +extern GroupDef *HTAA_parseGroupDef(FILE *fp); + /* Fill in Pointers to referenced Group Definitions in a Group Definition @@ -110,8 +109,9 @@ Fill in Pointers to referenced Group Definitions in a Group Definition */ -extern void HTAA_resolveGroupReferences (GroupDef * group_def, - GroupDefList * group_def_list); +extern void HTAA_resolveGroupReferences(GroupDef *group_def, + GroupDefList *group_def_list); + /* Read Group File (and do caching) @@ -121,7 +121,8 @@ Read Group File (and do caching) */ -extern GroupDefList *HTAA_readGroupFile (const char * filename); +extern GroupDefList *HTAA_readGroupFile(const char *filename); + /* Delete Group Definition @@ -131,14 +132,16 @@ Delete Group Definition */ -extern void GroupDef_delete (GroupDef * group_def); +extern void GroupDef_delete(GroupDef *group_def); + /* Print Out Group Definition (for trace purposes) */ -extern void HTAA_printGroupDef (GroupDef * group_def); +extern void HTAA_printGroupDef(GroupDef *group_def); + /* Does a User Belong to a Given Set of Groups @@ -148,26 +151,26 @@ Does a User Belong to a Given Set of Groups */ /* PUBLIC HTAA_userAndInetInGroup() -** CHECK IF USER BELONGS TO TO A GIVEN GROUP -** AND THAT THE CONNECTION COMES FROM AN -** ADDRESS THAT IS ALLOWED BY THAT GROUP -** ON ENTRY: -** group the group definition structure. -** username connecting user. -** ip_number browser host IP number, optional. -** ip_name browser host IP name, optional. -** However, one of ip_number or ip_name -** must be given. -** ON EXIT: -** returns HTAA_IP_MASK, if IP address mask was -** reason for failing. -** HTAA_NOT_MEMBER, if user does not belong -** to the group. -** HTAA_OK if both IP address and user are ok. -*/ -extern HTAAFailReasonType HTAA_userAndInetInGroup (GroupDef * group, - char * username, - char * ip_number, - char * ip_name); + * CHECK IF USER BELONGS TO TO A GIVEN GROUP + * AND THAT THE CONNECTION COMES FROM AN + * ADDRESS THAT IS ALLOWED BY THAT GROUP + * ON ENTRY: + * group the group definition structure. + * username connecting user. + * ip_number browser host IP number, optional. + * ip_name browser host IP name, optional. + * However, one of ip_number or ip_name + * must be given. + * ON EXIT: + * returns HTAA_IP_MASK, if IP address mask was + * reason for failing. + * HTAA_NOT_MEMBER, if user does not belong + * to the group. + * HTAA_OK if both IP address and user are ok. + */ +extern HTAAFailReasonType HTAA_userAndInetInGroup(GroupDef *group, + char *username, + char *ip_number, + char *ip_name); #endif /* not HTGROUP_H */ |