"Fossies" - the Fresh Open Source Software Archive

Member "mod_auth_dce-3.4/auth_dce/mod_auth_dce.h" (10 Aug 2006, 2044 Bytes) of package /linux/www/apache_httpd_modules/old/mod_auth_dce-3.4.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file.

    1 /*
    2  * DCE Authentication Module for Apache HTTP Server
    3  *
    4  * Paul B. Henson <henson@acm.org>
    5  *
    6  * Copyright (c) 1996-2003 Paul B. Henson -- see COPYRIGHT file for details
    7  *
    8  */
    9 
   10 #ifndef MOD_AUTH_DCE_H
   11 #define MOD_AUTH_DCE_H
   12 
   13 /* #define DEBUG */
   14 
   15 #ifdef __GNUC__ 
   16 #ifdef DEBUG
   17 #define DEBUG_R(X...) ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, r, X)
   18 #define DEBUG_S(X...) ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, s, X)
   19 #else
   20 #define DEBUG_R(X...)
   21 #define DEBUG_S(X...)
   22 #endif
   23 #else
   24 #define DEBUG_R()
   25 #define DEBUG_S()
   26 #endif
   27 
   28 /* Comment out on systems without DFS */
   29 #define WITH_DFS
   30 
   31 #ifndef NO_CACHING
   32 /* How often per server process to log cache statistics, comment out to disable */
   33 #define CACHE_STATS_INTERVAL 500
   34 
   35 /* How many extra random characters to append to a given username for cache stress testing */
   36 /* #define CACHE_TEST_LEVEL 4 */
   37 #endif
   38 
   39 typedef struct server_config_struct {
   40     char *user;
   41     char *keytab;
   42     int certify_identity;
   43 #ifndef NO_CACHING
   44     unsigned int cache_buckets;
   45     unsigned int cache_graceperiod;
   46     unsigned int cache_lifetime;
   47     unsigned int cache_max_idle;
   48     unsigned int cache_sweep_interval;
   49 #endif
   50 } server_config_rec;
   51 
   52 typedef struct dir_config_struct {
   53   int active;
   54 #ifdef WITH_DFS
   55   int dfs_authorization;
   56 #endif
   57   int include_pw;
   58   int impersonate_browser;
   59   int authoritative;
   60   char *index_names;
   61 } dir_config_rec;
   62 
   63 
   64 typedef struct request_config_struct {
   65 #ifndef NO_CACHING
   66   unsigned char hash_key[16];
   67   unsigned int hash_index;
   68   unsigned long pag;
   69 #else
   70   void *login_context;
   71 #endif
   72 } request_config_rec;
   73 
   74 #ifndef NO_CACHING
   75 void auth_dce_purge_context(server_rec *s, unsigned long pag);
   76 void auth_dce_initialize_cache(server_rec *s, pool *p);
   77 void auth_dce_find_cached_context(request_rec *r, request_config_rec *request_config, char *username, char *password);
   78 void auth_dce_add_cached_context(request_rec *r, request_config_rec *request_config);
   79 void auth_dce_release_cached_context(request_rec *r, request_config_rec *request_config);
   80 #endif
   81 
   82 #endif