Monday, May 26, 2014

Encrypt/Decrypt Zip File In Linux

1:37 PM

We can see how zip utility is used and how it's beneficial to use as well as how to secure your zip files and what precautions you should take while zipping or while providing security to your zip files.To enhance security of zip files i have also included encryption and decryption concept a bit.

Encrypting a file in gpg command


root@linuxstorage:~#gpg -c data.zip
Enter passphrase:

gpg utility has been used here to encrypt the zip file.

-c option is used to create gpg based encrypted file.


root@linuxstorage:ls
data.zip.gpg

We can't able to unzip the gpg zipped file without decrypting. So first decrypt and then unzip the file.


root@linuxstorage:gpg data.zip.gpg
Enter passphrase:

now when you enter the passphrase which you have given during encryption time the file will be decrypted.


root@linuxstorage:unzip data.zip
root@linuxstorage:ls
data

Written by

0 comments :

Post a Comment

 

© 2014 Linux Storages | Updated . All rights resevered. Designed by Templateism