aboutsummaryrefslogtreecommitdiff
path: root/src/script/sign.cpp
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2018-07-14 19:19:44 -0700
committerAndrew Chow <achow101-github@achow101.com>2018-08-09 18:39:56 -0700
commit48b1473c898129a99212e2db36c61cf93625ea17 (patch)
tree5450731f5b800cec8548802e28deccfd45cc946a /src/script/sign.cpp
parent18dfea0dd082af18dfb02981b7ee1cd44d514388 (diff)
downloadbitcoin-48b1473c898129a99212e2db36c61cf93625ea17.tar.xz
Use 71 byte signature for DUMMY_SIGNATURE_CREATOR
Changes DUMMY_SIGNATURE_CREATOR to create 71 byte dummy signatures. Update comments to reflect this change
Diffstat (limited to 'src/script/sign.cpp')
-rw-r--r--src/script/sign.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/script/sign.cpp b/src/script/sign.cpp
index fa09adbaf8..c103e3c2f0 100644
--- a/src/script/sign.cpp
+++ b/src/script/sign.cpp
@@ -423,16 +423,16 @@ public:
bool CreateSig(const SigningProvider& provider, std::vector<unsigned char>& vchSig, const CKeyID& keyid, const CScript& scriptCode, SigVersion sigversion) const override
{
// Create a dummy signature that is a valid DER-encoding
- vchSig.assign(72, '\000');
+ vchSig.assign(71, '\000');
vchSig[0] = 0x30;
- vchSig[1] = 69;
+ vchSig[1] = 68;
vchSig[2] = 0x02;
- vchSig[3] = 33;
+ vchSig[3] = 32;
vchSig[4] = 0x01;
- vchSig[4 + 33] = 0x02;
- vchSig[5 + 33] = 32;
- vchSig[6 + 33] = 0x01;
- vchSig[6 + 33 + 32] = SIGHASH_ALL;
+ vchSig[4 + 32] = 0x02;
+ vchSig[5 + 32] = 32;
+ vchSig[6 + 32] = 0x01;
+ vchSig[6 + 32 + 32] = SIGHASH_ALL;
return true;
}
};