21
21
#ifndef DRIZZLED_SECURITY_CONTEXT_H
22
22
#define DRIZZLED_SECURITY_CONTEXT_H
30
@class SecurityContext
26
@class Security_context
31
27
@brief A set of Session members describing the current authenticated user.
34
class SecurityContext {
30
class Security_context {
43
password_type(PLAIN_TEXT)
46
const std::string& getIp() const
51
void setIp(const char *newip)
56
const std::string& getUser() const
61
void setUser(const std::string &newuser)
66
PasswordType getPasswordType(void) const
71
void setPasswordType(PasswordType newpassword_type)
73
password_type= newpassword_type;
76
const std::string& getPasswordContext() const
78
return password_context;
81
void setPasswordContext(const char *newpassword_context, size_t size)
83
password_context.assign(newpassword_context, size);
87
PasswordType password_type;
34
host - host of the client
35
user - user of the client, set to NULL until the user has been read from
37
priv_user - The user privilege we are using. May be "" for anonymous user.
90
std::string password_context;
44
inline const char *priv_host_name()
46
return (ip.c_str() ? ip.c_str() : (char *)"%");
93
} /* namespace drizzled */
95
50
#endif /* DRIZZLED_SECURITY_CONTEXT_H */