@Override
		public void onPacket(SendClientHandshakePacket packet) throws ProtocolException {

			log.info("Player[" + packet.nickname + "] tries to login...");

			boolean passwordCorrect = ssparams.getHashedServerPassword() == null
						|| (packet.hashedPassword != null && Hasher.isEqual(ssparams.getHashedServerPassword(), packet.hashedPassword));
			
			sendHandshakeResponse(passwordCorrect);
			
			if(passwordCorrect && !tooManyPlayer) {
				accepted = true;
			}else{
				log.info("Password is " + (passwordCorrect? "correct" : "incorrect") + "!");
				if(tooManyPlayer)
					log.info("But server is full!");
			}
			
			if(!passwordCorrect) {
				throw new SecurityException("Wrong password!");
			}
			
			if(!accepted) {
				throw new ProtocolException("Player not accepted!");
			}
			
			playerName = packet.nickname;
		}