trans_delete(scp_trans); // Closes scp_fd as well
}
}
return rv;
}
/******************************************************************************/ staticint
handle_logout_request(struct trans *self)
{
LOG(LOG_LEVEL_INFO, "xrdp-sesexec pid %d is now logging out", g_pid);
sesexec_terminate_main_loop(0); return0;
}
/******************************************************************************/ staticint
handle_create_session_request(struct trans *self)
{ int scp_fd; struct session_parameters sp = {0}; int rv;
rv = eicp_get_create_session_request(self, &scp_fd, &sp.display,
&sp.type, &sp.width, &sp.height,
&sp.bpp, &sp.shell, &sp.directory); if (rv == 0)
{ // Need to talk to the SCP client struct trans *scp_trans;
scp_trans = scp_init_trans_from_fd(scp_fd, TRANS_TYPE_SERVER,
sesexec_is_term); if (scp_trans == NULL)
{
LOG(LOG_LEVEL_ERROR, "Can't create SCP trans");
g_file_close(scp_fd);
rv = 1;
} else
{ enum scp_screate_status scp_status = E_SCP_SCREATE_OK;
// Use the UID from the SCP connection if the user hasn't // explicitly logged in if (g_login_info == NULL &&
(g_login_info = login_info_uds_login_user(scp_trans)) == NULL)
{
scp_status = E_SCP_SCREATE_GENERAL_ERROR;
}
if (scp_status == E_SCP_SCREATE_OK)
{ // Try to create the session
sp.guid = guid_new();
scp_status = session_start(g_login_info, &sp, &g_session_data);
}
// Return the status to the SCP client
rv = scp_send_create_session_response(scp_trans, scp_status,
sp.display, &sp.guid);
trans_delete(scp_trans);
// Further comms from sesexec is sent over the ERCP protocol
ercp_trans_from_eicp_trans(self,
sesexec_ercp_data_in,
(void *)self);
/******************************************************************************/ int
eicp_server(struct trans *self)
{ int rv = 0; enum eicp_msg_code msgno;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.