From 3a5e7617c0040eccdf3935c9ec5a31a95c970cef Mon Sep 17 00:00:00 2001 From: Ahmed Abdelhalim Date: Fri, 24 Jul 2026 14:33:53 +0200 Subject: Rotate gpg key --- .gitconfig | 6 +++--- .gnupg/sshcontrol | 2 +- .ssh/config | 8 +++++++- Debian.md | 34 ---------------------------------- README.md | 11 +++++++++++ 5 files changed, 22 insertions(+), 39 deletions(-) diff --git a/.gitconfig b/.gitconfig index 1d0a9cb..5f85786 100644 --- a/.gitconfig +++ b/.gitconfig @@ -13,10 +13,10 @@ [merge] tool = vimdiff [user] - name = Ahmed AbdelHalim - email = pm@a14m.me + name = Ahmed Abdelhalim + email = pm@a14m.dev username = a14m - signingkey = 83786B48F734C4F7C2CEEC30D9FDD29DE1EA6405! + signingkey = 8B329B4CA58513705BAD1262C3A28FB43A6B6226! [branch] sort = -committerdate ; autosetuprebase = always diff --git a/.gnupg/sshcontrol b/.gnupg/sshcontrol index 54013e3..78d70d8 100644 --- a/.gnupg/sshcontrol +++ b/.gnupg/sshcontrol @@ -12,5 +12,5 @@ # To show the keygrip id used for the following keys, use the following command # gpg -k --with-keygrip # -A0D69D1C4A50DCA187040B2BBB0AACF987088B94 +3CBDAFF01814B706CBD238E2A61B986792A117B9 F76FBB2832E971AF3714FC9F5F7148C0A149D305 diff --git a/.ssh/config b/.ssh/config index 0527486..1092e8f 100644 --- a/.ssh/config +++ b/.ssh/config @@ -5,7 +5,13 @@ Host *iso.local StrictHostKeyChecking no UserKnownHostsFile /dev/null -Host *.local +Host proxy.home.arpa git.home.arpa + user root + Port 39901 + StrictHostKeyChecking no + UserKnownHostsFile /dev/null + +Host *.local *.home.arpa User a14m Port 39901 StrictHostKeyChecking accept-new diff --git a/Debian.md b/Debian.md index aa7fdd7..68f44b8 100644 --- a/Debian.md +++ b/Debian.md @@ -26,37 +26,3 @@ sudo apt install ffuf -y git clone https://github.com/wireghoul/dotdotpwn.git ~/dotdotpwn sudo mv ~/dotdotpwn /opt/ ``` - -## TailsOS - -## GPG restore smart key - -```bash -$ zbarcam -1 --raw > key.asc -$ gpg --import key.asc -$ gpg --edit-key --expert -gpg> trust -gpg> keytocard -Really move the primary key? (y/N) y -Please select where to store the key: - (1) Signature key - (3) Authentication key -Your selection? 1 -... -gpg> key 1 -gpg> keytocard -Please select where to store the key: - (2) Encryption key -Your selection? 2 -... -gpg> key 1 -gpg> key 2 -gpg> keytocard -Please select where to store the key: - (3) Authentication key -Your selection? 3 -... - -gpg> quit -Save changes? (y/N) y -``` diff --git a/README.md b/README.md index 98dc7dd..d482696 100644 --- a/README.md +++ b/README.md @@ -42,3 +42,14 @@ brew install git-crypt cd ~/.rc git-crypt unlock ``` + +### GPG + +To rotate the GPG keys, after generating and backing up. + +- Get the new gpg key ID with `gpg --list-keys `. +- Get the new gpg key grip with `gpg --list-keys --with-keygrip ` +- Update the `.gitconfig` signing key: +- Update the GPG key in the password store `.gpg-id` file with +- Update the sshcontrol config file with the authentication key of +- Update git-crypt with the new key: `git-crypt add-gpg-user ` -- cgit v1.2.3