aspose file tools*
The moose likes General Computing and the fly likes Can we password protect a File / folder / Windows Drive using java? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » General Computing
Bookmark "Can we password protect a File / folder / Windows Drive using java?" Watch "Can we password protect a File / folder / Windows Drive using java?" New topic
Author

Can we password protect a File / folder / Windows Drive using java?

Lokendra Shekhawat
Ranch Hand

Joined: Jun 08, 2009
Posts: 40
Hi Friends....

I have questions...

Can we password protect a file / folder / drive (Pen drive or c: / d: drive of windows) using java?

I can zip and password protect a file and folder, but its actually creating the copy of original data....

can we password protect file / folder without zipping them?
can we password protect pen drive or windows drive?

Awaiting your response...

Thank you..


SCJP5 93%. SCWCD 98%.

Visit my website http://www.rajasthan4tourism.com for information about rajasthan tourist places and much more.....!!!
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 38910
    
  23
Too difficult a question for “beginning”. Moving discussion. Let’s try general computing.
Ivan Jozsef Balazs
Rancher

Joined: May 22, 2012
Posts: 867
    
    5
Do you want to use a service provided by the OS or roll out something own?
Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5830
    
    7

Why write something in Java to do this when there are many free tools available that already do this?

And yes, you can password protect a file in Java. Here is a simple example with strings but you can apply the same principles to an entire file:
http://docs.oracle.com/javase/7/docs/technotes/guides/security/crypto/CryptoSpec.html#SimpleEncrEx


JBoss In Action
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can we password protect a File / folder / Windows Drive using java?