Development:Network:process undock

From Ghoulwiki
Jump to: navigation, search

example packetlog

packetlog by wireshark

// peer0_0 = client > server
char peer0_0[] = {
0x00, 0x00, 0x00, 0x14, 0x01, 0x00, 0x00, 0x00 };
char peer0_1[] = {
0x27, 0xb2, 0x00, 0x81, 0x77, 0xe4, 0x67, 0x64, 
0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 
0xbd, 0xbc, 0x00, 0x7b };
char peer1_0[] = {
0x00, 0x00, 0x00, 0x2d, 0x01, 0x00, 0x7a, 0x09 };
char peer1_1[] = {
0x31, 0x94, 0x00, 0x00, 0x77, 0xe4, 0x67, 0xa5, 0x00, 0x00, 0x00, 0x1d, 0x00, 0x00, 0x63, 0x74, 0xbc, 0x02, 0x02, 0x21, 0xbc, 0x00, 0x11, 0x75, 0x6e, 0x69, 0x74, 0x5f, 0x74, 0x6f, 0x5f, 0x64, 
0x6f, 0x63, 0x6b, 0x5f, 0x77, 0x69, 0x74, 0x68, 0xbe, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x31, 0x01, 0x00, 0x7a, 0x09, 0x31, 0x94, 0x00, 0x00, 0x77, 0xe4, 0x67, 0xa5, 0x00, 0x00, 0x00, 
0x21, 0x00, 0x00, 0x75, 0x63, 0xbc, 0x01, 0x02, 0x21, 0xbc, 0x00, 0x11, 0x75, 0x6e, 0x69, 0x74, 0x5f, 0x74, 0x6f, 0x5f, 0x64, 0x6f, 0x63, 0x6b, 0x5f, 0x77, 0x69, 0x74, 0x68, 0xbe, 0x00, 0x00, 
0x00, 0x00, 0x21, 0xbc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x01, 0x00, 0x7a, 0x09, 0x27, 0x94, 0x00, 0x81, 0x77, 0xe4, 0x67, 0xa5, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x65, 0x6d, 0xbd, 0xbc, 
0x00, 0x7b, 0x00, 0x00, 0x00, 0x68, 0x01, 0x00, 0x7a, 0x09, 0x11, 0x94, 0x00, 0x81, 0x77, 0xe4, 0x67, 0xa5, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x70, 0x6f, 0xd3, 0xbd, 0xbc, 0x00, 0x81, 0xd4, 
0xd9, 0x7b, 0xbf, 0x5a, 0x54, 0x01, 0xd5, 0x7b, 0xbe, 0xaf, 0x0e, 0x10, 0x7b, 0xbe, 0xc6, 0x43, 0x2c, 0x7b, 0xbd, 0x9c, 0x17, 0xcf, 0xd6, 0x7c, 0xf7, 0x95, 0x77, 0xce, 0xd5, 0x88, 0x3f, 0x42, 
0x7c, 0x41, 0x89, 0x3a, 0x88, 0x4c, 0x2b, 0x23, 0x42, 0x7c, 0x64, 0xb4, 0x2d, 0xe9, 0xe4, 0x07, 0x02, 0x42, 0xd5, 0x7b, 0x00, 0x00, 0x00, 0x00, 0x7b, 0x00, 0x00, 0x00, 0x00, 0x7b, 0x00, 0x00, 
0x00, 0x00, 0xd5, 0x7b, 0x00, 0x00, 0x00, 0x00, 0x7b, 0x00, 0x00, 0x00, 0x00, 0x7b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x29, 0x01, 0x00, 0x7a, 0x09, 0x31, 0x94, 0x00, 0x00, 0x77, 0xe4, 
0x67, 0xa5, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, 0x00, 0xbc, 0x02, 0x02, 0x21, 0xbc, 0x00, 0x0d, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x73, 0xbe, 0xff, 
0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x30, 0x01, 0x00, 0x7a, 0x09, 0x31, 0x94, 0x00, 0x00, 0x77, 0xe4, 0x67, 0xa5, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x75, 0x63, 0xbc, 0x02, 0x02, 0x21, 0xbc, 
0x00, 0x14, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xbe, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x28, 0x01, 
0x00, 0x7a, 0x09 };
char peer1_2[] = {
0x31, 0x94, 0x00, 0x00, 0x77, 0xe4, 0x67, 0xa5, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x69, 0xbc, 0x02, 0x02, 0x21, 0xbc, 0x00, 0x0c, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x76, 
0x61, 0x72, 0x73, 0xbe, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x47, 0x01, 0x00, 0x7a, 0x09, 0x31, 0x94, 0x00, 0x00, 0x77, 0xe4, 0x67, 0xa5, 0x00, 0x00, 0x00, 0x37, 0x00, 0x00, 0xff, 0xff, 
0xbc, 0x01, 0x02, 0x21, 0xbc, 0x00, 0x04, 0x6e, 0x65, 0x77, 0x73, 0xbe, 0x00, 0x00, 0x00, 0x00, 0x21, 0xbc, 0x00, 0x23, 0x23, 0x61, 0x73, 0x64, 0x61, 0x73, 0x64, 0x20, 0x68, 0x61, 0x73, 0x20, 
0x75, 0x6e, 0x64, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, 0x52, 0x65, 0x6c, 0x61, 0x79 };
-- packetlogs/undock.c
Packet({from=client,cmd=CMD_UNDOCK,head={{len=20,pri=1,flags=0x0},{cmd=39,serial=129,datalen=4,flags=0x0}}})
Packet({from=server,cmd=CMD_SAVEDATA,head={{len=45,pri=1,flags=0x7a},{cmd=49,serial=0,datalen=29,flags=0x0}}})
Packet({from=server,cmd=CMD_SAVEDATA,head={{len=49,pri=1,flags=0x7a},{cmd=49,serial=0,datalen=33,flags=0x0}}})
Packet({from=server,cmd=CMD_UNDOCK,head={{len=20,pri=1,flags=0x7a},{cmd=39,serial=129,datalen=4,flags=0x0}}})
Packet({from=server,cmd=CMD_POSUPDATE,head={{len=104,pri=1,flags=0x7a},{cmd=17,serial=129,datalen=88,flags=0x0}}})
Packet({from=server,cmd=CMD_SAVEDATA,head={{len=41,pri=1,flags=0x7a},{cmd=49,serial=0,datalen=25,flags=0x0}}})
Packet({from=server,cmd=CMD_SAVEDATA,head={{len=48,pri=1,flags=0x7a},{cmd=49,serial=0,datalen=32,flags=0x0}}})
Packet({from=server,cmd=CMD_SAVEDATA,head={{len=40,pri=1,flags=0x7a},{cmd=49,serial=0,datalen=24,flags=0x0}}})
Packet({from=server,cmd=CMD_SAVEDATA,head={{len=71,pri=1,flags=0x7a},{cmd=49,serial=0,datalen=55,flags=0x0}}})