1 (* Copyright 2001, 2002 b8_bavard, b8_fee_carabine, INRIA *)
3 This file is part of mldonkey.
5 mldonkey is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
10 mldonkey is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with mldonkey; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
34 let compatibleclient = ref 10
36 let get_emule_version () =
37 (!compatibleclient lsl 24) lor
38 (int_of_string
(Autoconf.major_version
) lsl 17) lor
39 (int_of_string
(Autoconf.minor_version
) lsl 10) lor
40 (int_of_string
(Autoconf.sub_version
) lsl 7)
42 let mldonkey_emule_proto =
44 emule_version
= get_emule_version ();
46 emule_osinfosupport
= 1;
49 (* emule_miscoptions1 *)
50 received_miscoptions1
= false;
54 emule_compression
= 1;
55 emule_secident
= 3; (* Emule uses v1 if advertising both, v2 if only advertising 2 *)
56 emule_sourceexchange
= 2; (* 2 : +client_md4 3 : +IdHybrid (emule Kademlia?)*)
57 emule_extendedrequest
= 1; (* 1: +file_status 2: +ncomplete_sources*)
60 emule_noviewshared
= 0;
61 emule_multipacket
= 0;
62 emule_supportpreview
= 0;
64 (* emule_miscoptions2 *)
65 received_miscoptions2
= false;
66 emule_require_crypt
= 0;
67 emule_request_crypt
= 0;
68 emule_support_crypt
= 0;
69 emule_extmultipacket
= 0;
71 emule_kad_version
= 0;
72 emule_support_captcha
= 1;
75 let emule_miscoptions1 m
=
77 (m
.emule_aich
lsl 29) lor
78 (m
.emule_unicode
lsl 28) lor
79 (m
.emule_udpver
lsl 24) lor
80 (m
.emule_compression
lsl 20) lor
81 (m
.emule_secident
lsl 16) lor
82 (m
.emule_sourceexchange
lsl 12) lor
83 (m
.emule_extendedrequest
lsl 8) lor
84 (m
.emule_comments
lsl 4) lor
85 (m
.emule_peercache
lsl 3) lor
86 (m
.emule_noviewshared
lsl 2) lor
87 (m
.emule_multipacket
lsl 1) lor
88 (m
.emule_supportpreview
lsl 0)
92 let update_emule_proto_from_miscoptions1 m
o =
93 let o = Int64.to_int
o in
94 m
.emule_aich
<- (o lsr 29) land 0x7;
95 m
.emule_unicode
<- (o lsr 28) land 0xf;
96 m
.emule_udpver
<- (o lsr 24) land 0xf;
97 m
.emule_compression
<- (o lsr 20) land 0xf;
98 m
.emule_secident
<- (o lsr 16) land 0xf;
99 m
.emule_sourceexchange
<- (o lsr 12) land 0xf;
100 m
.emule_extendedrequest
<- (o lsr 8) land 0xf;
101 m
.emule_comments
<- (o lsr 4) land 0xf;
102 m
.emule_peercache
<- (o lsr 3) land 0x1;
103 m
.emule_noviewshared
<- (o lsr 2) land 0x1;
104 m
.emule_multipacket
<- (o lsr 1) land 0x1;
105 m
.emule_supportpreview
<- (o lsr 0) land 0x1
107 let print_emule_proto_miscoptions1 m
=
108 let buf = Buffer.create
50 in
109 if m
.emule_aich
<> 0 then Printf.bprintf
buf " aich %d\n" m
.emule_aich
;
110 if m
.emule_unicode
<> 0 then Printf.bprintf
buf " unicode %d\n" m
.emule_unicode
;
111 if m
.emule_udpver
<> 0 then Printf.bprintf
buf " udpver %d\n" m
.emule_udpver
;
112 if m
.emule_compression
<> 0 then Printf.bprintf
buf " compression %d\n" m
.emule_compression
;
113 if m
.emule_secident
<> 0 then Printf.bprintf
buf " secident %d\n" m
.emule_secident
;
114 if m
.emule_sourceexchange
<> 0 then Printf.bprintf
buf " sourceexchange %d\n" m
.emule_sourceexchange
;
115 if m
.emule_extendedrequest
<> 0 then Printf.bprintf
buf " extendedrequest %d\n" m
.emule_extendedrequest
;
116 if m
.emule_comments
<> 0 then Printf.bprintf
buf " comments %d\n" m
.emule_comments
;
117 if m
.emule_peercache
<> 0 then Printf.bprintf
buf " peercache %d\n" m
.emule_peercache
;
118 if m
.emule_noviewshared
<> 0 then Printf.bprintf
buf " noviewshared %d\n" m
.emule_noviewshared
;
119 if m
.emule_multipacket
<> 0 then Printf.bprintf
buf " multipacket %d\n" m
.emule_multipacket
;
120 if m
.emule_supportpreview
<> 0 then Printf.bprintf
buf " supportpreview %d\n" m
.emule_supportpreview
;
123 let emule_miscoptions2 m
=
125 (m
.emule_support_captcha
lsl 11) lor
126 (m
.emule_largefiles
lsl 4)
130 let update_emule_proto_from_miscoptions2 m
o =
131 let o = Int64.to_int
o in
132 m
.emule_support_captcha
<- (o lsr 11) land 0x1;
133 m
.emule_require_crypt
<- (o lsr 9) land 0x1;
134 m
.emule_request_crypt
<- (o lsr 8) land 0x1;
135 m
.emule_support_crypt
<- (o lsr 7) land 0x1;
136 m
.emule_extmultipacket
<- (o lsr 5) land 0x1;
137 m
.emule_largefiles
<- (o lsr 4) land 0x1;
138 m
.emule_kad_version
<- (o lsr 0) land 0xf
140 let print_emule_proto_miscoptions2 m
=
141 let buf = Buffer.create
50 in
142 if m
.emule_require_crypt
<> 0 then Printf.bprintf
buf " require_crypt %d\n" m
.emule_require_crypt
;
143 if m
.emule_request_crypt
<> 0 then Printf.bprintf
buf " request_crypt %d\n" m
.emule_request_crypt
;
144 if m
.emule_support_crypt
<> 0 then Printf.bprintf
buf " support_crypt %d\n" m
.emule_support_crypt
;
145 if m
.emule_extmultipacket
<> 0 then Printf.bprintf
buf " extmultipacket %d\n" m
.emule_extmultipacket
;
146 if m
.emule_largefiles
<> 0 then Printf.bprintf
buf " largefiles %d\n" m
.emule_largefiles
;
147 if m
.emule_kad_version
<> 0 then Printf.bprintf
buf " kad_version %d\n" m
.emule_kad_version
;
148 if m
.emule_support_captcha
<> 0 then Printf.bprintf
buf " support_captcha %d\n" m
.emule_support_captcha
;
151 let emule_compatoptions m
=
152 (m
.emule_osinfosupport
lsl 0)
154 let update_emule_proto_from_compatoptions m
o =
155 m
.emule_osinfosupport
<- (o lsr 0) land 0x1
157 let extendedrequest e
=
158 min e
.emule_extendedrequest
mldonkey_emule_proto.emule_extendedrequest
160 let sourceexchange e
=
161 min e
.emule_sourceexchange
mldonkey_emule_proto.emule_sourceexchange
164 BAD MESSAGE FROM CONNECTING CLIENT
166 ascii: [(1)(16)(231)(129)(131)(26) O(247)(154)(145)(251)(253)(167) G }(207) j(146)(140) { l(139) F(18)(0)(0)(0)(0)(0)(0)(0)(0)(0)(0)]
170 (231)(129)(131)(26)(79)(247)(154)(145)(251)(253)(167)(71)(125)(207)(106)(146)
177 let rec lbprint_tags buf tags
=
179 [] -> Printf.bprintf
buf ""
181 Printf.bprintf
buf " (%s)=(%s)" (escaped_string_of_field tag
)
182 (string_of_tag_value tag
.tag_value
);
183 lbprint_tags buf tags
185 module Connect
= struct
192 server_info
: (Ip.t
* int) option;
196 let names_of_tag = client_common_tags
199 List.map
(fun (v
, name
) -> (v
, Field_KNOWN name
)) names_of_tag
201 let parse reply len s
=
202 let hash_len, pos
= if not reply
then get_uint8 s
1, 2 else -1, 1 in
203 let md4 = get_md4 s pos
in
204 let ip = get_ip s
(pos
+16) in
205 let port = get_port s
(pos
+20) in
206 let tags, pos
= get_tags s
(pos
+22) names_of_tag in
207 let server_info = Some
(get_ip s pos
, get_port s
(pos
+4)) in
208 let left_bytes = String.sub s
(pos
+6) (String.length s
- pos
- 6) in
215 server_info = server_info;
216 left_bytes = left_bytes;
221 let b1 = Buffer.create
50 in
222 let b2 = Buffer.create
5 in
223 lbprint_tags b1 t
.tags;
224 String.iter
(fun c
-> Printf.bprintf
b2 "(%d)" (int_of_char c
)) t
.left_bytes;
225 lprintf_nl
"Connect [hl: %d] [md4: %s] [ip: %s:%d] [server: %s] [left: %s] [tags:%s]"
227 (Md4.to_string t
.md4)
228 (Ip.to_string t
.ip) t
.port
229 (match t
.server_info with
231 | Some
(ip, port) -> Printf.sprintf
"%s:%d" (Ip.to_string
ip) port)
232 (if String.length t
.left_bytes <> 0 then (Buffer.contents
b2) else "None")
236 let write reply
buf t
=
243 buf_tags
buf t
.tags names_of_tag;
245 match t
.server_info with
260 let (s
, p
) = get_string s
1 in
264 lprintf_nl
"SAY %s" t
270 module OneMd4
= functor(M
: sig val m
: string end) -> (struct
277 lprintf_nl
"OneMd4: %s OF %s" M.m
(Md4.to_string t
)
284 module JoinQueue
= struct
285 type t
= Md4.t
option
293 lprintf_nl
"JOIN QUEUE %s"
294 (match t
with None
-> "" | Some
md4 ->
295 Printf.sprintf
"OF %s" (Md4.to_string
md4))
297 let write emule
buf t
=
298 if extendedrequest emule
> 0 then
307 val parse : int -> string -> t
308 val print : t -> unit
309 val write : Buffer.t -> t -> unit
315 (* In Emule, this message contains much more information, and will probably
316 remove the need for QueryChunks. *)
318 let get_bitmap s pos
=
319 let nchunks = get_int16 s pos
in
321 if nchunks = 0 then (Bitv.create
0 false), pos
+2 else
323 let chunks = (Bitv.create
nchunks false) in
324 for i
= 0 to (nchunks-1) / 8 do
325 let m = get_uint8 s
(pos + i
) in
329 Bitv.set
chunks n ((m land (1 lsl j
)) <> 0);
332 let pos = pos + (nchunks-1)/8 + 1 in
337 let print_bitmap chunks =
338 lprintf
"\n%s\n" (Bitv.to_string
chunks)
340 let write_bitmap buf chunks =
341 let nchunks = Bitv.length
chunks in
342 buf_int16
buf nchunks;
344 for i
= 0 to (nchunks-1) / 8 do
349 if (Bitv.get
chunks n) then
350 m := !m lor (1 lsl j
);
355 module QueryFile
= struct
358 emule_extension
: (Bitv.t
* int) option;
361 let parse emule len s
=
362 (* lprintf "Query File: emule version %d len %d"
363 (extendedrequest emule) len;
365 let md4 = get_md4 s
1 in
366 let emule_extension =
368 if len
< 18 || extendedrequest emule
= 0 then None
else
369 let chunks, pos = get_bitmap s
17 in
370 let ncompletesources =
371 if extendedrequest emule
> 1 && len
> pos+1 then get_int16 s
pos
373 Some
(chunks, ncompletesources)
377 emule_extension = emule_extension }
380 lprintf_nl
"QUERY FILE OF %s" (Md4.to_string t
.md4);
381 match t
.emule_extension with
383 | Some
(bitmap
, ncompletesources) ->
386 if ncompletesources >= 0 then
387 lprintf_nl
"Complete sources: %d" ncompletesources
389 let write emule
buf t
=
391 match t
.emule_extension with
393 | Some
(chunks, ncompletesources) ->
394 if extendedrequest emule
> 0 then begin
395 write_bitmap buf chunks;
396 if extendedrequest emule
> 1 && ncompletesources >= 0 then
397 buf_int16
buf ncompletesources
401 module QueryChunks
= OneMd4
(struct let m = "QUERY CHUNKS" end)
404 module QueryChunkMd4
= OneMd4
(struct let m = "QUERY CHUNKS MD4" end)
405 module EndOfDownload
= OneMd4
(struct let m = "END OF DOWNLOAD MD4" end)
406 module NoSuchFile
= OneMd4
(struct let m = "NO SUCH FILE" end)
408 module QueryChunksReply
= struct (* Request 80 *)
416 let md4 = get_md4 s
1 in
417 let chunks, pos = get_bitmap s
17 in
424 lprintf_nl
"CHUNKS for %s" (Md4.to_string t
.md4);
425 lprintf_nl
"%s\n" (Bitv.to_string t
.chunks)
429 write_bitmap buf t
.chunks;
430 if Bitv.length t
.chunks = 0 then buf_int8
buf 0
433 dec: [(96)(215)(1)(0)(0)(0)(0)(0)(0)(0)(0)(0)(0)]
435 OP_QUEUERANKING: int16
438 module QueryChunkMd4Reply
= struct (* Request 80 *)
446 let md4 = get_md4 s
1 in
447 let nchunks = get_int16 s
17 in
448 (* lprintf "nchunks : %d" nchunks; lprint_newline (); *)
449 let chunks = Array.make
nchunks md4 in
450 for i
= 0 to nchunks - 1 do
451 chunks.(i
) <- get_md4 s
(19 + i
* 16)
459 lprintf_nl
"CHUNKSMd4 for %s" (Md4.to_string t
.md4);
462 lprintf
" %s" (Md4.to_string b
))
468 let nchunks = Array.length t
.chunks in
469 buf_int16
buf nchunks;
470 for i
= 0 to nchunks - 1 do
471 buf_md4
buf t
.chunks.(i
)
475 module QueryFileReply
= struct
482 let name, _
= get_string s
17 in
488 lprintf_nl
"QUERY FILE REPLY OF %s : \"%s\"" (Md4.to_string t
.md4) t
.name
492 buf_string
buf t
.name
506 let parse usesixtyfour len s
=
509 usesixtyfour
= usesixtyfour
;
510 start_pos
= if usesixtyfour
then get_int64 s
17 else get_uint64_32 s
17;
511 end_pos
= if usesixtyfour
then get_int64 s
25 else get_uint64_32 s
21;
513 bloc_begin
= if usesixtyfour
then 33 else 25;
514 bloc_len
= if usesixtyfour
then len
- 33 else len
- 25;
518 lprintf_nl
"BLOC OF %s len %Ld [%Ld - %Ld] " (Md4.to_string t
.md4)
519 (t
.end_pos
-- t
.start_pos
)
525 if t
.usesixtyfour
then buf_int64
buf t
.start_pos
else buf_int64_32
buf t
.start_pos
;
526 if t
.usesixtyfour
then buf_int64
buf t
.end_pos
else buf_int64_32
buf t
.end_pos
;
527 Buffer.add_substring
buf t
.bloc_str t
.bloc_begin t
.bloc_len
530 module QueryBloc
= struct
534 start_pos1
: int64
; (* 180 ko *)
542 let parse usesixtyfour len s
=
545 usesixtyfour
= usesixtyfour
;
546 start_pos1
= if usesixtyfour
then get_int64 s
17 else get_uint64_32 s
17;
547 end_pos1
= if usesixtyfour
then get_int64 s
41 else get_uint64_32 s
29;
548 start_pos2
= if usesixtyfour
then get_int64 s
25 else get_uint64_32 s
21;
549 end_pos2
= if usesixtyfour
then get_int64 s
49 else get_uint64_32 s
33;
550 start_pos3
= if usesixtyfour
then get_int64 s
33 else get_uint64_32 s
25;
551 end_pos3
= if usesixtyfour
then get_int64 s
57 else get_uint64_32 s
37;
555 lprintf_nl
"QUERY BLOCS OF %s [%s - %s] [%s - %s] [%s - %s]"
556 (Md4.to_string t
.md4)
557 (Int64.to_string t
.start_pos1
) (Int64.to_string t
.end_pos1
)
558 (Int64.to_string t
.start_pos2
) (Int64.to_string t
.end_pos2
)
559 (Int64.to_string t
.start_pos3
) (Int64.to_string t
.end_pos3
)
563 if t
.usesixtyfour
then buf_int64
buf t
.start_pos1
else buf_int64_32
buf t
.start_pos1
;
564 if t
.usesixtyfour
then buf_int64
buf t
.start_pos2
else buf_int64_32
buf t
.start_pos2
;
565 if t
.usesixtyfour
then buf_int64
buf t
.start_pos3
else buf_int64_32
buf t
.start_pos3
;
566 if t
.usesixtyfour
then buf_int64
buf t
.end_pos1
else buf_int64_32
buf t
.end_pos1
;
567 if t
.usesixtyfour
then buf_int64
buf t
.end_pos2
else buf_int64_32
buf t
.end_pos2
;
568 if t
.usesixtyfour
then buf_int64
buf t
.end_pos3
else buf_int64_32
buf t
.end_pos3
572 module NoArg
= functor(M
: sig val m : string end) -> (struct
580 let write (buf: Buffer.t
) (t
: t
) = unit
585 val parse : int -> string -> t
586 val print : t -> unit
587 val write : Buffer.t -> t -> unit
592 module AvailableSlot
= NoArg
(struct let m = "AvailableSlot" end)
593 module ReleaseSlot
= NoArg
(struct let m = "ReleaseSlot" end)
594 module OutOfParts
= NoArg
(struct let m = "OutOfParts" end)
595 module ViewFiles
= NoArg
(struct let m = "VIEW FILES" end)
596 module ViewDirs
= NoArg
(struct let m = "VIEW DIRS" end)
598 module ViewFilesReply
= struct
607 type t = tagged_file list
609 let names_of_tag = file_common_tags
611 let rec get_files s
pos n =
612 if n = 0 then [], pos else
613 let md4 = get_md4 s
pos in
614 let ip = get_ip s
(pos + 16) in
615 let port = get_port s
(pos + 20) in
616 let tags, pos = get_tags s
(pos+22) names_of_tag in
623 let files, pos = get_files s
pos (n-1) in
627 let n = get_int s
1 in
628 let files, pos = get_files s
5 n in
632 lprintf_nl
"VIEW FILES REPLY:";
635 lprintf_nl
" MD4: %s" (Md4.to_string
t.f_md4
);
636 lprintf_nl
" ip: %s" (Ip.to_string
t.f_ip
);
637 lprintf_nl
" port: %d" t.f_port
;
640 lprint_newline
();) t
642 let rec write_files buf files =
646 buf_md4
buf file.f_md4
;
647 buf_ip
buf file.f_ip
;
648 buf_port
buf file.f_port
;
649 buf_tags
buf file.f_tags
names_of_tag;
650 write_files buf files
653 buf_int
buf (List.length
t);
656 let rec write_files_max buf files nfiles max_len
=
657 let prev_len = Buffer.length
buf in
659 [] -> nfiles
, prev_len
661 buf_md4
buf file.f_md4
;
662 buf_ip
buf file.f_ip
;
663 buf_port
buf file.f_port
;
664 buf_tags
buf file.f_tags
names_of_tag;
665 if Buffer.length
buf < max_len
then
666 write_files_max buf files (nfiles
+1) max_len
671 module ViewDirsReply
= struct
675 let rec get_dirs s
pos n =
676 if n = 0 then [], pos else
677 let dir, pos = get_string16 s
pos in
678 let dirs, pos = get_dirs s
pos (n-1) in
682 let dirs, pos = get_dirs s
2 (get_int16 s
0) in
686 lprintf_nl
"VIEW DIRS REPLY:";
687 List.iter
(fun dir ->
688 lprintf_nl
"DIR: %s" dir;) t
691 buf_int
buf (List.length
t);
692 List.iter
(fun dir ->
693 buf_string
buf dir;) t
697 module ViewFilesDir
= struct
702 lprintf_nl
"VIEW FILES DIR: %s" t
705 let dir, pos = get_string s
1 in
713 module ViewFilesDirReply
= struct
715 type t = string * tagged_file list
717 let names_of_tag = file_common_tags
720 let dir, pos = get_string s
1 in
721 let n = get_int s
(pos+1) in
722 let files, pos = ViewFilesReply.get_files s
(pos+5) n in
726 lprintf_nl
"VIEW FILES DIR REPLY:";
727 let dir, files = t in begin
728 lprintf_nl
"DIR: %s" dir;
729 List.iter
(fun file ->
731 lprintf_nl
" MD4: %s" (Md4.to_string
file.f_md4
);
732 lprintf_nl
" ip: %s" (Ip.to_string
file.f_ip
);
733 lprintf_nl
" port: %d" file.f_port
;
735 print_tags
file.f_tags
;
736 lprint_newline
();) files
740 let dir, files = t in begin
742 buf_int
buf (List.length
files);
743 ViewFilesReply.write_files buf files
748 module OtherLocations
= struct
754 for i
= 0 to len
/ 4 - 1 do
755 list := (get_ip s
(i
*4+1)) :: !list;
760 lprintf_nl
"OTHER LOCATIONS:\n";
762 lprintf_nl
" ip: %s" (Ip.to_string
ip);) t
765 List.iter
(buf_ip
buf) t
768 module NewUserID
= struct
773 get_ip s
1, get_ip s
5
775 let print (ip1
,ip2
) =
776 lprintf_nl
"NEW USER ID: %s -> %s" (Ip.to_string ip1
)
779 let write buf (ip1
,ip2
) =
785 module Sources
= struct
789 sources
: (Ip.t * int * Ip.t) list;
793 let len = get_int16 s
1 in
794 let md4 = get_md4 s
3 in
796 (* let pos = 19 in *)
797 for i
= 0 to len - 1 do
798 list := (get_ip s
(19 + 10 * i
), get_port s
(23 + 10 * i
),
799 get_ip s
(25 + 10 * i
)) :: !list;
806 lprintf_nl
"SOURCES for %s:" (Md4.to_string
t.md4);
807 List.iter
(fun (ip1
, port, ip2
) ->
808 lprintf_nl
" %s:%d:%s" (Ip.to_string ip1
) port(Ip.to_string ip2
)) t.sources
811 buf_int16
buf (List.length
t.sources
);
813 List.iter
(fun (ip1
, port, ip2
) ->
816 buf_ip
buf ip2
) t.sources
819 module EmuleClientInfo
= struct
822 version
: int; (* CURRENT_VERSION_SHORT = !!emule_protocol_version *)
823 protversion
: int; (* EMULE_PROTOCOL_VERSION = 0x1 *)
824 mutable tags : tag
list;
827 let names_of_tag = client_common_tags
830 List.map
(fun (v
, name) -> (v
, Field_KNOWN
name)) names_of_tag
833 let version = get_uint8 s
1 in
834 let protversion = get_uint8 s
2 in
835 let tags,_
= get_tags s
3 names_of_tag in
838 protversion = protversion;
843 let b1 = Buffer.create
50 in
844 lbprint_tags b1 t.tags;
845 lprintf_nl
"%s: [version: %d] [protversion: %d] [tags:%s]" m t.version t.protversion (Buffer.contents
b1)
848 buf_int8
buf t.version;
849 buf_int8
buf t.protversion;
850 buf_tags
buf t.tags names_of_tag;
854 module EmuleQueueRanking
= struct
858 let parse len s
= get_int16 s
1
860 lprintf_nl
"EmuleQueueRanking: %d" t
862 let string_null10 = String.make
10 (char_of_int
0)
866 Buffer.add_string
buf string_null10
870 module QueueRank
= struct
874 let parse len s
= get_int s
1
876 lprintf_nl
"QueueRank: %d" t
883 module EmuleRequestSources
= struct
891 lprintf_nl
"EmuleRequestSources: %s" (Md4.to_string
t)
899 let buf_estring buf s
=
900 let len = String.length s
in
902 Buffer.add_string
buf s
904 module EmuleSignatureReq
= struct
912 lprintf_nl
"EmuleSignatureReq [type %d] [sig(%d): %s]" t.ip_type
(String.length
t.signature
) (String.escaped
t.signature
)
915 let mlen = get_uint8 s
1 in
916 let slen = String.length s
in
917 let signature = String.sub s
2 mlen in
918 let ip_type = if mlen = (slen-2) then 0 else get_uint8 s
(2 + mlen) in
920 signature = signature;
925 buf_estring buf t.signature;
926 if (t.ip_type <> 0) then
927 buf_int8
buf t.ip_type;
932 module EmulePublicKeyReq
= struct
937 lprintf_nl
"EmulePublicKeyReq [key(%d): %s]" (String.length
t) (String.escaped
t)
940 let len = get_uint8 s
1 in
949 module EmuleCaptchaReq
= struct
954 lprintf_nl
"EmuleCaptchaReq [CAPTCHA BMP length=%d bytedata=%s]" (String.length
t) (String.escaped
t)
957 String.sub s
2 (len - 2)
965 module EmuleCaptchaRes
= struct
970 lprintf_nl
"EmuleCaptchaRes RESPONSE=%d" t
981 module EmuleSecIdentStateReq
= struct
989 lprintf_nl
"EmuleSecIdentStateReq [state: %d] [challenge: %Ld]" t.state
t.challenge
992 let state = get_uint8 s
1 in
993 let challenge = get_uint64_32 s
2 in
996 challenge = challenge;
1000 buf_int8
buf t.state;
1001 buf_int64_32
buf t.challenge
1005 module EmuleRequestSourcesReply
= struct
1010 mutable src_server_ip
: Ip.t;
1011 mutable src_server_port
: int;
1012 mutable src_md4
: Md4.t;
1013 mutable src_cc
: int option;
1018 sources
: source array
;
1021 let dummy_source = {
1024 src_server_ip
= Ip.null
;
1025 src_server_port
= 0;
1031 let md4 = get_md4 s
1 in
1032 let ncount = get_int16 s
17 in
1035 if ncount = 0 then [||] else
1036 let slen = (len - 19) / ncount in
1037 (* lprintf "PER SOURCES LEN: %d\n" slen; *)
1038 let sources = Array.make
ncount dummy_source in
1039 let rec iter pos i
=
1042 let ip = get_ip s
pos in
1046 src_port
= get_int16 s
(pos+4);
1047 src_cc
= Geoip.get_country_code_option
ip
1050 if slen > 6 then begin
1051 ss.src_server_ip
<- get_ip s
(pos+6);
1052 ss.src_server_port
<- get_int16 s
(pos+10);
1053 if slen > 12 && (sourceexchange e
> 1) then begin
1054 ss.src_md4
<- get_md4 s
(pos+12);
1073 let ncount = Array.length
t.sources in
1074 lprintf_nl
"EMULE SOURCES REPLY: %d sources for %s"
1075 ncount (Md4.to_string
t.md4);
1076 for i
= 0 to ncount - 1 do
1077 let s = t.sources.(i
) in
1079 (if Ip.valid
s.src_ip
then
1080 Printf.sprintf
"%s:%d" (Ip.to_string
s.src_ip
) s.src_port
1082 Printf.sprintf
"%s:%d (Indirect)" (Ip.to_string
s.src_server_ip
) s.src_server_port
)
1083 (if s.src_md4
!= Md4.null
then
1084 Printf.sprintf
"MD4: %s" (Md4.to_string
s.src_md4
)
1090 let ncount = Array.length
t.sources in
1091 buf_int16
buf ncount;
1093 for i
= 0 to ncount - 1 do
1094 let s = t.sources.(i
) in
1095 buf_ip
buf s.src_ip
;
1096 buf_port
buf s.src_port
;
1097 if sourceexchange e
> 0 then begin
1098 buf_ip
buf s.src_server_ip
;
1099 buf_port
buf s.src_server_port
;
1100 if sourceexchange e
> 1 then
1101 buf_md4
buf s.src_md4
1106 module EmuleFileDesc
= struct
1114 let rating = get_uint8
s 1 in
1115 let (comment
, _
) = get_string32
s 2 in
1122 lprintf_nl
"EmuleFileDesc [%d][%s]" t.rating t.comment
1125 buf_int8
buf t.rating;
1126 buf_string
buf t.comment
1129 module EmuleCompressedPart
= struct
1133 usesixtyfour
: bool;
1139 let parse usesixtyfour
len s =
1142 usesixtyfour
= usesixtyfour
;
1143 statpos
= if usesixtyfour
then get_int64
s 17 else get_uint64_32
s 17;
1144 newsize
= if usesixtyfour
then get_uint64_32
s 25 else get_uint64_32
s 21;
1145 bloc
= if usesixtyfour
then String.sub
s 29 (len-29) else String.sub
s 25 (len-25)
1149 lprintf_nl
"EmuleCompressedPart for %s %Ld %Ld len %d"
1150 (Md4.to_string
t.md4) t.statpos
t.newsize
(String.length
t.bloc
)
1154 if t.usesixtyfour
then buf_int64
buf t.statpos
else buf_int64_32
buf t.statpos
;
1155 buf_int64_32
buf t.newsize
;
1156 Buffer.add_string
buf t.bloc
1159 module EmulePortTestReq
= struct
1164 lprintf_nl
"Emule porttest request %s" (String.escaped
s)
1174 | ConnectReq
of Connect.t
1175 | ConnectReplyReq
of Connect.t
1176 | QueryFileReq
of QueryFile.t
1177 | QueryFileReplyReq
of QueryFileReply.t
1179 | QueryBlocReq
of QueryBloc.t
1180 | JoinQueueReq
of JoinQueue.t (* sent before queryBloc *)
1181 | AvailableSlotReq
of AvailableSlot.t
1182 | ReleaseSlotReq
of ReleaseSlot.t
1183 | OutOfPartsReq
of OutOfParts.t
1184 | QueryChunksReq
of QueryChunks.t
1185 | QueryChunksReplyReq
of QueryChunksReply.t
1186 | QueryChunkMd4Req
of QueryChunkMd4.t
1187 | QueryChunkMd4ReplyReq
of QueryChunkMd4Reply.t
1188 | ViewFilesReq
of ViewFiles.t
1189 | ViewFilesReplyReq
of ViewFilesReply.t
1190 | ViewDirsReq
of ViewDirs.t
1191 | ViewDirsReplyReq
of ViewDirsReply.t
1192 | ViewFilesDirReq
of ViewFilesDir.t
1193 | ViewFilesDirReplyReq
of ViewFilesDirReply.t
1194 | QueueReq
of OtherLocations.t
1195 | UnknownReq
of int * string
1196 | OtherLocationsReq
of OtherLocations.t
1198 | SourcesReq
of Sources.t
1199 | EndOfDownloadReq
of EndOfDownload.t
1200 | NewUserIDReq
of NewUserID.t
1201 | NoSuchFileReq
of NoSuchFile.t
1202 | QueueRankReq
of QueueRank.t
1204 | EmuleClientInfoReq
of EmuleClientInfo.t
1205 | EmuleClientInfoReplyReq
of EmuleClientInfo.t
1206 | EmuleQueueRankingReq
of EmuleQueueRanking.t
1207 | EmuleRequestSourcesReq
of EmuleRequestSources.t
1208 | EmuleRequestSourcesReplyReq
of EmuleRequestSourcesReply.t
1209 | EmuleFileDescReq
of EmuleFileDesc.t
1210 | EmulePublicKeyReq
of EmulePublicKeyReq.t
1211 | EmuleSignatureReq
of EmuleSignatureReq.t
1212 | EmuleSecIdentStateReq
of EmuleSecIdentStateReq.t
1213 | EmuleMultiPacketReq
of Md4.t * t list
1214 | EmuleMultiPacketAnswerReq
of Md4.t * t list
1215 | EmuleCompressedPart
of EmuleCompressedPart.t
1216 | EmulePortTestReq
of EmulePortTestReq.t
1217 | EmuleCaptchaReq
of EmuleCaptchaReq.t
1218 | EmuleCaptchaRes
of EmuleCaptchaRes.t
1223 | ConnectReq
t -> Connect.print t
1224 | ConnectReplyReq
t -> Connect.print t
1225 | QueryFileReq
t -> QueryFile.print t
1226 | QueryFileReplyReq
t -> QueryFileReply.print t
1227 | BlocReq
t -> Bloc.print t
1228 | QueryBlocReq
t -> QueryBloc.print t
1229 | JoinQueueReq
t -> JoinQueue.print t
1230 | AvailableSlotReq
t -> AvailableSlot.print t
1231 | ReleaseSlotReq
t -> ReleaseSlot.print t
1232 | OutOfPartsReq
t -> OutOfParts.print t
1233 | QueryChunksReq
t -> QueryChunks.print t
1234 | QueryChunksReplyReq
t -> QueryChunksReply.print t
1235 | QueryChunkMd4Req
t -> QueryChunkMd4.print t
1236 | QueryChunkMd4ReplyReq
t -> QueryChunkMd4Reply.print t
1237 | ViewFilesReplyReq
t -> ViewFilesReply.print t
1238 | ViewFilesReq
t -> ViewFiles.print t
1239 | ViewDirsReq
t -> ViewDirs.print t
1240 | ViewDirsReplyReq
t -> ViewDirsReply.print t
1241 | ViewFilesDirReq
t -> ViewFilesDir.print t
1242 | ViewFilesDirReplyReq
t -> ViewFilesDirReply.print t
1243 | QueueReq
t -> OtherLocations.print t
1244 | OtherLocationsReq
t -> OtherLocations.print t
1245 | SayReq
t -> Say.print t
1246 | SourcesReq
t -> Sources.print t
1247 | EndOfDownloadReq
t -> EndOfDownload.print t
1248 | NewUserIDReq
t -> NewUserID.print t
1249 | NoSuchFileReq
t -> NoSuchFile.print t
1253 | EmuleClientInfoReq
t ->
1254 EmuleClientInfo.print "EmuleClientInfo" t
1255 | EmuleClientInfoReplyReq
t ->
1256 EmuleClientInfo.print "EmuleClientInfoReply" t
1257 | EmuleQueueRankingReq
t ->
1258 EmuleQueueRanking.print t
1259 | EmuleRequestSourcesReq
t ->
1260 EmuleRequestSources.print t
1261 | EmuleRequestSourcesReplyReq
t ->
1262 EmuleRequestSourcesReply.print t
1264 | EmuleFileDescReq
t ->
1265 EmuleFileDesc.print t
1267 | EmuleMultiPacketReq
(md4, list) ->
1268 lprintf_nl
"EmuleMultiPacket for %s:" (Md4.to_string
md4);
1274 | EmuleMultiPacketAnswerReq
(md4, list) ->
1275 lprintf_nl
"EmuleMultiPacketAnswer for %s:" (Md4.to_string
md4);
1280 | EmuleSecIdentStateReq
t ->
1281 EmuleSecIdentStateReq.print t
1282 | EmuleSignatureReq
t ->
1283 EmuleSignatureReq.print t
1284 | EmulePublicKeyReq
t ->
1285 EmulePublicKeyReq.print t
1286 | EmuleCompressedPart
t ->
1287 EmuleCompressedPart.print t
1288 | EmulePortTestReq
t ->
1289 EmulePortTestReq.print t
1290 | EmuleCaptchaReq
t ->
1291 EmuleCaptchaReq.print t
1292 | EmuleCaptchaRes
t ->
1293 EmuleCaptchaRes.print t
1294 | UnknownReq
(opcode
, s) ->
1295 let len = String.length
s in
1296 lprintf_nl
"UnknownReq: magic (%d), opcode (%d) len (%d)" opcode
1300 for i
= 0 to len - 1 do
1302 let n = int_of_char
c in
1303 if n > 31 && n < 127 then
1310 for i
= 0 to len - 1 do
1312 let n = int_of_char
c in
1318 let rec parse_emule_packet emule opcode
len s =
1320 lprintf "Emule magic: %d opcode %d:" magic opcode; lprint_newline ();
1321 dump s; lprint_newline ();
1323 let t = match opcode
with
1324 | 1 -> EmuleClientInfoReq
(EmuleClientInfo.parse len s)
1325 | 2 -> EmuleClientInfoReplyReq
(EmuleClientInfo.parse len s)
1327 | 0x60 (* 96 *) -> EmuleQueueRankingReq
(EmuleQueueRanking.parse len s)
1329 | 0x61 (* 97 *) -> EmuleFileDescReq
(EmuleFileDesc.parse len s)
1331 | 0x81 (* 129 *) -> EmuleRequestSourcesReq
(EmuleRequestSources.parse len s)
1333 EmuleRequestSourcesReplyReq
(
1334 EmuleRequestSourcesReply.parse emule
len s)
1337 (* OP_COMPRESSEDPART *)
1338 EmuleCompressedPart
(EmuleCompressedPart.parse false len s)
1341 EmulePublicKeyReq
(EmulePublicKeyReq.parse len s)
1344 EmuleSignatureReq
(EmuleSignatureReq.parse len s)
1347 EmuleSecIdentStateReq
(EmuleSecIdentStateReq.parse len s)
1349 (* | 0x90 (* 144 *) -> RequestPreview *)
1350 (* | 0x91 (* 145 *) -> PreviewAnswer *)
1352 let md4 = get_md4
s 1 in
1354 (* lprintf "MULTI EMULE VERSION %d"
1355 (extendedrequest emule); print_newline (); *)
1356 (* let pos = 17 in *)
1359 let opcode = get_uint8
s pos in
1362 let bitmap, pos = get_bitmap s (pos+1) in
1363 let ncompletesources, pos =
1364 if extendedrequest emule
> 1 then
1365 get_int16
s pos, pos+2
1369 QueryFile.md4 = md4;
1370 QueryFile.emule_extension = Some
(bitmap, ncompletesources);
1373 (QueryChunksReq
md4) :: iter (pos+1)
1375 (EmuleRequestSourcesReq
md4) :: iter (pos+1)
1377 lprintf_nl
"Unknown short emule packet %d" opcode;
1382 EmuleMultiPacketReq
(md4, iter 17)
1385 if String.length
s < 16 then begin
1386 if !verbose_unknown_messages
then lprintf_nl
"EmuleMultiPacketAnswer: incomplete request";
1389 let md4 = get_md4
s 1 in
1391 (* lprintf "MULTI EMULE VERSION %d"
1392 (extendedrequest emule); print_newline (); *)
1393 let rec iter s pos len =
1395 let opcode = get_uint8
s pos in
1398 let module Q
= QueryFileReply
in
1399 let name, pos = get_string
s (pos+1) in
1404 (QueryFileReplyReq
q) :: (iter s pos len)
1406 let module Q
= QueryChunksReply
in
1407 let chunks, pos = get_bitmap s (pos+1) in
1412 (QueryChunksReplyReq
q) :: (iter s pos len)
1414 lprintf_nl
"Unknown packet in emule multipacket 0x93: %d" opcode;
1419 EmuleMultiPacketAnswerReq
(md4, iter s 17 len)
1421 | 0xa1 (* 161 *) -> (* OP_COMPRESSEDPART_I64 *)
1422 EmuleCompressedPart
(EmuleCompressedPart.parse true len s)
1423 | 0xa2 -> BlocReq
(Bloc.parse true len s) (* OP_SENDINGPART_I64 *)
1424 | 0xa3 -> QueryBlocReq
(QueryBloc.parse true len s) (*OP_REQUESTPARTS_I64 *)
1425 | 0xa5 (* 165 *) -> EmuleCaptchaReq
(EmuleCaptchaReq.parse len s) (* OP_CHATCAPTCHAREQ *)
1426 | 0xa6 (* 166 *) -> EmuleCaptchaRes
(EmuleCaptchaRes.parse s) (* OP_CHATCAPTCHARES *)
1427 | 0xfe (* 254 *) -> EmulePortTestReq
s
1430 if !CommonOptions.verbose_unknown_messages
then
1431 lprintf_nl
"EDK: unknown eMule message %d" code
;
1435 lprintf "EMULE MESSAGE: "; lprint_newline ();
1437 lprint_newline (); *)
1440 and parse emule_version magic
s =
1442 let len = String.length
s in
1443 if len = 0 then raise Not_found
;
1444 let opcode = int_of_char
(s.[0]) in
1445 (*lprintf "opcode: %d" opcode; lprint_newline (); *)
1450 | 1 -> ConnectReq
(Connect.parse false len s)
1451 | 70 -> BlocReq
(Bloc.parse false len s)
1452 | 71 -> QueryBlocReq
(QueryBloc.parse false len s)
1453 | 72 -> NoSuchFileReq
(NoSuchFile.parse len s)
1454 | 73 -> EndOfDownloadReq
(EndOfDownload.parse len s)
1455 | 74 -> ViewFilesReq
(ViewFiles.parse len s)
1456 | 75 -> ViewFilesReplyReq
(ViewFilesReply.parse len s)
1457 | 76 -> ConnectReplyReq
(Connect.parse true len s)
1458 | 77 -> NewUserIDReq
(NewUserID.parse len s)
1459 | 78 -> SayReq
(Say.parse len s)
1460 | 79 -> QueryChunksReq
(QueryChunks.parse len s)
1461 | 80 -> QueryChunksReplyReq
(QueryChunksReply.parse len s)
1462 | 81 -> QueryChunkMd4Req
(QueryChunkMd4.parse len s)
1463 | 82 -> QueryChunkMd4ReplyReq
(QueryChunkMd4Reply.parse len s)
1464 (* JoinQueue: the sender wants to join the upload queue *)
1465 | 84 -> JoinQueueReq
(JoinQueue.parse len s)
1466 (* AvailableSlot: there is an available slot in upload queue *)
1467 | 85 -> AvailableSlotReq
(AvailableSlot.parse len s)
1468 (* ReleaseSlot: the upload is finished *)
1469 | 86 -> ReleaseSlotReq
(ReleaseSlot.parse len s)
1470 (* OutOfParts: the upload slot is not available *)
1471 | 87 -> OutOfPartsReq
(OutOfParts.parse len s)
1472 | 88 -> QueryFileReq
(QueryFile.parse emule_version
len s)
1473 | 89 -> QueryFileReplyReq
(QueryFileReply.parse len s)
1474 | 92 -> QueueRankReq
(QueueRank.parse len s)
1475 | 93 -> ViewDirsReq
(ViewDirs.parse len s)
1476 | 94 -> ViewFilesDirReq
(ViewFilesDir.parse len s)
1478 | 95 -> ViewDirsReplyReq (ViewDirsReply.parse len s)
1479 | 96 -> ViewFilesDirReplyReq (ViewFilesDirReply.parse len s)
1481 | 250 -> SourcesReq
(Sources.parse len s)
1483 | _
-> raise Not_found
1486 | 0xc5 -> (* 197: emule extended protocol *)
1487 parse_emule_packet emule_version
opcode len s
1489 (* Compressed packet, probably sent by cDonkey ? *)
1493 let s = Zlib.uncompress_string2
(String.sub
s 1 (len-1)) in
1494 let s = Printf.sprintf
"%c%s" (char_of_int
opcode) s in
1496 parse_emule_packet emule_version
opcode (String.length
s) s
1499 if !CommonOptions.verbose_unknown_messages
then begin
1500 lprintf_nl
"Unknown message From client: %s (magic %d)"
1501 (Printexc2.to_string e
) magic
;
1502 let tmp_file = Filename2.temp_file
"comp" "pak" in
1503 File.from_string
tmp_file s;
1504 lprintf_nl
"Saved unknown packet %s" tmp_file;
1508 UnknownReq
(magic
,s)
1512 if !CommonOptions.verbose_unknown_messages
then
1513 lprintf_nl
"Strange magic: %d" magic
;
1517 if !CommonOptions.verbose_unknown_messages
then begin
1518 lprintf_nl
"Unknown message From client: %s (magic %d)"
1519 (Printexc2.to_string e
) magic
;
1520 let tmp_file = Filename2.temp_file
"comp" "pak" in
1521 File.from_string
tmp_file s;
1522 lprintf_nl
"Saved unknown packet %s" tmp_file;
1527 UnknownReq
(magic
,s)
1529 let write emule
buf t =
1530 let magic = match t with
1531 EmuleMultiPacketAnswerReq _
1532 | EmuleMultiPacketReq _
1533 | EmuleSecIdentStateReq _
1534 | EmuleSignatureReq _
1535 | EmulePublicKeyReq _
1536 | EmuleRequestSourcesReplyReq _
1537 | EmuleRequestSourcesReq _
1538 | EmuleClientInfoReplyReq _
1539 | EmuleClientInfoReq _
1540 | EmuleFileDescReq _
1541 | EmuleQueueRankingReq _
1544 | EmuleCompressedPart _
1546 | QueryBlocReq
t when t.QueryBloc.usesixtyfour
-> 0xC5
1547 | BlocReq
t when t.Bloc.usesixtyfour
-> 0xC5
1555 Connect.write false buf t
1556 | ConnectReplyReq
t ->
1558 Connect.write true buf t
1561 QueryFile.write emule
buf t
1562 | QueryFileReplyReq
t ->
1564 QueryFileReply.write buf t
1567 OtherLocations.write buf t
1569 buf_int8
buf (if t.QueryBloc.usesixtyfour
then 0xa3 else 71);
1570 QueryBloc.write buf t
1572 buf_int8
buf (if t.Bloc.usesixtyfour
then 0xa2 else 70);
1576 JoinQueue.write emule
buf t
1577 | QueryChunksReq
t ->
1579 QueryChunks.write buf t
1580 | QueryChunksReplyReq
t ->
1582 QueryChunksReply.write buf t
1583 | QueryChunkMd4Req
t ->
1585 QueryChunkMd4.write buf t
1586 | QueryChunkMd4ReplyReq
t ->
1588 QueryChunkMd4Reply.write buf t
1589 | AvailableSlotReq
t ->
1591 AvailableSlot.write buf t
1592 | ReleaseSlotReq
t ->
1594 ReleaseSlot.write buf t
1595 | OutOfPartsReq
t ->
1597 OutOfParts.write buf t
1600 ViewFiles.write buf t
1601 | ViewFilesReplyReq
t ->
1603 ViewFilesReply.write buf t
1606 ViewDirs.write buf t
1607 | ViewDirsReplyReq
t ->
1609 ViewDirsReply.write buf t
1610 | ViewFilesDirReq
t ->
1612 ViewFilesDir.write buf t
1613 | ViewFilesDirReplyReq
t ->
1615 ViewFilesDirReply.write buf t
1616 | OtherLocationsReq
t ->
1618 OtherLocations.write buf t
1627 NewUserID.write buf t
1628 | EndOfDownloadReq
t ->
1630 EndOfDownload.write buf t
1631 | NoSuchFileReq
t ->
1633 NoSuchFile.write buf t
1636 QueueRank.write buf t
1638 | EmuleClientInfoReq
t ->
1640 EmuleClientInfo.write buf t
1641 | EmuleClientInfoReplyReq
t ->
1643 EmuleClientInfo.write buf t
1644 | EmuleQueueRankingReq
t ->
1646 EmuleQueueRanking.write buf t
1647 | EmuleRequestSourcesReq
t ->
1649 EmuleRequestSources.write buf t
1650 | EmuleRequestSourcesReplyReq
t ->
1652 EmuleRequestSourcesReply.write emule
buf t
1653 | EmuleFileDescReq
t ->
1655 EmuleFileDesc.write buf t
1656 | EmuleCompressedPart
t ->
1657 buf_int8
buf (if t.EmuleCompressedPart.usesixtyfour
then 0xa1 else 0x40);
1658 EmuleCompressedPart.write buf t
1659 | EmuleMultiPacketReq
(md4, list) ->
1666 (match t.QueryFile.emule_extension with
1668 | Some
(bitmap, ncompletesources) ->
1669 write_bitmap buf bitmap;
1670 if ncompletesources >= 0 && extendedrequest emule
> 1 then
1671 buf_int16
buf ncompletesources)
1672 | QueryChunksReq _
->
1674 | EmuleRequestSourcesReq _
->
1677 lprintf_nl
"WARNING: Don't know how to write short packet:";
1682 | EmuleMultiPacketAnswerReq
(md4, list) ->
1687 QueryFileReplyReq
t ->
1689 buf_string
buf t.QueryFileReply.name
1690 | QueryChunksReplyReq
t ->
1692 write_bitmap buf t.QueryChunksReply.chunks
1694 lprintf_nl
"WARNING: Don't know how to write short packet:";
1699 | EmuleSecIdentStateReq
t ->
1701 EmuleSecIdentStateReq.write buf t
1703 | EmuleSignatureReq
t ->
1705 EmuleSignatureReq.write buf t
1707 | EmulePublicKeyReq
t ->
1709 EmulePublicKeyReq.write buf t
1711 | EmulePortTestReq
t ->
1713 EmulePortTestReq.write buf
1715 | EmuleCaptchaReq
t ->
1717 EmuleCaptchaReq.write buf t
1719 | EmuleCaptchaRes
t ->
1721 EmuleCaptchaRes.write buf t
1723 | UnknownReq
(opcode, s) ->
1724 Buffer.add_string
buf s
1730 ------------------------------------------------------
1731 1044008574.297 192.168.0.3:37522 -> 80.26.114.12:13842 of len 6
1732 ? Become Friend ? ping ?
1737 ------------------------------------------------------
1738 1044008576.274 80.26.114.12:13842 -> 192.168.0.3:37522 of len 6
1741 (227)(1)(0)(0)(0)(99)]
1743 ------------------------------------------------------
1744 1044008687.977 192.168.0.3:37522 -> 80.26.114.12:13842 of len 6
1750 ------------------------------------------------------
1751 1044008690.832 80.26.114.12:13842 -> 192.168.0.3:37522 of len 43
1752 Browse Main Dir Reply
1755 (2)(0)(0)(0) --------> 2 directories:
1756 (12)(0) C : \ D o w n l o a d s
1757 (17)(0) ! I n c o m p l e t e F i l e s
1760 ------------------------------------------------------
1761 1044008766.137 192.168.0.3:37522 -> 80.26.114.12:13842 of len 20
1766 (12)(0) C : \ D o w n l o a d s
1768 ------------------------------------------------------
1769 1044008769.045 80.26.114.12:13842 -> 192.168.0.3:37522 of len 300
1770 (227) p(8)(0)(0) `(12)(0) C : \ D o w n l o a d s(21)(0)(0)(0)(152) 2(229)(158)(218)(141)(217)(138) n(181) 6 ( ) h V(179)(0)(0)(0)(0)(0)(0)(3)(0)(0)(0)(2)(1)(0)(1)(11)(0) d e s k t o p . i n i(3)(1)(0)(2)(180)(0)(0)(0)(3)(1)(0)(19)(0)(0)(0)(0) y(16)(15) 9 O Z(219) i e(200)(10) |(29)(27) F(128)(0)(0)(0)(0)(0)(0)(5)(0)(0)(0)(2)(1)(0)(1)(15)(0) u t b o n u s p a c k . z i p(3)(1)(0)(2) J(16)(221)(0)(2)(1)(0)(3)(3)(0) P r o(2)(1)(0)(4)(3)(0) z i p(3)(1)(0)(19)(0)(0)(0)(0)(178)(145)(161)(146) P(199)(228)(249) K a :(9)(237)(246)(233) v(0)(0)(0)(0)(0)(0)(5)(0)(0)(0)(2)(1)(0)(1)(11)(0) c t f m a p s . z i p(3)(1)(0)(2)(236)(239)(23)(0)(2)(1)(0)(3)(3)(0) P r o(2)(1)(0)(4)(3)(0) z i p(3)(1)(0)(19)(0)(0)(0)(0) a n(251)(225) ^ g(205)(133)(25)(12) # ' J A(221) `(0)(0)(0)(0)(0)(0)(5)(0)(0)(0)(2)(1)(0)(1)(23)(0) u t i n o x x p a c k - n o - u m o d . z i p(3)(1)(0)(2)]
1774 (12)(0) C : \ D o w n l o a d s
1775 (21)(0)(0)(0) 21 files
1777 (152)(50)(229)(158)(218)(141)(217)(138)(110)(181)(54)(40)(41)(104)(86)(179)
1783 (11)(0) d e s k t o p . i n i
1791 (121)(16)(15)(57)(79)(90)(219)(105)(101)(200)(10)(124)(29)(27)(70)(128)
1797 (15)(0) u t b o n u s p a c k . z i p
1814 (* 92: Queue Rank *)