uselesskey-pgp-native 0.5.0

Native OpenPGP key type adapters for uselesskey fixtures.
Documentation

uselesskey-pgp-native

Adapters from uselesskey OpenPGP fixtures to native pgp crate types.

Feature support

Feature Source artifact Native output
pgp-native PgpKeyPair SignedSecretKey, SignedPublicKey

Example

use uselesskey_core::Factory;
use uselesskey_pgp::{PgpFactoryExt, PgpSpec};
use uselesskey_pgp_native::PgpNativeExt;

let fx = Factory::random();
let keypair = fx.pgp("signer", PgpSpec::ed25519());

let secret = keypair.secret_key_armor();
let public = keypair.public_key_armor();

assert_eq!(secret.fingerprint(), public.fingerprint());
println!("fingerprint={}", secret.fingerprint());

Tests

  • one smoke test that parses binary and armored fixture values
  • one integration-style assertion test for deterministic conversion in an external path

License

Licensed under either of Apache License, Version 2.0 or MIT license, at your option.