From 00b944e30ae158481ad0b28a0bbc0939ef5466e8 Mon Sep 17 00:00:00 2001 From: Adam Wick Date: Mon, 4 Feb 2019 19:25:57 -0800 Subject: [PATCH] Remove From requirement on the k-generator. --- src/dsa/rfc6979.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/dsa/rfc6979.rs b/src/dsa/rfc6979.rs index c81ef20..365c647 100644 --- a/src/dsa/rfc6979.rs +++ b/src/dsa/rfc6979.rs @@ -1,4 +1,4 @@ -use cryptonum::unsigned::{CryptoNum,Decoder,Encoder,U512}; +use cryptonum::unsigned::{CryptoNum,Decoder,Encoder}; use digest::{BlockInput,Digest,FixedOutput,Input,Reset}; use digest::generic_array::ArrayLength; use hmac::{Hmac,Mac}; @@ -27,7 +27,7 @@ impl DSASignature pub struct KIterator where H: BlockInput + Clone + Default + Digest + FixedOutput + Input + Reset, - N: Clone + Decoder + Encoder + From + PartialOrd + Shr, + N: Clone + Decoder + Encoder + PartialOrd + Shr, Hmac: Mac { hmac_k: Hmac, @@ -39,7 +39,7 @@ pub struct KIterator impl KIterator where H: BlockInput + Clone + Default + Digest + FixedOutput + Input + Reset, - N: Clone + Decoder + Encoder + From + PartialOrd + Shr + Sub, + N: Clone + Decoder + Encoder + PartialOrd + Shr + Sub, Hmac: Mac { pub fn new(h1: &[u8], qlen: usize, q: &N, x: &N) -> KIterator @@ -128,7 +128,7 @@ impl KIterator impl Iterator for KIterator where H: BlockInput + Clone + Default + Digest + FixedOutput + Input + Reset, - N: Clone + CryptoNum + Decoder + Encoder + From + PartialOrd + Shr, + N: Clone + CryptoNum + Decoder + Encoder + PartialOrd + Shr, Hmac: Mac { type Item = N;