Main Page | Modules | Data Structures | File List | Data Fields | Globals | Related Pages

lcas.h File Reference

API of the LCAS library. More...

#include <gssapi.h>
#include "lcas_types.h"

Go to the source code of this file.

Functions

int lcas_init (FILE *fp)
 Initialize the LCAS module.

int lcas_init_and_log (FILE *fp, unsigned short logtype)
 Initialize the LCAS module.

int lcas_init_and_logfile (char *logfile, FILE *fp, unsigned short logtype)
 Initialize the LCAS module.

int lcas_term ()
 Terminate the LCAS module.

int lcas_get_fabric_authorization (char *user_dn_tmp, gss_cred_id_t user_cred, lcas_request_t request)
 submit authorization request to the LCAS


Detailed Description

API of the LCAS library.

Author:
Martijn Steenbakkers for the EU DataGrid.
This header contains the declarations of the LCAS library functions:
  1. lcas_init(): To initialize the LCAS module
  2. lcas_get_fabric_authorization(): to place an authorization request
  3. lcas_term(): To cleanly terminate the module

Definition in file lcas.h.


Function Documentation

lcas_get_fabric_authorization char *  user_dn_tmp,
gss_cred_id_t  user_cred,
lcas_request_t  request
 

submit authorization request to the LCAS

This function calls the plugins for authorization. As a back-up for empty credentials the user DN may be specified as well. For this ALLOW_EMPTY_CREDENTIALS should be defined.

Parameters:
user_dn_tmp user DN
user_cred GSS/GSI user credential
request authorization request as RSL string
Return values:
0 initialization succeeded.
1 initialization failed.

Definition at line 971 of file lcas.c.

References AUTHPROC, FAILED_LCAS_OTHER, FAILED_LCAS_PLUGIN, lcas_fill_cred(), lcas_get_dn(), lcas_log(), lcas_log_debug(), lcas_log_time(), LCAS_MOD_SUCCESS, lcas_plugindl_t, lcas_release_cred(), lcas_request_t, lcas_plugindl_s::next, lcas_plugindl_s::pluginname, and lcas_plugindl_s::procs.

lcas_init FILE *  fp  ) 
 

Initialize the LCAS module.

The function does the following:

  • initialize LCAS module.
  • setup logging, error handling (not yet).
  • read from LCAS database the plugins to be loaded.
  • initialize the plugins

Parameters:
fp file handle for logging (from gatekeeper)
Return values:
0 initialization succeeded.
1 initialization failed.

Definition at line 465 of file lcas.c.

References DO_SYSLOG, DO_USRLOG, and lcas_init_and_log().

lcas_init_and_log FILE *  fp,
unsigned short  logtype
 

Initialize the LCAS module.

The function does the following:

  • select logging type
  • setup logging, error handling (not yet).
  • read from LCAS database the plugins to be loaded.
  • initialize the plugins

Parameters:
fp file handle for logging (from gatekeeper or other previously opened file handle). If the file handle is zero, assume that only syslogging is requested.
logtype type of logging (usrlog and/or syslog)
Return values:
0 initialization succeeded.
1 initialization failed.

Definition at line 443 of file lcas.c.

References lcas_init_and_logfile().

Referenced by lcas_init().

lcas_init_and_logfile char *  logfile,
FILE *  fp,
unsigned short  logtype
 

Initialize the LCAS module.

The function does the following:

  • select logging type
  • setup logging by providing a file handle or file name, error handling (not yet).
  • read from LCAS database the plugins to be loaded.
  • initialize the plugins

Parameters:
logfile name of the logfile
fp file handle for logging (from gatekeeper or other previously opened file handle). If the file handle is zero, assume that only syslogging is requested.
logtype type of logging (usrlog and/or syslog)
Return values:
0 initialization succeeded.
1 initialization failed.

Definition at line 222 of file lcas.c.

References clean_plugin_list(), lcas_db_clean(), lcas_db_clean_list(), lcas_db_entry_t, lcas_db_fill_entry(), lcas_db_read(), LCAS_ETC_HOME, lcas_genfilename(), lcas_log(), lcas_log_debug(), lcas_log_open(), lcas_log_time(), LCAS_MAXARGSTRING, LCAS_MAXPATHLEN, lcas_plugindl_t, MAXAUTHMODS, lcas_db_entry_s::next, lcas_plugindl_s::next, NUL, lcas_db_entry_s::pluginargs, PluginInit(), lcas_db_entry_s::pluginname, lcas_plugindl_s::pluginname, and print_lcas_plugin().

Referenced by lcas_init_and_log().

lcas_term  ) 
 

Terminate the LCAS module.

The function does the following:

  • terminate the LCAS module
  • terminate the plugins

Return values:
0 initialization succeeded.
1 initialization failed.

Definition at line 1106 of file lcas.c.

References lcas_plugindl_s::argc, lcas_plugindl_s::argv, lcas_log(), lcas_log_close(), lcas_log_debug(), lcas_log_time(), LCAS_MOD_SUCCESS, lcas_plugindl_t, lcas_plugindl_s::next, lcas_plugindl_s::pluginname, lcas_plugindl_s::procs, and TERMPROC.


Generated on Fri May 27 18:10:48 2005 for lcas by doxygen 1.3.5