diff options
author | Pieter Wuille <pieter@wuille.net> | 2021-04-23 11:35:15 -0700 |
---|---|---|
committer | Pieter Wuille <pieter@wuille.net> | 2021-04-23 11:35:15 -0700 |
commit | a5a447a352463c7b75752aa08b6d9cb46aa051ea (patch) | |
tree | 16b3dcf91f6f1fe7b8e9ec62ed76b12631edbf6f /src/secp256k1/include/secp256k1_extrakeys.h | |
parent | cabb5661234f8d832dbc3b65bf80b0acc02db0a0 (diff) | |
parent | bdca9bcb6c9379707d09c63f02326884befbefb2 (diff) | |
download | bitcoin-a5a447a352463c7b75752aa08b6d9cb46aa051ea.tar.xz |
Update libsecp256k1 subtree to latest upstream master
Diffstat (limited to 'src/secp256k1/include/secp256k1_extrakeys.h')
-rw-r--r-- | src/secp256k1/include/secp256k1_extrakeys.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/secp256k1/include/secp256k1_extrakeys.h b/src/secp256k1/include/secp256k1_extrakeys.h index 0c5dff2c94..6fc7b290f8 100644 --- a/src/secp256k1/include/secp256k1_extrakeys.h +++ b/src/secp256k1/include/secp256k1_extrakeys.h @@ -165,6 +165,19 @@ SECP256K1_API SECP256K1_WARN_UNUSED_RESULT int secp256k1_keypair_create( const unsigned char *seckey ) SECP256K1_ARG_NONNULL(1) SECP256K1_ARG_NONNULL(2) SECP256K1_ARG_NONNULL(3); +/** Get the secret key from a keypair. + * + * Returns: 0 if the arguments are invalid. 1 otherwise. + * Args: ctx: pointer to a context object (cannot be NULL) + * Out: seckey: pointer to a 32-byte buffer for the secret key (cannot be NULL) + * In: keypair: pointer to a keypair (cannot be NULL) + */ +SECP256K1_API SECP256K1_WARN_UNUSED_RESULT int secp256k1_keypair_sec( + const secp256k1_context* ctx, + unsigned char *seckey, + const secp256k1_keypair *keypair +) SECP256K1_ARG_NONNULL(1) SECP256K1_ARG_NONNULL(2) SECP256K1_ARG_NONNULL(3); + /** Get the public key from a keypair. * * Returns: 0 if the arguments are invalid. 1 otherwise. |