Solved

password protecting folders using api in java

Posted on 2011-03-02
3
243 Views
Last Modified: 2012-05-11
Hi,

I have some files in a folder which needs to be password protected using java. So i need to stop direct access from other users to open the folder but should be only accessible using the api.
This needs to be implemented in java only.

Please help me.

Thanks
0
Comment
Question by:ranga_kartik
  • 2
3 Comments
 
LVL 47

Expert Comment

by:for_yan
ID: 35024756
What is the operating system you are talking about - is it Window, Unix?
0
 
LVL 47

Expert Comment

by:for_yan
ID: 35024795

On Unix system you can create folders and make them accessible only to the user
who created them. Then you could allow other people to access them through your Java
program and may require credentials to do so. In this way these folders
will become accessible only after authentication.
Of course Unix administartor will still have access to this data.

This is a java-centric discussion about password protected files:
http://www.dreamincode.net/forums/topic/22760-creating-password-protected-files-through-java/
0
 
LVL 86

Accepted Solution

by:
CEHJ earned 200 total points
ID: 35024916
This isn't practicably possible: access control to a file system is done at operating system level and therefore makes little sense for a cross-platform language like Java.

Consider instead using storage outside the file system, which of course you can implement in a platform-independent way
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
This video teaches viewers about errors in exception handling.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now