diff options
author | Andrew Chow <achow101-github@achow101.com> | 2019-06-17 15:47:12 -0400 |
---|---|---|
committer | Andrew Chow <achow101-github@achow101.com> | 2019-07-09 16:20:18 -0400 |
commit | 16f8096e911e4d59292240a17e2d4004f0500b9e (patch) | |
tree | d5d878d2f0384ef78dedf5f4ae3f95512e4fd416 /src/script/sign.h | |
parent | d9becff4e13da8e182631baa79b9794c03d44434 (diff) |
Move KeyOriginInfo to its own header file
Diffstat (limited to 'src/script/sign.h')
-rw-r--r-- | src/script/sign.h | 26 |
1 files changed, 1 insertions, 25 deletions
diff --git a/src/script/sign.h b/src/script/sign.h index 9df4dc98fa..7b4627cca2 100644 --- a/src/script/sign.h +++ b/src/script/sign.h @@ -10,6 +10,7 @@ #include <hash.h> #include <pubkey.h> #include <script/interpreter.h> +#include <script/keyorigin.h> #include <streams.h> class CKey; @@ -20,31 +21,6 @@ class CTransaction; struct CMutableTransaction; -struct KeyOriginInfo -{ - unsigned char fingerprint[4]; //!< First 32 bits of the Hash160 of the public key at the root of the path - std::vector<uint32_t> path; - - friend bool operator==(const KeyOriginInfo& a, const KeyOriginInfo& b) - { - return std::equal(std::begin(a.fingerprint), std::end(a.fingerprint), std::begin(b.fingerprint)) && a.path == b.path; - } - - ADD_SERIALIZE_METHODS; - template <typename Stream, typename Operation> - inline void SerializationOp(Stream& s, Operation ser_action) - { - READWRITE(fingerprint); - READWRITE(path); - } - - void clear() - { - memset(fingerprint, 0, 4); - path.clear(); - } -}; - /** An interface to be implemented by keystores that support signing. */ class SigningProvider { |