Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/AnonR/smanonr..../opt/saltstac.../salt/include
File: kdb.h
/* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
[0] Fix | Delete
/*
[1] Fix | Delete
* Copyright 1990, 1991, 2016 by the Massachusetts Institute of Technology.
[2] Fix | Delete
* All Rights Reserved.
[3] Fix | Delete
*
[4] Fix | Delete
* Export of this software from the United States of America may
[5] Fix | Delete
* require a specific license from the United States Government.
[6] Fix | Delete
* It is the responsibility of any person or organization contemplating
[7] Fix | Delete
* export to obtain such a license before exporting.
[8] Fix | Delete
*
[9] Fix | Delete
* WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
[10] Fix | Delete
* distribute this software and its documentation for any purpose and
[11] Fix | Delete
* without fee is hereby granted, provided that the above copyright
[12] Fix | Delete
* notice appear in all copies and that both that copyright notice and
[13] Fix | Delete
* this permission notice appear in supporting documentation, and that
[14] Fix | Delete
* the name of M.I.T. not be used in advertising or publicity pertaining
[15] Fix | Delete
* to distribution of the software without specific, written prior
[16] Fix | Delete
* permission. Furthermore if you modify this software you must label
[17] Fix | Delete
* your software as modified software and not distribute it in such a
[18] Fix | Delete
* fashion that it might be confused with the original M.I.T. software.
[19] Fix | Delete
* M.I.T. makes no representations about the suitability of
[20] Fix | Delete
* this software for any purpose. It is provided "as is" without express
[21] Fix | Delete
* or implied warranty.
[22] Fix | Delete
*/
[23] Fix | Delete
/*
[24] Fix | Delete
* Copyright (C) 1998 by the FundsXpress, INC.
[25] Fix | Delete
*
[26] Fix | Delete
* All rights reserved.
[27] Fix | Delete
*
[28] Fix | Delete
* Export of this software from the United States of America may require
[29] Fix | Delete
* a specific license from the United States Government. It is the
[30] Fix | Delete
* responsibility of any person or organization contemplating export to
[31] Fix | Delete
* obtain such a license before exporting.
[32] Fix | Delete
*
[33] Fix | Delete
* WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
[34] Fix | Delete
* distribute this software and its documentation for any purpose and
[35] Fix | Delete
* without fee is hereby granted, provided that the above copyright
[36] Fix | Delete
* notice appear in all copies and that both that copyright notice and
[37] Fix | Delete
* this permission notice appear in supporting documentation, and that
[38] Fix | Delete
* the name of FundsXpress. not be used in advertising or publicity pertaining
[39] Fix | Delete
* to distribution of the software without specific, written prior
[40] Fix | Delete
* permission. FundsXpress makes no representations about the suitability of
[41] Fix | Delete
* this software for any purpose. It is provided "as is" without express
[42] Fix | Delete
* or implied warranty.
[43] Fix | Delete
*
[44] Fix | Delete
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
[45] Fix | Delete
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
[46] Fix | Delete
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
[47] Fix | Delete
*/
[48] Fix | Delete
/*
[49] Fix | Delete
* Copyright 2009 Sun Microsystems, Inc. All rights reserved.
[50] Fix | Delete
* Use is subject to license terms.
[51] Fix | Delete
*/
[52] Fix | Delete
[53] Fix | Delete
/* KDC Database interface definitions */
[54] Fix | Delete
[55] Fix | Delete
/* This API is not considered as stable as the main krb5 API.
[56] Fix | Delete
*
[57] Fix | Delete
* - We may make arbitrary incompatible changes between feature
[58] Fix | Delete
* releases (e.g. from 1.7 to 1.8).
[59] Fix | Delete
* - We will make some effort to avoid making incompatible changes for
[60] Fix | Delete
* bugfix releases, but will make them if necessary.
[61] Fix | Delete
*/
[62] Fix | Delete
[63] Fix | Delete
#ifndef KRB5_KDB5__
[64] Fix | Delete
#define KRB5_KDB5__
[65] Fix | Delete
[66] Fix | Delete
#include <time.h>
[67] Fix | Delete
#include <krb5.h>
[68] Fix | Delete
[69] Fix | Delete
/* This version will be incremented when incompatible changes are made to the
[70] Fix | Delete
* KDB API, and will be kept in sync with the libkdb major version. */
[71] Fix | Delete
#define KRB5_KDB_API_VERSION 10
[72] Fix | Delete
[73] Fix | Delete
/* Salt types */
[74] Fix | Delete
#define KRB5_KDB_SALTTYPE_NORMAL 0
[75] Fix | Delete
/* #define KRB5_KDB_SALTTYPE_V4 1 */
[76] Fix | Delete
#define KRB5_KDB_SALTTYPE_NOREALM 2
[77] Fix | Delete
#define KRB5_KDB_SALTTYPE_ONLYREALM 3
[78] Fix | Delete
#define KRB5_KDB_SALTTYPE_SPECIAL 4
[79] Fix | Delete
/* #define KRB5_KDB_SALTTYPE_AFS3 5 */
[80] Fix | Delete
#define KRB5_KDB_SALTTYPE_CERTHASH 6
[81] Fix | Delete
[82] Fix | Delete
/* Attributes */
[83] Fix | Delete
#define KRB5_KDB_DISALLOW_POSTDATED 0x00000001
[84] Fix | Delete
#define KRB5_KDB_DISALLOW_FORWARDABLE 0x00000002
[85] Fix | Delete
#define KRB5_KDB_DISALLOW_TGT_BASED 0x00000004
[86] Fix | Delete
#define KRB5_KDB_DISALLOW_RENEWABLE 0x00000008
[87] Fix | Delete
#define KRB5_KDB_DISALLOW_PROXIABLE 0x00000010
[88] Fix | Delete
#define KRB5_KDB_DISALLOW_DUP_SKEY 0x00000020
[89] Fix | Delete
#define KRB5_KDB_DISALLOW_ALL_TIX 0x00000040
[90] Fix | Delete
#define KRB5_KDB_REQUIRES_PRE_AUTH 0x00000080
[91] Fix | Delete
#define KRB5_KDB_REQUIRES_HW_AUTH 0x00000100
[92] Fix | Delete
#define KRB5_KDB_REQUIRES_PWCHANGE 0x00000200
[93] Fix | Delete
#define KRB5_KDB_DISALLOW_SVR 0x00001000
[94] Fix | Delete
#define KRB5_KDB_PWCHANGE_SERVICE 0x00002000
[95] Fix | Delete
#define KRB5_KDB_SUPPORT_DESMD5 0x00004000
[96] Fix | Delete
#define KRB5_KDB_NEW_PRINC 0x00008000
[97] Fix | Delete
#define KRB5_KDB_OK_AS_DELEGATE 0x00100000
[98] Fix | Delete
#define KRB5_KDB_OK_TO_AUTH_AS_DELEGATE 0x00200000 /* S4U2Self OK */
[99] Fix | Delete
#define KRB5_KDB_NO_AUTH_DATA_REQUIRED 0x00400000
[100] Fix | Delete
#define KRB5_KDB_LOCKDOWN_KEYS 0x00800000
[101] Fix | Delete
[102] Fix | Delete
/* Creation flags */
[103] Fix | Delete
#define KRB5_KDB_CREATE_BTREE 0x00000001
[104] Fix | Delete
#define KRB5_KDB_CREATE_HASH 0x00000002
[105] Fix | Delete
[106] Fix | Delete
/* Entry get flags */
[107] Fix | Delete
/* Okay to generate a referral on lookup */
[108] Fix | Delete
#define KRB5_KDB_FLAG_REFERRAL_OK 0x00000010
[109] Fix | Delete
/* Client principal lookup (client referrals only) */
[110] Fix | Delete
#define KRB5_KDB_FLAG_CLIENT 0x00000040
[111] Fix | Delete
/* Map cross-realm principals */
[112] Fix | Delete
#define KRB5_KDB_FLAG_MAP_PRINCIPALS 0x00000080
[113] Fix | Delete
/* Protocol transition */
[114] Fix | Delete
#define KRB5_KDB_FLAG_PROTOCOL_TRANSITION 0x00000100
[115] Fix | Delete
/* Constrained delegation */
[116] Fix | Delete
#define KRB5_KDB_FLAG_CONSTRAINED_DELEGATION 0x00000200
[117] Fix | Delete
/* User-to-user */
[118] Fix | Delete
#define KRB5_KDB_FLAG_USER_TO_USER 0x00000800
[119] Fix | Delete
/* Cross-realm */
[120] Fix | Delete
#define KRB5_KDB_FLAG_CROSS_REALM 0x00001000
[121] Fix | Delete
/* Issuing referral */
[122] Fix | Delete
#define KRB5_KDB_FLAG_ISSUING_REFERRAL 0x00004000
[123] Fix | Delete
[124] Fix | Delete
[125] Fix | Delete
#define KRB5_KDB_FLAGS_S4U ( KRB5_KDB_FLAG_PROTOCOL_TRANSITION | \
[126] Fix | Delete
KRB5_KDB_FLAG_CONSTRAINED_DELEGATION )
[127] Fix | Delete
[128] Fix | Delete
/* KDB iteration flags */
[129] Fix | Delete
#define KRB5_DB_ITER_WRITE 0x00000001
[130] Fix | Delete
#define KRB5_DB_ITER_REV 0x00000002
[131] Fix | Delete
#define KRB5_DB_ITER_RECURSE 0x00000004
[132] Fix | Delete
[133] Fix | Delete
/* String attribute names recognized by krb5 */
[134] Fix | Delete
#define KRB5_KDB_SK_PAC_PRIVSVR_ENCTYPE "pac_privsvr_enctype"
[135] Fix | Delete
#define KRB5_KDB_SK_SESSION_ENCTYPES "session_enctypes"
[136] Fix | Delete
#define KRB5_KDB_SK_REQUIRE_AUTH "require_auth"
[137] Fix | Delete
[138] Fix | Delete
#if !defined(_WIN32)
[139] Fix | Delete
[140] Fix | Delete
/*
[141] Fix | Delete
* Note --- these structures cannot be modified without changing the
[142] Fix | Delete
* database version number in libkdb.a, but should be expandable by
[143] Fix | Delete
* adding new tl_data types.
[144] Fix | Delete
*/
[145] Fix | Delete
typedef struct _krb5_tl_data {
[146] Fix | Delete
struct _krb5_tl_data* tl_data_next; /* NOT saved */
[147] Fix | Delete
krb5_int16 tl_data_type;
[148] Fix | Delete
krb5_ui_2 tl_data_length;
[149] Fix | Delete
krb5_octet * tl_data_contents;
[150] Fix | Delete
} krb5_tl_data;
[151] Fix | Delete
[152] Fix | Delete
/* String attributes (currently stored inside tl-data) map C string keys to
[153] Fix | Delete
* values. They can be set via kadmin and consumed by KDC plugins. */
[154] Fix | Delete
typedef struct krb5_string_attr_st {
[155] Fix | Delete
char *key;
[156] Fix | Delete
char *value;
[157] Fix | Delete
} krb5_string_attr;
[158] Fix | Delete
[159] Fix | Delete
/*
[160] Fix | Delete
* If this ever changes up the version number and make the arrays be as
[161] Fix | Delete
* big as necessary.
[162] Fix | Delete
*
[163] Fix | Delete
* Currently the first type is the enctype and the second is the salt type.
[164] Fix | Delete
*/
[165] Fix | Delete
typedef struct _krb5_key_data {
[166] Fix | Delete
krb5_int16 key_data_ver; /* Version */
[167] Fix | Delete
krb5_ui_2 key_data_kvno; /* Key Version */
[168] Fix | Delete
krb5_int16 key_data_type[2]; /* Array of types */
[169] Fix | Delete
krb5_ui_2 key_data_length[2]; /* Array of lengths */
[170] Fix | Delete
krb5_octet * key_data_contents[2]; /* Array of pointers */
[171] Fix | Delete
} krb5_key_data;
[172] Fix | Delete
[173] Fix | Delete
#define KRB5_KDB_V1_KEY_DATA_ARRAY 2 /* # of array elements */
[174] Fix | Delete
[175] Fix | Delete
typedef struct _krb5_keysalt {
[176] Fix | Delete
krb5_int16 type;
[177] Fix | Delete
krb5_data data; /* Length, data */
[178] Fix | Delete
} krb5_keysalt;
[179] Fix | Delete
[180] Fix | Delete
/*
[181] Fix | Delete
* A principal database entry. Extensions to this structure currently use the
[182] Fix | Delete
* tl_data list. The e_data and e_length fields are not used by any calling
[183] Fix | Delete
* code except kdb5_util dump and load, which marshal and unmarshal the array
[184] Fix | Delete
* in the dump record. KDB modules may use these fields internally as long as
[185] Fix | Delete
* they set e_length appropriately (non-zero if the data should be marshalled
[186] Fix | Delete
* across dump and load, zero if not) and handle null e_data values in
[187] Fix | Delete
* caller-constructed principal entries.
[188] Fix | Delete
*/
[189] Fix | Delete
typedef struct _krb5_db_entry_new {
[190] Fix | Delete
krb5_magic magic; /* NOT saved */
[191] Fix | Delete
krb5_ui_2 len;
[192] Fix | Delete
krb5_ui_4 mask; /* members currently changed/set */
[193] Fix | Delete
krb5_flags attributes;
[194] Fix | Delete
krb5_deltat max_life;
[195] Fix | Delete
krb5_deltat max_renewable_life;
[196] Fix | Delete
krb5_timestamp expiration; /* When the client expires */
[197] Fix | Delete
krb5_timestamp pw_expiration; /* When its passwd expires */
[198] Fix | Delete
krb5_timestamp last_success; /* Last successful passwd */
[199] Fix | Delete
krb5_timestamp last_failed; /* Last failed passwd attempt */
[200] Fix | Delete
krb5_kvno fail_auth_count; /* # of failed passwd attempt */
[201] Fix | Delete
krb5_int16 n_tl_data;
[202] Fix | Delete
krb5_int16 n_key_data;
[203] Fix | Delete
krb5_ui_2 e_length; /* Length of extra data */
[204] Fix | Delete
krb5_octet * e_data; /* Extra data to be saved */
[205] Fix | Delete
[206] Fix | Delete
krb5_principal princ; /* Length, data */
[207] Fix | Delete
krb5_tl_data * tl_data; /* Linked list */
[208] Fix | Delete
[209] Fix | Delete
/* key_data must be sorted by kvno in descending order. */
[210] Fix | Delete
krb5_key_data * key_data; /* Array */
[211] Fix | Delete
} krb5_db_entry;
[212] Fix | Delete
[213] Fix | Delete
typedef struct _osa_policy_ent_t {
[214] Fix | Delete
int version;
[215] Fix | Delete
char *name;
[216] Fix | Delete
krb5_ui_4 pw_min_life;
[217] Fix | Delete
krb5_ui_4 pw_max_life;
[218] Fix | Delete
krb5_ui_4 pw_min_length;
[219] Fix | Delete
krb5_ui_4 pw_min_classes;
[220] Fix | Delete
krb5_ui_4 pw_history_num;
[221] Fix | Delete
krb5_ui_4 policy_refcnt; /* no longer used */
[222] Fix | Delete
/* Only valid if version > 1 */
[223] Fix | Delete
krb5_ui_4 pw_max_fail; /* pwdMaxFailure */
[224] Fix | Delete
krb5_ui_4 pw_failcnt_interval; /* pwdFailureCountInterval */
[225] Fix | Delete
krb5_ui_4 pw_lockout_duration; /* pwdLockoutDuration */
[226] Fix | Delete
/* Only valid if version > 2 */
[227] Fix | Delete
krb5_ui_4 attributes;
[228] Fix | Delete
krb5_ui_4 max_life;
[229] Fix | Delete
krb5_ui_4 max_renewable_life;
[230] Fix | Delete
char * allowed_keysalts;
[231] Fix | Delete
krb5_int16 n_tl_data;
[232] Fix | Delete
krb5_tl_data * tl_data;
[233] Fix | Delete
} osa_policy_ent_rec, *osa_policy_ent_t;
[234] Fix | Delete
[235] Fix | Delete
typedef void (*osa_adb_iter_policy_func) (void *, osa_policy_ent_t);
[236] Fix | Delete
[237] Fix | Delete
typedef struct __krb5_key_salt_tuple {
[238] Fix | Delete
krb5_enctype ks_enctype;
[239] Fix | Delete
krb5_int32 ks_salttype;
[240] Fix | Delete
} krb5_key_salt_tuple;
[241] Fix | Delete
[242] Fix | Delete
#define KRB5_KDB_MAGIC_NUMBER 0xdbdbdbdb
[243] Fix | Delete
#define KRB5_KDB_V1_BASE_LENGTH 38
[244] Fix | Delete
[245] Fix | Delete
#define KRB5_KDB_MAX_ALLOWED_KS_LEN 512
[246] Fix | Delete
[247] Fix | Delete
#define KRB5_TL_LAST_PWD_CHANGE 0x0001
[248] Fix | Delete
#define KRB5_TL_MOD_PRINC 0x0002
[249] Fix | Delete
#define KRB5_TL_KADM_DATA 0x0003
[250] Fix | Delete
#define KRB5_TL_KADM5_E_DATA 0x0004
[251] Fix | Delete
#define KRB5_TL_RB1_CHALLENGE 0x0005
[252] Fix | Delete
#ifdef SECURID
[253] Fix | Delete
#define KRB5_TL_SECURID_STATE 0x0006
[254] Fix | Delete
#endif /* SECURID */
[255] Fix | Delete
#define KRB5_TL_USER_CERTIFICATE 0x0007
[256] Fix | Delete
#define KRB5_TL_MKVNO 0x0008
[257] Fix | Delete
#define KRB5_TL_ACTKVNO 0x0009
[258] Fix | Delete
#define KRB5_TL_MKEY_AUX 0x000a
[259] Fix | Delete
[260] Fix | Delete
/* String attributes may not always be represented in tl-data. kadmin clients
[261] Fix | Delete
* must use the get_strings and set_string RPCs. */
[262] Fix | Delete
#define KRB5_TL_STRING_ATTRS 0x000b
[263] Fix | Delete
[264] Fix | Delete
#define KRB5_TL_PAC_LOGON_INFO 0x0100 /* NDR encoded validation info */
[265] Fix | Delete
#define KRB5_TL_SERVER_REFERRAL 0x0200 /* ASN.1 encoded ServerReferralInfo */
[266] Fix | Delete
#define KRB5_TL_SVR_REFERRAL_DATA 0x0300 /* ASN.1 encoded PA-SVR-REFERRAL-DATA */
[267] Fix | Delete
#define KRB5_TL_CONSTRAINED_DELEGATION_ACL 0x0400 /* Each entry is a permitted SPN */
[268] Fix | Delete
#define KRB5_TL_LM_KEY 0x0500 /* LM OWF */
[269] Fix | Delete
#define KRB5_TL_X509_SUBJECT_ISSUER_NAME 0x0600 /* <I>IssuerDN<S>SubjectDN */
[270] Fix | Delete
#define KRB5_TL_LAST_ADMIN_UNLOCK 0x0700 /* Timestamp of admin unlock */
[271] Fix | Delete
[272] Fix | Delete
#define KRB5_TL_DB_ARGS 0x7fff
[273] Fix | Delete
[274] Fix | Delete
/* version number for KRB5_TL_ACTKVNO data */
[275] Fix | Delete
#define KRB5_TL_ACTKVNO_VER 1
[276] Fix | Delete
[277] Fix | Delete
/* version number for KRB5_TL_MKEY_AUX data */
[278] Fix | Delete
#define KRB5_TL_MKEY_AUX_VER 1
[279] Fix | Delete
[280] Fix | Delete
typedef struct _krb5_actkvno_node {
[281] Fix | Delete
struct _krb5_actkvno_node *next;
[282] Fix | Delete
krb5_kvno act_kvno;
[283] Fix | Delete
krb5_timestamp act_time;
[284] Fix | Delete
} krb5_actkvno_node;
[285] Fix | Delete
[286] Fix | Delete
typedef struct _krb5_mkey_aux_node {
[287] Fix | Delete
struct _krb5_mkey_aux_node *next;
[288] Fix | Delete
krb5_kvno mkey_kvno; /* kvno of mkey protecting the latest_mkey */
[289] Fix | Delete
krb5_key_data latest_mkey; /* most recent mkey */
[290] Fix | Delete
} krb5_mkey_aux_node;
[291] Fix | Delete
[292] Fix | Delete
typedef struct _krb5_keylist_node {
[293] Fix | Delete
krb5_keyblock keyblock;
[294] Fix | Delete
krb5_kvno kvno;
[295] Fix | Delete
struct _krb5_keylist_node *next;
[296] Fix | Delete
} krb5_keylist_node;
[297] Fix | Delete
[298] Fix | Delete
/*
[299] Fix | Delete
* Determines the number of failed KDC requests before DISALLOW_ALL_TIX is set
[300] Fix | Delete
* on the principal.
[301] Fix | Delete
*/
[302] Fix | Delete
#define KRB5_MAX_FAIL_COUNT 5
[303] Fix | Delete
[304] Fix | Delete
/* XXX depends on knowledge of krb5_parse_name() formats */
[305] Fix | Delete
#define KRB5_KDB_M_NAME "K/M" /* Kerberos/Master */
[306] Fix | Delete
[307] Fix | Delete
/* prompts used by default when reading the KDC password from the keyboard. */
[308] Fix | Delete
#define KRB5_KDC_MKEY_1 "Enter KDC database master key"
[309] Fix | Delete
#define KRB5_KDC_MKEY_2 "Re-enter KDC database master key to verify"
[310] Fix | Delete
[311] Fix | Delete
[312] Fix | Delete
extern char *krb5_mkey_pwd_prompt1;
[313] Fix | Delete
extern char *krb5_mkey_pwd_prompt2;
[314] Fix | Delete
[315] Fix | Delete
/*
[316] Fix | Delete
* These macros specify the encoding of data within the database.
[317] Fix | Delete
*
[318] Fix | Delete
* Data encoding is little-endian.
[319] Fix | Delete
*/
[320] Fix | Delete
#ifdef _KRB5_INT_H
[321] Fix | Delete
#include "k5-platform.h"
[322] Fix | Delete
#define krb5_kdb_decode_int16(cp, i16) \
[323] Fix | Delete
*((krb5_int16 *) &(i16)) = load_16_le(cp)
[324] Fix | Delete
#define krb5_kdb_decode_int32(cp, i32) \
[325] Fix | Delete
*((krb5_int32 *) &(i32)) = load_32_le(cp)
[326] Fix | Delete
#define krb5_kdb_encode_int16(i16, cp) store_16_le(i16, cp)
[327] Fix | Delete
#define krb5_kdb_encode_int32(i32, cp) store_32_le(i32, cp)
[328] Fix | Delete
#endif /* _KRB5_INT_H */
[329] Fix | Delete
[330] Fix | Delete
#define KRB5_KDB_OPEN_RW 0
[331] Fix | Delete
#define KRB5_KDB_OPEN_RO 1
[332] Fix | Delete
[333] Fix | Delete
#ifndef KRB5_KDB_SRV_TYPE_KDC
[334] Fix | Delete
#define KRB5_KDB_SRV_TYPE_KDC 0x0100
[335] Fix | Delete
#endif
[336] Fix | Delete
[337] Fix | Delete
#ifndef KRB5_KDB_SRV_TYPE_ADMIN
[338] Fix | Delete
#define KRB5_KDB_SRV_TYPE_ADMIN 0x0200
[339] Fix | Delete
#endif
[340] Fix | Delete
[341] Fix | Delete
/* 0x0300 was KRB5_KDB_SRV_TYPE_PASSWD but it is no longer used. */
[342] Fix | Delete
[343] Fix | Delete
#ifndef KRB5_KDB_SRV_TYPE_OTHER
[344] Fix | Delete
#define KRB5_KDB_SRV_TYPE_OTHER 0x0400
[345] Fix | Delete
#endif
[346] Fix | Delete
[347] Fix | Delete
#define KRB5_KDB_OPT_SET_DB_NAME 0
[348] Fix | Delete
#define KRB5_KDB_OPT_SET_LOCK_MODE 1
[349] Fix | Delete
[350] Fix | Delete
#define KRB5_DB_LOCKMODE_SHARED 0x0001
[351] Fix | Delete
#define KRB5_DB_LOCKMODE_EXCLUSIVE 0x0002
[352] Fix | Delete
#define KRB5_DB_LOCKMODE_PERMANENT 0x0008
[353] Fix | Delete
[354] Fix | Delete
/* libkdb.spec */
[355] Fix | Delete
krb5_error_code krb5_db_setup_lib_handle(krb5_context kcontext);
[356] Fix | Delete
krb5_error_code krb5_db_open( krb5_context kcontext, char **db_args, int mode );
[357] Fix | Delete
krb5_error_code krb5_db_init ( krb5_context kcontext );
[358] Fix | Delete
krb5_error_code krb5_db_create ( krb5_context kcontext, char **db_args );
[359] Fix | Delete
krb5_error_code krb5_db_inited ( krb5_context kcontext );
[360] Fix | Delete
krb5_error_code kdb5_db_create ( krb5_context kcontext, char **db_args );
[361] Fix | Delete
krb5_error_code krb5_db_fini ( krb5_context kcontext );
[362] Fix | Delete
const char * krb5_db_errcode2string ( krb5_context kcontext, long err_code );
[363] Fix | Delete
krb5_error_code krb5_db_destroy ( krb5_context kcontext, char **db_args );
[364] Fix | Delete
krb5_error_code krb5_db_promote ( krb5_context kcontext, char **db_args );
[365] Fix | Delete
krb5_error_code krb5_db_get_age ( krb5_context kcontext, char *db_name, time_t *t );
[366] Fix | Delete
krb5_error_code krb5_db_lock ( krb5_context kcontext, int lock_mode );
[367] Fix | Delete
krb5_error_code krb5_db_unlock ( krb5_context kcontext );
[368] Fix | Delete
krb5_error_code krb5_db_get_principal ( krb5_context kcontext,
[369] Fix | Delete
krb5_const_principal search_for,
[370] Fix | Delete
unsigned int flags,
[371] Fix | Delete
krb5_db_entry **entry );
[372] Fix | Delete
void krb5_db_free_principal ( krb5_context kcontext, krb5_db_entry *entry );
[373] Fix | Delete
krb5_error_code krb5_db_put_principal ( krb5_context kcontext,
[374] Fix | Delete
krb5_db_entry *entry );
[375] Fix | Delete
krb5_error_code krb5_db_delete_principal ( krb5_context kcontext,
[376] Fix | Delete
krb5_principal search_for );
[377] Fix | Delete
krb5_error_code krb5_db_rename_principal ( krb5_context kcontext,
[378] Fix | Delete
krb5_principal source,
[379] Fix | Delete
krb5_principal target );
[380] Fix | Delete
[381] Fix | Delete
/*
[382] Fix | Delete
* Iterate over principals in the KDB. If the callback may write to the DB,
[383] Fix | Delete
* the caller must get an exclusive lock with krb5_db_lock before iterating,
[384] Fix | Delete
* and release it with krb5_db_unlock after iterating.
[385] Fix | Delete
*/
[386] Fix | Delete
krb5_error_code krb5_db_iterate ( krb5_context kcontext,
[387] Fix | Delete
char *match_entry,
[388] Fix | Delete
int (*func) (krb5_pointer, krb5_db_entry *),
[389] Fix | Delete
krb5_pointer func_arg, krb5_flags iterflags );
[390] Fix | Delete
[391] Fix | Delete
[392] Fix | Delete
krb5_error_code krb5_db_store_master_key ( krb5_context kcontext,
[393] Fix | Delete
char *keyfile,
[394] Fix | Delete
krb5_principal mname,
[395] Fix | Delete
krb5_kvno kvno,
[396] Fix | Delete
krb5_keyblock *key,
[397] Fix | Delete
char *master_pwd);
[398] Fix | Delete
krb5_error_code krb5_db_store_master_key_list ( krb5_context kcontext,
[399] Fix | Delete
char *keyfile,
[400] Fix | Delete
krb5_principal mname,
[401] Fix | Delete
char *master_pwd);
[402] Fix | Delete
krb5_error_code krb5_db_fetch_mkey ( krb5_context context,
[403] Fix | Delete
krb5_principal mname,
[404] Fix | Delete
krb5_enctype etype,
[405] Fix | Delete
krb5_boolean fromkeyboard,
[406] Fix | Delete
krb5_boolean twice,
[407] Fix | Delete
char *db_args,
[408] Fix | Delete
krb5_kvno *kvno,
[409] Fix | Delete
krb5_data *salt,
[410] Fix | Delete
krb5_keyblock *key);
[411] Fix | Delete
krb5_error_code
[412] Fix | Delete
krb5_db_fetch_mkey_list( krb5_context context,
[413] Fix | Delete
krb5_principal mname,
[414] Fix | Delete
const krb5_keyblock * mkey );
[415] Fix | Delete
[416] Fix | Delete
krb5_error_code
[417] Fix | Delete
krb5_dbe_find_enctype( krb5_context kcontext,
[418] Fix | Delete
krb5_db_entry *dbentp,
[419] Fix | Delete
krb5_int32 ktype,
[420] Fix | Delete
krb5_int32 stype,
[421] Fix | Delete
krb5_int32 kvno,
[422] Fix | Delete
krb5_key_data **kdatap);
[423] Fix | Delete
[424] Fix | Delete
[425] Fix | Delete
krb5_error_code krb5_dbe_search_enctype ( krb5_context kcontext,
[426] Fix | Delete
krb5_db_entry *dbentp,
[427] Fix | Delete
krb5_int32 *start,
[428] Fix | Delete
krb5_int32 ktype,
[429] Fix | Delete
krb5_int32 stype,
[430] Fix | Delete
krb5_int32 kvno,
[431] Fix | Delete
krb5_key_data **kdatap);
[432] Fix | Delete
[433] Fix | Delete
krb5_error_code
[434] Fix | Delete
krb5_db_setup_mkey_name ( krb5_context context,
[435] Fix | Delete
const char *keyname,
[436] Fix | Delete
const char *realm,
[437] Fix | Delete
char **fullname,
[438] Fix | Delete
krb5_principal *principal);
[439] Fix | Delete
[440] Fix | Delete
/**
[441] Fix | Delete
* Decrypts the key given in @@a key_data. If @a mkey is specified, that
[442] Fix | Delete
* master key is used. If @a mkey is NULL, then all master keys are tried.
[443] Fix | Delete
*/
[444] Fix | Delete
krb5_error_code
[445] Fix | Delete
krb5_dbe_decrypt_key_data( krb5_context context,
[446] Fix | Delete
const krb5_keyblock * mkey,
[447] Fix | Delete
const krb5_key_data * key_data,
[448] Fix | Delete
krb5_keyblock * dbkey,
[449] Fix | Delete
krb5_keysalt * keysalt);
[450] Fix | Delete
[451] Fix | Delete
krb5_error_code
[452] Fix | Delete
krb5_dbe_encrypt_key_data( krb5_context context,
[453] Fix | Delete
const krb5_keyblock * mkey,
[454] Fix | Delete
const krb5_keyblock * dbkey,
[455] Fix | Delete
const krb5_keysalt * keysalt,
[456] Fix | Delete
int keyver,
[457] Fix | Delete
krb5_key_data * key_data);
[458] Fix | Delete
[459] Fix | Delete
krb5_error_code
[460] Fix | Delete
krb5_dbe_fetch_act_key_list(krb5_context context,
[461] Fix | Delete
krb5_principal princ,
[462] Fix | Delete
krb5_actkvno_node **act_key_list);
[463] Fix | Delete
[464] Fix | Delete
krb5_error_code
[465] Fix | Delete
krb5_dbe_find_act_mkey( krb5_context context,
[466] Fix | Delete
krb5_actkvno_node * act_mkey_list,
[467] Fix | Delete
krb5_kvno * act_kvno,
[468] Fix | Delete
krb5_keyblock ** act_mkey);
[469] Fix | Delete
[470] Fix | Delete
krb5_error_code
[471] Fix | Delete
krb5_dbe_find_mkey( krb5_context context,
[472] Fix | Delete
krb5_db_entry * entry,
[473] Fix | Delete
krb5_keyblock ** mkey);
[474] Fix | Delete
[475] Fix | Delete
/* Set *mkvno to mkvno in entry tl_data, or 0 if not present. */
[476] Fix | Delete
krb5_error_code
[477] Fix | Delete
krb5_dbe_lookup_mkvno( krb5_context context,
[478] Fix | Delete
krb5_db_entry * entry,
[479] Fix | Delete
krb5_kvno * mkvno);
[480] Fix | Delete
[481] Fix | Delete
krb5_keylist_node *
[482] Fix | Delete
krb5_db_mkey_list_alias( krb5_context kcontext );
[483] Fix | Delete
[484] Fix | Delete
/* Set *mkvno to mkvno in entry tl_data, or minimum value from mkey_list. */
[485] Fix | Delete
krb5_error_code
[486] Fix | Delete
krb5_dbe_get_mkvno( krb5_context context,
[487] Fix | Delete
krb5_db_entry * entry,
[488] Fix | Delete
krb5_kvno * mkvno);
[489] Fix | Delete
[490] Fix | Delete
krb5_error_code
[491] Fix | Delete
krb5_dbe_lookup_mod_princ_data( krb5_context context,
[492] Fix | Delete
krb5_db_entry * entry,
[493] Fix | Delete
krb5_timestamp * mod_time,
[494] Fix | Delete
krb5_principal * mod_princ);
[495] Fix | Delete
[496] Fix | Delete
krb5_error_code
[497] Fix | Delete
krb5_dbe_lookup_mkey_aux( krb5_context context,
[498] Fix | Delete
krb5_db_entry * entry,
[499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function