[wellylug] encryption question

Richard richard at redspider.co.nz
Sat Aug 28 19:40:28 NZST 2004


> sorry to keep bugging you all....
> 
> I am trying to recursively encrypt/unencrypted the files contained in
> various directory trees
> 
> I have been playing with ccrypt which is easy to use but appears to get
> confused with some complicated file and directory names. For example some
> files don't get the extension .cpt added as they should but are still
> actually encrypted and the odd file simply refuses to encrypt.
> 
> So I installed mycrypt but I am going around in circles with the syntax (yes
> I read the man page - I must be having a slow brain day).
> 
> All I want to be able to do is point an encryption program at a key file and
> point it at a directory tree and have the program  walk through the tree
> encrypting and renaming (and maybe compressing but not essential) all the
> files it comes across as it goes.
> 
> Any suggestions appreciated

Why don't you just tar the dir up and encrypt that?

either way:

tar -cf - ./ | gpg -c >my_encrypted_files.tar.gpg

or:

# find all files that are not named .gpg and gpg them
# will ask for the passphrase a *lot*. better alternative is
# using the -e switch with a proper pub key
find ./ -type f ! -iname \*.gpg --exec gpg -c {} \;

(untested, don't try these on important data first.)

-- 
Richard Clark,
Analysis and Design,
Red Spider Ltd.
(+64) 021 478 219
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.wellylug.org.nz/pipermail/wellylug/attachments/20040828/f00e61e2/attachment.pgp 


More information about the wellylug mailing list