From fd42c4877764f09e75dbc2c81764a5df9782ea20 Mon Sep 17 00:00:00 2001 From: wanderer Date: Mon, 9 Mar 2015 21:24:11 -0400 Subject: [PATCH 1/6] fix json, added package.json --- genesis.json | 48 ++++++++--- index.js | 4 + package.json | 22 +++++ params.json | 228 +++++++++++++++++++++++++++++++++++++++------------ 4 files changed, 238 insertions(+), 64 deletions(-) create mode 100644 index.js create mode 100644 package.json diff --git a/genesis.json b/genesis.json index 9c6d09f..ff2f9b4 100644 --- a/genesis.json +++ b/genesis.json @@ -1,14 +1,38 @@ { - "0000000000000000000000000000000000000001": { "wei": "1" }, - "0000000000000000000000000000000000000002": { "wei": "1" }, - "0000000000000000000000000000000000000003": { "wei": "1" }, - "0000000000000000000000000000000000000004": { "wei": "1" }, - "dbdbdb2cbd23b783741e8d7fcf51e459b497e4a6": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, - "e6716f9544a56c530d868e4bfbacb172315bdead": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, - "b9c015918bdaba24b4ff057a92a3873d6eb201be": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, - "1a26338f0d905e295fccb71fa9ea849ffa12aaf4": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, - "2ef47100e0787b915105fd5e3f4ff6752079d5cb": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, - "cd2a3d9f938e13cd947ec05abc7fe734df8dd826": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, - "6c386a4b26f73c802f34673f7248bb118f97424a": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, - "e4157b34ea9615cfbde6b4fda419828124b70c78": { "wei": "1606938044258990275541962092341162602522202993782792835301376" }, + "0000000000000000000000000000000000000001": { + "wei": "1" + }, + "0000000000000000000000000000000000000002": { + "wei": "1" + }, + "0000000000000000000000000000000000000003": { + "wei": "1" + }, + "0000000000000000000000000000000000000004": { + "wei": "1" + }, + "dbdbdb2cbd23b783741e8d7fcf51e459b497e4a6": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + }, + "e6716f9544a56c530d868e4bfbacb172315bdead": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + }, + "b9c015918bdaba24b4ff057a92a3873d6eb201be": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + }, + "1a26338f0d905e295fccb71fa9ea849ffa12aaf4": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + }, + "2ef47100e0787b915105fd5e3f4ff6752079d5cb": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + }, + "cd2a3d9f938e13cd947ec05abc7fe734df8dd826": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + }, + "6c386a4b26f73c802f34673f7248bb118f97424a": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + }, + "e4157b34ea9615cfbde6b4fda419828124b70c78": { + "wei": "1606938044258990275541962092341162602522202993782792835301376" + } } diff --git a/index.js b/index.js new file mode 100644 index 0000000..ae07f87 --- /dev/null +++ b/index.js @@ -0,0 +1,4 @@ +module.exports = { + allotments: require('./genesis.json'), + fees: require('./params.json') +}; diff --git a/package.json b/package.json new file mode 100644 index 0000000..db359e8 --- /dev/null +++ b/package.json @@ -0,0 +1,22 @@ +{ + "name": "ethereum-common", + "version": "0.0.1", + "description": "Resources common to all Ethereum implementations", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "repository": { + "type": "git", + "url": "https://github.com/ethereum/common.git" + }, + "keywords": [ + "ethereum" + ], + "author": "", + "license": "MIT", + "bugs": { + "url": "https://github.com/ethereum/common/issues" + }, + "homepage": "https://github.com/ethereum/common" +} diff --git a/params.json b/params.json index 7ee5f21..80aec79 100644 --- a/params.json +++ b/params.json @@ -1,56 +1,180 @@ { - "genesisGasLimit": { "v": 3141592, "d": "Gas limit of the Genesis block." }, - "minGasLimit": { "v": 125000, "d": "Minimum the gas limit may ever be." }, - "gasLimitBoundDivisor": { "v": 1024, "d": "The bound divisor of the gas limit, used in update calculations." }, - "genesisDifficulty": { "v": 131072, "d": "Difficulty of the Genesis block." }, - "minimumDifficulty": { "v": 131072, "d": "The minimum that the difficulty may ever be." }, - "difficultyBoundDivisor": { "v": 2048, "d": "The bound divisor of the difficulty, used in the update calculations." }, - "durationLimit": { "v": 8, "d": "The decision boundary on the blocktime duration used to determine whether difficulty should go up or not." }, - "maximumExtraDataSize": { "v": 1024, "d": "Maximum size extra data may be after Genesis." }, - "epochDuration": { "v": 30000, "d": "Duration between proof-of-work epochs." }, - "stackLimit": { "v": 1024, "d": "Maximum size of VM stack allowed." }, - "callCreateDepth": { "v": 1024, "d": "Maximum depth of call/create stack." }, + "genesisGasLimit": { + "v": 3141592, + "d": "Gas limit of the Genesis block." + }, + "minGasLimit": { + "v": 125000, + "d": "Minimum the gas limit may ever be." + }, + "gasLimitBoundDivisor": { + "v": 1024, + "d": "The bound divisor of the gas limit, used in update calculations." + }, + "genesisDifficulty": { + "v": 131072, + "d": "Difficulty of the Genesis block." + }, + "minimumDifficulty": { + "v": 131072, + "d": "The minimum that the difficulty may ever be." + }, + "difficultyBoundDivisor": { + "v": 2048, + "d": "The bound divisor of the difficulty, used in the update calculations." + }, + "durationLimit": { + "v": 8, + "d": "The decision boundary on the blocktime duration used to determine whether difficulty should go up or not." + }, + "maximumExtraDataSize": { + "v": 1024, + "d": "Maximum size extra data may be after Genesis." + }, + "epochDuration": { + "v": 30000, + "d": "Duration between proof-of-work epochs." + }, + "stackLimit": { + "v": 1024, + "d": "Maximum size of VM stack allowed." + }, + "callCreateDepth": { + "v": 1024, + "d": "Maximum depth of call/create stack." + }, - "tierStepGas": { "v": [ 0, 2, 3, 5, 8, 10, 20 ], "d": "Once per operation, for a selection of them." }, - "expGas": { "v": 10, "d": "Once per EXP instuction." }, - "expByteGas": { "v": 10, "d": "Times ceil(log256(exponent)) for the EXP instruction." }, + "tierStepGas": { + "v": [0, 2, 3, 5, 8, 10, 20], + "d": "Once per operation, for a selection of them." + }, + "expGas": { + "v": 10, + "d": "Once per EXP instuction." + }, + "expByteGas": { + "v": 10, + "d": "Times ceil(log256(exponent)) for the EXP instruction." + }, + "sha3Gas": { + "v": 30, + "d": "Once per SHA3 operation." + }, + "sha3WordGas": { + "v": 6, + "d": "Once per word of the SHA3 operation's data." + }, + "sloadGas": { + "v": 50, + "d": "Once per SLOAD operation." + }, + "sstoreSetGas": { + "v": 20000, + "d": "Once per SSTORE operation if the zeroness changes from zero." + }, + "sstoreResetGas": { + "v": 5000, + "d": "Once per SSTORE operation if the zeroness does not change from zero." + }, + "sstoreRefundGas": { + "v": 15000, + "d": "Once per SSTORE operation if the zeroness changes to zero." + }, + "jumpdestGas": { + "v": 1, + "d": "Refunded gas, once per SSTORE operation if the zeroness changes to zero." + }, + "logGas": { + "v": 375, + "d": "Per LOG* operation." + }, + "logDataGas": { + "v": 8, + "d": "Per byte in a LOG* operation's data." + }, + "logTopicGas": { + "v": 375, + "d": "Multiplied by the * of the LOG*, per LOG transaction. e.g. LOG0 incurs 0 * c_txLogTopicGas, LOG4 incurs 4 * c_txLogTopicGas." + }, + "createGas": { + "v": 32000, + "d": "Once per CREATE operation & contract-creation transaction." + }, + "callGas": { + "v": 40, + "d": "Once per CALL operation & message call transaction." + }, + "callStipend": { + "v": 2300, + "d": "Free gas given at beginning of call." + }, + "callValueTransferGas": { + "v": 9000, + "d": "Paid for CALL when the value transfor is non-zero." + }, + "callNewAccountGas": { + "v": 25000, + "d": "Paid for CALL when the destination address didn't exist prior." + }, - "sha3Gas": { "v": 30, "d": "Once per SHA3 operation." }, - "sha3WordGas": { "v": 6, "d": "Once per word of the SHA3 operation's data." }, - "sloadGas": { "v": 50, "d": "Once per SLOAD operation." }, - "sstoreSetGas": { "v": 20000, "d": "Once per SSTORE operation if the zeroness changes from zero." }, - "sstoreResetGas": { "v": 5000, "d": "Once per SSTORE operation if the zeroness does not change from zero." }, - "sstoreRefundGas": { "v": 15000, "d": "Once per SSTORE operation if the zeroness changes to zero." }, - "jumpdestGas": { "v": 1, "d": "Refunded gas, once per SSTORE operation if the zeroness changes to zero." }, - - "logGas": { "v": 375, "d": "Per LOG* operation." }, - "logDataGas": { "v": 8, "d": "Per byte in a LOG* operation's data." }, - "logTopicGas": { "v": 375, "d": "Multiplied by the * of the LOG*, per LOG transaction. e.g. LOG0 incurs 0 * c_txLogTopicGas, LOG4 incurs 4 * c_txLogTopicGas." }, - - "createGas": { "v": 32000, "d": "Once per CREATE operation & contract-creation transaction." }, - - "callGas": { "v": 40, "d": "Once per CALL operation & message call transaction." }, - "callStipend": { "v": 2300, "d": "Free gas given at beginning of call." }, - "callValueTransferGas": { "v": 9000, "d": "Paid for CALL when the value transfor is non-zero." }, - "callNewAccountGas": { "v": 25000, "d": "Paid for CALL when the destination address didn't exist prior." }, - - "suicideRefundGas": { "v": 24000, "d": "Refunded following a suicide operation." }, - - "memoryGas": { "v": 3, "d": "Times the address of the (highest referenced byte in memory + 1). NOTE: referencing happens on read, write and in instructions such as RETURN and CALL." }, "quadCoeffDiv": { "v": 512, "d": "Divisor for the quadratic particle of the memory cost equation." }, - - "createDataGas": { "v": 200, "d": "" }, - "txGas": { "v": 21000, "d": "Per transaction. NOTE: Not payable on data of calls between transactions." }, - "txDataZeroGas": { "v": 4, "d": "Per byte of data attached to a transaction that equals zero. NOTE: Not payable on data of calls between transactions." }, - "txDataNonZeroGas": { "v": 68, "d": "Per byte of data attached to a transaction that is not equal to zero. NOTE: Not payable on data of calls between transactions." }, - - "copyGas": { "v": 3, "d": "Multiplied by the number of 32-byte words that are copied (round up) for any *COPY operation and added." }, - - "ecrecoverGas": { "v": 3000, "d": "" }, - "sha256Gas": { "v": 60, "d": "" }, - "sha256WordGas": { "v": 12, "d": "" }, - "ripemd160Gas": { "v": 600, "d": "" }, - "ripemd160WordGas": { "v": 120, "d": "" }, - "identityGas": { "v": 15, "d": "" }, - "identityWordGas": { "v": 3, "d": ""} + "suicideRefundGas": { + "v": 24000, + "d": "Refunded following a suicide operation." + }, + "memoryGas": { + "v": 3, + "d": "Times the address of the (highest referenced byte in memory + 1). NOTE: referencing happens on read, write and in instructions such as RETURN and CALL." + }, + "quadCoeffDiv": { + "v": 512, + "d": "Divisor for the quadratic particle of the memory cost equation." + }, + "createDataGas": { + "v": 200, + "d": "" + }, + "txGas": { + "v": 21000, + "d": "Per transaction. NOTE: Not payable on data of calls between transactions." + }, + "txDataZeroGas": { + "v": 4, + "d": "Per byte of data attached to a transaction that equals zero. NOTE: Not payable on data of calls between transactions." + }, + "txDataNonZeroGas": { + "v": 68, + "d": "Per byte of data attached to a transaction that is not equal to zero. NOTE: Not payable on data of calls between transactions." + }, + "copyGas": { + "v": 3, + "d": "Multiplied by the number of 32-byte words that are copied (round up) for any *COPY operation and added." + }, + "ecrecoverGas": { + "v": 3000, + "d": "" + }, + "sha256Gas": { + "v": 60, + "d": "" + }, + "sha256WordGas": { + "v": 12, + "d": "" + }, + "ripemd160Gas": { + "v": 600, + "d": "" + }, + "ripemd160WordGas": { + "v": 120, + "d": "" + }, + "identityGas": { + "v": 15, + "d": "" + }, + "identityWordGas": { + "v": 3, + "d": "" + } } - From e9ad077a08fd8f86e877d5c5011f67c73919489c Mon Sep 17 00:00:00 2001 From: wanderer Date: Mon, 16 Mar 2015 16:57:52 -0400 Subject: [PATCH 2/6] updated genesis --- genesis.json | 48 ++++++++++++------------------------------------ 1 file changed, 12 insertions(+), 36 deletions(-) diff --git a/genesis.json b/genesis.json index ff2f9b4..f320b23 100644 --- a/genesis.json +++ b/genesis.json @@ -1,38 +1,14 @@ { - "0000000000000000000000000000000000000001": { - "wei": "1" - }, - "0000000000000000000000000000000000000002": { - "wei": "1" - }, - "0000000000000000000000000000000000000003": { - "wei": "1" - }, - "0000000000000000000000000000000000000004": { - "wei": "1" - }, - "dbdbdb2cbd23b783741e8d7fcf51e459b497e4a6": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - }, - "e6716f9544a56c530d868e4bfbacb172315bdead": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - }, - "b9c015918bdaba24b4ff057a92a3873d6eb201be": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - }, - "1a26338f0d905e295fccb71fa9ea849ffa12aaf4": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - }, - "2ef47100e0787b915105fd5e3f4ff6752079d5cb": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - }, - "cd2a3d9f938e13cd947ec05abc7fe734df8dd826": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - }, - "6c386a4b26f73c802f34673f7248bb118f97424a": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - }, - "e4157b34ea9615cfbde6b4fda419828124b70c78": { - "wei": "1606938044258990275541962092341162602522202993782792835301376" - } + "0000000000000000000000000000000000000001": "1", + "0000000000000000000000000000000000000002": "1", + "0000000000000000000000000000000000000003": "1", + "0000000000000000000000000000000000000004": "1", + "dbdbdb2cbd23b783741e8d7fcf51e459b497e4a6": "1606938044258990275541962092341162602522202993782792835301376", + "e6716f9544a56c530d868e4bfbacb172315bdead": "1606938044258990275541962092341162602522202993782792835301376", + "b9c015918bdaba24b4ff057a92a3873d6eb201be": "1606938044258990275541962092341162602522202993782792835301376", + "1a26338f0d905e295fccb71fa9ea849ffa12aaf4": "1606938044258990275541962092341162602522202993782792835301376", + "2ef47100e0787b915105fd5e3f4ff6752079d5cb": "1606938044258990275541962092341162602522202993782792835301376", + "cd2a3d9f938e13cd947ec05abc7fe734df8dd826": "1606938044258990275541962092341162602522202993782792835301376", + "6c386a4b26f73c802f34673f7248bb118f97424a": "1606938044258990275541962092341162602522202993782792835301376", + "e4157b34ea9615cfbde6b4fda419828124b70c78": "1606938044258990275541962092341162602522202993782792835301376" } From 1f958ef3543cd8ea4794cbe033faaa544d47f552 Mon Sep 17 00:00:00 2001 From: wanderer Date: Mon, 16 Mar 2015 16:59:00 -0400 Subject: [PATCH 3/6] bump --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index db359e8..67cb002 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ethereum-common", - "version": "0.0.1", + "version": "0.0.2", "description": "Resources common to all Ethereum implementations", "main": "index.js", "scripts": { From c994835b21f0cf0e8712aae5ff3c123a3fa4c382 Mon Sep 17 00:00:00 2001 From: wanderer Date: Thu, 9 Apr 2015 16:05:54 -0400 Subject: [PATCH 4/6] added miner amounts --- params.json | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/params.json b/params.json index 80aec79..1a68856 100644 --- a/params.json +++ b/params.json @@ -176,5 +176,19 @@ "identityWordGas": { "v": 3, "d": "" + }, + "minerReward":{ + "v": "1500000000000000000", + "d": "the amount a miner get rewarded for mining a block" + + }, + "uncleReward":{ + "v": "1406250000000000000", + "d": "The amount of wei a miner of an uncle block gets for being inculded in the blockchain" + + }, + "nephewReward":{ + "v": "46875000000000000", + "d": "the amount a miner gets for inculding a uncle" } } From 4a7c0ab922a38cff09752bbbeb18cafb4423ce0f Mon Sep 17 00:00:00 2001 From: wanderer Date: Sat, 8 Aug 2015 01:14:58 +0000 Subject: [PATCH 5/6] bump package --- genesis.json | 14 -------------- index.js | 5 +---- package.json | 2 +- 3 files changed, 2 insertions(+), 19 deletions(-) delete mode 100644 genesis.json diff --git a/genesis.json b/genesis.json deleted file mode 100644 index f320b23..0000000 --- a/genesis.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "0000000000000000000000000000000000000001": "1", - "0000000000000000000000000000000000000002": "1", - "0000000000000000000000000000000000000003": "1", - "0000000000000000000000000000000000000004": "1", - "dbdbdb2cbd23b783741e8d7fcf51e459b497e4a6": "1606938044258990275541962092341162602522202993782792835301376", - "e6716f9544a56c530d868e4bfbacb172315bdead": "1606938044258990275541962092341162602522202993782792835301376", - "b9c015918bdaba24b4ff057a92a3873d6eb201be": "1606938044258990275541962092341162602522202993782792835301376", - "1a26338f0d905e295fccb71fa9ea849ffa12aaf4": "1606938044258990275541962092341162602522202993782792835301376", - "2ef47100e0787b915105fd5e3f4ff6752079d5cb": "1606938044258990275541962092341162602522202993782792835301376", - "cd2a3d9f938e13cd947ec05abc7fe734df8dd826": "1606938044258990275541962092341162602522202993782792835301376", - "6c386a4b26f73c802f34673f7248bb118f97424a": "1606938044258990275541962092341162602522202993782792835301376", - "e4157b34ea9615cfbde6b4fda419828124b70c78": "1606938044258990275541962092341162602522202993782792835301376" -} diff --git a/index.js b/index.js index ae07f87..15da2c4 100644 --- a/index.js +++ b/index.js @@ -1,4 +1 @@ -module.exports = { - allotments: require('./genesis.json'), - fees: require('./params.json') -}; +module.exports = require('./params.json') diff --git a/package.json b/package.json index 67cb002..b03b2c9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ethereum-common", - "version": "0.0.2", + "version": "0.0.3", "description": "Resources common to all Ethereum implementations", "main": "index.js", "scripts": { From c25dc32a6cf64f1144b0d7d852196f2a1d108a79 Mon Sep 17 00:00:00 2001 From: wanderer Date: Sat, 8 Aug 2015 01:30:44 +0000 Subject: [PATCH 6/6] proper revison --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b03b2c9..61b7206 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ethereum-common", - "version": "0.0.3", + "version": "0.0.4", "description": "Resources common to all Ethereum implementations", "main": "index.js", "scripts": {