![]()  | 
  
    MySQL 8.4.7
    
   Source Code Documentation 
   | 
 
Class to handle information stored in mysql.user.user_attributes. More...
#include <acl_table_user.h>
Public Member Functions | |
| Acl_user_attributes (MEM_ROOT *mem_root, bool read_restrictions, Auth_id &auth_id, Access_bitmask global_privs) | |
| Default constructor.  More... | |
| Acl_user_attributes (MEM_ROOT *mem_root, bool read_restrictions, Auth_id &auth_id, Restrictions *m_restrictions, I_multi_factor_auth *mfa) | |
| ~Acl_user_attributes () | |
| bool | deserialize (const Json_object &json_object) | 
| Obtain info from JSON representation of user attributes.  More... | |
| bool | serialize (Json_object &json_object) const | 
| Create JSON object from user attributes.  More... | |
| bool | update_additional_password (std::string &credential) | 
| Update second password for user.  More... | |
| void | discard_additional_password () | 
| Discard second password.  More... | |
| const std::string | get_additional_password () const | 
| Get second password.  More... | |
| Restrictions | get_restrictions () const | 
| Get the restriction list for the user.  More... | |
| void | update_restrictions (const Restrictions &restricitions) | 
| auto | get_failed_login_attempts () const | 
| auto | get_password_lock_time_days () const | 
| auto | get_password_lock () const | 
| void | set_password_lock (Password_lock password_lock) | 
| I_multi_factor_auth * | get_mfa () | 
| void | set_mfa (I_multi_factor_auth *mfa) | 
| bool | consume_user_attributes_json (Json_dom_ptr json) | 
| Take over ownership of the json pointer.  More... | |
Private Member Functions | |
| void | report_and_remove_invalid_db_restrictions (DB_restrictions &db_restrictions, Access_bitmask mask, enum loglevel level, ulonglong errcode) | 
| bool | deserialize_password_lock (const Json_object &json_object) | 
| bool | deserialize_multi_factor (const Json_object &json_object) | 
Private Attributes | |
| MEM_ROOT * | m_mem_root | 
| Mem root.  More... | |
| bool | m_read_restrictions | 
| Operation for restrictions.  More... | |
| Auth_id | m_auth_id | 
| Auth ID.  More... | |
| std::string | m_additional_password | 
| Second password for user.  More... | |
| Restrictions | m_restrictions | 
| Restrictions_list on certain databases for user.  More... | |
| Access_bitmask | m_global_privs | 
| Global static privileges.  More... | |
| Password_lock | m_password_lock | 
| password locking  More... | |
| I_multi_factor_auth * | m_mfa | 
| multi factor auth info  More... | |
| Json_dom_ptr | m_user_attributes_json | 
| Save the original json object.  More... | |
Class to handle information stored in mysql.user.user_attributes.
| acl_table::Acl_user_attributes::Acl_user_attributes | ( | MEM_ROOT * | mem_root, | 
| bool | read_restrictions, | ||
| Auth_id & | auth_id, | ||
| Access_bitmask | global_privs | ||
| ) | 
Default constructor.
| acl_table::Acl_user_attributes::Acl_user_attributes | ( | MEM_ROOT * | mem_root, | 
| bool | read_restrictions, | ||
| Auth_id & | auth_id, | ||
| Restrictions * | m_restrictions, | ||
| I_multi_factor_auth * | mfa | ||
| ) | 
| acl_table::Acl_user_attributes::~Acl_user_attributes | ( | ) | 
| bool acl_table::Acl_user_attributes::consume_user_attributes_json | ( | Json_dom_ptr | json | ) | 
Take over ownership of the json pointer.
| true | An error occurred | 
| false | Success | 
| bool acl_table::Acl_user_attributes::deserialize | ( | const Json_object & | json_object | ) | 
Obtain info from JSON representation of user attributes.
| [in] | json_object | JSON object that holds user attributes | 
| false | Success | 
| true | Error parsing the JSON object | 
Second password
      
  | 
  private | 
      
  | 
  private | 
| void acl_table::Acl_user_attributes::discard_additional_password | ( | ) | 
Discard second password.
| const std::string acl_table::Acl_user_attributes::get_additional_password | ( | ) | const | 
Get second password.
      
  | 
  inline | 
      
  | 
  inline | 
      
  | 
  inline | 
      
  | 
  inline | 
| Restrictions acl_table::Acl_user_attributes::get_restrictions | ( | ) | const | 
Get the restriction list for the user.
      
  | 
  private | 
| bool acl_table::Acl_user_attributes::serialize | ( | Json_object & | json_object | ) | const | 
Create JSON object from user attributes.
| [out] | json_object | Object to store serialized user attributes | 
| false | Success | 
| true | Error serializing user attributes | 
      
  | 
  inline | 
      
  | 
  inline | 
| bool acl_table::Acl_user_attributes::update_additional_password | ( | std::string & | credential | ) | 
Update second password for user.
We replace existing one if any.
| [in] | credential | Second password | 
| false | Success | 
| true | Error. Second password is empty | 
| void acl_table::Acl_user_attributes::update_restrictions | ( | const Restrictions & | restricitions | ) | 
      
  | 
  private | 
Second password for user.
      
  | 
  private | 
Auth ID.
      
  | 
  private | 
Global static privileges.
      
  | 
  private | 
Mem root.
      
  | 
  private | 
multi factor auth info
      
  | 
  private | 
password locking
      
  | 
  private | 
Operation for restrictions.
      
  | 
  private | 
Restrictions_list on certain databases for user.
      
  | 
  private | 
Save the original json object.