diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2019-11-27 16:36:15 +0100 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2019-11-27 16:36:15 +0100 |
commit | 4f886702d004830df94dd03d02763dcffb9c92fc (patch) | |
tree | 4bb853a500b3b56bdb74d38cdd182efed99922db | |
parent | 5eb6ad9f545291f05f5f2455684da68594c8a4dd (diff) |
openpgp: Add missing KeyIter::authentication_capable.
-rw-r--r-- | openpgp/src/tpk/keyiter.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/openpgp/src/tpk/keyiter.rs b/openpgp/src/tpk/keyiter.rs index 50f59cbe..d7ec9684 100644 --- a/openpgp/src/tpk/keyiter.rs +++ b/openpgp/src/tpk/keyiter.rs @@ -310,6 +310,13 @@ impl<'a, P: 'a + key::KeyParts, R: 'a + key::KeyRole> KeyIter<'a, P, R> self.key_flags(KeyFlags::default().set_sign(true)) } + /// Returns keys that are authentication capable. + /// + /// See `key_flags` for caveats. + pub fn authentication_capable(self) -> Self { + self.key_flags(KeyFlags::default().set_authenticate(true)) + } + /// Returns keys that are capable of encrypting data at rest. /// /// See `key_flags` for caveats. |