Replaced C++ comments with C-style

git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/trunk/rdesktop@539 423420c4-83ab-492f-b58f-81f9feb106b5
This commit is contained in:
Peter Åstrand 2003-10-31 20:34:26 +00:00
parent db87e93fd5
commit 6dbb270f2f
3 changed files with 27 additions and 27 deletions

View File

@ -701,7 +701,7 @@ process_bmpcache(STREAM s)
/* Begin compressedBitmapData */ /* Begin compressedBitmapData */
in_uint16_le(s, pad2); /* pad */ in_uint16_le(s, pad2); /* pad */
in_uint16_le(s, size); in_uint16_le(s, size);
// in_uint8s(s, 4); /* row_size, final_size */ /* in_uint8s(s, 4); */ /* row_size, final_size */
in_uint16_le(s, row_size); in_uint16_le(s, row_size);
in_uint16_le(s, final_size); in_uint16_le(s, final_size);

48
rdp.c
View File

@ -171,33 +171,33 @@ rdp_send_logon_info(uint32 flags, char *domain, char *user,
{ {
flags |= RDP_LOGON_BLOB; flags |= RDP_LOGON_BLOB;
DEBUG_RDP5(("Sending RDP5-style Logon packet\n")); DEBUG_RDP5(("Sending RDP5-style Logon packet\n"));
packetlen = 4 + // Unknown uint32 packetlen = 4 + /* Unknown uint32 */
4 + // flags 4 + /* flags */
2 + // len_domain 2 + /* len_domain */
2 + // len_user 2 + /* len_user */
(flags & RDP_LOGON_AUTO ? 2 : 0) + // len_password (flags & RDP_LOGON_AUTO ? 2 : 0) + /* len_password */
(flags & RDP_LOGON_BLOB ? 2 : 0) + // Length of BLOB (flags & RDP_LOGON_BLOB ? 2 : 0) + /* Length of BLOB */
2 + // len_program 2 + /* len_program */
2 + // len_directory 2 + /* len_directory */
(0 < len_domain ? len_domain : 2) + // domain (0 < len_domain ? len_domain : 2) + /* domain */
len_user + (flags & RDP_LOGON_AUTO ? len_password : 0) + 0 + // We have no 512 byte BLOB. Perhaps we must? len_user + (flags & RDP_LOGON_AUTO ? len_password : 0) + 0 + /* We have no 512 byte BLOB. Perhaps we must? */
(flags & RDP_LOGON_BLOB && !(flags & RDP_LOGON_AUTO) ? 2 : 0) + // After the BLOB is a unknown int16. If there is a BLOB, that is. (flags & RDP_LOGON_BLOB && !(flags & RDP_LOGON_AUTO) ? 2 : 0) + /* After the BLOB is a unknown int16. If there is a BLOB, that is. */
(0 < len_program ? len_program : 2) + (0 < len_directory ? len_directory : 2) + 2 + // Unknown (2) (0 < len_program ? len_program : 2) + (0 < len_directory ? len_directory : 2) + 2 + /* Unknown (2) */
2 + // Client ip length 2 + /* Client ip length */
len_ip + // Client ip len_ip + /* Client ip */
2 + // DLL string length 2 + /* DLL string length */
len_dll + // DLL string len_dll + /* DLL string */
2 + // Unknown 2 + /* Unknown */
2 + // Unknown 2 + /* Unknown */
64 + // Time zone #0 64 + /* Time zone #0 */
2 + // Unknown 2 + /* Unknown */
64 + // Time zone #1 64 + /* Time zone #1 */
32; // Unknown 32; /* Unknown */
s = sec_init(sec_flags, packetlen); s = sec_init(sec_flags, packetlen);
DEBUG_RDP5(("Called sec_init with packetlen %d\n", packetlen)); DEBUG_RDP5(("Called sec_init with packetlen %d\n", packetlen));
out_uint32(s, 0); // Unknown out_uint32(s, 0); /* Unknown */
out_uint32_le(s, flags); out_uint32_le(s, flags);
out_uint16_le(s, len_domain); out_uint16_le(s, len_domain);
out_uint16_le(s, len_user); out_uint16_le(s, len_user);
@ -243,7 +243,7 @@ rdp_send_logon_info(uint32 flags, char *domain, char *user,
out_uint16_le(s, 0); out_uint16_le(s, 0);
} }
out_uint16_le(s, 2); out_uint16_le(s, 2);
out_uint16_le(s, len_ip + 2); // Length of client ip out_uint16_le(s, len_ip + 2); /* Length of client ip */
rdp_out_unistr(s, "127.0.0.1", len_ip); rdp_out_unistr(s, "127.0.0.1", len_ip);
out_uint16_le(s, len_dll + 2); out_uint16_le(s, len_dll + 2);
rdp_out_unistr(s, "C:\\WINNT\\System32\\mstscax.dll", len_dll); rdp_out_unistr(s, "C:\\WINNT\\System32\\mstscax.dll", len_dll);

View File

@ -700,7 +700,7 @@ sec_process_crypt_info(STREAM s)
DEBUG(("Generating client random\n")); DEBUG(("Generating client random\n"));
/* Generate a client random, and hence determine encryption keys */ /* Generate a client random, and hence determine encryption keys */
// This is what the MS client do: /* This is what the MS client do: */
memset(inr, 0, SEC_RANDOM_SIZE); memset(inr, 0, SEC_RANDOM_SIZE);
/* *ARIGL!* Plaintext attack, anyone? /* *ARIGL!* Plaintext attack, anyone?
I tried doing: I tried doing:
@ -844,7 +844,7 @@ sec_connect(char *server, char *username)
if (!mcs_connect(server, &mcs_data, username)) if (!mcs_connect(server, &mcs_data, username))
return False; return False;
// sec_process_mcs_data(&mcs_data); /* sec_process_mcs_data(&mcs_data); */
if (g_encryption) if (g_encryption)
sec_establish_key(); sec_establish_key();
xfree(mcs_data.data); xfree(mcs_data.data);