authentication using java swing client working