Hi!
>>>>> "Grigory" == Grigory Kolesov <[EMAIL PROTECTED]> writes: <cut> Grigory> 1) Endiannes. I figured out that the size of packet is stored at the Grigory> beginning of packet as little endian unsigned int. Grigory> Is it so in all cases, or it just happens because both client and server Grigory> run on little endian machines? The packets are always sent as little endians, independent of the architecture of the server/client. Grigory> 2) Currently I rewrite only packets which contain: Grigory> <size uint>+\x02+dbname Grigory> <size uint>+<something>+\x00+dbname (connection init) Grigory> <size uint>+\x03+"\s*use\s*"+dbname. Grigory> I am not sure whether it is always correct. The above command will take care of the 'USE database' commands, but not be able to handle SQL commands where you directly refer to the database. Grigory> 3) Does anyone need such tool, should I post it on web somewhere? You could always add it to the MySQL portal section at: http://www.mysql.com/portal/software/html/index.html Regards, Monty -- For technical support contracts, goto https://order.mysql.com/ __ ___ ___ ____ __ / |/ /_ __/ __/ __ \/ / Mr. Michael Widenius <[EMAIL PROTECTED]> / /|_/ / // /\ \/ /_/ / /__ MySQL AB, CTO /_/ /_/\_, /___/\___\_\___/ Helsinki, Finland <___/ www.mysql.com --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php