Allow Conduit requests to be signed with a public/private keypair
Summary:
This allows callers (in the future, servers in a cluster or instances) to sign Conduit requests with an asymmetric keypair instead of a certificate or token.
Overall we could get away without this, but it seems worth doing for a few reasons:
- By binding Device identity to SSH keys, we can also authorize them over (real) SSH easily, and not need separate conduit / SSH keys.
- Asymmetric key cryptography is strong and well understood, and we never have to share or transmit private keys.
- This is potentially useful to third parties for device identity, in a way that custom Conduit stuff wouldn't be.
Test Plan:
- Added unit tests.
- Will actually test once I mess with the other half of this.
Reviewers: hach-que, #blessed_reviewers, btrahan
Reviewed By: #blessed_reviewers, btrahan
Subscribers: epriestley, Korvin
Maniphest Tasks: T6240
Differential Revision: https://secure.phabricator.com/D10402