[wellylug] encryption question
jumbophut
jumbophut at gmail.com
Sun Aug 29 10:55:11 NZST 2004
On Sat, 28 Aug 2004 22:04:57 +1200, Mark Signal wrote:
> IFS=$'\n'
> # if the encryption key is there use it to encrypt all files
> if [ -f $KEY ]; then
> for FILE in `find $DATADIR -type 'f' | grep -i -E
> "\.[dx][ol][cs]$"`;
> do
> ccrypt -eqfS .encrypted -k $KEY $FILE
> done
> fi
>
> this just encrypts .doc and .xls file at the moment
>
To be specific, this would also encrypt any files with a .xoc, .xlc,
.xos, etc. extension. That may not cause any problems, but if it
does, you could use:
grep -i -E '\.doc$|\.xls$'
instead of your existing grep expression. The infix operator (|) can
be used as many times as you like.
--
Tony (echo 'spend!,pocket awide' | sed 'y/acdeikospntw!, /l at omcgtjuba.phi/')
More information about the wellylug
mailing list