Skip to content

Commit

Permalink
Correctly report high-S violations
Browse files Browse the repository at this point in the history
  • Loading branch information
sipa committed Feb 10, 2016
1 parent 11d74f6 commit 9d95187
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/script/interpreter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,10 @@ bool static IsLowDERSignature(const valtype &vchSig, ScriptError* serror) {
return set_error(serror, SCRIPT_ERR_SIG_DER);
}
std::vector<unsigned char> vchSigCopy(vchSig.begin(), vchSig.begin() + vchSig.size() - 1);
return CPubKey::CheckLowS(vchSigCopy);
if (!CPubKey::CheckLowS(vchSigCopy)) {
return set_error(serror, SCRIPT_ERR_SIG_HIGH_S);
}
return true;
}

bool static IsDefinedHashtypeSignature(const valtype &vchSig) {
Expand Down

0 comments on commit 9d95187

Please sign in to comment.