summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/common5
-rwxr-xr-xsrc/monkeysphere-server2
2 files changed, 6 insertions, 1 deletions
diff --git a/src/common b/src/common
index 01e6f32..19b5485 100644
--- a/src/common
+++ b/src/common
@@ -468,6 +468,11 @@ trust_key() {
# get key fingerprint
fingerprint=$(get_key_fingerprint "$keyID")
+ # attach a "non-exportable" signature to the key
+ # this is required for the key to have any validity at all
+ # the 'y's on stdin indicates "yes, i really want to sign"
+ echo -e 'y\ny' | gpg --lsign-key --command-fd 0 "$fingerprint"
+
# import "full" trust for fingerprint into gpg
echo ${fingerprint}:5: | gpg --import-ownertrust
if [ $? = 0 ] ; then
diff --git a/src/monkeysphere-server b/src/monkeysphere-server
index 13221c5..e05b4b7 100755
--- a/src/monkeysphere-server
+++ b/src/monkeysphere-server
@@ -47,7 +47,7 @@ gen_key() {
# set key defaults
KEY_TYPE=${KEY_TYPE:-"RSA"}
KEY_LENGTH=${KEY_LENGTH:-"2048"}
- KEY_USAGE=${KEY_USAGE:-"encrypt,auth"}
+ KEY_USAGE=${KEY_USAGE:-"auth,encrypt"}
SERVICE=${SERVICE:-"ssh"}
HOSTNAME_FQDN=${HOSTNAME_FQDN:-$(hostname -f)}