60 |
|
|
61 |
/* Receive an RDP packet */ |
/* Receive an RDP packet */ |
62 |
static STREAM |
static STREAM |
63 |
rdp_recv(uint8 *type) |
rdp_recv(uint8 * type) |
64 |
{ |
{ |
65 |
static STREAM rdp_s; |
static STREAM rdp_s; |
66 |
uint16 length, pdu_type; |
uint16 length, pdu_type; |
156 |
int len_program = 2 * strlen(program); |
int len_program = 2 * strlen(program); |
157 |
int len_directory = 2 * strlen(directory); |
int len_directory = 2 * strlen(directory); |
158 |
uint32 sec_flags = encryption ? (SEC_LOGON_INFO | SEC_ENCRYPT) |
uint32 sec_flags = encryption ? (SEC_LOGON_INFO | SEC_ENCRYPT) |
159 |
: SEC_LOGON_INFO; |
: SEC_LOGON_INFO; |
160 |
STREAM s; |
STREAM s; |
161 |
|
|
162 |
s = sec_init(sec_flags, 18 + len_domain + len_user + len_password |
s = sec_init(sec_flags, 18 + len_domain + len_user + len_password |
443 |
RDP_CAPLEN_BMPCACHE + RDP_CAPLEN_COLCACHE + |
RDP_CAPLEN_BMPCACHE + RDP_CAPLEN_COLCACHE + |
444 |
RDP_CAPLEN_ACTIVATE + RDP_CAPLEN_CONTROL + |
RDP_CAPLEN_ACTIVATE + RDP_CAPLEN_CONTROL + |
445 |
RDP_CAPLEN_POINTER + RDP_CAPLEN_SHARE + RDP_CAPLEN_UNKNOWN |
RDP_CAPLEN_POINTER + RDP_CAPLEN_SHARE + RDP_CAPLEN_UNKNOWN |
446 |
+ 4 /* w2k fix, why? */; |
+ 4 /* w2k fix, why? */ ; |
447 |
|
|
448 |
s = rdp_init(14 + caplen + sizeof(RDP_SOURCE)); |
s = rdp_init(14 + caplen + sizeof(RDP_SOURCE)); |
449 |
|
|
616 |
in_uint16_le(s, map.ncolours); |
in_uint16_le(s, map.ncolours); |
617 |
in_uint8s(s, 2); /* pad */ |
in_uint8s(s, 2); /* pad */ |
618 |
in_uint8p(s, colours, (map.ncolours * 3)); |
in_uint8p(s, colours, (map.ncolours * 3)); |
619 |
map.colours = (COLOURENTRY *)colours; |
map.colours = (COLOURENTRY *) colours; |
620 |
|
|
621 |
hmap = ui_create_colourmap(&map); |
hmap = ui_create_colourmap(&map); |
622 |
ui_set_colourmap(hmap); |
ui_set_colourmap(hmap); |