authentication script using java