[jcifs] SmbFile getURL OpenStream not working SmbAuthException account currently disabled.

Michael B Allen ioplex at gmail.com
Tue Sep 7 20:08:33 MDT 2010


Hi Ashokkumar,

You are not supplying suitable credentials and JCIFS is falling back
to "GUEST" which is almost always disabled on the server. Create a
proper NtlmPasswordAuthentication object for your SmbFile instances.

Mike

-- 
Michael B Allen
Java Active Directory Integration
http://www.ioplex.com/


On Tue, Sep 7, 2010 at 9:59 AM, Ashokkumar <ashokkumar.bala at tcs.com> wrote:
> Dear Sir/Madam,
>
> I am trying to read an SmbFile using the below piece of code and it works fine.
>
> SmbFile smbFile = new SmbFile("smb://server1/temp/1.xml", getAuthentication());
> InputStream inputStream = smbFile.getInputStream();
>
> But the below piece of coding results in the error "jcifs.smb.SmbAuthException:
> Logon failure: account currently disabled."
>
> SmbFile smbFile = new SmbFile("smb://server1/temp/1.xml", getAuthentication());
> InputStream inputStream = smbFile.getURL().openStream(); // Doesn't work
>
> I need to pass the URL object to ANT library and it tries to call the openStream
> (). Thats why I want to read the file using getURL().openStream() method.
>
> Could you please guide me to solve the problem?
>
> Thanks and Regards,
> Ashokkumar B.
>
>


More information about the jCIFS mailing list