aboutsummaryrefslogtreecommitdiff
path: root/src/key.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/key.cpp')
-rw-r--r--src/key.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/key.cpp b/src/key.cpp
index 9d982fc44f..c17f6a0ae2 100644
--- a/src/key.cpp
+++ b/src/key.cpp
@@ -163,6 +163,12 @@ void CKey::MakeNewKey(bool fCompressedIn) {
fCompressed = fCompressedIn;
}
+bool CKey::Negate()
+{
+ assert(fValid);
+ return secp256k1_ec_privkey_negate(secp256k1_context_sign, keydata.data());
+}
+
CPrivKey CKey::GetPrivKey() const {
assert(fValid);
CPrivKey privkey;