From bfda197c4d0c702d969d2d68ca8f7585b9f48264 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=A1clav=20Val=C3=AD=C4=8Dek=20=28YCNet=29?= Date: Sun, 17 May 2020 10:38:33 +0200 Subject: [PATCH] Migrate to ed25519 key, change id_rsa to identity file name --- checker/cloner-lib-auth | 2 +- dockerbin/wizzard | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/checker/cloner-lib-auth b/checker/cloner-lib-auth index b7d32a3..312214e 100644 --- a/checker/cloner-lib-auth +++ b/checker/cloner-lib-auth @@ -13,6 +13,6 @@ function prepareGitAuth(){ # git configure http authenticator git config --global credential.helper "store --file=$confdir/git-credentials" # git configure ssh auth - git config --global core.sshcommand "ssh -i $confdir/ssh/id_rsa -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes -q" + git config --global core.sshcommand "ssh -i $confdir/ssh/identity -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes -q" } diff --git a/dockerbin/wizzard b/dockerbin/wizzard index 97f1293..f7eafe5 100755 --- a/dockerbin/wizzard +++ b/dockerbin/wizzard @@ -93,10 +93,10 @@ function createDetectorConfig(){ function generateSSHKey(){ # generates ssh key with $1 path and $2 description - local keyfile=$1/id_rsa + local keyfile=$1/identity local description=$2 echo "Creating SSH deployment key.." - ssh-keygen -f $keyfile -b 4096 -C "$description" -N "" + ssh-keygen -f $keyfile -t ed25519 -C "$description" -N "" echo echo "Public key is:" echo "-----------------------------------------------------" @@ -196,7 +196,7 @@ fi if [[ "$read_ssh" =~ ^[Uu]$ ]] then # load key - reuseSSHKey $root/config/auth/ssh/id_rsa + reuseSSHKey $root/config/auth/ssh/identity fi