Helm/Sign: Difference between revisions
Jump to navigation
Jump to search
| Line 42: | Line 42: | ||
gpg --batch --yes --pinentry-mode loopback --passphrase ${PASSPHRASE} --output ${HOME}/.config/gnupg/chorke.key --armor --export-secret-key info@chorke.org | gpg --batch --yes --pinentry-mode loopback --passphrase ${PASSPHRASE} --output ${HOME}/.config/gnupg/chorke.key --armor --export-secret-key info@chorke.org | ||
</syntaxhighlight> | </syntaxhighlight> | ||
==GnuPG » Key » Terminology== | |||
{|class='wikitable mw-collapsible' | |||
!scope='col' style='width:800px' colspan='3'| | |||
'''Key » Terminology''' | |||
|- | |||
!scope="col" style='width:100px'| Field | |||
!scope="col" style='width:400px'| Value | |||
!scope="col" style='width:240px'| Meaning | |||
|- | |||
| '''Key ID''' || <code>A1349F92</code> (last 8 chars of fingerprint) || Short key ID | |||
|- | |||
| '''Long Key ID''' || <code>75D4D308A1349F92</code> (last 16 chars) || Long key ID | |||
|- | |||
| '''Fingerprint''' || <code>C9C2EDE5CBCF39BF574B0B3175D4D308A1349F92</code> || Full 40-char key fingerprint | |||
|- | |||
| '''Email/UID''' || <code>info@chorke.org</code> || Used to reference key | |||
|} | |||
==Playground== | ==Playground== | ||
Revision as of 00:54, 27 June 2025
cat <<'EXE'| sudo bash
apt-get update;echo
mkdir -p /etc/apt/keyrings
apt list -a --upgradable;apt-get upgrade -y;echo
apt-get install -y apt-transport-https ca-certificates gnupg && apt-get clean
EXE
GnuPG » Batch » Config
export GPG_TTY=$(tty)
mkdir -p ${HOME}/.config/gnupg
echo -n 'Password: ';read -s PASSPHRASE;export PASSPHRASE;echo
# Password: sadaqah!
cat << CFG | tee ${HOME}/.config/gnupg/chorke.conf >/dev/null
%echo Generating a GPG key
Key-Type: RSA
Key-Length: 3072
Subkey-Type: RSA
Subkey-Length: 3072
Name-Real: Chorke Academia, Inc
Name-Email: info@chorke.org
Expire-Date: 1y
Passphrase: ${PASSPHRASE}
%commit
%echo Done
CFG
GnuPG » Generate » Keys
export GPG_TTY=$(tty)
echo -n 'Password: ';read -s PASSPHRASE;export PASSPHRASE;echo
# Password: sadaqah!
gpg --batch --generate-key ${HOME}/.config/gnupg/chorke.conf
gpg --output ${HOME}/.config/gnupg/chorke.asc --armor --export info@chorke.org
gpg --batch --yes --pinentry-mode loopback --passphrase ${PASSPHRASE} --output ${HOME}/.config/gnupg/chorke.key --armor --export-secret-key info@chorke.org
GnuPG » Key » Terminology
|
Key » Terminology | ||
|---|---|---|
| Field | Value | Meaning |
| Key ID | A1349F92 (last 8 chars of fingerprint) |
Short key ID |
| Long Key ID | 75D4D308A1349F92 (last 16 chars) |
Long key ID |
| Fingerprint | C9C2EDE5CBCF39BF574B0B3175D4D308A1349F92 |
Full 40-char key fingerprint |
| Email/UID | info@chorke.org |
Used to reference key |
Playground
cat <<'CFG'| tee -a ${HOME}/.gnupg/gpg.conf >/dev/null
use-agent
pinentry-mode loopback
CFG
|
cat <<'CFG'| tee -a ${HOME}/.gnupg/gpg-agent.conf >/dev/null
allow-loopback-pinentry
CFG
|
gpgconf --kill gpg-agent
file ${HOME}/.config/gnupg/chorke.asc
file ${HOME}/.config/gnupg/chorke.key
gpg --import ${HOME}/.config/gnupg/chorke.key
|
|
| ||
References
|
| ||
|
| ||