1. 11 Feb, 2020 5 commits
  2. 07 Feb, 2020 4 commits
  3. 06 Feb, 2020 2 commits
  4. 31 Jan, 2020 1 commit
    • Neal H. Walfield's avatar
      openpgp: Add a policy object. · a464ce81
      Neal H. Walfield authored
        - Change all functions that need to evaluate the validity of a
          signature (either directly or indirectly to take a policy object.
        - Use the policy object to allow the user to place additional
          constraints on a signature's validity.
        - This addresses the first half of #274 (it introduces the policy
          object, but does not yet implement any policy).
  5. 24 Jan, 2020 8 commits
  6. 23 Jan, 2020 1 commit
    • Neal H. Walfield's avatar
      openpgp: Have Cert::primary_key return a PrimaryKeyAmalgamation. · 925a351f
      Neal H. Walfield authored
        - Currently, `Cert::primary_key` returns a `KeyAmalgamation`, and
          `KeyAmalgamation::key()` returns a `Key<key::PublicKey,
          This means that when we want to use `Cert::primary_key().key()` as
          a primary key, we first need to coerce it into a
          `Key<key::PublicKey, key:PrimaryRole>`.  That's unergonomic.
        - Since `Cert::primary_key` will only ever return primary keys, we
          should be able to do better.
          It is tempting to turn the key's role in a `KeyAmalgamation` into
          a type variable.  This doesn't work, because `Cert::keys` would
          have to erase the role type.
          One could solve this by having not just `KeyAmalgamation<_,
          key::PrimaryRole>` and `KeyAmalgamation<_, key::SubordinateRole>`,
          but also implementing `KeyAmalgamation<_, key::UnspecifiedRole>`,
          which uses an enum, and appropriate conversion functions.
          That gets very ugly, very fast.
          Instead, we wrap `KeyAmalgamation` and `ValidKeyAmalgamation` so
          that we can specialize the `key` method.
  7. 22 Jan, 2020 1 commit
    • Neal H. Walfield's avatar
      openpgp: Use named constructors. · b295a5e6
      Neal H. Walfield authored
        - We are currently using two `From` implementations to construct
        - Use named constructors (`KeyAmalgamation::new_primary`, and
          `KeyAmalgamation::new_subordinate`), instead.
  8. 21 Jan, 2020 6 commits
  9. 20 Jan, 2020 4 commits
  10. 18 Jan, 2020 3 commits
  11. 14 Jan, 2020 2 commits
    • Neal H. Walfield's avatar
      openpgp: Add methods to KeyAmalgamation to query the Cert. · ebe746be
      Neal H. Walfield authored
        - Given a `KeyAmalgamation`, it is often necessary to determine the
          certificate's revocation status, or whether it is alive.
        - It is possible to get the `Cert` using `KeyAmalgamation::cert`,
          and to query it directly, but then the referece time needs to be
        - To make it harder for the user to pass the wrong reference time,
          and to simplify the code, add methods to query the certificate
          using the KeyAmalgamation's reference time.
    • Neal H. Walfield's avatar
      openpgp: Add KeyAmalgamation::cert. · 5e636b73
      Neal H. Walfield authored
        - Add a method to KeyAmalgamation to return the key's certificate.
  12. 08 Jan, 2020 1 commit
    • Neal H. Walfield's avatar
      openpgp: Include a reference time in KeyAmalgamation. · 5b0b546c
      Neal H. Walfield authored
        - Including the reference time in the KeyAmalgamation structure
          rather than having the user supply it to the individual
          methods (like `KeyAmalgamation::alive`) helps ensure that the key
          is used consistent.  For instance, this makes it harder to
          mistakenly query key's liveness at time t, but then use the
          current time to determine the key's capabilities.
  13. 25 Dec, 2019 1 commit
  14. 19 Dec, 2019 1 commit