From 3c76d468060a02b0aa129308bc413b91d166167b Mon Sep 17 00:00:00 2001 From: Justus Winter Date: Tue, 10 Oct 2023 11:14:45 +0200 Subject: openpgp: Drop assertion that does not hold. - Instead, just accept that if other signature types come in, we miscompute the hash, and we'll reject the signature later on. --- openpgp/src/parse/hashed_reader.rs | 3 --- 1 file changed, 3 deletions(-) (limited to 'openpgp/src/parse') diff --git a/openpgp/src/parse/hashed_reader.rs b/openpgp/src/parse/hashed_reader.rs index f3646a73..7668fecd 100644 --- a/openpgp/src/parse/hashed_reader.rs +++ b/openpgp/src/parse/hashed_reader.rs @@ -331,9 +331,6 @@ impl Cookie { for h in self.sig_groups[0].hashes.iter_mut() { t!("{:?}: {:?} hashing {} bytes.", hashes_for, h.map(|ctx| ctx.algo()), data.len()); - assert!(matches!(h, HashingMode::Text(_) - | HashingMode::TextLastWasCr(_)), - "CSF transformation uses text signatures"); h.update(data); } } -- cgit v1.2.3