Hi everyone,
I'm pleased to announce the release of version 0.29.0 of Sequoia sq, our general-purpose command-line tool for Sequoia PGP.
I have published sequoia-sq on crates.io:
https://crates.io/crates/sequoia-sq
You can also fetch version 0.29.0 using the v0.29.0 tag:
https://gitlab.com/sequoia-pgp/sequoia-sq/-/tags/v0.29.0
which I signed:
$ git verify-tag v0.29.0 gpg: Signature made Fri Apr 07 23:52:44 2023 +02:00 gpg: using RSA key C03FA6411B03AE12576461187223B56678E02528 gpg: Good signature from "Neal H. Walfield neal@walfield.org" [ultimate] gpg: "Neal H. Walfield neal@gnupg.org" gpg: "Neal H. Walfield neal@pep-project.org" gpg: "Neal H. Walfield neal@pep.foundation" gpg: "Neal H. Walfield neal@sequoia-pgp.org"
sq version 0.29.0 is packed full of exciting, user-visible changes. This release of sq is the culmination of two years of work, and includes several major user-visible improvements. To date, sq has operated in a stateless manner: users explicitly passed the keys and certificates that it should operate on, and implemented their own trust model by maintaining an ad-hoc curated keyring. Version 0.29.0 of sq adds support for a certificate store, includes a powerful web-of-trust engine based on flow networks, and introduces an easier-to-use interface, sq link, to manage authentication decisions based on concepts from how people use address books.
Here's a quick demo of downloading a certificate from keys.openpgp.org:
$ sq keyserver get neal@sequoia-pgp.org Recorded provenance information for DC09F5862D531848CBC4C0D8C6AD186AB030E354, "Downloaded from the keyserver keys.openpgp.org"
Created the local CA "Downloaded from the keyserver keys.openpgp.org" for certifying certificates downloaded from this service. The CA's trust amount is set to 1 of 120. Use `sq link add --ca '*' --amount N DC09F5862D531848CBC4C0D8C6AD186AB030E354` to override it. Or `sq link retract DC09F5862D531848CBC4C0D8C6AD186AB030E354` to disable it.
Recorded provenance information for 8F17777118A33DDA9BA48E62AACB3243630052D9, "Neal H. Walfield neal@gnupg.org" Recorded provenance information for 8F17777118A33DDA9BA48E62AACB3243630052D9, "Neal H. Walfield neal@pep-project.org" Recorded provenance information for 8F17777118A33DDA9BA48E62AACB3243630052D9, "Neal H. Walfield neal@sequoia-pgp.org" Recorded provenance information for 8F17777118A33DDA9BA48E62AACB3243630052D9, "Neal H. Walfield neal@walfield.org" Importing 1 certificates into the certificate store:
1. 8F17777118A33DDA9BA48E62AACB3243630052D9 Neal H. Walfield neal@walfield.org
Imported 1 new certificates, updated 0 certificates, 0 certificates unchanged, 0 errors.
After checking that a certificate really belongs to the stated owner, use "sq link add FINGERPRINT" to mark the certificate as authenticated.
We see that `sq` has saved the provenance information, and explains how to link the certificate and the identity. When we now look up the certificate associated with neal@sequoia-pgp.org, we see that it has been certified by a minimally trusted, local, shadow CA for keys.openpgp.org, which is in turn certified by the local trust root:
$ sq wot lookup --email neal@sequoia-pgp.org [ ] 8F17777118A33DDA9BA48E62AACB3243630052D9 Neal H. Walfield neal@sequoia-pgp.org: marginally authenticated (0%) ◯ 15BEF9EDD4759647BE5F008AAD0B4189CE8A7D1B ("Local Trust Root") │ partially certified (amount: 1 of 120) the following certificate on 2023-04-07 as a partially trusted (1 of 120) introducer (depth: 1) ├ DC4981E703D4448C778396EDA349F3FA419E04AC ("Downloaded from the keyserver keys.openpgp.org") │ certified the following binding on 2023-04-07 └ 8F17777118A33DDA9BA48E62AACB3243630052D9 "Neal H. Walfield neal@sequoia-pgp.org"
Could not authenticate any paths.
If we are convinced that keys.openpgp.org is reliable, then we can easily change how much we rely on the the shadow CA to check email addresses:
$ sq link add --ca * DC4981E703D4448C778396EDA349F3FA419E04AC --all DC4981E703D4448C778396EDA349F3FA419E04AC, Downloaded from the keyserver keys.openpgp.org was already linked at 2023-04-07 22:34:48 UTC. Updating trust amount: 1 -> 120. Update trust depth: 1 -> 255. Updating exportable flag: true -> false. Link parameters changed, updating link. Linking DC4981E703D4448C778396EDA349F3FA419E04AC and "Downloaded from the keyserver keys.openpgp.org".
Now, that certificate and any user IDs that were returned by keys.openpgp.org are considered fully authenticated:
$ sq wot lookup --email neal@sequoia-pgp.org [✓] 8F17777118A33DDA9BA48E62AACB3243630052D9 Neal H. Walfield neal@sequoia-pgp.org: fully authenticated (100%) ◯ 15BEF9EDD4759647BE5F008AAD0B4189CE8A7D1B ("Local Trust Root") │ certified the following certificate on 2023-04-07 as a fully trusted meta-introducer (depth: unconstrained) ├ DC4981E703D4448C778396EDA349F3FA419E04AC ("Downloaded from the keyserver keys.openpgp.org") │ certified the following binding on 2023-04-07 └ 8F17777118A33DDA9BA48E62AACB3243630052D9 "Neal H. Walfield neal@sequoia-pgp.org"
And we can address the certificate by user ID or email:
$ echo 'Hi Neal!' | sq encrypt --recipient-email neal@walfield.org -----BEGIN PGP MESSAGE----- ...
If we ever change our mind about how much we are willing to rely on keys.openpgp.org, we can easily modify the link, or even retract it:
$ sq link retract DC4981E703D4448C778396EDA349F3FA419E04AC DC4981E703D4448C778396EDA349F3FA419E04AC, Downloaded from the keyserver keys.openpgp.org was linked at 2023-04-07 22:37:52 UTC. Updating trust amount: 120 -> 0. Update trust depth: 255 -> 0. Link parameters changed, updating link. Breaking link between DC4981E703D4448C778396EDA349F3FA419E04AC and "Downloaded from the keyserver keys.openpgp.org".
$ sq link list DC4981E703D4448C778396EDA349F3FA419E04AC, "Downloaded from the keyserver keys.openpgp.org"'s link was retracted.
I've published an introduction to all the new functionality as well as the motivation for some of our unconventional design decisions in a blog post:
https://sequoia-pgp.org/blog/2023/04/08/sequoia-sq/
The list of changes in 0.29 is:
* New functionality - `sq` now supports and implicitly uses a certificate store. By default, `sq` uses the standard OpenPGP certificate directory. This is located at `$HOME/.local/share/pgp.cert.d` on XDG compliant systems. - `sq --no-cert-store`: A new switch to disable the use of the certificate store. - `sq --cert-store`: A new option to use an alternate certificate store. Currently, only OpenPGP certificate directories are supported. - `sq import`: A new command to import certificates into the certificate store. - `sq export`: A new command to export certificates from the certificate store. - `sq encrypt --recipient-cert`: A new option to specify a recipient's certificate by fingerprint or key ID, which is then looked up in the certificate store. - `sq verify --signer-cert`: A new option to specify a signer's certificate by fingerprint or key ID, which is then looked up in the certificate store. - `sq verify` now also implicitly looks for missing certificates in the certificate store. But, unless they are explicitly named using `--signer-cert`, they are not considered authenticated and the verification will always fail. - `sq certify`: If the certificate to certify is a fingerprint or Key ID, then the corresponding certificate is looked up in the certificate store. - Add a global option, `--time`, to set the reference time. This option replaces the various subcommand's `--time` argument as well as `sq key generate` and `sq key userid add`'s `--creation-time` arguments. - Add top-level option, `--trust-root`, to allow the user to specify trust roots. - Extend `sq encrypt` to allow addressing recipients by User ID (`--recipient-userid`) or email address (`--recipient-email`). Only User IDs that can be fully authenticated are considered. - Extend `sq verify` to verify certificates looked up from the certificate store using the web of trust. If the signature includes a Signer's User ID packet, and the binding can be fully authenticated, consider the signature to be authenticated. If there is no Signer's User ID packet, consider the signature to be authenticated if any binding can fully be authenticated. - Add `sq link add`, which uses the local trust root to certify the specified bindings. - Add `sq link retract`, which retracts certifications made by the local trust root on the specified bindings. - Add `sq link list`, which lists the links. - Add a top-level option, `--keyring`, to allow the user to specify additional keyrings to search for certificates. - Import web of trust subcommands from sq-wot. Specifically, add: - `sq wot authenticate` to authenticate a binding. - `sq wot lookup` to find a certificate with a particular User ID. - `sq wot identify` to list authenticated bindings for a certificate. - `sq wot list` to list authenticated bindings. - `sq wot path` to authenticate and lint a path in a web of trust. - `sq keyserver get`, `sq wkd get`, and `sq dane get` now import any certificates into the certificate store by default instead of exporting them on stdout. It is still possible to export them using the `--output` option. - When `sq keyserver get` (for verifying key servers), `sq wkd get`, or `sq dane get` saves a certificate to the local certificate store, `sq` certifies the validated User IDs (all returned User IDs in the case of verifying key servers; User IDs that contain the looked up email address in the case of WKD and DANE) using a local service-specific proxy CA. If the proxy key doesn't exist, it is created, and certified as a minimally trusted CA (trust amount 1 of 120) by the local trust root. The proxy certificates can be managed in the usual way using `sq link add` and `sq link retract`. - Extend `sq inspect` to inspect certificates from the certificate store using the `--cert` option. * Deprecated functionality - `sq key generate --creation-time TIME` is deprecated in favor of `sq key generate --time TIME`. - `sq key user id --creation-time TIME` is deprecated in favor of `sq user id --time TIME`.
Neal on behalf of the whole Sequoia PGP team