Argus PEP client API  2.3
pep.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) Members of the EGEE Collaboration. 2006-2010.
3  * See http://www.eu-egee.org/partners/ for details on the copyright holders.
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17 
18 /*
19  * Argus PEP client API
20  *
21  * $Id$
22  * @author Valery Tschopp <valery.tschopp@switch.ch>
23  * @version 2.1
24  */
25 #ifndef _PEP_H_
26 #define _PEP_H_
27 
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
31 
71 #include <stdarg.h> /* va_list */
72 #include "xacml.h"
73 #include "profiles.h"
74 #include "pip.h"
75 #include "oh.h"
76 #include "error.h"
77 
78 
79 
107 #define PEP_LOGLEVEL_NONE -1
108 #define PEP_LOGLEVEL_ERROR 0
109 #define PEP_LOGLEVEL_WARN 1
110 #define PEP_LOGLEVEL_INFO 2
111 #define PEP_LOGLEVEL_DEBUG 3
152 typedef int pep_log_handler_callback(int level, const char * format, va_list args);
153 
166 typedef struct pep_handle PEP;
167 
173 typedef enum pep_option {
188 } pep_option_t;
189 
194 const char * pep_version(void);
195 
210 
222 void pep_global_cleanup(void);
223 
231 PEP * pep_initialize(void);
232 
240 int pep_getid(PEP * pep);
241 
253 pep_error_t pep_addpip(PEP * pep, const pep_pip_t * pip);
254 
267 
325 pep_error_t pep_setoption(PEP * pep, pep_option_t option, ... );
326 
343 pep_error_t pep_authorize(PEP * pep, xacml_request_t ** request, xacml_response_t ** response);
344 
352 void pep_destroy(PEP * pep);
353 
360 #ifdef __cplusplus
361 }
362 #endif
363 
364 #endif