MySQL 8.4.2
Source Code Documentation
|
#include "client/include/multi_factor_passwordopt-vars.h"
#include "my_getopt.h"
#include "mysql.h"
#include "mysql/service_mysql_alloc.h"
#include "nulls.h"
Functions | |
void | parse_command_line_password_option (const struct my_option *opt, char *argument) |
Helper method used by clients to parse password set as part of command line. More... | |
void | set_password_options (MYSQL *mysql) |
Helper method used by clients to set password in mysql->options. More... | |
void | free_passwords () |
Release memory for opt_password. More... | |
Variables | |
char * | opt_password [MAX_AUTH_FACTORS] = {nullptr} |
bool | tty_password [MAX_AUTH_FACTORS] = {false} |
void free_passwords | ( | ) |
Release memory for opt_password.
void parse_command_line_password_option | ( | const struct my_option * | opt, |
char * | argument | ||
) |
Helper method used by clients to parse password set as part of command line.
parse passwords for –password or –password<N> option where N = 1,2,3
This method checks if password value is specified or not. If not then a flag is set to let client accept password from terminal.
opt | password option |
argument | value specified for –password<1,2,3> or –password |
void set_password_options | ( | MYSQL * | mysql | ) |
Helper method used by clients to set password in mysql->options.
Set password in mysql->options.
If tty_password is true get password from terminal and update in opt_password and set tty_password to false
If opt_password is populated call mysql_options4()
char* opt_password[MAX_AUTH_FACTORS] = {nullptr} |
bool tty_password[MAX_AUTH_FACTORS] = {false} |