File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed
Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 5151 strategy :
5252 matrix :
5353 rust :
54- - 1.85.0 # Minimum Rust version the tests pass on
54+ - 1.85.0 # MSRV
5555 - stable
5656 steps :
5757 - uses : actions/checkout@v4
Original file line number Diff line number Diff line change @@ -135,6 +135,21 @@ pub trait RandomizedDigestSigner<D: Digest, S> {
135135 ) -> Result < S , Error > ;
136136}
137137
138+ #[ cfg( all( feature = "digest" , feature = "rand_core" ) ) ]
139+ impl < S , T > RandomizedSigner < S > for T
140+ where
141+ S : PrehashSignature ,
142+ T : RandomizedDigestSigner < S :: Digest , S > ,
143+ {
144+ fn try_sign_with_rng < R : TryCryptoRng + ?Sized > (
145+ & self ,
146+ rng : & mut R ,
147+ msg : & [ u8 ] ,
148+ ) -> Result < S , Error > {
149+ self . try_sign_digest_with_rng ( rng, S :: Digest :: new_with_prefix ( msg) )
150+ }
151+ }
152+
138153/// Sign the provided message bytestring using `&mut Self` (e.g. an evolving
139154/// cryptographic key such as a stateful hash-based signature), and a per-signature
140155/// randomizer, returning a digital signature.
You can’t perform that action at this time.
0 commit comments