CUBRID Engine  latest
authenticate.h File Reference
#include <stdio.h>
#include <stdlib.h>
#include "error_manager.h"
#include "class_object.h"
#include "databases_file.h"
#include "object_fetch.h"
Include dependency graph for authenticate.h:

Go to the source code of this file.

Macros

#define AU_TYPE   DB_AUTH
 
#define AU_NONE   DB_AUTH_NONE
 
#define AU_SELECT   DB_AUTH_SELECT
 
#define AU_INSERT   DB_AUTH_INSERT
 
#define AU_UPDATE   DB_AUTH_UPDATE
 
#define AU_DELETE   DB_AUTH_DELETE
 
#define AU_ALTER   DB_AUTH_ALTER
 
#define AU_INDEX   DB_AUTH_INDEX
 
#define AU_EXECUTE   DB_AUTH_EXECUTE
 
#define AU_TYPE_MASK   0x7F
 
#define AU_GRANT_MASK   0x7F00
 
#define AU_FULL_AUTHORIZATION   0x7F7F
 
#define AU_NO_AUTHORIZATION   0
 
#define AU_GRANT_SHIFT   8
 
#define AU_CACHE_INVALID   0x80000000
 
#define AU_DISABLE(save)
 
#define AU_ENABLE(save)
 
#define AU_SAVE_AND_ENABLE(save)
 
#define AU_SAVE_AND_DISABLE(save)
 
#define AU_RESTORE(save)
 
#define AU_DISABLE_PASSWORDS   au_disable_passwords
 
#define AU_SET_USER   au_set_user
 
#define AU_MAX_PASSWORD_CHARS   31
 
#define AU_MAX_PASSWORD_BUF   2048
 
#define AU_MAX_COMMENT_CHARS   SM_MAX_COMMENT_LENGTH
 
#define au_free_authorization_cache_and_init(cache)
 

Functions

int au_disable (void)
 
void au_enable (int save)
 
MOP au_get_public_user (void)
 
MOP au_get_dba_user (void)
 
void au_init (void)
 
void au_final (void)
 
int au_install (void)
 
int au_force_write_new_auth (void)
 
int au_add_method_check_authorization (void)
 
int au_start (void)
 
int au_login (const char *name, const char *password, bool ignore_dba_privilege)
 
void au_disable_passwords (void)
 
int au_set_user (MOP newuser)
 
MOP au_find_user (const char *user_name)
 
int au_find_user_to_drop (const char *user_name, MOP *user)
 
MOP au_add_user (const char *name, int *exists)
 
int au_add_member (MOP group, MOP member)
 
int au_drop_member (MOP group, MOP member)
 
int au_drop_user (MOP user)
 
int au_set_password (MOP user, const char *password)
 
int au_set_user_comment (MOP user, const char *comment)
 
const char * au_user_name (void)
 
char * au_user_name_dup (void)
 
bool au_has_user_name (void)
 
int au_grant (MOP user, MOP class_mop, DB_AUTH type, bool grant_option)
 
int au_revoke (MOP user, MOP class_mop, DB_AUTH type)
 
int au_delete_auth_of_dropping_table (const char *class_name)
 
int au_fetch_class (MOP op, SM_CLASS **class_ptr, AU_FETCHMODE fetchmode, DB_AUTH type)
 
int au_fetch_class_by_classmop (MOP op, SM_CLASS **class_ptr, AU_FETCHMODE fetchmode, DB_AUTH type)
 
int au_fetch_class_by_instancemop (MOP op, SM_CLASS **class_ptr, AU_FETCHMODE fetchmode, DB_AUTH type)
 
int au_fetch_class_force (MOP op, SM_CLASS **class_, AU_FETCHMODE fetchmode)
 
int au_fetch_instance (MOP op, MOBJ *obj_ptr, AU_FETCHMODE mode, LC_FETCH_VERSION_TYPE fetch_version_type, DB_AUTH type)
 
int au_fetch_instance_force (MOP op, MOBJ *obj_ptr, AU_FETCHMODE fetchmode, LC_FETCH_VERSION_TYPE fetch_version_type)
 
int au_check_authorization (MOP op, DB_AUTH auth)
 
void au_free_authorization_cache (void *cache)
 
void au_reset_authorization_caches (void)
 
int au_change_owner (MOP classmop, MOP owner)
 
MOP au_get_class_owner (MOP classmop)
 
int au_check_user (void)
 
char * au_get_user_name (MOP obj)
 
bool au_is_dba_group_member (MOP user)
 
void au_change_serial_owner_method (MOP obj, DB_VALUE *returnval, DB_VALUE *serial, DB_VALUE *owner)
 
void au_dump (void)
 
void au_dump_to_file (FILE *fp)
 
void au_dump_user (MOP user, FILE *fp)
 
void au_link_static_methods (void)
 
int au_export_users (print_output &output_ctx)
 
int au_export_grants (print_output &output_ctx, MOP class_mop)
 
int au_get_class_privilege (DB_OBJECT *mop, unsigned int *auth)
 
void au_find_user_method (MOP class_mop, DB_VALUE *returnval, DB_VALUE *name)
 
void au_add_user_method (MOP class_mop, DB_VALUE *returnval, DB_VALUE *name, DB_VALUE *password)
 
void au_set_password_method (MOP user, DB_VALUE *returnval, DB_VALUE *password)
 
void au_set_password_encoded_method (MOP user, DB_VALUE *returnval, DB_VALUE *password)
 
void au_set_password_encoded_sha1_method (MOP user, DB_VALUE *returnval, DB_VALUE *password)
 
void au_add_member_method (MOP user, DB_VALUE *returnval, DB_VALUE *memval)
 
void au_drop_member_method (MOP user, DB_VALUE *returnval, DB_VALUE *memval)
 
void au_drop_user_method (MOP root, DB_VALUE *returnval, DB_VALUE *name)
 
void au_change_owner_method (MOP obj, DB_VALUE *returnval, DB_VALUE *class_, DB_VALUE *owner)
 
int au_change_trigger_owner (MOP trigger, MOP owner)
 
void au_change_trigger_owner_method (MOP obj, DB_VALUE *returnval, DB_VALUE *trigger, DB_VALUE *owner)
 
void au_get_owner_method (MOP obj, DB_VALUE *returnval, DB_VALUE *class_)
 
void au_check_authorization_method (MOP obj, DB_VALUE *returnval, DB_VALUE *class_, DB_VALUE *auth)
 
int au_change_sp_owner (MOP sp, MOP owner)
 
void au_change_sp_owner_method (MOP obj, DB_VALUE *returnval, DB_VALUE *sp, DB_VALUE *owner)
 
void au_login_method (MOP class_mop, DB_VALUE *returnval, DB_VALUE *user, DB_VALUE *password)
 
void au_dump_auth (FILE *fp)
 
void au_describe_user_method (MOP user, DB_VALUE *returnval)
 
void au_info_method (MOP class_mop, DB_VALUE *returnval, DB_VALUE *info)
 
void au_describe_root_method (MOP class_mop, DB_VALUE *returnval, DB_VALUE *info)
 
int au_check_serial_authorization (MOP serial_object)
 
const char * au_get_public_user_name (void)
 
const char * au_get_user_class_name (void)
 

Variables

const char * AU_ROOT_CLASS_NAME
 
const char * AU_OLD_ROOT_CLASS_NAME
 
const char * AU_USER_CLASS_NAME
 
const char * AU_PASSWORD_CLASS_NAME
 
const char * AU_AUTH_CLASS_NAME
 
const char * AU_GRANT_CLASS_NAME
 
const char * AU_PUBLIC_USER_NAME
 
const char * AU_DBA_USER_NAME
 
MOP Au_root
 
MOP Au_user
 
MOP Au_dba_user
 
MOP Au_public_user
 
char Au_user_password [AU_MAX_PASSWORD_BUF+4]
 
int Au_disable
 

Macro Definition Documentation

#define AU_ALTER   DB_AUTH_ALTER

Definition at line 73 of file authenticate.h.

Referenced by add_arg_domain(), add_method_internal(), appropriate_error(), au_add_method_check_authorization(), au_install(), boot_define_attribute(), boot_define_charsets(), boot_define_class(), boot_define_class_authorization(), boot_define_collations(), boot_define_data_type(), boot_define_domain(), boot_define_dual(), boot_define_ha_apply_info(), boot_define_index(), boot_define_index_key(), boot_define_meth_argument(), boot_define_meth_file(), boot_define_meth_sig(), boot_define_method(), boot_define_partition(), boot_define_query_spec(), boot_define_serial(), boot_define_stored_procedure(), boot_define_stored_procedure_arguments(), check_authorization(), check_target(), db_add_attribute_internal(), db_add_class_resolution(), db_add_method_file(), db_add_query_spec(), db_add_resolution(), db_add_set_attribute_domain(), db_add_super_internal(), db_change_default(), db_change_method_implementation(), db_change_query_spec(), db_drop_class_resolution(), db_drop_method_file(), db_drop_method_files(), db_drop_query_spec(), db_drop_resolution(), db_drop_set_attribute_domain(), db_drop_super(), db_drop_super_connect(), db_rename_internal(), db_set_loader_commands(), dbt_edit_class(), do_update_stats(), drop_internal(), fetch_descriptor_class(), find_attribute(), find_shared_attribute(), is_protected_class(), issue_grant_statement(), make_template(), obj_class_lock(), obj_locate_attribute(), obt_find_attribute(), pt_make_flat_name_list(), sm_add_constraint(), sm_add_trigger(), sm_delete_class_mop(), sm_drop_constraint(), sm_drop_trigger(), sm_finish_class(), sm_get_attribute_descriptor(), sm_get_trigger_cache(), sm_load_online_index(), sm_rename_class(), sm_update_class(), and sm_update_class_auto().

#define AU_DELETE   DB_AUTH_DELETE
#define AU_DISABLE (   save)
Value:
do \
{ \
save = Au_disable; \
} \
while (0)
int Au_disable
Definition: authenticate.c:309
while(1)
Definition: cnvlex.c:816

Definition at line 106 of file authenticate.h.

Referenced by au_add_member_internal(), au_add_method_check_authorization(), au_add_user(), au_change_owner(), au_change_serial_owner(), au_change_sp_owner(), au_change_trigger_owner(), au_delete_auth_of_dropping_table(), au_drop_member(), au_drop_user(), au_find_user(), au_force_write_new_auth(), au_get_new_auth(), au_grant(), au_install(), au_login(), au_revoke(), au_set_password_internal(), au_user_name(), catcls_class_install(), catcls_vclass_install(), check_missing_non_null_attrs(), dbt_drop_attribute(), delete_all_ha_apply_info(), delete_all_slave_ha_apply_info(), do_alter_change_auto_increment(), do_alter_serial(), do_change_att_schema_only(), do_check_for_empty_classes_in_delete(), do_check_internal_statements(), do_create_serial(), do_create_serial_internal(), do_delete(), do_drop_serial(), do_execute_do(), do_get_partition_parent(), do_get_serial_obj_id(), do_merge(), do_prepare_insert(), do_select_internal(), do_update(), do_update_auto_increment_serial_on_rename(), do_update_maxvalue_of_auto_increment_serial(), drop_foreign_key_ref_internal(), drop_stored_procedure(), emit_index_def(), emit_stored_procedure(), emit_stored_procedure_args(), fetch_instance(), get_select_list_to_update(), insert_ha_apply_info(), insert_local(), is_server_insert_allowed(), is_server_update_allowed(), jsp_add_stored_procedure(), jsp_add_stored_procedure_argument(), jsp_alter_stored_procedure(), jsp_do_call_stored_procedure(), jsp_find_stored_procedure(), jsp_get_return_type(), la_update_query_execute(), la_update_query_execute_with_values(), lang_db_put_charset(), loaddb_internal(), locator_mflush_force(), method_invoke_for_server(), method_receive_results_for_stand_alone(), mq_get_attribute(), mq_oid(), obj_set_att(), object_to_trigger(), pt_check_show_index(), pt_check_table_in_show_heap(), pt_to_insert_xasl(), put_timezone_checksum(), register_user_trigger(), select_delete_list(), sm_class_has_unique_constraint(), sm_delete_class_mop(), sm_get_ch_name(), sm_is_partitioned_class(), sm_partitioned_class_type(), sm_rename_class(), sm_truncate_class(), synccoll_force(), tr_check_authorization(), tr_delete_schema_cache(), tr_delete_triggers_for_class(), tr_drop_trigger(), tr_drop_trigger_internal(), tr_dump_trigger(), tr_find_all_triggers(), tr_find_event_triggers(), tr_find_trigger(), tr_prepare_class(), tr_prepare_statement(), tr_rename_trigger(), tr_set_comment(), tr_set_priority(), tr_set_status(), tr_trigger_action(), tr_trigger_action_time(), tr_trigger_action_type(), tr_trigger_attribute(), tr_trigger_class(), tr_trigger_comment(), tr_trigger_condition(), tr_trigger_condition_time(), tr_trigger_event(), tr_trigger_name(), tr_trigger_priority(), tr_trigger_status(), trigger_table_add(), trigger_table_drop(), trigger_table_rename(), trigger_to_object(), unregister_user_trigger(), update_cache(), update_class(), and update_foreign_key_ref().

#define AU_ENABLE (   save)
Value:
do \
{ \
Au_disable = save; \
} \
while (0)
int Au_disable
Definition: authenticate.c:309
while(1)
Definition: cnvlex.c:816

Definition at line 113 of file authenticate.h.

Referenced by au_add_member_internal(), au_add_method_check_authorization(), au_add_user(), au_change_owner(), au_change_serial_owner(), au_change_sp_owner(), au_change_trigger_owner(), au_delete_auth_of_dropping_table(), au_drop_member(), au_drop_user(), au_find_user(), au_force_write_new_auth(), au_get_new_auth(), au_grant(), au_install(), au_login(), au_revoke(), au_set_password_internal(), au_user_name(), catcls_class_install(), catcls_vclass_install(), check_missing_non_null_attrs(), dbt_drop_attribute(), delete_all_ha_apply_info(), delete_all_slave_ha_apply_info(), do_alter_change_auto_increment(), do_alter_serial(), do_change_att_schema_only(), do_check_for_empty_classes_in_delete(), do_check_internal_statements(), do_create_serial(), do_create_serial_internal(), do_delete(), do_drop_serial(), do_execute_do(), do_get_partition_parent(), do_get_serial_obj_id(), do_merge(), do_prepare_insert(), do_select_internal(), do_update(), do_update_auto_increment_serial_on_rename(), do_update_maxvalue_of_auto_increment_serial(), drop_foreign_key_ref_internal(), drop_stored_procedure(), emit_index_def(), emit_stored_procedure(), emit_stored_procedure_args(), fetch_instance(), get_select_list_to_update(), insert_ha_apply_info(), insert_local(), is_server_insert_allowed(), is_server_update_allowed(), jsp_add_stored_procedure(), jsp_add_stored_procedure_argument(), jsp_alter_stored_procedure(), jsp_do_call_stored_procedure(), jsp_find_stored_procedure(), jsp_get_return_type(), la_update_query_execute(), la_update_query_execute_with_values(), lang_db_put_charset(), loaddb_internal(), locator_mflush_force(), method_invoke_for_server(), method_receive_results_for_stand_alone(), mq_get_attribute(), mq_oid(), obj_set_att(), object_to_trigger(), pt_check_show_index(), pt_check_table_in_show_heap(), pt_to_insert_xasl(), put_timezone_checksum(), register_user_trigger(), select_delete_list(), sm_class_has_unique_constraint(), sm_delete_class_mop(), sm_get_ch_name(), sm_is_partitioned_class(), sm_partitioned_class_type(), sm_rename_class(), sm_truncate_class(), synccoll_force(), tr_check_authorization(), tr_delete_schema_cache(), tr_delete_triggers_for_class(), tr_drop_trigger(), tr_drop_trigger_internal(), tr_dump_trigger(), tr_find_all_triggers(), tr_find_event_triggers(), tr_find_trigger(), tr_prepare_class(), tr_prepare_statement(), tr_rename_trigger(), tr_set_comment(), tr_set_priority(), tr_set_status(), tr_trigger_action(), tr_trigger_action_time(), tr_trigger_action_type(), tr_trigger_attribute(), tr_trigger_class(), tr_trigger_comment(), tr_trigger_condition(), tr_trigger_condition_time(), tr_trigger_event(), tr_trigger_name(), tr_trigger_priority(), tr_trigger_status(), trigger_table_add(), trigger_table_drop(), trigger_table_rename(), trigger_to_object(), unregister_user_trigger(), update_cache(), update_class(), and update_foreign_key_ref().

#define au_free_authorization_cache_and_init (   cache)
Value:
do \
{ \
(cache) = NULL; \
} \
while (0)
void au_free_authorization_cache(void *cache)
Definition: authenticate.c:784
#define NULL
Definition: freelistheap.h:34
while(1)
Definition: cnvlex.c:816

Definition at line 148 of file authenticate.h.

Referenced by classobj_free_class().

#define AU_FULL_AUTHORIZATION   0x7F7F

Definition at line 86 of file authenticate.h.

Referenced by au_export_grants(), make_class_user(), and update_cache().

#define AU_GRANT_MASK   0x7F00

Definition at line 85 of file authenticate.h.

Referenced by au_force_write_new_auth().

#define AU_MAX_COMMENT_CHARS   SM_MAX_COMMENT_LENGTH

Definition at line 145 of file authenticate.h.

Referenced by au_set_user_comment().

#define AU_MAX_PASSWORD_BUF   2048
#define AU_MAX_PASSWORD_CHARS   31

Definition at line 143 of file authenticate.h.

Referenced by au_add_user_method(), and au_set_password_internal().

#define AU_NO_AUTHORIZATION   0

Definition at line 87 of file authenticate.h.

Referenced by au_grant(), collect_class_grants(), and update_cache().

#define AU_NONE   DB_AUTH_NONE

Definition at line 68 of file authenticate.h.

#define AU_SAVE_AND_DISABLE (   save)
#define AU_SELECT   DB_AUTH_SELECT

Definition at line 69 of file authenticate.h.

Referenced by adjust_partition_range(), adjust_partition_size(), api_rmeta_get_info(), appropriate_error(), au_install(), boot_define_dual(), boot_define_ha_apply_info(), boot_define_serial(), boot_define_view_attribute(), boot_define_view_attribute_set_domain(), boot_define_view_authorization(), boot_define_view_class(), boot_define_view_db_charset(), boot_define_view_db_collation(), boot_define_view_index(), boot_define_view_index_key(), boot_define_view_method(), boot_define_view_method_argument(), boot_define_view_method_argument_set_domain(), boot_define_view_method_file(), boot_define_view_partition(), boot_define_view_stored_procedure(), boot_define_view_stored_procedure_arguments(), boot_define_view_super_class(), boot_define_view_trigger(), boot_define_view_vclass(), catcls_vclass_install(), check_authorization(), check_resolution_name(), check_set_object(), class_grant_loop(), db_find_class_of_index(), db_get_attribute(), db_get_attribute_domain(), db_get_attribute_names(), db_get_attributes(), db_get_class_attribute(), db_get_class_attribute_names(), db_get_class_attributes(), db_get_class_method(), db_get_class_method_names(), db_get_class_methods(), db_get_class_resolutions(), db_get_constraints(), db_get_loader_commands(), db_get_method(), db_get_method_file_names(), db_get_method_files(), db_get_method_function(), db_get_method_names(), db_get_methods(), db_get_ordered_attribute_names(), db_get_ordered_attributes(), db_get_query_specs(), db_get_resolutions(), db_get_shared_attribute(), db_get_shared_attribute_names(), db_get_subclass_names(), db_get_subclasses(), db_get_superclass_names(), db_get_superclasses(), db_is_updatable_attribute(), db_is_updatable_object(), db_seq_create(), db_set_create(), db_set_create_basic(), db_set_create_multi(), do_alter_index_rebuild(), do_alter_partitioning_pre(), do_coalesce_partition_post(), do_coalesce_partition_pre(), do_create_partition(), do_create_partition_constraint(), do_create_trigger(), do_drop_partition_list(), do_drop_partitioned_class(), do_get_partition_keycol(), do_get_partition_parent(), do_get_partition_size(), do_is_partitioned_subclass(), do_promote_partition_by_name(), do_promote_partition_list(), do_remove_partition_pre(), do_rename_partition(), do_reorganize_partition_post(), emit_index_def(), emit_partition_info(), extract_objects(), fetch_descriptor_class(), find_attribute(), find_attribute_op(), find_shared_attribute(), get_object_value(), help_describe_mop(), object_description::init(), class_description::init(), is_replace_or_odku_allowed(), issue_grant_statement(), la_repl_add_object(), ldr_act_add_class_all_attrs(), ldr_act_check_missing_non_null_attrs(), locator_mflush_force(), lock_supers(), lock_supers_drop(), obj_class_lock(), obj_copy(), obj_find_multi_attr(), obj_find_multi_desc(), obj_find_object_by_pkey(), obj_find_unique(), obj_inst_lock(), obj_is_instance_of(), obj_isinstance(), obj_locate_attribute(), pt_check_alter_partition(), pt_check_filter_index_expr(), pt_check_partitions(), pt_make_flat_name_list(), pt_resolve_using_index(), pt_spec_to_xasl_class_oid_list(), pt_to_insert_xasl(), pt_to_merge_insert_xasl(), pt_to_pred_expr(), sm_att_info(), sm_check_object_domain(), sm_class_check_uniques(), sm_class_constraints(), sm_class_has_triggers(), sm_class_has_unique_constraint(), sm_coerce_object_domain(), sm_drop_constraint(), sm_exist_index(), sm_fetch_all_objects_internal(), sm_find_index(), sm_find_subclass_in_hierarchy(), sm_flush_and_decache_objects(), sm_force_method_link(), sm_get_att_name(), sm_get_attribute_descriptor(), sm_get_ch_heap(), sm_get_ch_name(), sm_get_class(), sm_get_class_repid(), sm_get_class_with_statistics(), sm_get_index(), sm_get_method_source_file(), sm_get_statistics_force(), sm_get_trigger_cache(), sm_invalidate_trigger_cache(), sm_is_partition(), sm_is_subclass(), sm_object_size_quick(), sm_partitioned_class_type(), smt_check_foreign_key(), smt_delete_super_connect(), unloaddb(), update_class(), and update_object_tuple().

#define AU_SET_USER   au_set_user
#define AU_TYPE   DB_AUTH

Definition at line 67 of file authenticate.h.

Referenced by make_template().

#define AU_TYPE_MASK   0x7F

Definition at line 84 of file authenticate.h.

Referenced by au_force_write_new_auth(), au_grant(), au_revoke(), and issue_grant_statement().

Function Documentation

int au_add_member ( MOP  group,
MOP  member 
)

Definition at line 3134 of file authenticate.c.

References au_add_member_internal().

Referenced by au_add_member_method(), db_add_member(), and parse_user_define_line().

Here is the caller graph for this function:

int au_add_method_check_authorization ( void  )
int au_change_owner ( MOP  classmop,
MOP  owner 
)

Definition at line 5114 of file authenticate.c.

References ARG_FILE_LINE, sm_class::attributes, au_change_serial_owner(), AU_DISABLE, AU_ENABLE, au_fetch_class_force(), AU_FETCH_UPDATE, au_is_dba_group_member(), sm_attribute::auto_increment, ER_AU_DBA_ONLY, er_set(), ER_WARNING_SEVERITY, error(), sm_attribute::header, locator_flush_class(), sm_component::next, NO_ERROR, NULL, and sm_class::owner.

Referenced by au_change_owner_method(), au_install(), boot_define_attribute(), boot_define_charsets(), boot_define_class(), boot_define_class_authorization(), boot_define_collations(), boot_define_data_type(), boot_define_domain(), boot_define_dual(), boot_define_ha_apply_info(), boot_define_index(), boot_define_index_key(), boot_define_meth_argument(), boot_define_meth_file(), boot_define_meth_sig(), boot_define_method(), boot_define_partition(), boot_define_query_spec(), boot_define_serial(), boot_define_stored_procedure(), boot_define_stored_procedure_arguments(), boot_define_view_attribute(), boot_define_view_attribute_set_domain(), boot_define_view_authorization(), boot_define_view_class(), boot_define_view_db_charset(), boot_define_view_db_collation(), boot_define_view_index(), boot_define_view_index_key(), boot_define_view_method(), boot_define_view_method_argument(), boot_define_view_method_argument_set_domain(), boot_define_view_method_file(), boot_define_view_partition(), boot_define_view_stored_procedure(), boot_define_view_stored_procedure_arguments(), boot_define_view_super_class(), boot_define_view_trigger(), and boot_define_view_vclass().

int au_change_sp_owner ( MOP  sp,
MOP  owner 
)

Definition at line 5638 of file authenticate.c.

References ARG_FILE_LINE, AU_DISABLE, AU_ENABLE, au_is_dba_group_member(), db_make_object(), ER_AU_DBA_ONLY, er_set(), ER_WARNING_SEVERITY, error(), NO_ERROR, obj_set(), and SP_ATTR_OWNER.

Referenced by au_change_sp_owner_method().

Here is the caller graph for this function:

int au_change_trigger_owner ( MOP  trigger,
MOP  owner 
)
void au_change_trigger_owner_method ( MOP  obj,
DB_VALUE returnval,
DB_VALUE trigger,
DB_VALUE owner 
)
int au_check_authorization ( MOP  op,
DB_AUTH  auth 
)

Definition at line 6246 of file authenticate.c.

References Au_disable, au_fetch_class(), AU_FETCH_READ, error(), and NO_ERROR.

Referenced by au_check_authorization_method(), check_authorization(), check_target(), do_update_stats(), and load_has_authorization().

Here is the caller graph for this function:

void au_check_authorization_method ( MOP  obj,
DB_VALUE returnval,
DB_VALUE class_,
DB_VALUE auth 
)
int au_check_user ( void  )

Definition at line 5722 of file authenticate.c.

References ARG_FILE_LINE, ER_AU_INVALID_USER, er_set(), ER_WARNING_SEVERITY, error(), NO_ERROR, and NULL.

Referenced by db_get_all_chosen_classes(), sm_fetch_all_base_classes(), sm_fetch_all_classes(), and sm_mark_system_classes().

Here is the caller graph for this function:

void au_describe_root_method ( MOP  class_mop,
DB_VALUE returnval,
DB_VALUE info 
)

Definition at line 8168 of file authenticate.c.

References au_dump(), au_info_method(), db_make_null(), and NULL.

void au_describe_user_method ( MOP  user,
DB_VALUE returnval 
)

Definition at line 8114 of file authenticate.c.

References au_dump_user(), db_make_null(), and NULL.

int au_disable ( void  )

Definition at line 8619 of file authenticate.c.

References Au_disable.

Referenced by csql(), csql_do_session_cmd(), and main().

Here is the caller graph for this function:

void au_disable_passwords ( void  )

Definition at line 6472 of file authenticate.c.

References Au_ignore_passwords.

void au_dump ( void  )

Definition at line 8100 of file authenticate.c.

References au_dump_to_file().

Referenced by au_describe_root_method().

Here is the caller graph for this function:

void au_enable ( int  save)

Definition at line 8632 of file authenticate.c.

References Au_disable.

int au_fetch_class ( MOP  op,
SM_CLASS **  class_ptr,
AU_FETCHMODE  fetchmode,
DB_AUTH  type 
)

Definition at line 6174 of file authenticate.c.

References au_fetch_class_internal(), and DONT_KNOW.

Referenced by adjust_partition_range(), adjust_partition_size(), api_rmeta_get_info(), au_check_authorization(), check_resolution_name(), db_check_authorization(), db_check_authorization_and_grant_option(), db_find_class_of_index(), db_get_attribute(), db_get_attribute_domain(), db_get_attribute_names(), db_get_attributes(), db_get_class_attribute(), db_get_class_attribute_names(), db_get_class_attributes(), db_get_class_method(), db_get_class_method_names(), db_get_class_methods(), db_get_class_resolutions(), db_get_constraints(), db_get_loader_commands(), db_get_method(), db_get_method_file_names(), db_get_method_files(), db_get_method_function(), db_get_method_names(), db_get_methods(), db_get_ordered_attribute_names(), db_get_ordered_attributes(), db_get_query_specs(), db_get_resolutions(), db_get_shared_attribute(), db_get_shared_attribute_names(), db_get_subclass_names(), db_get_subclasses(), db_get_superclass_names(), db_get_superclasses(), db_is_updatable_attribute(), db_is_updatable_object(), db_seq_create(), db_set_create(), db_set_create_basic(), db_set_create_multi(), do_alter_index_rebuild(), do_alter_partitioning_pre(), do_coalesce_partition_post(), do_coalesce_partition_pre(), do_create_partition(), do_create_partition_constraint(), do_create_trigger(), do_drop_partition_list(), do_drop_partitioned_class(), do_get_partition_keycol(), do_get_partition_parent(), do_get_partition_size(), do_is_partitioned_subclass(), do_promote_partition_by_name(), do_promote_partition_list(), do_recreate_renamed_class_indexes(), do_remove_partition_pre(), do_rename_partition(), do_reorganize_partition_post(), do_save_all_indexes(), emit_index_def(), emit_partition_info(), extract_objects(), fetch_descriptor_class(), find_attribute(), find_attribute_op(), find_shared_attribute(), help_describe_mop(), object_description::init(), class_description::init(), is_replace_or_odku_allowed(), la_repl_add_object(), ldr_act_add_class_all_attrs(), ldr_act_check_missing_non_null_attrs(), locator_mflush_force(), lock_supers(), lock_supers_drop(), make_template(), obj_class_lock(), obj_copy(), obj_delete(), obj_find_multi_attr(), obj_find_multi_desc(), obj_find_object_by_pkey(), obj_find_unique(), obj_inst_lock(), obj_locate_attribute(), obj_send_array(), obj_send_list(), obj_send_va(), obt_find_attribute(), pt_check_alter_partition(), pt_check_filter_index_expr(), pt_check_partitions(), pt_make_flat_name_list(), pt_resolve_using_index(), pt_spec_to_xasl_class_oid_list(), pt_to_insert_xasl(), pt_to_merge_insert_xasl(), pt_to_pred_expr(), sm_add_trigger(), sm_att_info(), sm_check_index_exist(), sm_class_check_uniques(), sm_class_constraints(), sm_class_has_triggers(), sm_delete_class_mop(), sm_drop_constraint(), sm_drop_index(), sm_drop_trigger(), sm_exist_index(), sm_fetch_all_objects_internal(), sm_find_index(), sm_force_method_link(), sm_get_att_name(), sm_get_attribute_descriptor(), sm_get_ch_heap(), sm_get_ch_name(), sm_get_class(), sm_get_class_repid(), sm_get_class_with_statistics(), sm_get_index(), sm_get_method_descriptor(), sm_get_method_source_file(), sm_get_statistics_force(), sm_get_trigger_cache(), sm_invalidate_trigger_cache(), sm_is_partition(), sm_is_subclass(), sm_load_online_index(), sm_object_size_quick(), sm_partitioned_class_type(), sm_prelink_methods(), sm_rename_class(), sm_truncate_class(), sm_truncate_using_delete(), smt_check_foreign_key(), smt_check_index_exist(), smt_copy_class_mop(), smt_delete_super_connect(), smt_edit_class_mop(), smt_find_constraint(), truncate_need_repl_log(), unloaddb(), update_class(), and update_object_tuple().

int au_fetch_class_by_classmop ( MOP  op,
SM_CLASS **  class_ptr,
AU_FETCHMODE  fetchmode,
DB_AUTH  type 
)

Definition at line 6206 of file authenticate.c.

References au_fetch_class_internal(), and BY_CLASS_MOP.

Referenced by sm_class_has_unique_constraint(), sm_exist_index(), and sm_find_subclass_in_hierarchy().

Here is the caller graph for this function:

int au_fetch_class_by_instancemop ( MOP  op,
SM_CLASS **  class_ptr,
AU_FETCHMODE  fetchmode,
DB_AUTH  type 
)

Definition at line 6190 of file authenticate.c.

References au_fetch_class_internal(), and BY_INSTANCE_MOP.

int au_fetch_class_force ( MOP  op,
SM_CLASS **  class_,
AU_FETCHMODE  fetchmode 
)

Definition at line 6223 of file authenticate.c.

References DONT_KNOW, and fetch_class().

Referenced by abort_subclasses(), allocate_unique_constraint(), alter_trigger_hierarchy(), annotate_method_files(), au_change_owner(), au_change_owner_method(), au_get_class_owner(), au_grant(), au_revoke(), check_domain_class_type(), check_for_cons(), check_resolution_target(), classobj_copy_constraint_like(), classobj_copy_props(), classobj_is_exist_foreign_key_ref(), collect_hier_class_info(), db_get_attribute_force(), db_get_attributes_force(), db_is_any_class(), db_is_class(), db_is_vclass(), object_printer::describe_constraint(), do_evaluate_default_expr(), domain_search(), drop_foreign_key_ref_internal(), emit_schema(), fill_in_insert_default_function_arguments(), find_superclass(), flatten_method_files(), flatten_properties(), flatten_subclasses(), flatten_trigger_cache(), get_candidates(), inherit_constraint(), lock_subclasses_internal(), obj_get_att(), object_to_trigger(), pt_append_omitted_on_update_expr_assignments(), pt_bind_names_post(), pt_check_show_index(), pt_check_table_in_show_heap(), pt_find_omitted_default_expr(), pt_flush_classes(), pt_has_modified_class_helper(), pt_make_subclass_list(), pt_resolve_partition_spec(), retain_former_ids(), sm_check_class_domain(), sm_check_reuse_oid_class(), sm_coerce_object_domain(), sm_destroy_representations(), sm_fetch_all_base_classes(), sm_get_ch_name(), sm_get_class_collation(), sm_get_class_flag(), sm_get_class_tde_algorithm(), sm_is_nested_view_recached(), sm_is_partitioned_class(), sm_is_reuse_oid_class(), sm_mark_system_class(), sm_mark_system_classes(), sm_save_constraint_info(), sm_set_class_collation(), sm_set_class_comment(), sm_set_class_flag(), sm_set_class_tde_algorithm(), sm_update_statistics(), sm_virtual_queries(), smt_find_owner_of_constraint(), update_foreign_key_ref(), update_subclasses(), update_supers(), update_supers_drop(), vid_build_non_upd_object(), vid_compare_non_updatable_objects(), and ws_update_oid_and_class().

void au_final ( void  )

Definition at line 8518 of file authenticate.c.

References Au_disable, flush_caches(), and NULL.

Referenced by boot_client_all_finalize(), boot_initialize_client(), and boot_restart_client().

Here is the caller graph for this function:

void au_free_authorization_cache ( void *  cache)

Definition at line 784 of file authenticate.c.

References au_free_class_cache(), au_class_cache::next, and NULL.

MOP au_get_class_owner ( MOP  classmop)

Definition at line 5480 of file authenticate.c.

References Au_dba_user, au_fetch_class_force(), AU_FETCH_READ, NO_ERROR, NULL, and sm_class::owner.

Referenced by au_export_grants(), au_get_owner_method(), db_get_owner(), emit_class_owner(), and get_grants().

Here is the caller graph for this function:

int au_get_class_privilege ( DB_OBJECT mop,
unsigned int *  auth 
)
MOP au_get_dba_user ( void  )

Definition at line 8652 of file authenticate.c.

References Au_dba_user.

MOP au_get_public_user ( void  )

Definition at line 8642 of file authenticate.c.

References Au_public_user.

const char* au_get_public_user_name ( void  )

Definition at line 8706 of file authenticate.c.

References AU_PUBLIC_USER_NAME.

Referenced by uci_connect().

Here is the caller graph for this function:

const char* au_get_user_class_name ( void  )

Definition at line 8712 of file authenticate.c.

References AU_USER_CLASS_NAME.

int au_grant ( MOP  user,
MOP  class_mop,
DB_AUTH  type,
bool  grant_option 
)

Definition at line 4383 of file authenticate.c.

References add_grant_entry(), ARG_FILE_LINE, AU_DISABLE, AU_ENABLE, au_fetch_class_force(), au_fetch_instance(), AU_FETCH_READ, AU_FETCH_UPDATE, au_get_object(), au_grant(), AU_GRANT_SHIFT, au_insert_new_auth(), AU_NO_AUTHORIZATION, AU_TYPE_MASK, AU_UPDATE, au_update_new_auth(), AU_USER_CLASS_NAME, catcls_Enable, check_grant_option(), DB_AUTH_NONE, db_get_int(), db_make_int(), DB_NOT_PARTITIONED_CLASS, DB_PARTITIONED_CLASS, ER_AU_ACCESS_ERROR, ER_AU_CANT_GRANT_OWNER, ER_AU_CANT_UPDATE, ER_ERROR_SEVERITY, ER_LK_UNILATERALLY_ABORTED, er_set(), ER_WARNING_SEVERITY, error(), find_grant_entry(), free_and_init, get_grants(), GRANT_ENTRY_CACHE, au_grant::grants, i, LC_FETCH_MVCC_VERSION, NO_ERROR, NULL, obj_inst_lock(), sm_class::owner, reset_cache_for_user_and_class(), set_free(), set_get_element(), set_put_element(), sm_bump_local_schema_version(), sm_partitioned_class_type(), tran_abort_upto_system_savepoint(), tran_system_savepoint(), UNIQUE_PARTITION_SAVEPOINT_GRANT, and ws_is_same_object().

Referenced by au_add_method_check_authorization(), au_grant(), au_install(), boot_define_dual(), boot_define_ha_apply_info(), boot_define_serial(), boot_define_view_attribute(), boot_define_view_attribute_set_domain(), boot_define_view_authorization(), boot_define_view_class(), boot_define_view_db_charset(), boot_define_view_db_collation(), boot_define_view_index(), boot_define_view_index_key(), boot_define_view_method(), boot_define_view_method_argument(), boot_define_view_method_argument_set_domain(), boot_define_view_method_file(), boot_define_view_partition(), boot_define_view_stored_procedure(), boot_define_view_stored_procedure_arguments(), boot_define_view_super_class(), boot_define_view_trigger(), boot_define_view_vclass(), and db_grant().

bool au_has_user_name ( void  )

Definition at line 5804 of file authenticate.c.

References Au_user_name, NULL, and strlen.

Referenced by boot_restart_client().

Here is the caller graph for this function:

void au_info_method ( MOP  class_mop,
DB_VALUE returnval,
DB_VALUE info 
)

Definition at line 8140 of file authenticate.c.

References db_get_string(), DB_IS_NULL, db_make_null(), help_print_info(), IS_STRING, and NULL.

Referenced by au_describe_root_method().

Here is the caller graph for this function:

void au_init ( void  )

Definition at line 8497 of file authenticate.c.

References Au_disable, init_caches(), and NULL.

Referenced by boot_initialize_client(), and boot_restart_client().

Here is the caller graph for this function:

void au_link_static_methods ( void  )

Definition at line 8197 of file authenticate.c.

References db_link_static_methods().

Referenced by conn_restart_client(), and install_static_methods().

Here is the caller graph for this function:

void au_reset_authorization_caches ( void  )

Definition at line 1019 of file authenticate.c.

References Au_cache_depth, AU_CACHE_INVALID, au_class_cache::data, i, au_class_cache::next, and NULL.

Referenced by ws_abort_mops(), and ws_clear_all_hints().

Here is the caller graph for this function:

int au_set_password ( MOP  user,
const char *  password 
)

Definition at line 2657 of file authenticate.c.

References au_set_password_internal(), and ENCODE_PREFIX_SHA2_512.

Referenced by au_add_user_method(), au_set_password_method(), db_set_password(), do_alter_user(), and do_create_user().

Here is the caller graph for this function:

void au_set_password_encoded_method ( MOP  user,
DB_VALUE returnval,
DB_VALUE password 
)
void au_set_password_method ( MOP  user,
DB_VALUE returnval,
DB_VALUE password 
)
int au_set_user ( MOP  newuser)
char* au_user_name_dup ( void  )

Definition at line 2441 of file authenticate.c.

References Au_user_name, and strdup().

Referenced by boot_initialize_client().

Here is the caller graph for this function:

Variable Documentation

const char* AU_AUTH_CLASS_NAME
const char* AU_DBA_USER_NAME

Definition at line 113 of file authenticate.c.

Referenced by au_perform_login(), and au_start().

const char* AU_GRANT_CLASS_NAME

Definition at line 110 of file authenticate.c.

const char* AU_OLD_ROOT_CLASS_NAME

Definition at line 105 of file authenticate.c.

Referenced by au_install().

const char* AU_PASSWORD_CLASS_NAME

Definition at line 108 of file authenticate.c.

Referenced by au_install(), au_set_password_internal(), au_start(), and clist_init().

const char* AU_PUBLIC_USER_NAME
const char* AU_ROOT_CLASS_NAME

Definition at line 104 of file authenticate.c.

Referenced by au_install(), au_start(), and clist_init().

char Au_user_password[AU_MAX_PASSWORD_BUF+4]