mirror of https://github.com/tp4a/teleport
pull/32/head
parent
2b115fa2b5
commit
33aeaacdd1
|
@ -44,8 +44,9 @@
|
|||
#define TPE_OATH_MISMATCH 10002 // 身份验证器动态验证码错误
|
||||
#define TPE_SYS_MAINTENANCE 10003 // 系统维护中
|
||||
|
||||
#define TPE_USER_LOCKED 10100 // 用户已经被锁定
|
||||
#define TPE_USER_AUTH 10101 // 身份验证失败
|
||||
#define TPE_USER_LOCKED 10100 // 用户已经被锁定(连续多次错误密码)
|
||||
#define TPE_USER_BAN 10101 // 用户已经被禁用
|
||||
#define TPE_USER_AUTH 10102 // 身份验证失败
|
||||
|
||||
//-------------------------------------------------------
|
||||
// 助手程序专用错误值
|
||||
|
|
|
@ -326,8 +326,20 @@ int SshSession::_on_auth_password_request(ssh_session session, const char *user,
|
|||
|
||||
if (_this->m_auth_mode == TS_AUTH_MODE_PASSWORD) {
|
||||
// 膽邱끼桿슥빳駕되쩌(SSHv2股수)
|
||||
int retry_count = 0;
|
||||
rc = ssh_userauth_kbdint(_this->m_srv_session, NULL, NULL);
|
||||
while(rc == SSH_AUTH_INFO) {
|
||||
for (;;) {
|
||||
if (rc == SSH_AUTH_AGAIN) {
|
||||
retry_count += 1;
|
||||
if (retry_count >= 5)
|
||||
break;
|
||||
rc = ssh_userauth_kbdint(_this->m_srv_session, NULL, NULL);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (rc != SSH_AUTH_INFO)
|
||||
break;
|
||||
|
||||
int nprompts = ssh_userauth_kbdint_getnprompts(_this->m_srv_session);
|
||||
if(0 == nprompts) {
|
||||
rc = ssh_userauth_kbdint(_this->m_srv_session, NULL, NULL);
|
||||
|
|
|
@ -1 +1 @@
|
|||
@charset "utf-8";.page-content{padding:15px 30px 15px 30px}.stats{overflow:hidden;padding:15px;color:#686868;background-color:#fff;border-radius:3px;margin-bottom:10px}.stats span.sub-name{font-size:11px;font-weight:300}.stats.stats-warning{position:relative;background-color:#c86124}.stats.stats-warning .stats-content{text-align:center;font-size:24px}.stats .loading{color:#fff;font-size:14px}.stats.stats-id-host{border-top:5px solid #407deb}.stats.stats-id-user{border-top:5px solid #eba61e}.stats.stats-id-connect{border-top:5px solid #14c13c}.stats.stats-box{position:relative;height:116px}.stats.stats-box .stats-content{padding-left:100px}.stats.stats-box .stats-icon{font-size:130px;line-height:130px;left:20px;text-align:center;position:absolute;color:rgba(0,0,0,0.05)}.stats.stats-box .stats-name{font-size:18px;font-weight:500;color:rgba(0,0,0,0.6)}.stats.stats-box .stats-value{margin-top:5px;color:rgba(0,0,0,0.6);font-size:48px;line-height:52px;font-weight:300;white-space:nowrap;padding-left:20px}.stats.stats-bar{position:relative;height:320px}.stats.stats-bar .stats-name{font-size:16px;font-weight:500;color:rgba(0,0,0,0.6)}.stats.stats-bar .stats-value{margin-top:5px;color:rgba(0,0,0,0.6);font-size:48px;line-height:52px;font-weight:300;white-space:nowrap;padding-left:20px}.stats.stats-first{border-left:none}.stats a{color:#eee;color:rgba(255,255,255,0.7)}.stats a:hover{color:#fff}
|
||||
@charset "utf-8";.page-content{padding:15px 30px 15px 30px}.stats{overflow:hidden;padding:15px;color:#686868;background-color:#fff;border-radius:3px;margin-bottom:10px}.stats span.sub-name{font-size:11px;font-weight:300}.stats.stats-warning{position:relative;background-color:#c86124}.stats.stats-warning .stats-content{text-align:center;font-size:24px}.stats .loading{color:#fff;font-size:14px}.stats.stats-id-host{border-top:5px solid #407deb}.stats.stats-id-user{border-top:5px solid #eba61e}.stats.stats-id-connect{border-top:5px solid #14c13c}.stats.stats-box{position:relative;height:116px}.stats.stats-box .stats-content{padding-left:100px}.stats.stats-box .stats-icon{font-size:130px;line-height:130px;left:20px;text-align:center;position:absolute;color:rgba(0,0,0,0.05)}.stats.stats-box .stats-name{font-size:18px;font-weight:500;color:rgba(0,0,0,0.6)}.stats.stats-box .stats-value{margin-top:5px;color:rgba(0,0,0,0.6);font-size:48px;line-height:52px;font-weight:300;white-space:nowrap;padding-left:20px}.stats.stats-bar{position:relative;height:320px}.stats.stats-bar .stats-name{font-size:16px;font-weight:500;color:rgba(0,0,0,0.6)}.stats.stats-bar .stats-value{margin-top:5px;color:rgba(0,0,0,0.6);font-size:48px;line-height:52px;font-weight:300;white-space:nowrap;padding-left:20px}.stats.stats-first{border-left:none}.stats a{color:#eee;color:rgba(255,255,255,0.7)}.stats a:hover{color:#fff}/*# sourceMappingURL=dashboard.css.map */
|
Loading…
Reference in New Issue