some tools for internal use
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

7 lines
393 B

#!/usr/bin/env sh
test $# -gt 0 || { echo "argument missing."; exit 1; }
test -e $1 && { if=$1; shift; } || { echo "file does not exist: "$1; exit 2; }
of=$( echo ${if}|rev|cut -d"." -f2-|rev )
#~ ext=$( echo ${if}|rev|cut -d"." -f1-|rev ) # we usually encrypt pdf natively (aes-128, password is limited to 32 characters)
# decrypt symmetric encrypted file
gpg --output ${of} --decrypt ${if}