@@ -21,7 +21,9 @@ use crate::{
21
21
#[ cfg( feature = "hashes" ) ]
22
22
use crate :: { hashes, ThirtyTwoByteHash } ;
23
23
24
- /// Secret 256-bit key used as `x` in an ECDSA signature.
24
+ /// Secret key - a 256-bit key used to create ECDSA and Taproot signatures.
25
+ ///
26
+ /// This value should be generated using a [cryptographically secure pseudorandom number generator].
25
27
///
26
28
/// # Side channel attacks
27
29
///
@@ -50,6 +52,7 @@ use crate::{hashes, ThirtyTwoByteHash};
50
52
/// ```
51
53
/// [`bincode`]: https://docs.rs/bincode
52
54
/// [`cbor`]: https://docs.rs/cbor
55
+ /// [cryptographically secure pseudorandom number generator]: https://en.wikipedia.org/wiki/Cryptographically_secure_pseudorandom_number_generator
53
56
#[ derive( Copy , Clone ) ]
54
57
pub struct SecretKey ( [ u8 ; constants:: SECRET_KEY_SIZE ] ) ;
55
58
impl_display_secret ! ( SecretKey ) ;
@@ -117,7 +120,7 @@ impl str::FromStr for SecretKey {
117
120
}
118
121
}
119
122
120
- /// A Secp256k1 public key, used for verification of signatures.
123
+ /// Public key - used to verify ECDSA signatures and to do Taproot tweaks .
121
124
///
122
125
/// # Serde support
123
126
///
@@ -1082,7 +1085,7 @@ impl CPtr for KeyPair {
1082
1085
fn as_mut_c_ptr ( & mut self ) -> * mut Self :: Target { & mut self . 0 }
1083
1086
}
1084
1087
1085
- /// An x-only public key, used for verification of schnorr signatures and serialized according to BIP-340.
1088
+ /// An x-only public key, used for verification of Taproot signatures and serialized according to BIP-340.
1086
1089
///
1087
1090
/// # Serde support
1088
1091
///
0 commit comments