introducing a bad hack to send the connection request after establishing a secure connection, and without a negotiation request

This commit is contained in:
Lysann Kessler 2012-06-02 21:35:34 +02:00
parent ee9b0b93a1
commit b119af583a
2 changed files with 15 additions and 1 deletions

View File

@ -137,6 +137,20 @@ boolean rdp_client_connect(rdpRdp* rdp)
if (status != true)
return false;
if(!negotiateSecurityLayer)
{
// XXX: the whole negotioation thing should be called differently.
// this is more like a hack in order to allow connection requests after establishing a secure connection.
rdp->nego->state = NEGO_STATE_INITIAL;
rdp->nego->transport = rdp->transport;
rdp->nego->transport->settings->requested_protocols = PROTOCOL_RDP; // removes requested_protocols section
if (nego_connect(rdp->nego) != true)
{
printf("Error: X.224 connection request failure\n");
return false;
}
}
rdp_set_blocking_mode(rdp, false);
rdp->state = CONNECTION_STATE_NEGO;
rdp->finalize_sc_pdus = 0;

View File

@ -261,7 +261,7 @@ boolean nego_recv_response(rdpNego* nego)
if (transport_read(nego->transport, s) < 0)
return false;
return nego_recv(nego->transport, s, nego->transport->recv_extra);
return nego_recv(nego->transport, s, nego);
}
/**