* make interface for getting tx safer in Eval

* restrict lengths in cryptoconditions to avoid ridiculous situations
This commit is contained in:
Scott Sadler
2018-04-06 14:35:46 -03:00
parent 56cf273faf
commit 4729632250
7 changed files with 47 additions and 35 deletions

View File

@@ -41,9 +41,10 @@ public:
/*
* IO functions
*/
virtual bool GetTx(const uint256 &hash, CTransaction &txOut, uint256 &hashBlock, bool fAllowSlow) const;
virtual bool GetTxUnconfirmed(const uint256 &hash, CTransaction &txOut, uint256 &hashBlock) const;
virtual bool GetTxConfirmed(const uint256 &hash, CTransaction &txOut, CBlockIndex &block) const;
virtual unsigned int GetCurrentHeight() const;
virtual bool GetSpends(uint256 hash, std::vector<CTransaction> &spends) const;
virtual bool GetSpendsConfirmed(uint256 hash, std::vector<CTransaction> &spends) const;
virtual bool GetBlock(uint256 hash, CBlockIndex& blockIdx) const;
virtual int32_t GetNotaries(uint8_t pubkeys[64][33], int32_t height, uint32_t timestamp) const;
virtual bool GetNotarisationData(uint256 notarisationHash, NotarisationData &data) const;