[jcifs] JCIFS and Connection TimeOut exception..Please help

Ram Chavali rchavali at vmware.com
Wed Mar 4 06:06:52 GMT 2009

Hi Michael,

Thanks for the reply. I have to use java. Also querying AD will only result in AD domains/computers(Correct me if I am wrong). I need to discover LanMan Domains/computers in windows network from Linux box. 
So I am wondering if I could write a java wrapper around 'SmbTree' command.
Please let me know if this is the right way.

Again thanks for your help.

--Ram Chavali  

-----Original Message-----
From: Michael B Allen [mailto:ioplex at gmail.com] 
Sent: Tuesday, March 03, 2009 9:18 PM
To: Ram Chavali
Cc: jcifs at lists.samba.org
Subject: Re: [jcifs] JCIFS and Connection TimeOut exception..Please help

On Wed, Mar 4, 2009 at 12:04 AM, Ram Chavali <rchavali at vmware.com> wrote:
> Hi Michael,
> I need to discover all windows groups/Domains and computers  from linux box. I assume I can also use 'SmbTree' command. But, i think either SmbTree internally uses NetBios Session service.(Please let me know if I am wrong). With this network is there any other way I can use JCIFS to get the results.

JCIFS isn't good for that. If you're using Java, the best option at the moment is to use JNDI to query AD using LDAP. Using DCERPC calls is probably a little more consistent with what Windows does to acquire that information but JNDI will do the job just fine.

If you don't need Java specifically, you could probably use "rpcclient" from Samba (although technically I think rpcclient is known to be insecure).


Michael B Allen
Java Active Directory Integration

More information about the jcifs mailing list