cryptonote: rework block blob size sanity check

Use the actual block weight limit, assuming that weight is always
greater or equal to size
This commit is contained in:
moneromooo-monero 2019-04-04 00:15:57 +00:00
parent fe3403c8f0
commit 089c7637a6
No known key found for this signature in database
GPG key ID: 686F07454D6CEFC3
10 changed files with 100 additions and 16 deletions

View file

@ -37,9 +37,9 @@
#define CRYPTONOTE_DNS_TIMEOUT_MS 20000
#define CRYPTONOTE_MAX_BLOCK_NUMBER 500000000
#define CRYPTONOTE_MAX_BLOCK_SIZE 500000000 // block header blob limit, never used!
#define CRYPTONOTE_GETBLOCKTEMPLATE_MAX_BLOCK_SIZE 196608 //size of block (bytes) that is the maximum that miners will produce
#define CRYPTONOTE_MAX_TX_SIZE 1000000000
#define CRYPTONOTE_MAX_TX_SIZE 1000000
#define CRYPTONOTE_MAX_TX_PER_BLOCK 0x10000000
#define CRYPTONOTE_PUBLIC_ADDRESS_TEXTBLOB_VER 0
#define CRYPTONOTE_MINED_MONEY_UNLOCK_WINDOW 60
#define CURRENT_TRANSACTION_VERSION 2