7
1
How can I compress two folders into archive file (zip, gzip or something like that) with a password on the files?
For example I have folder structure:
- rootDir
- dir1
- dir2
- dir3
- dir4
I need bash command to add dir2 and dir4 to same archive file compressed with a password on it.
This is good, how do I do it for all folders , files and subfolders (recursive) ? And another question, how do I provide password without prompt ? – Perica Zivkovic – 2009-09-10T18:01:00.920
2so the answer I was looking for is: zip -rP "password" filename.zip dir2 dir4 – Perica Zivkovic – 2009-09-10T18:42:28.183
1
Note however, that
– sleske – 2010-01-04T11:25:23.683zip
's built-in encryption is fairly insecure: http://math.ucr.edu/~mike/zipattacks.pdf . If you want more than protection from casual peeping, use a real encryption software (such as GnuPG or TrueCrypt).