From b208cbc619735be0107c81c220a1ca46ce61c9cf Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Fri, 5 Jan 2024 16:35:08 -0500 Subject: [PATCH] Store intermediates in a Vec rather than a hash set (#10136) There's no particular need for a hash set --- src/rust/cryptography-x509-verification/src/lib.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/rust/cryptography-x509-verification/src/lib.rs b/src/rust/cryptography-x509-verification/src/lib.rs index ef9cdae84205..6265f75c5502 100644 --- a/src/rust/cryptography-x509-verification/src/lib.rs +++ b/src/rust/cryptography-x509-verification/src/lib.rs @@ -11,7 +11,6 @@ pub mod policy; pub mod trust_store; pub mod types; -use std::collections::HashSet; use std::vec; use cryptography_x509::extensions::{DuplicateExtensionsError, Extensions}; @@ -171,7 +170,7 @@ pub fn verify<'chain, B: CryptoOps>( } struct ChainBuilder<'a, 'chain, B: CryptoOps> { - intermediates: HashSet>, + intermediates: Vec>, policy: &'a Policy<'a, B>, store: &'a Store<'chain, B>, } @@ -197,7 +196,7 @@ impl ApplyNameConstraintStatus { impl<'a, 'chain, B: CryptoOps> ChainBuilder<'a, 'chain, B> { fn new( - intermediates: HashSet>, + intermediates: Vec>, policy: &'a Policy<'a, B>, store: &'a Store<'chain, B>, ) -> Self {