/[rdesktop]/sourceforge.net/trunk/rdesktop/rdp5.c
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /sourceforge.net/trunk/rdesktop/rdp5.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 343 by forsberg, Thu Mar 27 13:07:28 2003 UTC revision 428 by forsberg, Mon Jun 23 06:37:50 2003 UTC
# Line 24  Line 24 
24  extern uint8 *next_packet;  extern uint8 *next_packet;
25    
26  void  void
27  rdp5_process(STREAM s, BOOL encryption, BOOL shortform)  rdp5_process(STREAM s, BOOL encryption)
28  {  {
29          uint16 length, count;          uint16 length, count, x, y;
30          uint8 type;          uint8 type;
31          uint8 *next;          uint8 *next;
32    
33          if (encryption)          if (encryption)
34          {          {
35                  in_uint8s(s, shortform ? 6 : 7 /* XXX HACK */ );        /* signature */                  in_uint8s(s, 8);        /* signature */
36                  sec_decrypt(s->p, s->end - s->p);                  sec_decrypt(s->p, s->end - s->p);
37          }          }
38    
# Line 49  rdp5_process(STREAM s, BOOL encryption, Line 49  rdp5_process(STREAM s, BOOL encryption,
49    
50                  switch (type)                  switch (type)
51                  {                  {
52                            /* Thanks to Jeroen Meijer <jdmeijer at yahoo
53                               dot com> for finding out the meaning of
54                               most of the opcodes here. Especially opcode
55                               8! :) */
56                          case 0: /* orders */                          case 0: /* orders */
57                                  in_uint16_le(s, count);                                  in_uint16_le(s, count);
58                                  process_orders(s, count);                                  process_orders(s, count);
# Line 61  rdp5_process(STREAM s, BOOL encryption, Line 65  rdp5_process(STREAM s, BOOL encryption,
65                                  in_uint8s(s, 2);        /* uint16 = 2 */                                  in_uint8s(s, 2);        /* uint16 = 2 */
66                                  process_palette(s);                                  process_palette(s);
67                                  break;                                  break;
68                          case 3: /* probably an palette with offset 3. Weird */                          case 3: /* probably an palette with offset 3. Weird */
69                                  break;                                  break;
70                          case 5:                          case 5:
71                                  process_null_system_pointer_pdu(s);                                  process_null_system_pointer_pdu(s);
72                                  break;                                  break;
73                            case 8:
74                                    in_uint16_le(s, x);
75                                    in_uint16_le(s, y);
76                                    if (s_check(s))
77                                            ui_move_pointer(x, y);
78                                    break;
79                          case 9:                          case 9:
80                                  process_colour_pointer_pdu(s);                                  process_colour_pointer_pdu(s);
81                                  break;                                  break;
# Line 81  rdp5_process(STREAM s, BOOL encryption, Line 91  rdp5_process(STREAM s, BOOL encryption,
91  }  }
92    
93  void  void
94  rdp5_process_channel(STREAM s, uint16 channel)  rdp5_process_channel(STREAM s, uint16 channelno)
95  {  {
96          printf("Data on channel %02x:\n", channel);          rdp5_channel *channel;
97          hexdump(s->p, s->end - s->p);          channel = find_channel_by_channelno(channelno);
98            if (NULL != channel)
99            {
100                    channel->channelcallback(s, channelno);
101            }
102  }  }

Legend:
Removed from v.343  
changed lines
  Added in v.428

  ViewVC Help
Powered by ViewVC 1.1.26