next up previous
Next: User guide Up: Guide to LCAS Previous: Configuration

Adding authorization plugins

In addition to the three standard authorization plugins, new plugins may be written. The plugins have to be provided as shared objects. When the LCAS receives an authorization request, it uses dlopen to open the plugin shared object. The interface of the plugins to the LCAS consists of the following three functions, which are called in order with a dlsym call by the LCAS:

If these symbols cannot be found by LCAS at runtime, an error occurs, resulting in an authorization failure. More information on the plugin interface can be found in the apidoc documentation for the plugin interface. The LCAS Library also contains utilities for logging, file checking and (extremely simple) LCAS credential handling. The API to be used by the LCAS plugins can be found in the apidoc documentation for the API for the plugins. In order to use these utilities a line like
#include "lcas_modules.h"
has to appear in the plugin source. A line similar to
-I $GLOBUS_LOCATION/include/gcc32dbg -I /opt/edg/include/lcas
has to be added to the compilation command line in order to include the LCAS and GLOBUS include directories.

To make life easier for the plugin developer an example plugin has been written in C, which is available in the LCAS cvs repository. The example plugin is built using autotools (automake, autoconf, libtool), for which the files configure.in and Makefile.am have to be present. The source code can be found here. The new plugin can be tested without having a functioning edg-gatekeeper by running the program lcas-test in the src directory of the LCAS cvs repository, which is basically a copy of the part of the edg-gatekeeper that contacts the LCAS.


next up previous
Next: User guide Up: Guide to LCAS Previous: Configuration
Martijn Steenbakkers, Tuesday Sep 23 2003