Beginning of N@S solution using CoinbaseGuard CC

This commit is contained in:
miketout
2018-10-02 19:49:54 -07:00
parent c68ca1a225
commit 8a727a26a7
49 changed files with 832 additions and 62 deletions

View File

@@ -86,6 +86,14 @@ CScript CCSig(const CC *cond)
return CScript() << ffill;
}
std::vector<unsigned char> CCSigVec(const CC *cond)
{
unsigned char buf[10000];
size_t len = cc_fulfillmentBinary(cond, buf, 10000);
auto ffill = std::vector<unsigned char>(buf, buf+len);
ffill.push_back(1); // SIGHASH_ALL
return ffill;
}
std::string CCShowStructure(CC *cond)
{