source: libabac/abac_pl_yap.h @ e97d2e2

mei_rt2_fix_1
Last change on this file since e97d2e2 was 646e57e, checked in by Mei <mei@…>, 12 years ago

1) add partial proof

  • Property mode set to 100644
File size: 1.1 KB
Line 
1#ifndef __PL_YAP_H__
2#define __PL_YAP_H__
3
4#include "abac_internal.h"
5#include "abac_verifier.h"
6
7#define ABAC_PL_CRED_OK          0   // adding a credential succeeded
8#define ABAC_PL_CRED_INVALID     -1  // the credential was invalid
9#define ABAC_PL_CRED_DUP         -2  // the credential is already present
10
11typedef struct _abac_pl_t abac_pl_t;
12
13abac_pl_t *abac_pl_new(void);
14
15int abac_pl_add_credential(abac_pl_t *pl, abac_credential_t *cred);
16abac_pl_t *abac_pl_dup(abac_pl_t *pl);
17/* return a list of credentials */
18abac_stack_t *abac_pl_query(abac_pl_t *pl, char *role, char *principal);
19abac_stack_t *abac_pl_query_again(abac_pl_t *pl);
20abac_stack_t *abac_pl_query_with_structure(abac_pl_t *pl, abac_aspect_t *head_aspect, abac_aspect_t *tail_aspect);
21void abac_pl_set_no_partial(abac_pl_t *pl);
22void abac_pl_set_want_partial(abac_pl_t *pl);
23int abac_pl_returning_partial(abac_pl_t *pl);
24
25/* return a list of all credentials in the pl file */
26abac_stack_t *abac_pl_credentials(abac_pl_t *pl);
27abac_stack_t *abac_pl_principals(abac_pl_t *pl);
28
29void abac_pl_free(abac_pl_t *pl);
30
31
32#endif /* __PL_YAP_H__ */
Note: See TracBrowser for help on using the repository browser.