Lines Matching refs:KeyRejected
96 ) -> Result<Self, error::KeyRejected> { in positive_minimal_width_from_be_bytes() argument
100 return Err(error::KeyRejected::invalid_encoding()); in positive_minimal_width_from_be_bytes()
108 .map_err(|error::Unspecified| error::KeyRejected::unexpected_error())?; in positive_minimal_width_from_be_bytes()
235 ) -> Result<(Self, bits::BitLength), error::KeyRejected> { in from_be_bytes_with_bit_length() argument
242 ) -> Result<(Self, bits::BitLength), error::KeyRejected> { in from_nonnegative_with_bit_length() argument
250 fn from_boxed_limbs(n: BoxedLimbs<M>) -> Result<(Self, bits::BitLength), error::KeyRejected> { in from_boxed_limbs() argument
252 return Err(error::KeyRejected::too_large()); in from_boxed_limbs()
255 return Err(error::KeyRejected::unexpected_error()); in from_boxed_limbs()
258 return Err(error::KeyRejected::invalid_component()); in from_boxed_limbs()
261 return Err(error::KeyRejected::unexpected_error()); in from_boxed_limbs()
446 pub fn into_modulus<MM>(self) -> Result<Modulus<MM>, error::KeyRejected> { in into_modulus() argument
663 ) -> Result<Self, error::KeyRejected> { in from_be_bytes() argument
665 return Err(error::KeyRejected::too_large()); in from_be_bytes()
667 let value = input.read_all(error::KeyRejected::invalid_encoding(), |input| { in from_be_bytes()
671 return Err(error::KeyRejected::invalid_encoding()); in from_be_bytes()
677 .map_err(|untrusted::EndOfInput| error::KeyRejected::invalid_encoding())?; in from_be_bytes()
690 return Err(error::KeyRejected::invalid_component()); in from_be_bytes()
695 return Err(error::KeyRejected::invalid_component()); in from_be_bytes()
698 return Err(error::KeyRejected::too_small()); in from_be_bytes()
701 return Err(error::KeyRejected::too_large()); in from_be_bytes()