MySQL 8.0.39
Source Code Documentation
user_registration.cc File Reference
#include <scope_guard.h>
#include <sstream>
#include <vector>
#include "user_registration.h"
#include "my_hostname.h"
#include "my_inttypes.h"
#include "my_sys.h"
#include "mysql/service_mysql_alloc.h"
#include "mysqld_error.h"

Macros

#define QUERY_LENGTH   2048
 
#define MAX_QUERY_LENGTH   4096
 

Functions

static bool parse_register_option (char *what_factor, std::vector< unsigned int > &list)
 This helper method parses –fido-register-factor option values, and inserts the parsed values in list. More...
 
bool user_device_registration (MYSQL *mysql, char *register_option, char *errmsg)
 This helper method is used to perform device registration against a user account. More...
 

Macro Definition Documentation

◆ MAX_QUERY_LENGTH

#define MAX_QUERY_LENGTH   4096

◆ QUERY_LENGTH

#define QUERY_LENGTH   2048

Function Documentation

◆ parse_register_option()

static bool parse_register_option ( char *  what_factor,
std::vector< unsigned int > &  list 
)
static

This helper method parses –fido-register-factor option values, and inserts the parsed values in list.

Parameters
[in]what_factorcomma separated string containing what all factors are to be registered
[out]listcontainer holding individual factors
Returns
true failed
false success

◆ user_device_registration()

bool user_device_registration ( MYSQL mysql,
char *  register_option,
char *  errmsg 
)

This helper method is used to perform device registration against a user account.

Please refer How authentication_fido works? for more information.

Parameters
mysqlmysql connection handle
register_optionComma separated list of values, which specifies which factor requires registration. Valid values are "2", "3", "2,3" or "3,2"
errmsgBuffer tol hold error message in case of error.
Returns
true failed
false success