add method for add user

This commit is contained in:
xiongziliang
2017-05-05 21:29:12 +08:00
parent e91525e96e
commit 56078f3ba0
2 changed files with 4 additions and 1 deletions

View File

@@ -161,6 +161,7 @@ inline void ShellSession::sendHead() {
inline bool ShellSession::authUser(const string& user, const string& pwd) {
auto it = g_mapUser.find(user);
if (it == g_mapUser.end()) {
//WarnL << user << " " << pwd;
return false;
}
return it->second == pwd;