Permalink
Browse files

Make SCRIPT_VERIFY_STRICTENC mandatory

  • Loading branch information...
zander committed Jul 30, 2017
1 parent 5385cab commit c5adb3a733ab7c9aae059140b0fea98cfe175962
Showing with 5 additions and 0 deletions.
  1. +5 −0 src/script/interpreter.cpp
@@ -1417,6 +1417,11 @@ bool VerifyScript(const CScript& scriptSig, const CScript& scriptPubKey, unsigne
{
set_error(serror, SCRIPT_ERR_UNKNOWN_ERROR);
// If FORKID is enabled, we also ensure strict encoding.
if (flags & SCRIPT_ENABLE_SIGHASH_FORKID) {
flags |= SCRIPT_VERIFY_STRICTENC;
}
if ((flags & SCRIPT_VERIFY_SIGPUSHONLY) != 0 && !scriptSig.IsPushOnly()) {
return set_error(serror, SCRIPT_ERR_SIG_PUSHONLY);
}

0 comments on commit c5adb3a

Please sign in to comment.