Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / April 2006

Tip: Looking for answers? Try searching our database.

Java connecting to a file share

Thread view: 
ccjjharmon@gmail.com - 11 Apr 2006 15:20 GMT
Good morning everyone.

I have a need to read File objects from a network share on a Windows
file server. Currently I connect using a properly written URI to
retrieve the File object, and it works. I will be instantiating a bean
(from a servlet) that does this communication, and the servlet will
dispatch a JSP. In the end, this web app will be running within Tomcat
5.0.

OK so where's the question? My current state does not allow for
configuring the authentication to the file server. Whatever Tomcat is
running as determines how it authenticates with the file server.

What I would like to do is be able to pass a username and password
(encrypted of course).

I know there are several tools (JAAS, JNDI) that in some way can be
used for this, but I haven't read much about it... and certainly
anything that clearly says this one works, this one doesn't...

Can anyone provide some guidance?

Thanks!
Chris Uppal - 11 Apr 2006 17:24 GMT
> I have a need to read File objects from a network share on a Windows
> file server.[...]
>
> OK so where's the question? My current state does not allow for
> configuring the authentication to the file server. Whatever Tomcat is
> running as determines how it authenticates with the file server.

jCIFS might help.

   http://jcifs.samba.org/

E.g. read:

http://jcifs.samba.org/src/docs/faq.html#auth

SMB/CIFFS authentication appears to be something of a muddle, so be careful
that you understand what the authentication methods are (I don't ;-) and that
the method you are using satisfies your security requirements.

> I know there are several tools (JAAS, JNDI) that in some way can be
> used for this,

I don't think either of those are about authenticating your connection to an
existing (non-Java) application such as a Windows file server.

   -- chris


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.