mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 06:58:57 +01:00
Specify ECDSA constant sizes as constants
This commit is contained in:
12
src/key.h
12
src/key.h
@@ -1,5 +1,6 @@
|
||||
// Copyright (c) 2009-2010 Satoshi Nakamoto
|
||||
// Copyright (c) 2009-2016 The Bitcoin Core developers
|
||||
// Copyright (c) 2017 The Zcash developers
|
||||
// Distributed under the MIT software license, see the accompanying
|
||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
@@ -17,17 +18,18 @@
|
||||
|
||||
/**
|
||||
* secp256k1:
|
||||
* const unsigned int PRIVATE_KEY_SIZE = 279;
|
||||
* const unsigned int PUBLIC_KEY_SIZE = 65;
|
||||
* const unsigned int SIGNATURE_SIZE = 72;
|
||||
*
|
||||
*/
|
||||
const unsigned int PRIVATE_KEY_SIZE = 279;
|
||||
const unsigned int COMPRESSED_PRIVATE_KEY_SIZE = 214;
|
||||
/**
|
||||
* see www.keylength.com
|
||||
* script supports up to 75 for single byte push
|
||||
*/
|
||||
|
||||
/**
|
||||
* secure_allocator is defined in allocators.h
|
||||
* CPrivKey is a serialized private key, with all parameters included (279 bytes)
|
||||
* CPrivKey is a serialized private key, with all parameters included
|
||||
* (PRIVATE_KEY_SIZE bytes)
|
||||
*/
|
||||
typedef std::vector<unsigned char, secure_allocator<unsigned char> > CPrivKey;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user