Ok, I resolved the problem by myself. The problem was due that in my network the jifsDomain is not recognizable with his name. I don't know if this is an error in domain configuration, but changing the jcifsDomain with the IP everything work.
To resolve the problem i put the project in debug and I saw that throws an exception in the class JCIFSSpnegoAuthenticationHandler
try {
// proceed authentication using jcifs
synchronized (this) {
this.authentication.reset();
this.authentication.process(spnegoCredentials.getInitToken());
principal = this.authentication.getPrincipal();
nextToken = this.authentication.getNextToken();
}
} catch (jcifs.spnego.AuthenticationException e) {
throw new BadCredentialsAuthenticationException();
}
I suggest to trace the message of the catched exception.
Now I can authenticate the user with NTLM token because the token i received is NTLMSSP. How can i force the Kerberos authenication? Putting NTLM allowed to false doesn't work.
Thanks.
Andrea