rewrite the code of CcnetPacket implementation