#include <password.h>
Definition at line 72 of file password.h.
◆ login() [1/3]
◆ login() [2/3]
| tools::login::login |
( |
const login & |
| ) |
|
|
delete |
◆ login() [3/3]
| tools::login::login |
( |
login && |
| ) |
|
|
default |
◆ ~login()
◆ operator=() [1/2]
◆ operator=() [2/2]
◆ parse()
| boost::optional< login > tools::login::parse |
( |
std::string && |
userpass, |
|
|
bool |
verify, |
|
|
const std::function< boost::optional< password_container >(bool)> & |
prompt |
|
) |
| |
|
static |
Extracts username and password from the format username:password. A blank username or password is allowed. If the : character is not present, password_container::prompt will be called by forwarding the verify and message arguments.
- Parameters
-
- Returns
- The username and password, or boost::none if
password_container::prompt fails.
Definition at line 268 of file password.cpp.
272 const auto loc = userpass.find(
':');
273 if (loc == std::string::npos)
275 auto result = prompt(verify);
283 out.password = password_container{userpass.substr(loc + 1)};
286 out.username = userpass.substr(0, loc);
287 password_container wipe{
std::move(userpass)};
const T & move(const T &t)
◆ password
◆ username
| std::string tools::login::username |
The documentation for this struct was generated from the following files:
- /home/abuild/rpmbuild/BUILD/electroneum-5.0.0.4/src/common/password.h
- /home/abuild/rpmbuild/BUILD/electroneum-5.0.0.4/src/common/password.cpp