[jcifs] SmbAuthException while calling list() on a
SmbFile("smb://").
Michael P. Jung
suriver at gmail.com
Mon Sep 6 21:56:21 GMT 2004
After looking at the code fragment which throws the exception I don't
think that my setup causes all this anymore...
Line 191-193 in jcifs/smb/SmbSession.java:
if( response.isLoggedInAsGuest ) {
throw new SmbAuthException( NtStatus.NT_STATUS_LOGON_FAILURE );
}
So what shall happen if I _want_ to log in as guest? I just changed it a bit...
if( !request.auth.getUsername().toUpperCase().equals("GUEST") &&
response.isLoggedInAsGuest ) {
throw new SmbAuthException( NtStatus.NT_STATUS_LOGON_FAILURE );
}
Now it works as expected. Since the user "GUEST" could also be a
normal user account I'd rather use an empty string and/or null to
check wether isLoggedInAsGuest shall throw an exception.
I just patched it that way because I don't want to mess with the other
JCIFS internals like adding extra config variables, etc.
Thanks,
Michael
More information about the jcifs
mailing list