Package com.l2jfrozen.loginserver.network.gameserverpackets

Examples of com.l2jfrozen.loginserver.network.gameserverpackets.PlayerAuthRequest


  private void onReceivePlayerAuthRequest(byte[] data) throws IOException
  {
    if(isAuthed())
    {
      PlayerAuthRequest par = new PlayerAuthRequest(data);
      PlayerAuthResponse authResponse;

      if(Config.DEBUG)
      {
        _log.info("auth request received for Player " + par.getAccount());
      }

      SessionKey key = LoginController.getInstance().getKeyForAccount(par.getAccount());

      if(key != null && key.equals(par.getKey()))
      {
        if(Config.DEBUG)
        {
          _log.info("auth request: OK");
        }

        LoginController.getInstance().removeAuthedLoginClient(par.getAccount());
        authResponse = new PlayerAuthResponse(par.getAccount(), true);
      }
      else
      {
        if(Config.DEBUG)
        {
          _log.info("auth request: NO");
          _log.info("session key from self: " + key);
          _log.info("session key sent: " + par.getKey());
        }
        authResponse = new PlayerAuthResponse(par.getAccount(), false);
      }
      sendPacket(authResponse);

      par = null;
      authResponse = null;
View Full Code Here

TOP

Related Classes of com.l2jfrozen.loginserver.network.gameserverpackets.PlayerAuthRequest

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.