[jcifs] Possible SMB URL incompatibility with standard URL syntax.

Christopher R. Hertel crh at ubiqx.mn.org
Thu Dec 12 09:47:00 EST 2002

I know how much people love to dig into the details of the SMB URL...  ;)

Here's the thing.  I was studying the general URI syntax given in Appendix 
A of RFC 2396, and I found a possible conflict.

The SMB URL allows "smb://", which we interpret to mean "gimme a list of 
workgroups".  That format works just fine with the general URL syntax.
The thing is, we have also talked about this:


as a way of sending credentials when querying the LMB for the list of 

There are a few things about this that that have me bothered:

1) I don't know if it's necessary.  I know that listing shares may require 
   authentication, but the query used to get the list of workgroups is not 
   the same as the one used to get the list of shares.  In my testing, I 
   was able to get a list of workgroups (using smbclient) from a W2K box 
   even though the same box would not provide the list of shares.

   Does anyone have a counter-example?  I know we had a discussion about 
   this sort of issue recently but I couldn't find the right thread when I
   went back to the archives.

2) I don't know if it applies to W2K Active Directory and LDAP queries.
   I don't think it does.  What does "smb://" mean in a port 445 
   environment?  Would it mean "search for any old AD server you can 
   find"?  The whole Active Directory/LDAP thing is a big missing piece of 
   the SMB URL semantics definition.

3) The most gnawing thing about "smb://user:passwd@" is that it clashes
   with the general URL syntax, which doesn't allow <userinfo> to exists
   unless <hostport> also exists (and is non-empty).

I would like to be able to conclude that the format:


is disallowed.


Chris -)-----

Samba Team -- http://www.samba.org/     -)-----   Christopher R. Hertel
jCIFS Team -- http://jcifs.samba.org/   -)-----   ubiqx development, uninq.
ubiqx Team -- http://www.ubiqx.org/     -)-----   crh at ubiqx.mn.org
OnLineBook -- http://ubiqx.org/cifs/    -)-----   crh at ubiqx.org

More information about the jcifs mailing list