public void Process(Tcp tcp, Packet packet) { var payload = Encoding.Default.GetBytes(packet.Payload); // windows-1252 var password = Encoding.Default.GetBytes(tcp.Password); var encrypted = Crypto.GenerateAuth(payload, password); var authpacket = PacketTemplates.Auth(encrypted, Enums.OnlineStatus.Online); tcp.SendPacket(authpacket); }
public void Process(Tcp tcp, Packet packet) { tcp.SendPacket(PacketTemplates.PING()); }