tb-openpgp-certs

Crates.iotb-openpgp-certs
lib.rstb-openpgp-certs
version0.1.0
sourcesrc
created_at2021-01-27 18:27:06.811443
updated_at2021-01-27 18:27:06.811443
descriptionA tool to interact with TB78 (and later) OpenPGP cert storage
homepage
repositoryhttps://gitlab.com/hkos/tb-openpgp-certs
max_upload_size
id347411
size119,374
Heiko Schaefer (hko-s)

documentation

README

This is a tool to interact with TB78 (and later) OpenPGP cert storage. It only deals with "public keys", private keys are not handled.

CAUTION: This tool is a hack to interact with Thunderbird's OpenPGP certificate storage. It might eat your keyring (see below).

Import all keys from a Keylist into Thunderbird

Three parameters are needed to import a Keylist into the Thunderbird databases:

  • The filesystem path of the Thunderbird profile that the Keylist should be imported into,
  • the URL of a Keylist,
  • the expected CA Fingerprint for that Keylist.

The Gpgsync demo Keylist can be imported into Thunderbird like this:

$ tb-openpgp-certs -p ~/.thunderbird/foobar.default/ import keylist https://raw.githubusercontent.com/firstlookmedia/gpgsync/develop/example-keylist/keylist.json --ca 4CA5857F960C8A78D82C11F36D00387A7A0206E2

Details

Thunderbird 78+ stores public OpenPGP certificate data in two locations, in Thunderbird profile directories:

  • pubring.gpg contains the actual OpenPGP certificates
  • openpgp.sqlite contains some metadata, in particular the "acceptance" level of each certificate

This tool modifies the content of those two files.

However, note that Thunderbird does not currently reload changes from these files until it is restarted.

Before running this tool, make backups of (at least) the files pubring.gpg and openpgp.sqlite, if you worry about corrupting or losing your Thunderbird OpenPGP certificate store.

Commit count: 9

cargo fmt