Jul 13, 2012 #1 D Doseon Newbie Spellweaver 10 Happy Years Joined Nov 28, 2009 Messages 36 Reaction score 1 Is there a way to see inbound and outbound packets in your own server? Since you can't sniff your own server with mapleshark, is there a way to do this?
Is there a way to see inbound and outbound packets in your own server? Since you can't sniff your own server with mapleshark, is there a way to do this?
Jul 13, 2012 #2 V Veda Experienced Elementalist Trophy Point Collector 10 Happy Years Joined Mar 21, 2011 Messages 237 Reaction score 118 MapleServerHandler.java, find messageReceived and after short packetId add: PHP: System.out.println(" Recv : 0x" + Integer.toHexString(packetId).toUpperCase()); As for sent, depending on whether you use MaplePacket or bytes arrays, you have to handle it in messageSent: PHP: @Override public void messageSent(IoSession session, Object message) throws Exception { byte[] packet = (byte[]) message; short packetId = (short) (packet[0] + (packet[1] << 8)); System.out.println(" Send: 0x" + Integer.toHexString(packetId).toUpperCase()); super.messageSent(session, message); } Upvote 0
MapleServerHandler.java, find messageReceived and after short packetId add: PHP: System.out.println(" Recv : 0x" + Integer.toHexString(packetId).toUpperCase()); As for sent, depending on whether you use MaplePacket or bytes arrays, you have to handle it in messageSent: PHP: @Override public void messageSent(IoSession session, Object message) throws Exception { byte[] packet = (byte[]) message; short packetId = (short) (packet[0] + (packet[1] << 8)); System.out.println(" Send: 0x" + Integer.toHexString(packetId).toUpperCase()); super.messageSent(session, message); }
Jul 13, 2012 #3 D Doseon Newbie Spellweaver 10 Happy Years Joined Nov 28, 2009 Messages 36 Reaction score 1 That shows the headers/opcodes but is there a way to see the entire packet? Preferably not in the command since it'll get spammed way too quick. Upvote 0
That shows the headers/opcodes but is there a way to see the entire packet? Preferably not in the command since it'll get spammed way too quick.