Difference between revisions of "Samba4 Port: hdb & ldb Interfaces"
From K5Wiki
(→heimdal-internal hdb interface) |
(→heimdal-internal hdb interface) |
||
Line 85: | Line 85: | ||
| free_hdb_entry |
| free_hdb_entry |
||
| heimdal/lib/hdb/asn1_hdb_entry.c |
| heimdal/lib/hdb/asn1_hdb_entry.c |
||
− | | both |
+ | | both + |
|- |
|- |
||
Line 115: | Line 115: | ||
| _hdb_find_master_key |
| _hdb_find_master_key |
||
| heimdal/lib/hdb/mkey.c |
| heimdal/lib/hdb/mkey.c |
||
− | | heimdal |
+ | | heimdal + |
|- |
|- |
||
| _hdb_mkey_decrypt |
| _hdb_mkey_decrypt |
||
| heimdal/lib/hdb/mkey.c |
| heimdal/lib/hdb/mkey.c |
||
− | | heimdal |
+ | | heimdal + |
|- |
|- |
||
Line 135: | Line 135: | ||
| hdb_check_db_format |
| hdb_check_db_format |
||
| heimdal/lib/hdb/hdb.c |
| heimdal/lib/hdb/hdb.c |
||
− | | heimdal |
+ | | heimdal + |
|- |
|- |
||
Line 145: | Line 145: | ||
| hdb_clear_master_key |
| hdb_clear_master_key |
||
| heimdal/lib/hdb/mkey.c |
| heimdal/lib/hdb/mkey.c |
||
− | | heimdal |
+ | | heimdal + |
|- |
|- |
||
Line 155: | Line 155: | ||
| hdb_db_dir |
| hdb_db_dir |
||
| heimdal/lib/hdb/dbinfo.c |
| heimdal/lib/hdb/dbinfo.c |
||
− | | heimdal |
+ | | heimdal + |
|- |
|- |
||
Line 199: | Line 199: | ||
|- |
|- |
||
| hdb_free_dbinfo |
| hdb_free_dbinfo |
||
+ | | heimdal/lib/hdb/dbinfo.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_get_dbinfo |
||
| heimdal/lib/hdb/dbinfo.c |
| heimdal/lib/hdb/dbinfo.c |
||
| no |
| no |
||
Line 206: | Line 211: | ||
| heimdal/lib/hdb/dbinfo.c |
| heimdal/lib/hdb/dbinfo.c |
||
| no |
| no |
||
+ | |||
+ | |- |
||
+ | | hdb_init_db |
||
+ | | heimdal/lib/hdb/hdb.c |
||
+ | | heimdal |
||
|- |
|- |
||
| hdb_enctype2key |
| hdb_enctype2key |
||
| heimdal/lib/hdb/hdb.c |
| heimdal/lib/hdb/hdb.c |
||
− | | both |
+ | | both ++ |
|- |
|- |
||
Line 265: | Line 275: | ||
| hdb_find_extension |
| hdb_find_extension |
||
| heimdal/lib/hdb/ext.c |
| heimdal/lib/hdb/ext.c |
||
− | | heimdal |
+ | | heimdal + |
|- |
|- |
||
Line 275: | Line 285: | ||
| hdb_free_entry |
| hdb_free_entry |
||
| heimdal/lib/hdb/hdb.c |
| heimdal/lib/hdb/hdb.c |
||
− | | both |
+ | | both ++ |
+ | |- |
||
+ | | hdb_free_key |
||
+ | | heimdal/lib/hdb/hdb.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_free_keys |
||
+ | | heimdal/lib/hdb/keys.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_free_master_key |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_generate_key_set |
||
+ | | heimdal/lib/hdb/keys.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_generate_key_set_password |
||
+ | | heimdal/lib/hdb/keys.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_kt_ops{} |
||
+ | | heimdal/lib/hdb/keytab.c |
||
+ | | samba4 |
||
+ | |||
+ | |- |
||
+ | | hdb_list_builtin |
||
+ | | heimdal/lib/hdb/hdb.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_lock (func ptr) |
||
+ | | kdc/hdb-samba4.c |
||
+ | | heimdal ++ |
||
+ | |||
+ | |- |
||
+ | | hdb_lock |
||
+ | | heimdal/lib/hdb/hdb.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_next_enctype2key |
||
+ | | heimdal/lib/hdb/hdb.c |
||
+ | | heimdal + |
||
+ | |||
+ | |- |
||
+ | | hdb_process_master_key |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal + |
||
+ | |||
+ | |- |
||
+ | | hdb_read_master_key |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_replace_extension |
||
+ | | heimdal/lib/hdb/ext.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_seal_key |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_seal_keys |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_seal_key_mkey |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_seal_keys_mkey |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_set_master_key |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_set_master_keyfile |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_unlock (func ptr) |
||
+ | | kdc/hdb-samba4.c |
||
+ | | heimdal ++ |
||
+ | |||
+ | |- |
||
+ | | hdb_unlock |
||
+ | | heimdal/lib/hdb/hdb.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_unseal_key |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | no |
||
+ | |||
+ | |- |
||
+ | | hdb_unseal_keys |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal + |
||
+ | |||
+ | |- |
||
+ | | hdb_unseal_key_mkey |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal |
||
+ | |||
+ | |- |
||
+ | | hdb_unseal_keys_mkey |
||
+ | | heimdal/lib/hdb/mkey.c |
||
+ | | heimdal |
||
Revision as of 17:44, 12 September 2009
This page aims to reduce the confusion about the two hdb interfaces, the LDB interface, and the big ldb interface.
Contents
- 1 LDB Interface
- 2 hdb Interface
- 3 ldb interface
- 3.1 ldb basic calls
- 3.2 ldb_attr_ calls
- 3.3 ldb_build_..._req calls
- 3.4 ldb_dn_ calls
- 3.5 ldb_extended_ calls
- 3.6 ldb_get_ calls
- 3.7 ldb_ldif_ calls
- 3.8 ldb_module_ calls
- 3.9 ldb_..._module_ops calls
- 3.10 ldb_msg_ calls
- 3.11 ldb_next_
- 3.12 ldb_request
- 3.13 ldb_schema_ calls
- 3.14 ldb_set_ calls
- 3.15 ldb_transaction_ calls
- 3.16 ldb_val_ calls
- 3.17 ldb miscellaneous calls
LDB Interface
source4/kdc/hdb-samba4.c contains the LDB functions. In Samba4's heimdal/lib/hdb/hdb.h, Heimdal's HDB structure contains "hdb-" prefixed function-pointers to the LDB functions:
- (HDB *)->hdb_dbc = NULL;
- (HDB *)->hdb_open = LDB_open;
- (HDB *)->hdb_close = LDB_close;
- (HDB *)->hdb_fetch = LDB_fetch;
- (HDB *)->hdb_store = LDB_store;
- (HDB *)->hdb_remove = LDB_remove;
- (HDB *)->hdb_firstkey = LDB_firstkey;
- (HDB *)->hdb_nextkey = LDB_nextkey;
- (HDB *)->hdb_lock = LDB_lock;
- (HDB *)->hdb_unlock = LDB_unlock;
- (HDB *)->hdb_rename = LDB_rename;
- (HDB *)->hdb__get = NULL;
- (HDB *)->hdb__put = NULL;
- (HDB *)->hdb__del = NULL;
- (HDB *)->hdb_destroy = LDB_destroy;
hdb Interface
Samba4's heimdal/lib/hdb/hdb.c defines another set of hdb_ functions:
External entry-points:
- hdb_next_enctype2key
- hdb_enctype2key
- hdb_free_key
- hdb_lock
- hdb_unlock
- hdb_free_entry
- hdb_foreach
- hdb_check_db_format
- hdb_init_db
- hdb_list_builtin
- hdb_createandlers
There are also some event-handlers (local fcns invoked via function-pointers):
- hdb_ldb_free_entry in kdc/hdb-samba4.c
- hdb_samba4_create in kdc/kdc.c
heimdal-internal hdb interface
Entry-point | Samba4 file | Used by |
copy_hdb_entry | heimdal/lib/hdb/asn1_hdb_entry.c | no |
copy_hdb_entry_alias | heimdal/lib/hdb/asn1_hdb_entry_alias.c | no |
decode_hdb_entry | heimdal/lib/hdb/asn1_hdb_entry.c | no |
decode_hdb_entry_alias | heimdal/lib/hdb/asn1_hdb_entry_alias.c | no |
encode_hdb_entry | heimdal/lib/hdb/asn1_hdb_entry.c | no |
encode_hdb_entry_alias | heimdal/lib/hdb/asn1_hdb_entry_alias.c | no |
free_hdb_entry | heimdal/lib/hdb/asn1_hdb_entry.c | both + |
free_hdb_entry_alias | heimdal/lib/hdb/asn1_hdb_entry_alias.c | heimdal |
initialize_hdb_error_table | heimdal/lib/hdb/hdb_err.c | no |
initialize_hdb_error_table_r | heimdal/lib/hdb/hdb_err.c | both |
length_hdb_entry | heimdal/lib/hdb/asn1_hdb_entry.c | no |
length_hdb_entry_alias | heimdal/lib/hdb/asn1_hdb_entry_alias.c | no |
_hdb_find_master_key | heimdal/lib/hdb/mkey.c | heimdal + |
_hdb_mkey_decrypt | heimdal/lib/hdb/mkey.c | heimdal + |
_hdb_mkey_version | heimdal/lib/hdb/mkey.c | heimdal |
hdb_add_master_key | heimdal/lib/hdb/mkey.c | no |
hdb_check_db_format | heimdal/lib/hdb/hdb.c | heimdal + |
hdb_clear_extension | heimdal/lib/hdb/ext.c | heimdal |
hdb_clear_master_key | heimdal/lib/hdb/mkey.c | heimdal + |
hdb_create | heimdal/lib/hdb/hdb.c | heimdal |
hdb_db_dir | heimdal/lib/hdb/dbinfo.c | heimdal + |
hdb_dbinfo_get_acl_file | heimdal/lib/hdb/dbinfo.c | no |
hdb_dbinfo_get_binding | heimdal/lib/hdb/dbinfo.c | no |
hdb_dbinfo_get_dbname | heimdal/lib/hdb/dbinfo.c | no |
hdb_dbinfo_get_label | heimdal/lib/hdb/dbinfo.c | no |
hdb_dbinfo_get_log_file | heimdal/lib/hdb/dbinfo.c | no |
hdb_dbinfo_get_mkey_file | heimdal/lib/hdb/dbinfo.c | no |
hdb_dbinfo_get_next | heimdal/lib/hdb/dbinfo.c | no |
hdb_dbinfo_get_realm | heimdal/lib/hdb/dbinfo.c | no |
hdb_free_dbinfo | heimdal/lib/hdb/dbinfo.c | no |
hdb_get_dbinfo | heimdal/lib/hdb/dbinfo.c | no |
hdb_default_db | heimdal/lib/hdb/dbinfo.c | no |
hdb_init_db | heimdal/lib/hdb/hdb.c | heimdal |
hdb_enctype2key | heimdal/lib/hdb/hdb.c | both ++ |
hdb_entry_check_mandatory | heimdal/lib/hdb/ext.c | no |
hdb_entry_clear_password | heimdal/lib/hdb/ext.c | no |
hdb_entry_get_aliases | heimdal/lib/hdb/ext.c | no |
hdb_entry_get_ConstrainedDelegACL | heimdal/lib/hdb/ext.c | heimdal |
hdb_entry_get_password | heimdal/lib/hdb/ext.c | heimdal |
hdb_entry_get_pkinit_acl | heimdal/lib/hdb/ext.c | heimdal |
hdb_entry_get_pkinit_hash | heimdal/lib/hdb/ext.c | no |
hdb_entry_get_pw_change_time | heimdal/lib/hdb/ext.c | no |
hdb_entry_set_password | heimdal/lib/hdb/ext.c | no |
hdb_entry_set_pw_change_time | heimdal/lib/hdb/ext.c | no |
hdb_find_extension | heimdal/lib/hdb/ext.c | heimdal + |
hdb_foreach | heimdal/lib/hdb/hdb.c | no |
hdb_free_entry | heimdal/lib/hdb/hdb.c | both ++ |
hdb_free_key | heimdal/lib/hdb/hdb.c | no |
hdb_free_keys | heimdal/lib/hdb/keys.c | no |
hdb_free_master_key | heimdal/lib/hdb/mkey.c | heimdal |
hdb_generate_key_set | heimdal/lib/hdb/keys.c | heimdal |
hdb_generate_key_set_password | heimdal/lib/hdb/keys.c | no |
hdb_kt_ops{} | heimdal/lib/hdb/keytab.c | samba4 |
hdb_list_builtin | heimdal/lib/hdb/hdb.c | no |
hdb_lock (func ptr) | kdc/hdb-samba4.c | heimdal ++ |
hdb_lock | heimdal/lib/hdb/hdb.c | heimdal |
hdb_next_enctype2key | heimdal/lib/hdb/hdb.c | heimdal + |
hdb_process_master_key | heimdal/lib/hdb/mkey.c | heimdal + |
hdb_read_master_key | heimdal/lib/hdb/mkey.c | heimdal |
hdb_replace_extension | heimdal/lib/hdb/ext.c | heimdal |
hdb_seal_key | heimdal/lib/hdb/mkey.c | no |
hdb_seal_keys | heimdal/lib/hdb/mkey.c | no |
hdb_seal_key_mkey | heimdal/lib/hdb/mkey.c | heimdal |
hdb_seal_keys_mkey | heimdal/lib/hdb/mkey.c | heimdal |
hdb_set_master_key | heimdal/lib/hdb/mkey.c | no |
hdb_set_master_keyfile | heimdal/lib/hdb/mkey.c | heimdal |
hdb_unlock (func ptr) | kdc/hdb-samba4.c | heimdal ++ |
hdb_unlock | heimdal/lib/hdb/hdb.c | heimdal |
hdb_unseal_key | heimdal/lib/hdb/mkey.c | no |
hdb_unseal_keys | heimdal/lib/hdb/mkey.c | heimdal + |
hdb_unseal_key_mkey | heimdal/lib/hdb/mkey.c | heimdal |
hdb_unseal_keys_mkey | heimdal/lib/hdb/mkey.c | heimdal
|
ldb interface
These routines are defined & used only in Samba4, and not in samba4's heimdal snapshot tree.
ldb basic calls
- ldb_add
- ldb_connect
- ldb_debug
- ldb_delete
- ldb_errstring
- ldb_init
- ldb_modify
- ldb_qsort
- ldb_rename
- ldb_request
- ldb_search
- ldb_wait
ldb_attr_ calls
- ldb_attr_casefold
- ldb_attr_dn
- ldb_attr_in_list
- ldb_attr_list_copy
- ldb_attr_list_copy_add
ldb_build_..._req calls
- ldb_build_add_req
- ldb_build_del_req
- ldb_build_extended_req
- ldb_build_mod_req
- ldb_build_rename_req
- ldb_build_search_req
- ldb_build_search_req_ex
ldb_dn_ calls
- ldb_dn_add_base
- ldb_dn_add_base_fmt
- ldb_dn_add_child
- ldb_dn_add_child_fmt
- ldb_dn_alloc_casefold
- ldb_dn_alloc_linearized
- ldb_dn_canonical_ex_strin
- ldb_dn_canonical_string
- ldb_dn_check_local
- ldb_dn_check_special
- ldb_dn_compare
- ldb_dn_compare_base
- ldb_dn_copy
- ldb_dn_escape_value
- ldb_dn_extended_add_synta
- ldb_dn_extended_syntax_by
- ldb_dn_from_ldb_val
- ldb_dn_get_casefold
- ldb_dn_get_comp_num
- ldb_dn_get_component_name
- ldb_dn_get_component_val
- ldb_dn_get_extended_compo
- ldb_dn_get_extended_linea
- ldb_dn_get_linearized
- ldb_dn_get_parent
- ldb_dn_get_rdn_name
- ldb_dn_get_rdn_val
- ldb_dn_has_extended
- ldb_dn_is_null
- ldb_dn_is_special
- ldb_dn_is_valid
- ldb_dn_map_local
- ldb_dn_map_rebase_remote
- ldb_dn_new
- ldb_dn_new_fmt
- ldb_dn_remove_base_compon
- ldb_dn_remove_child_compo
- ldb_dn_set_component
- ldb_dn_set_extended_compo
- ldb_dn_validate
ldb_extended_ calls
- ldb_extended
- ldb_extended_default_call
- ldb_extended_dn_in_module
- ldb_extended_dn_out_deref
- ldb_extended_dn_out_ldb_m
- ldb_extended_dn_store_mod
ldb_get_ calls
- ldb_get_config_basedn
- ldb_get_create_perms
- ldb_get_default_basedn
- ldb_get_event_context
- ldb_get_opaque
- ldb_get_root_basedn
- ldb_get_schema_basedn
ldb_ldif_ calls
- ldb_ldif_read_file
- ldb_ldif_read_free
- ldb_ldif_read_string
- ldb_ldif_write_file
ldb_module_ calls
- ldb_module_done
- ldb_module_get_ctx
- ldb_module_get_private
- ldb_module_new
- ldb_module_send_entry
- ldb_module_send_referral
- ldb_module_set_private
- ldb_modules_list_from_str
- ldb_init_module_chain
- ldb_load_modules
- ldb_load_modules_list
ldb_..._module_ops calls
- ldb_anr_module_ops
- ldb_asq_module_ops
- ldb_dsdb_cache_module_ops
- ldb_entryuuid_module_ops
- ldb_instancetype_module_ops
- ldb_kludge_acl_module_ops
- ldb_ldap_backend_ops
- ldb_ldapi_backend_ops
- ldb_ldaps_backend_ops
- ldb_linked_attributes_module_ops
- ldb_local_password_module_ops
- ldb_naming_fsmo_module_ops
- ldb_nsuniqueid_module_ops
- ldb_objectclass_module_ops
- ldb_objectguid_module_ops
- ldb_operational_module_ops
- ldb_paged_results_module_ops
- ldb_paged_searches_module_ops
- ldb_partition_module_ops
- ldb_password_hash_module_ops
- ldb_pdc_fsmo_module_ops
- ldb_ranged_results_module_ops
- ldb_rdn_name_module_ops
- ldb_register_module
- ldb_repl_meta_data_module_ops
- ldb_rootdse_module_ops
- ldb_samba3sam_module_ops
- ldb_samldb_module_ops
- ldb_server_sort_module_ops
- ldb_show_deleted_module_ops
- ldb_skel_module_ops
- ldb_subtree_delete_module_ops
- ldb_subtree_rename_module_ops
- ldb_tdb_backend_ops
- ldb_update_keytab_module_ops
- ldb_wins_ldb_module_ops
ldb_msg_ calls
- ldb_msg_add
- ldb_msg_add_empty
- ldb_msg_add_fmt
- ldb_msg_add_steal_string
- ldb_msg_add_steal_value
- ldb_msg_add_string
- ldb_msg_add_value
- ldb_msg_canonicalize
- ldb_msg_check_string_attr
- ldb_msg_copy
- ldb_msg_copy_attr
- ldb_msg_copy_shallow
- ldb_msg_diff
- ldb_msg_element_compare
- ldb_msg_find_attr_as_bool
- ldb_msg_find_attr_as_dn
- ldb_msg_find_attr_as_int
- ldb_msg_find_attr_as_int6
- ldb_msg_find_attr_as_stri
- ldb_msg_find_attr_as_uint
- ldb_msg_find_element
- ldb_msg_find_ldb_val
- ldb_msg_find_val
- ldb_msg_new
- ldb_msg_remove_attr
- ldb_msg_remove_element
- ldb_msg_sanity_check
- ldb_msg_sort_elements
ldb_next_
- ldb_next_del_trans
- ldb_next_end_trans
- ldb_next_init
- ldb_next_remote_request
- ldb_next_request
- ldb_next_start_trans
ldb_request
- ldb_request_add_control
- ldb_request_done
- ldb_request_get_control
- ldb_request_get_status
- ldb_request_set_state
ldb_schema_ calls
- ldb_schema_attribute_add
- ldb_schema_attribute_add_
- ldb_schema_attribute_by_n
- ldb_schema_attribute_remo
- ldb_schema_attribute_set_
- ldb_schema_fsmo_module_op
ldb_set_ calls
- ldb_set_create_perms
- ldb_set_debug
- ldb_set_debug_stderr
- ldb_set_default_dns
- ldb_set_errstring
- ldb_set_modules_dir
- ldb_set_opaque
- ldb_set_timeout
- ldb_set_utf8_default
- ldb_set_utf8_fns
ldb_transaction_ calls
- ldb_transaction_cancel
- ldb_transaction_commit
- ldb_transaction_start
ldb_val_ calls
- ldb_val_dup
- ldb_val_equal_exact
- ldb_valid_attr_name
- ldb_val_map_local
- ldb_val_map_remote
ldb miscellaneous calls
- ldb_asprintf_errstring
- ldb_base64_decode
- ldb_base64_encode
- ldb_binary_encode
- ldb_binary_encode_string
- ldb_casefold
- ldb_cmdline_process
- ldb_comparison_binary
- ldb_connect_backend
- ldb_debug_set
- ldb_filter_from_tree
- ldb_handle_new
- ldb_handler_copy
- ldb_map_init
- ldb_match_msg
- ldb_mod_register_control
- ldb_op_default_callback
- ldb_parse_control_strings
- ldb_parse_tree
- ldb_parse_tree_attr_replace
- ldb_register_samba_handle
- ldb_reply_get_control
- ldb_reset_err_string
- ldb_samba_syntax_by_lDAPD
- ldb_samba_syntax_by_name
- ldb_search_default_callback
- ldb_sequence_number
- ldb_setup_wellknown_attri
- ldb_should_b64_encode
- ldb_standard_syntax_by_name
- ldb_strerror
- ldb_string_to_time
- ldb_string_utc_to_time
- ldb_timestring
- ldb_timestring_utc
- ldb_wrap_connect