use the same message magic everywhere (to hash)

This commit is contained in:
Miguel Freitas 2013-08-04 11:36:44 -03:00
parent 2bd0f7de12
commit 78e97ac9dc
2 changed files with 3 additions and 5 deletions

View File

@ -57,7 +57,7 @@ multimap<uint256, CBlock*> mapOrphanBlocksByPrev;
// Constant stuff for coinbase transactions we create:
CScript COINBASE_FLAGS;
const string strMessageMagic = "Bitcoin Signed Message:\n";
const string strMessageMagic = "twister Signed Message:\n";
double dHashesPerSec = 0.0;
int64 nHPSTimerStart = 0;

View File

@ -5,8 +5,6 @@
#include <boost/filesystem.hpp>
const string strTwisterMessageMagic = "twister Signed Message:\n";
twister::twister()
{
}
@ -210,7 +208,7 @@ std::string createSignature(std::string &strMessage, std::string &strUsername)
}
CHashWriter ss(SER_GETHASH, 0);
ss << strTwisterMessageMagic;
ss << strMessageMagic;
ss << strMessage;
vector<unsigned char> vchSig;
@ -260,7 +258,7 @@ bool verifySignature(std::string const &strMessage, std::string const &strUserna
(const unsigned char*)strSign.data() + strSign.size());
CHashWriter ss(SER_GETHASH, 0);
ss << strTwisterMessageMagic;
ss << strMessageMagic;
ss << strMessage;
CPubKey pubkeyRec;