Advertisement
Guest User

Untitled

a guest
Jul 5th, 2018
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.52 KB | None | 0 0
  1. Authentication
  2. ____________________
  3. public void Deserialize(byte[] buffer)
  4. {
  5. if (buffer.Length == 312)
  6. {
  7. ushort length = BitConverter.ToUInt16(buffer, 0);
  8. if (length == 312)
  9. {
  10. ushort type = BitConverter.ToUInt16(buffer, 2);
  11. byte[] temp = new byte[16];
  12. if (type == 1542)
  13. {
  14. MemoryStream MS = new MemoryStream(buffer);
  15. BinaryReader BR = new BinaryReader(MS);
  16. BR.ReadUInt16();
  17. BR.ReadUInt16();
  18. Username = Encoding.Default.GetString(BR.ReadBytes(32));
  19. Username = Username.Replace("\0", "");
  20. BR.ReadBytes(36);
  21. var PasswordArray = BR.ReadBytes(32);
  22. // LoaderEncryption.Decrypt(PasswordArray, 32);
  23. Password = Encoding.Default.GetString(PasswordArray);
  24. Password = Password.Replace("\0", "");
  25. BR.ReadBytes(32);
  26. Server = Encoding.Default.GetString(BR.ReadBytes(32));
  27. Server = Server.Replace("\0", "");
  28. BR.Close();
  29. MS.Close();
  30. }
  31. }
  32. }
  33. }
  34. ____________________________________
  35. Constants
  36. _________
  37. GameCryptographyKey = "C238xs65pjy7HU9Q",
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement