A C# implementation of the OpenPGP Web Key Directory (WKD) (https://datatracker.ietf.org/doc/draft-koch-openpgp-webkey-service/), a service to locate OpenPGP keys by mail address using a Web service and the HTTPS protocol.
WKD Client library. Implements Key discovery, Policy file and Submission Address fetching, and basic key validation logic. It also defines two contract interfaces (IPgpKeyParser
and IPgpKeyWrapper
) for application-defined keyring parsing.
Uses: CSharpFunctionalExtensions
Implements IPgpKeyParser
and IPgpKeyWrapper
using the Bouncy Castle 2.1 crypto library.
Methods and classes for configuring the WKD Client and related services into the Microsoft dependency injection container.
An example commandline application, a small program that
- given a domain, verifies that the WELLKNOWN/policy file is present and well-formed, the WELLKNOWN/submission-address is present and there is a valid public key available for the submission address.
- given an email address, tries to discover the key(s)
Test suite, mostly based on the Java implementation test suite (https://github.com/pgpainless/wkd-java/tree/main/wkd-test-suite)
This library implements a protocol that is currently in Internet-Draft status. The library itself is a work in progress, so the API is unstable and may change anytime.
Currently, the library is versioned after the supported version of the specification, with the scheme 0.{draft-version}.{patch}-draft
. The I-D is currently at version 15 (released 2022-11-14, expires on 2023-05-18), so the library version is 0.15.0-draft
. When the specification will be stable and published as an RFC, the usual semantic version will be used.
Copyright (c) 2022 Fabrizio Tarizzo
This project is licensed under the MIT License
- WKD on the GnuPG Wiki
- Setting up OpenPGP Web Key Directory (WKD) (by uriports.com)
- How to set up PGP WKD (Web Key Directory) (by sindastra.de)
- How to setup your own WKD server (by Christian Rebischke)
- WKD Checker (by metacode.biz)