@@ -18,7 +18,7 @@ use crate::keys::{
1818 PseudonymGlobalPublicKey , PseudonymSessionPublicKey , PseudonymSessionSecretKey ,
1919} ;
2020use derive_more:: { Deref , From } ;
21- use rand_core:: { CryptoRng , RngCore } ;
21+ use rand_core:: { CryptoRng , Rng } ;
2222#[ cfg( feature = "serde" ) ]
2323use serde:: { Deserialize , Deserializer , Serialize , Serializer } ;
2424use std:: io:: { Error , ErrorKind } ;
@@ -444,7 +444,7 @@ impl Encryptable for LongPseudonym {
444444
445445 fn encrypt < R > ( & self , public_key : & Self :: PublicKeyType , rng : & mut R ) -> Self :: EncryptedType
446446 where
447- R : RngCore + CryptoRng ,
447+ R : Rng + CryptoRng ,
448448 {
449449 let encrypted_blocks = self
450450 . blocks ( )
@@ -461,7 +461,7 @@ impl Encryptable for LongPseudonym {
461461 rng : & mut R ,
462462 ) -> Self :: EncryptedType
463463 where
464- R : RngCore + CryptoRng ,
464+ R : Rng + CryptoRng ,
465465 {
466466 let encrypted_blocks = self
467467 . blocks ( )
@@ -497,7 +497,7 @@ impl Encryptable for LongAttribute {
497497
498498 fn encrypt < R > ( & self , public_key : & Self :: PublicKeyType , rng : & mut R ) -> Self :: EncryptedType
499499 where
500- R : RngCore + CryptoRng ,
500+ R : Rng + CryptoRng ,
501501 {
502502 let encrypted_blocks = self
503503 . blocks ( )
@@ -514,7 +514,7 @@ impl Encryptable for LongAttribute {
514514 rng : & mut R ,
515515 ) -> Self :: EncryptedType
516516 where
517- R : RngCore + CryptoRng ,
517+ R : Rng + CryptoRng ,
518518 {
519519 let encrypted_blocks = self
520520 . blocks ( )
@@ -636,7 +636,7 @@ impl Encrypted for LongEncryptedPseudonym {
636636 #[ cfg( feature = "elgamal3" ) ]
637637 fn rerandomize < R > ( & self , rng : & mut R ) -> Self
638638 where
639- R : RngCore + CryptoRng ,
639+ R : Rng + CryptoRng ,
640640 {
641641 let r = ScalarNonZero :: random ( rng) ;
642642 self . rerandomize_known ( & RerandomizeFactor ( r) )
@@ -649,7 +649,7 @@ impl Encrypted for LongEncryptedPseudonym {
649649 rng : & mut R ,
650650 ) -> Self
651651 where
652- R : RngCore + CryptoRng ,
652+ R : Rng + CryptoRng ,
653653 {
654654 let r = ScalarNonZero :: random ( rng) ;
655655 self . rerandomize_known ( public_key, & RerandomizeFactor ( r) )
@@ -733,7 +733,7 @@ impl Encrypted for LongEncryptedAttribute {
733733 #[ cfg( feature = "elgamal3" ) ]
734734 fn rerandomize < R > ( & self , rng : & mut R ) -> Self
735735 where
736- R : RngCore + CryptoRng ,
736+ R : Rng + CryptoRng ,
737737 {
738738 let r = ScalarNonZero :: random ( rng) ;
739739 self . rerandomize_known ( & RerandomizeFactor ( r) )
@@ -746,7 +746,7 @@ impl Encrypted for LongEncryptedAttribute {
746746 rng : & mut R ,
747747 ) -> Self
748748 where
749- R : RngCore + CryptoRng ,
749+ R : Rng + CryptoRng ,
750750 {
751751 let r = ScalarNonZero :: random ( rng) ;
752752 self . rerandomize_known ( public_key, & RerandomizeFactor ( r) )
0 commit comments