krb5  1.18
About: Kerberos is a network authentication protocol. It is designed to provide strong authentication for client/server applications by using secret-key cryptography (MIT implementation). Current release.
  Fossies Dox: krb5-1.18.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

adb_policy.c File Reference
#include "k5-int.h"
#include <sys/file.h>
#include "policy_db.h"
Include dependency graph for adb_policy.c:

Go to the source code of this file.

Macros

#define OPENLOCK(db, mode)
 
#define CLOSELOCK(db)
 

Functions

krb5_error_code osa_adb_create_policy (osa_adb_policy_t db, osa_policy_ent_t entry)
 
krb5_error_code osa_adb_destroy_policy (osa_adb_policy_t db, char *name)
 
krb5_error_code osa_adb_get_policy (osa_adb_policy_t db, char *name, osa_policy_ent_t *entry_ptr)
 
krb5_error_code osa_adb_put_policy (osa_adb_policy_t db, osa_policy_ent_t entry)
 
krb5_error_code osa_adb_iter_policy (osa_adb_policy_t db, osa_adb_iter_policy_func func, void *data)
 
void osa_free_policy_ent (osa_policy_ent_t val)
 

Macro Definition Documentation

◆ CLOSELOCK

#define CLOSELOCK (   db)
Value:
{ \
int cl_ret; \
if ((cl_ret = osa_adb_close_and_unlock(db)) != OSA_ADB_OK) \
return cl_ret; \
}

Definition at line 24 of file adb_policy.c.

◆ OPENLOCK

#define OPENLOCK (   db,
  mode 
)
Value:
{ \
int olret; \
if (db == NULL) \
return EINVAL; \
else if (db->magic != OSA_ADB_POLICY_DB_MAGIC) \
return OSA_ADB_DBINIT; \
else if ((olret = osa_adb_open_and_lock(db, mode)) != OSA_ADB_OK) \
return olret; \
}

Definition at line 13 of file adb_policy.c.

Function Documentation

◆ osa_adb_create_policy()

◆ osa_adb_destroy_policy()

krb5_error_code osa_adb_destroy_policy ( osa_adb_policy_t  db,
char *  name 
)

◆ osa_adb_get_policy()

◆ osa_adb_iter_policy()

◆ osa_adb_put_policy()

◆ osa_free_policy_ent()

void osa_free_policy_ent ( osa_policy_ent_t  val)

Definition at line 374 of file adb_policy.c.

References free(), NULL, XDR_FREE, xdr_osa_policy_ent_rec(), and xdrmem_create.

Referenced by osa_adb_iter_policy().

mode
int mode
Definition: t_shs3.c:54
NULL
#define NULL
Definition: db-int.h:258
osa_adb_open_and_lock
krb5_error_code osa_adb_open_and_lock(osa_adb_princ_t db, int locktype)
Definition: adb_openclose.c:319
osa_adb_close_and_unlock
krb5_error_code osa_adb_close_and_unlock(osa_adb_princ_t db)
Definition: adb_openclose.c:348
OSA_ADB_POLICY_DB_MAGIC
#define OSA_ADB_POLICY_DB_MAGIC
Definition: policy_db.h:47
OSA_ADB_OK
#define OSA_ADB_OK
Definition: policy_db.h:77