From 7c4fe2e92918a3f05bd8dfcbafc0e3942cfca558 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Thu, 18 Sep 2014 16:37:46 -0300 Subject: Initial import --- lsign | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100755 lsign (limited to 'lsign') diff --git a/lsign b/lsign new file mode 100755 index 0000000..e1ceb3d --- /dev/null +++ b/lsign @@ -0,0 +1,25 @@ +#!/bin/bash +# +# Locally sign an OpenPGP key. +# + +# Parameters +BASENAME="`basename $0`" +NAME="$1" +set -e + +# Syntax check +if [ -z "$NAME" ]; then + echo "usage: $BASENAME " + exit 1 +fi + +# Optional reason +read -e -p 'Optional lsignreason notation: ' REASON + +# Local signature +if [ ! -z "$REASON" ]; then + gpg --lsign --ask-cert-expire "$NAME" +else + gpg --lsign --cert-notation "lsigreason@notations.openpgp.fifthhorseman.net=${REASON}" --ask-cert-expire "$NAME" +fi -- cgit v1.2.3