[jcifs] authentication problem when server is in shared security mode

leostone leostone at mail.ru
Sat Mar 26 15:42:48 GMT 2005


Can someone please revise the code in jcifs.smb.SmbSession around line 300
and related code. From a first glance I suspect a program logic problem when a server is configured
with "shared" security. I encountered the same problem like Larry Weber, on a linux/samba server and 
on a XP/SP2 machine. I tracked the problem down to that if on the Windows Machine I DON'T use 
"Simple Sharing" ( "Einfache Dateifreigabe", I use a german system) (Explorer->Extras->Folder options->Use Simple Sharing)
everything works fine, but if I use it it seems even though I supply valid user credentials the session is beeing logged on as "Guest" and the
checking code throws an exception. 
Similar with the linux machine. I had the samba server configured with shared security and had 
a share that was configured "only user", see "man smb.conf", with that configuration the session on is also beeing established as guest.
When I changed the server security to "user" everthing worked as excpected. 
I guess the problem is that you do a tree connect to IPC$ and if the server is in "shared" security mode it will always? return a guest session which
causes all connections that are not beeing made as guest will get kickt out by that checking code around line 300.







More information about the jcifs mailing list