Download distro key:
wget http://ftp.th.pld-linux.org/dists/th/PLD-3.0-Th-GPG-key.asc
Verify it's validity ;-)
Import key to rpm:
sudo rpm --import PLD-3.0-Th-GPG-key.asc
Checking installed keys:
rpm -qa gpg-pub*
gpg-pubkey-e64e7bf7-47b35206.(none)
Checkign details of given key:
rpm -qi gpg-pubkey-e64e7bf7-47b35206
or
rpm -q gpg-pubkey --qf '%{name}-%{version}-%{release} --> %{summary}\n'
Import key to gpg keyring:
gpg --import PLD-3.0-Th-GPG-key.asc
gpg: key E4F1BC2D: public key "DSApub (PLD Linux Distribution 3.0 (Th)) " imported
gpg: key EAE6F8B8: public key "RSApub (PLD Linux Distribution 3.0 (Th)) " imported
gpg: Total number processed: 2
gpg: imported: 2 (RSA: 1)
List installed gpg keys:
gpg --list-keys
/home/users/matkor/.gnupg/pubring.gpg
-------------------------------------
pub 1024D/E4F1BC2D 2008-02-13
uid DSApub (PLD Linux Distribution 3.0 (Th))
pub 1024R/EAE6F8B8 2008-02-13
uid RSApub (PLD Linux Distribution 3.0 (Th))
Verificaton details of given package (here we see missing key e4f1bc2d):
rpm -K ./0verkill-0.16-4.i686.rpm -v
./0verkill-0.16-4.i686.rpm:
Header V3 DSA signature: NOKEY, key ID e4f1bc2d
Header SHA1 digest: OK (58b413f3e63ddad1503a43a64acd6187864fd33b)
MD5 digest: OK (5f66e9757673f41e9d0ff3b28c521638)
V3 DSA signature: NOKEY, key ID e4f1bc2d
Deleting multiple keys from rpm (specifies multiple packages error):
sudo rpm -e --allmatches gpg-pubkey-e64e7bf7-47b35206