blob: e1ceb3d77cbec64d54e0f4e82f5cd5d7ef291ba9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
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 <key>"
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
|