[jcifs] jcifs.smb.SmbTree.treeDisconnect() not resetting service

Ti Lian Hwang lian_hwang.ti at fairprice.com.sg
Fri Jan 4 00:51:21 GMT 2008


I'm using it as part of the HttpAuth against W2K3

Actually, I tracked it further to that if the tree got disconnected,
it should not be reuse, trying to reconnect causes a problem.

Resetting the tree instance values does not help.

The tree should be removed from the "trees" Vector in SmbSession.logoff()
once it got disconnected, and should not be reused, 
as a reconnection seems to cause failure,
as I guess the SMB digest etc is invalidated by the server.

Is SmbSession.logoff() called upon timeout ?

Still testing ... forcing a failure is hard, but users can always cause it :-(

> Still trying to figure out the W2K3 problem.
> Managed to track down to probably the issue is that
> jcifs.smb.SmbTree.treeDisconnect() does not reset the service to '?????'
> When it reconnects, it will ask for the service 'IPC'.
> This seems to cause a logon failure.
> Could anyone verify such a behaviour ?

Interesting. I'll add this to the TODO list. This should definitely be
fixed, but I'm curious - if JCIFS successfully connected to the share and
found it to be IPC then why would the server care if it was explicitly
specified as IPC instead of '?????' the second time?  Is there a specific
implementation that this causes a problem with?


Michael B Allen
PHP Active Directory SPNEGO SSO

More information about the jcifs mailing list