aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/key.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/key.cpp b/src/key.cpp
index e5943af79a..a845ba13d1 100644
--- a/src/key.cpp
+++ b/src/key.cpp
@@ -227,6 +227,9 @@ public:
}
bool Verify(const uint256 &hash, const std::vector<unsigned char>& vchSig) {
+ if (vchSig.empty())
+ return false;
+
// New versions of OpenSSL will reject non-canonical DER signatures. de/re-serialize first.
unsigned char *norm_der = NULL;
ECDSA_SIG *norm_sig = ECDSA_SIG_new();