diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-08-20 00:29:09 -0500 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-08-20 00:29:09 -0500 |
commit | 57029de2707808c3e7d12568af3de87eaca71828 (patch) | |
tree | 0dd7aca471ffddede7d6ec8d54d075e515a9ca9e /sesman/scp_v0.c | |
parent | b62256d54dd71705a29da49bc8ee62d6ebd95230 (diff) | |
parent | c5862f367ca68763dd3070598a36ea82db7f3566 (diff) | |
download | xrdp-proprietary-57029de2707808c3e7d12568af3de87eaca71828.tar.gz xrdp-proprietary-57029de2707808c3e7d12568af3de87eaca71828.zip |
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'sesman/scp_v0.c')
-rw-r--r-- | sesman/scp_v0.c | 31 |
1 files changed, 19 insertions, 12 deletions
diff --git a/sesman/scp_v0.c b/sesman/scp_v0.c index 886aaa29..092585cf 100644 --- a/sesman/scp_v0.c +++ b/sesman/scp_v0.c @@ -40,8 +40,7 @@ scp_v0_process(struct SCP_CONNECTION* c, struct SCP_SESSION* s) struct session_item* s_item; data = auth_userpass(s->username, s->password); - - if (data) + if (s->type == SCP_GW_AUTHENTICATION) { s_item = session_get_bydata(s->username, s->width, s->height, s->bpp, s->type); @@ -60,42 +59,51 @@ scp_v0_process(struct SCP_CONNECTION* c, struct SCP_SESSION* s) display = s_item->display; if (0 != s->client_ip) { - log_message(&(g_cfg->log), LOG_LEVEL_INFO, "++ reconnected session: username %s, display :%d.0, session_pid %d, ip %s", s->username, display, s_item->pid, s->client_ip); + log_message( LOG_LEVEL_INFO, "++ reconnected session: username %s, " + "display :%d.0, session_pid %d, ip %s", + s->username, display, s_item->pid, s->client_ip); } else { - log_message(&(g_cfg->log), LOG_LEVEL_INFO, "++ reconnected session: username %s, display :%d.0, session_pid %d", s->username, display, s_item->pid); + log_message(LOG_LEVEL_INFO, "++ reconnected session: username %s, " + "display :%d.0, session_pid %d", s->username, display, + s_item->pid); } + session_reconnect(display, s->username); auth_end(data); /* don't set data to null here */ } else { - LOG_DBG(&(g_cfg->log), "pre auth"); + LOG_DBG("pre auth"); if (1 == access_login_allowed(s->username)) { if (0 != s->client_ip) { - log_message(&(g_cfg->log), LOG_LEVEL_INFO, "++ created session (access granted): username %s, ip %s", s->username, s->client_ip); + log_message(LOG_LEVEL_INFO, "++ created session (access granted): " + "username %s, ip %s", s->username, s->client_ip); } else { - log_message(&(g_cfg->log), LOG_LEVEL_INFO, "++ created session (access granted): username %s", s->username); + log_message(LOG_LEVEL_INFO, "++ created session (access granted): " + "username %s", s->username); } if (SCP_SESSION_TYPE_XVNC == s->type) { - log_message(&(g_cfg->log), LOG_LEVEL_INFO, "starting Xvnc session..."); + log_message( LOG_LEVEL_INFO, "starting Xvnc session..."); display = session_start(s->width, s->height, s->bpp, s->username, s->password, data, SESMAN_SESSION_TYPE_XVNC, - s->domain, s->program, s->directory, s->client_ip); + s->domain, s->program, s->directory, + s->client_ip); } else { - log_message(&(g_cfg->log), LOG_LEVEL_INFO, "starting X11rdp session..."); + log_message(LOG_LEVEL_INFO, "starting X11rdp session..."); display = session_start(s->width, s->height, s->bpp, s->username, s->password, data, SESMAN_SESSION_TYPE_XRDP, - s->domain, s->program, s->directory, s->client_ip); + s->domain, s->program, s->directory, + s->client_ip); } } else @@ -118,4 +126,3 @@ scp_v0_process(struct SCP_CONNECTION* c, struct SCP_SESSION* s) scp_v0s_deny_connection(c); } } - |