Merge pull request #31 from gnosis/feature/WA-238-implementation-multisig-tx

WA-238 Implementation Multisig TXs
This commit is contained in:
Adolfo Panizo 2018-05-31 13:45:41 +02:00 committed by GitHub
commit 948196b100
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
51 changed files with 26992 additions and 32951 deletions

View File

@ -87,7 +87,7 @@
"storybook-host": "^4.1.5",
"storybook-router": "^0.3.3",
"style-loader": "^0.20.2",
"truffle": "4.1.8",
"truffle": "git://github.com/trufflesuite/truffle.git#develop",
"truffle-contract": "^1.1.8",
"truffle-solidity-loader": "0.0.8",
"uglifyjs-webpack-plugin": "^1.2.2",

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -50,11 +50,11 @@
"type": "fallback"
}
],
"bytecode": "0x608060405234801561001057600080fd5b5060405161026d38038061026d83398101806040528101908080519060200190929190805182019291905050508160008173ffffffffffffffffffffffffffffffffffffffff161415151561006457600080fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506000815111156100f15773ffffffffffffffffffffffffffffffffffffffff60005416600080835160208501846127105a03f46040513d6000823e60008214156100ed573d81fd5b5050505b505061016b806101026000396000f30060806040526004361061004c576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680634555d5c91461008b5780635c60da1b146100b6575b73ffffffffffffffffffffffffffffffffffffffff600054163660008037600080366000845af43d6000803e6000811415610086573d6000fd5b3d6000f35b34801561009757600080fd5b506100a061010d565b6040518082815260200191505060405180910390f35b3480156100c257600080fd5b506100cb610116565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b60006002905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050905600a165627a7a72305820caf2b106039b60d7c8f99a3087b6cbf6014cdee3748f0823ccd8cbf983ee4a720029",
"deployedBytecode": "0x60806040526004361061004c576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680634555d5c91461008b5780635c60da1b146100b6575b73ffffffffffffffffffffffffffffffffffffffff600054163660008037600080366000845af43d6000803e6000811415610086573d6000fd5b3d6000f35b34801561009757600080fd5b506100a061010d565b6040518082815260200191505060405180910390f35b3480156100c257600080fd5b506100cb610116565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b60006002905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050905600a165627a7a72305820caf2b106039b60d7c8f99a3087b6cbf6014cdee3748f0823ccd8cbf983ee4a720029",
"sourceMap": "355:882:0:-;;;610:625;8:9:-1;5:2;;;30:1;27;20:12;5:2;610:625:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;668:11;593:1:12;578:11;:16;;;;570:25;;;;;;;;618:11;605:10;;:24;;;;;;;;;;;;;;;;;;508:128;735:1:0;714:11;:18;:22;710:519;;;879:42;875:1;869:8;865:57;1043:1;1040;1026:11;1020:18;1013:4;1000:11;996:22;984:10;976:5;971:3;967:15;954:91;1079:4;1073:11;1124:14;1121:1;1116:3;1101:38;1171:1;1162:7;1159:14;1156:2;;;1188:14;1183:3;1176:27;1156:2;829:390;;;;610:625;;355:882;;;;;;",
"deployedSourceMap": "355:882:0:-;;;;;;;;;;;;;;;;;;;;;;;;;;915:42:12;911:1;905:8;901:57;990:14;987:1;984;971:34;1085:1;1082;1066:14;1063:1;1051:10;1046:3;1033:54;1121:16;1118:1;1115;1100:38;1166:1;1157:7;1154:14;1151:2;;;1181:16;1178:1;1171:27;1151:2;1223:16;1220:1;1213:27;1386:104;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1386:104:12;;;;;;;;;;;;;;;;;;;;;;;1262:118;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1262:118:12;;;;;;;;;;;;;;;;;;;;;;;;;;;1386:104;1452:7;1482:1;1475:8;;1386:104;:::o;1262:118::-;1333:7;1363:10;;;;;;;;;;;1356:17;;1262:118;:::o",
"source": "pragma solidity 0.4.23;\nimport \"./Proxy.sol\";\n\n\n/// @title Delegate Constructor Proxy - Generic proxy contract allows to execute all transactions applying the code of a master contract. It is possible to send along initialization data with the constructor.\n/// @author Stefan George - <stefan@gnosis.pm>\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract DelegateConstructorProxy is Proxy {\n\n /// @dev Constructor function sets address of master copy contract.\n /// @param _masterCopy Master copy address.\n /// @param initializer Data used for a delegate call to initialize the contract.\n constructor(address _masterCopy, bytes initializer) Proxy(_masterCopy)\n public\n {\n if (initializer.length > 0) {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let masterCopy := and(sload(0), 0xffffffffffffffffffffffffffffffffffffffff)\n let success := delegatecall(sub(gas, 10000), masterCopy, add(initializer, 0x20), mload(initializer), 0, 0)\n let ptr := mload(0x40)\n returndatacopy(ptr, 0, returndatasize)\n if eq(success, 0) { revert(ptr, returndatasize) }\n }\n }\n }\n}\n",
"bytecode": "0x608060405234801561001057600080fd5b506040516102fc3803806102fc83398101806040528101908080519060200190929190805182019291905050508160008173ffffffffffffffffffffffffffffffffffffffff16141515156100f3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001807f496e76616c6964206d617374657220636f707920616464726573732070726f7681526020017f696465640000000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506000815111156101805773ffffffffffffffffffffffffffffffffffffffff60005416600080835160208501846127105a03f46040513d6000823e600082141561017c573d81fd5b5050505b505061016b806101916000396000f30060806040526004361061004c576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680634555d5c91461008b5780635c60da1b146100b6575b73ffffffffffffffffffffffffffffffffffffffff600054163660008037600080366000845af43d6000803e6000811415610086573d6000fd5b3d6000f35b34801561009757600080fd5b506100a061010d565b6040518082815260200191505060405180910390f35b3480156100c257600080fd5b506100cb610116565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b60006002905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050905600a165627a7a72305820bab5357556c704bffef0f96326dd27742408be175057ffd8f4f58237314cfd520029",
"deployedBytecode": "0x60806040526004361061004c576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680634555d5c91461008b5780635c60da1b146100b6575b73ffffffffffffffffffffffffffffffffffffffff600054163660008037600080366000845af43d6000803e6000811415610086573d6000fd5b3d6000f35b34801561009757600080fd5b506100a061010d565b6040518082815260200191505060405180910390f35b3480156100c257600080fd5b506100cb610116565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b60006002905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050905600a165627a7a72305820bab5357556c704bffef0f96326dd27742408be175057ffd8f4f58237314cfd520029",
"sourceMap": "355:882:0:-;;;610:625;8:9:-1;5:2;;;30:1;27;20:12;5:2;610:625:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;668:11;593:1:11;578:11;:16;;;;570:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;658:11;645:10;;:24;;;;;;;;;;;;;;;;;;508:168;735:1:0;714:11;:18;:22;710:519;;;879:42;875:1;869:8;865:57;1043:1;1040;1026:11;1020:18;1013:4;1000:11;996:22;984:10;976:5;971:3;967:15;954:91;1079:4;1073:11;1124:14;1121:1;1116:3;1101:38;1171:1;1162:7;1159:14;1156:2;;;1188:14;1183:3;1176:27;1156:2;829:390;;;;610:625;;355:882;;;;;;",
"deployedSourceMap": "355:882:0:-;;;;;;;;;;;;;;;;;;;;;;;;;;955:42:11;951:1;945:8;941:57;1030:14;1027:1;1024;1011:34;1125:1;1122;1106:14;1103:1;1091:10;1086:3;1073:54;1161:16;1158:1;1155;1140:38;1206:1;1197:7;1194:14;1191:2;;;1221:16;1218:1;1211:27;1191:2;1263:16;1260:1;1253:27;1426:104;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1426:104:11;;;;;;;;;;;;;;;;;;;;;;;1302:118;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1302:118:11;;;;;;;;;;;;;;;;;;;;;;;;;;;1426:104;1492:7;1522:1;1515:8;;1426:104;:::o;1302:118::-;1373:7;1403:10;;;;;;;;;;;1396:17;;1302:118;:::o",
"source": "pragma solidity 0.4.24;\nimport \"./Proxy.sol\";\n\n\n/// @title Delegate Constructor Proxy - Generic proxy contract allows to execute all transactions applying the code of a master contract. It is possible to send along initialization data with the constructor.\n/// @author Stefan George - <stefan@gnosis.pm>\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract DelegateConstructorProxy is Proxy {\n\n /// @dev Constructor function sets address of master copy contract.\n /// @param _masterCopy Master copy address.\n /// @param initializer Data used for a delegate call to initialize the contract.\n constructor(address _masterCopy, bytes initializer) Proxy(_masterCopy)\n public\n {\n if (initializer.length > 0) {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let masterCopy := and(sload(0), 0xffffffffffffffffffffffffffffffffffffffff)\n let success := delegatecall(sub(gas, 10000), masterCopy, add(initializer, 0x20), mload(initializer), 0, 0)\n let ptr := mload(0x40)\n returndatacopy(ptr, 0, returndatasize)\n if eq(success, 0) { revert(ptr, returndatasize) }\n }\n }\n }\n}\n",
"sourcePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/DelegateConstructorProxy.sol",
"ast": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/DelegateConstructorProxy.sol",
@ -71,7 +71,7 @@
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:0"
@ -82,7 +82,7 @@
"id": 2,
"nodeType": "ImportDirective",
"scope": 24,
"sourceUnit": 1509,
"sourceUnit": 1603,
"src": "24:21:0",
"symbolAliases": [],
"unitAlias": ""
@ -96,10 +96,10 @@
"id": 3,
"name": "Proxy",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1508,
"referencedDeclaration": 1602,
"src": "392:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Proxy_$1508",
"typeIdentifier": "t_contract$_Proxy_$1602",
"typeString": "contract Proxy"
}
},
@ -109,7 +109,7 @@
}
],
"contractDependencies": [
1508
1602
],
"contractKind": "contract",
"documentation": "@title Delegate Constructor Proxy - Generic proxy contract allows to execute all transactions applying the code of a master contract. It is possible to send along initialization data with the constructor.\n @author Stefan George - <stefan@gnosis.pm>\n @author Richard Meissner - <richard@gnosis.pm>",
@ -117,7 +117,7 @@
"id": 23,
"linearizedBaseContracts": [
23,
1508
1602
],
"name": "DelegateConstructorProxy",
"nodeType": "ContractDefinition",
@ -264,10 +264,10 @@
"name": "Proxy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1508,
"referencedDeclaration": 1602,
"src": "662:5:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_Proxy_$1508_$",
"typeIdentifier": "t_type$_t_contract$_Proxy_$1602_$",
"typeString": "type(contract Proxy)"
}
},
@ -371,7 +371,7 @@
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:0"
@ -382,7 +382,7 @@
"id": 2,
"nodeType": "ImportDirective",
"scope": 24,
"sourceUnit": 1509,
"sourceUnit": 1603,
"src": "24:21:0",
"symbolAliases": [],
"unitAlias": ""
@ -396,10 +396,10 @@
"id": 3,
"name": "Proxy",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1508,
"referencedDeclaration": 1602,
"src": "392:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Proxy_$1508",
"typeIdentifier": "t_contract$_Proxy_$1602",
"typeString": "contract Proxy"
}
},
@ -409,7 +409,7 @@
}
],
"contractDependencies": [
1508
1602
],
"contractKind": "contract",
"documentation": "@title Delegate Constructor Proxy - Generic proxy contract allows to execute all transactions applying the code of a master contract. It is possible to send along initialization data with the constructor.\n @author Stefan George - <stefan@gnosis.pm>\n @author Richard Meissner - <richard@gnosis.pm>",
@ -417,7 +417,7 @@
"id": 23,
"linearizedBaseContracts": [
23,
1508
1602
],
"name": "DelegateConstructorProxy",
"nodeType": "ContractDefinition",
@ -564,10 +564,10 @@
"name": "Proxy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1508,
"referencedDeclaration": 1602,
"src": "662:5:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_Proxy_$1508_$",
"typeIdentifier": "t_type$_t_contract$_Proxy_$1602_$",
"typeString": "type(contract Proxy)"
}
},
@ -658,9 +658,9 @@
},
"compiler": {
"name": "solc",
"version": "0.4.23+commit.124ca40d.Emscripten.clang"
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
},
"networks": {},
"schemaVersion": "2.0.0",
"updatedAt": "2018-05-10T10:43:07.891Z"
"updatedAt": "2018-05-28T05:59:52.697Z"
}

File diff suppressed because it is too large Load Diff

View File

@ -1,31 +1,31 @@
{
"contractName": "Enum",
"abi": [],
"bytecode": "0x6080604052348015600f57600080fd5b50603580601d6000396000f3006080604052600080fd00a165627a7a72305820346c40fd38e691d9042d78bf7c33e05e8eafc3767b153318d8f2a9f5daf08bcf0029",
"deployedBytecode": "0x6080604052600080fd00a165627a7a72305820346c40fd38e691d9042d78bf7c33e05e8eafc3767b153318d8f2a9f5daf08bcf0029",
"sourceMap": "115:95:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;115:95:0;;;;;;;",
"deployedSourceMap": "115:95:0:-;;;;;",
"source": "pragma solidity 0.4.23;\n\n\n/// @title Enum - Collection of enums\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract Enum {\n enum Operation {\n Call,\n DelegateCall,\n Create\n }\n}\n",
"bytecode": "0x6080604052348015600f57600080fd5b50603580601d6000396000f3006080604052600080fd00a165627a7a72305820641ab8b295edfaa2b1c8a8e0ae7d17ea2f4c8b95ea27e45d8947ed9a4799ca1f0029",
"deployedBytecode": "0x6080604052600080fd00a165627a7a72305820641ab8b295edfaa2b1c8a8e0ae7d17ea2f4c8b95ea27e45d8947ed9a4799ca1f0029",
"sourceMap": "115:95:1:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;115:95:1;;;;;;;",
"deployedSourceMap": "115:95:1:-;;;;;",
"source": "pragma solidity 0.4.24;\n\n\n/// @title Enum - Collection of enums\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract Enum {\n enum Operation {\n Call,\n DelegateCall,\n Create\n }\n}\n",
"sourcePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/Enum.sol",
"ast": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/Enum.sol",
"exportedSymbols": {
"Enum": [
6
30
]
},
"id": 7,
"id": 31,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1,
"id": 25,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:0"
"src": "0:23:1"
},
{
"baseContracts": [],
@ -33,66 +33,66 @@
"contractKind": "contract",
"documentation": "@title Enum - Collection of enums\n @author Richard Meissner - <richard@gnosis.pm>",
"fullyImplemented": true,
"id": 6,
"id": 30,
"linearizedBaseContracts": [
6
30
],
"name": "Enum",
"nodeType": "ContractDefinition",
"nodes": [
{
"canonicalName": "Enum.Operation",
"id": 5,
"id": 29,
"members": [
{
"id": 2,
"id": 26,
"name": "Call",
"nodeType": "EnumValue",
"src": "160:4:0"
"src": "160:4:1"
},
{
"id": 3,
"id": 27,
"name": "DelegateCall",
"nodeType": "EnumValue",
"src": "174:12:0"
"src": "174:12:1"
},
{
"id": 4,
"id": 28,
"name": "Create",
"nodeType": "EnumValue",
"src": "196:6:0"
"src": "196:6:1"
}
],
"name": "Operation",
"nodeType": "EnumDefinition",
"src": "135:73:0"
"src": "135:73:1"
}
],
"scope": 7,
"src": "115:95:0"
"scope": 31,
"src": "115:95:1"
}
],
"src": "0:211:0"
"src": "0:211:1"
},
"legacyAST": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/Enum.sol",
"exportedSymbols": {
"Enum": [
6
30
]
},
"id": 7,
"id": 31,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1,
"id": 25,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:0"
"src": "0:23:1"
},
{
"baseContracts": [],
@ -100,52 +100,52 @@
"contractKind": "contract",
"documentation": "@title Enum - Collection of enums\n @author Richard Meissner - <richard@gnosis.pm>",
"fullyImplemented": true,
"id": 6,
"id": 30,
"linearizedBaseContracts": [
6
30
],
"name": "Enum",
"nodeType": "ContractDefinition",
"nodes": [
{
"canonicalName": "Enum.Operation",
"id": 5,
"id": 29,
"members": [
{
"id": 2,
"id": 26,
"name": "Call",
"nodeType": "EnumValue",
"src": "160:4:0"
"src": "160:4:1"
},
{
"id": 3,
"id": 27,
"name": "DelegateCall",
"nodeType": "EnumValue",
"src": "174:12:0"
"src": "174:12:1"
},
{
"id": 4,
"id": 28,
"name": "Create",
"nodeType": "EnumValue",
"src": "196:6:0"
"src": "196:6:1"
}
],
"name": "Operation",
"nodeType": "EnumDefinition",
"src": "135:73:0"
"src": "135:73:1"
}
],
"scope": 7,
"src": "115:95:0"
"scope": 31,
"src": "115:95:1"
}
],
"src": "0:211:0"
"src": "0:211:1"
},
"compiler": {
"name": "solc",
"version": "0.4.23+commit.124ca40d.Emscripten.clang"
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
},
"networks": {},
"schemaVersion": "2.0.0",
"updatedAt": "2018-05-16T10:51:14.736Z"
"updatedAt": "2018-05-28T05:59:52.697Z"
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -16,40 +16,40 @@
"type": "function"
}
],
"bytecode": "0x608060405234801561001057600080fd5b50610158806100206000396000f300608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680637de7edef14610046575b600080fd5b34801561005257600080fd5b50610087600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610089565b005b3073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156100c357600080fd5b60008173ffffffffffffffffffffffffffffffffffffffff16141515156100e957600080fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505600a165627a7a7230582073cd5ab8858f9d67e5e09748f71ecf939357d0d1230776e9f935b1ef5d664eb00029",
"deployedBytecode": "0x608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680637de7edef14610046575b600080fd5b34801561005257600080fd5b50610087600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610089565b005b3073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156100c357600080fd5b60008173ffffffffffffffffffffffffffffffffffffffff16141515156100e957600080fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505600a165627a7a7230582073cd5ab8858f9d67e5e09748f71ecf939357d0d1230776e9f935b1ef5d664eb00029",
"sourceMap": "203:633:4:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;203:633:4;;;;;;;",
"deployedSourceMap": "203:633:4:-;;;;;;;;;;;;;;;;;;;;;;;;626:208;;8:9:-1;5:2;;;30:1;27;20:12;5:2;626:208:4;;;;;;;;;;;;;;;;;;;;;;;;;;;;;244:4:8;222:27;;:10;:27;;;214:36;;;;;;;;791:1:4;776:11;:16;;;;768:25;;;;;;;;816:11;803:10;;:24;;;;;;;;;;;;;;;;;;626:208;:::o",
"source": "pragma solidity 0.4.23;\nimport \"./SelfAuthorized.sol\";\n\n\n/// @title MasterCopy - Base for master copy contracts (should always be first super contract)\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract MasterCopy is SelfAuthorized {\n // masterCopy always needs to be first declared variable, to ensure that it is at the same location as in the Proxy contract.\n // It should also always be ensured that the address is stored alone (uses a full word)\n address masterCopy;\n\n /// @dev Allows to upgrade the contract. This can only be done via a Safe transaction.\n /// @param _masterCopy New contract address.\n function changeMasterCopy(address _masterCopy)\n public\n authorized\n {\n // Master copy address cannot be null.\n require(_masterCopy != 0);\n masterCopy = _masterCopy;\n }\n}\n",
"bytecode": "0x608060405234801561001057600080fd5b50610276806100206000396000f300608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680637de7edef14610046575b600080fd5b34801561005257600080fd5b50610087600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610089565b005b3073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610152576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642066726f6d207481526020017f68697320636f6e7472616374000000000000000000000000000000000000000081525060400191505060405180910390fd5b60008173ffffffffffffffffffffffffffffffffffffffff1614151515610207576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001807f496e76616c6964206d617374657220636f707920616464726573732070726f7681526020017f696465640000000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505600a165627a7a72305820243ca7a44eb0464a47c14309cc3a29e407df6e966674981a787df22c0d9280220029",
"deployedBytecode": "0x608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680637de7edef14610046575b600080fd5b34801561005257600080fd5b50610087600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610089565b005b3073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610152576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642066726f6d207481526020017f68697320636f6e7472616374000000000000000000000000000000000000000081525060400191505060405180910390fd5b60008173ffffffffffffffffffffffffffffffffffffffff1614151515610207576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001807f496e76616c6964206d617374657220636f707920616464726573732070726f7681526020017f696465640000000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505600a165627a7a72305820243ca7a44eb0464a47c14309cc3a29e407df6e966674981a787df22c0d9280220029",
"sourceMap": "203:673:5:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;203:673:5;;;;;;;",
"deployedSourceMap": "203:673:5:-;;;;;;;;;;;;;;;;;;;;;;;;626:248;;8:9:-1;5:2;;;30:1;27;20:12;5:2;626:248:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;244:4:13;222:27;;:10;:27;;;214:84;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;791:1:5;776:11;:16;;;;768:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;856:11;843:10;;:24;;;;;;;;;;;;;;;;;;626:248;:::o",
"source": "pragma solidity 0.4.24;\nimport \"./SelfAuthorized.sol\";\n\n\n/// @title MasterCopy - Base for master copy contracts (should always be first super contract)\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract MasterCopy is SelfAuthorized {\n // masterCopy always needs to be first declared variable, to ensure that it is at the same location as in the Proxy contract.\n // It should also always be ensured that the address is stored alone (uses a full word)\n address masterCopy;\n\n /// @dev Allows to upgrade the contract. This can only be done via a Safe transaction.\n /// @param _masterCopy New contract address.\n function changeMasterCopy(address _masterCopy)\n public\n authorized\n {\n // Master copy address cannot be null.\n require(_masterCopy != 0, \"Invalid master copy address provided\");\n masterCopy = _masterCopy;\n }\n}\n",
"sourcePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/MasterCopy.sol",
"ast": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/MasterCopy.sol",
"exportedSymbols": {
"MasterCopy": [
580
662
]
},
"id": 581,
"id": 663,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 556,
"id": 637,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:4"
"src": "0:23:5"
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/SelfAuthorized.sol",
"file": "./SelfAuthorized.sol",
"id": 557,
"id": 638,
"nodeType": "ImportDirective",
"scope": 581,
"sourceUnit": 1360,
"src": "24:30:4",
"scope": 663,
"sourceUnit": 1655,
"src": "24:30:5",
"symbolAliases": [],
"unitAlias": ""
},
@ -59,42 +59,42 @@
"arguments": null,
"baseName": {
"contractScope": null,
"id": 558,
"id": 639,
"name": "SelfAuthorized",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1359,
"src": "226:14:4",
"referencedDeclaration": 1654,
"src": "226:14:5",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SelfAuthorized_$1359",
"typeIdentifier": "t_contract$_SelfAuthorized_$1654",
"typeString": "contract SelfAuthorized"
}
},
"id": 559,
"id": 640,
"nodeType": "InheritanceSpecifier",
"src": "226:14:4"
"src": "226:14:5"
}
],
"contractDependencies": [
1359
1654
],
"contractKind": "contract",
"documentation": "@title MasterCopy - Base for master copy contracts (should always be first super contract)\n @author Richard Meissner - <richard@gnosis.pm>",
"fullyImplemented": true,
"id": 580,
"id": 662,
"linearizedBaseContracts": [
580,
1359
662,
1654
],
"name": "MasterCopy",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 561,
"id": 642,
"name": "masterCopy",
"nodeType": "VariableDeclaration",
"scope": 580,
"src": "465:18:4",
"scope": 662,
"src": "465:18:5",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
@ -102,10 +102,10 @@
"typeString": "address"
},
"typeName": {
"id": 560,
"id": 641,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "465:7:4",
"src": "465:7:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -116,9 +116,9 @@
},
{
"body": {
"id": 578,
"id": 660,
"nodeType": "Block",
"src": "711:123:4",
"src": "711:163:5",
"statements": [
{
"expression": {
@ -130,19 +130,19 @@
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 571,
"id": 652,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 569,
"id": 650,
"name": "_masterCopy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 563,
"src": "776:11:4",
"referencedDeclaration": 644,
"src": "776:11:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -153,14 +153,14 @@
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 570,
"id": 651,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "791:1:4",
"src": "791:1:5",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
@ -168,11 +168,29 @@
},
"value": "0"
},
"src": "776:16:4",
"src": "776:16:5",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "496e76616c6964206d617374657220636f707920616464726573732070726f7669646564",
"id": 653,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "794:38:5",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_108d84599042957b954e89d43b52f80be89321dfc114a37800028eba58dafc87",
"typeString": "literal_string \"Invalid master copy address provided\""
},
"value": "Invalid master copy address provided"
}
],
"expression": {
@ -180,23 +198,27 @@
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_108d84599042957b954e89d43b52f80be89321dfc114a37800028eba58dafc87",
"typeString": "literal_string \"Invalid master copy address provided\""
}
],
"id": 568,
"id": 649,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
2399,
2400
2657,
2658
],
"referencedDeclaration": 2399,
"src": "768:7:4",
"referencedDeclaration": 2658,
"src": "768:7:5",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 572,
"id": 654,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -204,32 +226,32 @@
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "768:25:4",
"src": "768:65:5",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 573,
"id": 655,
"nodeType": "ExpressionStatement",
"src": "768:25:4"
"src": "768:65:5"
},
{
"expression": {
"argumentTypes": null,
"id": 576,
"id": 658,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 574,
"id": 656,
"name": "masterCopy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 561,
"src": "803:10:4",
"referencedDeclaration": 642,
"src": "843:10:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -239,68 +261,68 @@
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 575,
"id": 657,
"name": "_masterCopy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 563,
"src": "816:11:4",
"referencedDeclaration": 644,
"src": "856:11:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "803:24:4",
"src": "843:24:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 577,
"id": 659,
"nodeType": "ExpressionStatement",
"src": "803:24:4"
"src": "843:24:5"
}
]
},
"documentation": "@dev Allows to upgrade the contract. This can only be done via a Safe transaction.\n @param _masterCopy New contract address.",
"id": 579,
"id": 661,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [
{
"arguments": null,
"id": 566,
"id": 647,
"modifierName": {
"argumentTypes": null,
"id": 565,
"id": 646,
"name": "authorized",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1358,
"src": "696:10:4",
"referencedDeclaration": 1653,
"src": "696:10:5",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "696:10:4"
"src": "696:10:5"
}
],
"name": "changeMasterCopy",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 564,
"id": 645,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 563,
"id": 644,
"name": "_masterCopy",
"nodeType": "VariableDeclaration",
"scope": 579,
"src": "652:19:4",
"scope": 661,
"src": "652:19:5",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
@ -308,10 +330,10 @@
"typeString": "address"
},
"typeName": {
"id": 562,
"id": 643,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "652:7:4",
"src": "652:7:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -321,56 +343,56 @@
"visibility": "internal"
}
],
"src": "651:21:4"
"src": "651:21:5"
},
"payable": false,
"returnParameters": {
"id": 567,
"id": 648,
"nodeType": "ParameterList",
"parameters": [],
"src": "711:0:4"
"src": "711:0:5"
},
"scope": 580,
"src": "626:208:4",
"scope": 662,
"src": "626:248:5",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
}
],
"scope": 581,
"src": "203:633:4"
"scope": 663,
"src": "203:673:5"
}
],
"src": "0:837:4"
"src": "0:877:5"
},
"legacyAST": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/MasterCopy.sol",
"exportedSymbols": {
"MasterCopy": [
580
662
]
},
"id": 581,
"id": 663,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 556,
"id": 637,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:4"
"src": "0:23:5"
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/SelfAuthorized.sol",
"file": "./SelfAuthorized.sol",
"id": 557,
"id": 638,
"nodeType": "ImportDirective",
"scope": 581,
"sourceUnit": 1360,
"src": "24:30:4",
"scope": 663,
"sourceUnit": 1655,
"src": "24:30:5",
"symbolAliases": [],
"unitAlias": ""
},
@ -380,42 +402,42 @@
"arguments": null,
"baseName": {
"contractScope": null,
"id": 558,
"id": 639,
"name": "SelfAuthorized",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1359,
"src": "226:14:4",
"referencedDeclaration": 1654,
"src": "226:14:5",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SelfAuthorized_$1359",
"typeIdentifier": "t_contract$_SelfAuthorized_$1654",
"typeString": "contract SelfAuthorized"
}
},
"id": 559,
"id": 640,
"nodeType": "InheritanceSpecifier",
"src": "226:14:4"
"src": "226:14:5"
}
],
"contractDependencies": [
1359
1654
],
"contractKind": "contract",
"documentation": "@title MasterCopy - Base for master copy contracts (should always be first super contract)\n @author Richard Meissner - <richard@gnosis.pm>",
"fullyImplemented": true,
"id": 580,
"id": 662,
"linearizedBaseContracts": [
580,
1359
662,
1654
],
"name": "MasterCopy",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 561,
"id": 642,
"name": "masterCopy",
"nodeType": "VariableDeclaration",
"scope": 580,
"src": "465:18:4",
"scope": 662,
"src": "465:18:5",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
@ -423,10 +445,10 @@
"typeString": "address"
},
"typeName": {
"id": 560,
"id": 641,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "465:7:4",
"src": "465:7:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -437,9 +459,9 @@
},
{
"body": {
"id": 578,
"id": 660,
"nodeType": "Block",
"src": "711:123:4",
"src": "711:163:5",
"statements": [
{
"expression": {
@ -451,19 +473,19 @@
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 571,
"id": 652,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 569,
"id": 650,
"name": "_masterCopy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 563,
"src": "776:11:4",
"referencedDeclaration": 644,
"src": "776:11:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -474,14 +496,14 @@
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 570,
"id": 651,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "791:1:4",
"src": "791:1:5",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
@ -489,11 +511,29 @@
},
"value": "0"
},
"src": "776:16:4",
"src": "776:16:5",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "496e76616c6964206d617374657220636f707920616464726573732070726f7669646564",
"id": 653,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "794:38:5",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_108d84599042957b954e89d43b52f80be89321dfc114a37800028eba58dafc87",
"typeString": "literal_string \"Invalid master copy address provided\""
},
"value": "Invalid master copy address provided"
}
],
"expression": {
@ -501,23 +541,27 @@
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_108d84599042957b954e89d43b52f80be89321dfc114a37800028eba58dafc87",
"typeString": "literal_string \"Invalid master copy address provided\""
}
],
"id": 568,
"id": 649,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
2399,
2400
2657,
2658
],
"referencedDeclaration": 2399,
"src": "768:7:4",
"referencedDeclaration": 2658,
"src": "768:7:5",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 572,
"id": 654,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -525,32 +569,32 @@
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "768:25:4",
"src": "768:65:5",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 573,
"id": 655,
"nodeType": "ExpressionStatement",
"src": "768:25:4"
"src": "768:65:5"
},
{
"expression": {
"argumentTypes": null,
"id": 576,
"id": 658,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 574,
"id": 656,
"name": "masterCopy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 561,
"src": "803:10:4",
"referencedDeclaration": 642,
"src": "843:10:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -560,68 +604,68 @@
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 575,
"id": 657,
"name": "_masterCopy",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 563,
"src": "816:11:4",
"referencedDeclaration": 644,
"src": "856:11:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "803:24:4",
"src": "843:24:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 577,
"id": 659,
"nodeType": "ExpressionStatement",
"src": "803:24:4"
"src": "843:24:5"
}
]
},
"documentation": "@dev Allows to upgrade the contract. This can only be done via a Safe transaction.\n @param _masterCopy New contract address.",
"id": 579,
"id": 661,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [
{
"arguments": null,
"id": 566,
"id": 647,
"modifierName": {
"argumentTypes": null,
"id": 565,
"id": 646,
"name": "authorized",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1358,
"src": "696:10:4",
"referencedDeclaration": 1653,
"src": "696:10:5",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "696:10:4"
"src": "696:10:5"
}
],
"name": "changeMasterCopy",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 564,
"id": 645,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 563,
"id": 644,
"name": "_masterCopy",
"nodeType": "VariableDeclaration",
"scope": 579,
"src": "652:19:4",
"scope": 661,
"src": "652:19:5",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
@ -629,10 +673,10 @@
"typeString": "address"
},
"typeName": {
"id": 562,
"id": 643,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "652:7:4",
"src": "652:7:5",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -642,33 +686,33 @@
"visibility": "internal"
}
],
"src": "651:21:4"
"src": "651:21:5"
},
"payable": false,
"returnParameters": {
"id": 567,
"id": 648,
"nodeType": "ParameterList",
"parameters": [],
"src": "711:0:4"
"src": "711:0:5"
},
"scope": 580,
"src": "626:208:4",
"scope": 662,
"src": "626:248:5",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
}
],
"scope": 581,
"src": "203:633:4"
"scope": 663,
"src": "203:673:5"
}
],
"src": "0:837:4"
"src": "0:877:5"
},
"compiler": {
"name": "solc",
"version": "0.4.23+commit.124ca40d.Emscripten.clang"
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
},
"networks": {},
"schemaVersion": "2.0.0",
"updatedAt": "2018-05-16T10:51:14.746Z"
"updatedAt": "2018-05-28T05:59:52.701Z"
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@ -16,28 +16,28 @@
"type": "function"
}
],
"bytecode": "0x608060405234801561001057600080fd5b5061013a806100206000396000f300608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680638d80ff0a14610046575b600080fd5b34801561005257600080fd5b506100ad600480360381019080803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091929192905050506100af565b005b805160205b8181101561010957808301516020820184015160608301850151608084018601600080838386885af1600081146100ea576100ef565b600080fd5b5060208060208401040260800185019450505050506100b4565b5050505600a165627a7a7230582085c54bc0284c5004bee6b973aad924e63fe6628856cdf34c1eedabe70b1787fb0029",
"deployedBytecode": "0x608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680638d80ff0a14610046575b600080fd5b34801561005257600080fd5b506100ad600480360381019080803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091929192905050506100af565b005b805160205b8181101561010957808301516020820184015160608301850151608084018601600080838386885af1600081146100ea576100ef565b600080fd5b5060208060208401040260800185019450505050506100b4565b5050505600a165627a7a7230582085c54bc0284c5004bee6b973aad924e63fe6628856cdf34c1eedabe70b1787fb0029",
"bytecode": "0x608060405234801561001057600080fd5b5061013a806100206000396000f300608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680638d80ff0a14610046575b600080fd5b34801561005257600080fd5b506100ad600480360381019080803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091929192905050506100af565b005b805160205b8181101561010957808301516020820184015160608301850151608084018601600080838386885af1600081146100ea576100ef565b600080fd5b50602080601f8401040260800185019450505050506100b4565b5050505600a165627a7a72305820d762b9a26edc788e8139b309555c37a91970e3acfe5f209dff1eaf14345bdbe60029",
"deployedBytecode": "0x608060405260043610610041576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680638d80ff0a14610046575b600080fd5b34801561005257600080fd5b506100ad600480360381019080803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091929192905050506100af565b005b805160205b8181101561010957808301516020820184015160608301850151608084018601600080838386885af1600081146100ea576100ef565b600080fd5b50602080601f8401040260800185019450505050506100b4565b5050505600a165627a7a72305820d762b9a26edc788e8139b309555c37a91970e3acfe5f209dff1eaf14345bdbe60029",
"sourceMap": "253:1073:16:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;253:1073:16;;;;;;;",
"deployedSourceMap": "253:1073:16:-;;;;;;;;;;;;;;;;;;;;;;;;593:731;;8:9:-1;5:2;;;30:1;27;20:12;5:2;593:731:16;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;768:12;762:19;803:4;820:488;834:6;831:1;828:13;820:488;;;898:1;884:12;880:20;874:27;962:4;959:1;955:12;941;937:31;931:38;1035:4;1032:1;1028:12;1014;1010:31;1004:38;1096:4;1093:1;1089:12;1075;1071:31;1168:1;1165;1153:10;1147:4;1140:5;1136:2;1131:3;1126:44;1192:1;1187:23;;;;1119:91;;1187:23;1206:1;1203;1196:12;1119:91;;1287:4;1280;1273;1261:10;1257:21;1253:32;1249:43;1243:4;1239:54;1236:1;1232:62;1227:67;;846:462;;;;820:488;;;734:584;;;:::o",
"source": "pragma solidity 0.4.23;\n\n\n/// @title Multi Send - Allows to batch multiple transactions into one.\n/// @author Nick Dodson - <nick.dodson@consensys.net>\n/// @author Gonçalo Sá - <goncalo.sa@consensys.net>\n/// @author Stefan George - <stefan@gnosis.pm>\ncontract MultiSend {\n\n /// @dev Sends multiple transactions and reverts all if one fails.\n /// @param transactions Encoded transactions. Each transaction is encoded as\n /// a tuple(address,uint256,bytes). The bytes of all\n /// encoded transactions are concatenated to form the input.\n function multiSend(bytes transactions)\n public\n {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let length := mload(transactions)\n let i := 0x20\n for { } lt(i, length) { } {\n let to := mload(add(transactions, i))\n let value := mload(add(transactions, add(i, 0x20)))\n let dataLength := mload(add(transactions, add(i, 0x60)))\n let data := add(transactions, add(i, 0x80))\n switch call(gas, to, value, data, dataLength, 0, 0)\n case 0 { revert(0, 0) }\n i := add(i, add(0x80, mul(div(add(dataLength, 0x20), 0x20), 0x20)))\n }\n }\n }\n}\n",
"source": "pragma solidity 0.4.24;\n\n\n/// @title Multi Send - Allows to batch multiple transactions into one.\n/// @author Nick Dodson - <nick.dodson@consensys.net>\n/// @author Gonçalo Sá - <goncalo.sa@consensys.net>\n/// @author Stefan George - <stefan@gnosis.pm>\ncontract MultiSend {\n\n /// @dev Sends multiple transactions and reverts all if one fails.\n /// @param transactions Encoded transactions. Each transaction is encoded as\n /// a tuple(address,uint256,bytes). The bytes of all\n /// encoded transactions are concatenated to form the input.\n function multiSend(bytes transactions)\n public\n {\n // solium-disable-next-line security/no-inline-assembly\n assembly {\n let length := mload(transactions)\n let i := 0x20\n for { } lt(i, length) { } {\n let to := mload(add(transactions, i))\n let value := mload(add(transactions, add(i, 0x20)))\n let dataLength := mload(add(transactions, add(i, 0x60)))\n let data := add(transactions, add(i, 0x80))\n switch call(gas, to, value, data, dataLength, 0, 0)\n case 0 { revert(0, 0) }\n i := add(i, add(0x80, mul(div(add(dataLength, 0x1f), 0x20), 0x20)))\n }\n }\n }\n}\n",
"sourcePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/libraries/MultiSend.sol",
"ast": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/libraries/MultiSend.sol",
"exportedSymbols": {
"MultiSend": [
1614
1775
]
},
"id": 1615,
"id": 1776,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1606,
"id": 1767,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:16"
@ -48,16 +48,16 @@
"contractKind": "contract",
"documentation": "@title Multi Send - Allows to batch multiple transactions into one.\n @author Nick Dodson - <nick.dodson@consensys.net>\n @author Gonçalo Sá - <goncalo.sa@consensys.net>\n @author Stefan George - <stefan@gnosis.pm>",
"fullyImplemented": true,
"id": 1614,
"id": 1775,
"linearizedBaseContracts": [
1614
1775
],
"name": "MultiSend",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 1612,
"id": 1773,
"nodeType": "Block",
"src": "651:673:16",
"statements": [
@ -65,7 +65,7 @@
"externalReferences": [
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "768:12:16",
@ -74,7 +74,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "884:12:16",
@ -83,7 +83,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "941:12:16",
@ -92,7 +92,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "1014:12:16",
@ -101,7 +101,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "1075:12:16",
@ -109,15 +109,15 @@
}
}
],
"id": 1611,
"id": 1772,
"nodeType": "InlineAssembly",
"operations": "{\n let length := mload(transactions)\n let i := 0x20\n for {\n }\n lt(i, length)\n {\n }\n {\n let to := mload(add(transactions, i))\n let value := mload(add(transactions, add(i, 0x20)))\n let dataLength := mload(add(transactions, add(i, 0x60)))\n let data := add(transactions, add(i, 0x80))\n switch call(gas(), to, value, data, dataLength, 0, 0)\n case 0 {\n revert(0, 0)\n }\n i := add(i, add(0x80, mul(div(add(dataLength, 0x20), 0x20), 0x20)))\n }\n}",
"operations": "{\n let length := mload(transactions)\n let i := 0x20\n for {\n }\n lt(i, length)\n {\n }\n {\n let to := mload(add(transactions, i))\n let value := mload(add(transactions, add(i, 0x20)))\n let dataLength := mload(add(transactions, add(i, 0x60)))\n let data := add(transactions, add(i, 0x80))\n switch call(gas(), to, value, data, dataLength, 0, 0)\n case 0 {\n revert(0, 0)\n }\n i := add(i, add(0x80, mul(div(add(dataLength, 0x1f), 0x20), 0x20)))\n }\n}",
"src": "725:599:16"
}
]
},
"documentation": "@dev Sends multiple transactions and reverts all if one fails.\n @param transactions Encoded transactions. Each transaction is encoded as\n a tuple(address,uint256,bytes). The bytes of all\n encoded transactions are concatenated to form the input.",
"id": 1613,
"id": 1774,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
@ -125,15 +125,15 @@
"name": "multiSend",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 1609,
"id": 1770,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1608,
"id": 1769,
"name": "transactions",
"nodeType": "VariableDeclaration",
"scope": 1613,
"scope": 1774,
"src": "612:18:16",
"stateVariable": false,
"storageLocation": "default",
@ -142,7 +142,7 @@
"typeString": "bytes"
},
"typeName": {
"id": 1607,
"id": 1768,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "612:5:16",
@ -159,19 +159,19 @@
},
"payable": false,
"returnParameters": {
"id": 1610,
"id": 1771,
"nodeType": "ParameterList",
"parameters": [],
"src": "651:0:16"
},
"scope": 1614,
"scope": 1775,
"src": "593:731:16",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
}
],
"scope": 1615,
"scope": 1776,
"src": "253:1073:16"
}
],
@ -181,18 +181,18 @@
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/libraries/MultiSend.sol",
"exportedSymbols": {
"MultiSend": [
1614
1775
]
},
"id": 1615,
"id": 1776,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1606,
"id": 1767,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:16"
@ -203,16 +203,16 @@
"contractKind": "contract",
"documentation": "@title Multi Send - Allows to batch multiple transactions into one.\n @author Nick Dodson - <nick.dodson@consensys.net>\n @author Gonçalo Sá - <goncalo.sa@consensys.net>\n @author Stefan George - <stefan@gnosis.pm>",
"fullyImplemented": true,
"id": 1614,
"id": 1775,
"linearizedBaseContracts": [
1614
1775
],
"name": "MultiSend",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 1612,
"id": 1773,
"nodeType": "Block",
"src": "651:673:16",
"statements": [
@ -220,7 +220,7 @@
"externalReferences": [
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "768:12:16",
@ -229,7 +229,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "884:12:16",
@ -238,7 +238,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "941:12:16",
@ -247,7 +247,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "1014:12:16",
@ -256,7 +256,7 @@
},
{
"transactions": {
"declaration": 1608,
"declaration": 1769,
"isOffset": false,
"isSlot": false,
"src": "1075:12:16",
@ -264,15 +264,15 @@
}
}
],
"id": 1611,
"id": 1772,
"nodeType": "InlineAssembly",
"operations": "{\n let length := mload(transactions)\n let i := 0x20\n for {\n }\n lt(i, length)\n {\n }\n {\n let to := mload(add(transactions, i))\n let value := mload(add(transactions, add(i, 0x20)))\n let dataLength := mload(add(transactions, add(i, 0x60)))\n let data := add(transactions, add(i, 0x80))\n switch call(gas(), to, value, data, dataLength, 0, 0)\n case 0 {\n revert(0, 0)\n }\n i := add(i, add(0x80, mul(div(add(dataLength, 0x20), 0x20), 0x20)))\n }\n}",
"operations": "{\n let length := mload(transactions)\n let i := 0x20\n for {\n }\n lt(i, length)\n {\n }\n {\n let to := mload(add(transactions, i))\n let value := mload(add(transactions, add(i, 0x20)))\n let dataLength := mload(add(transactions, add(i, 0x60)))\n let data := add(transactions, add(i, 0x80))\n switch call(gas(), to, value, data, dataLength, 0, 0)\n case 0 {\n revert(0, 0)\n }\n i := add(i, add(0x80, mul(div(add(dataLength, 0x1f), 0x20), 0x20)))\n }\n}",
"src": "725:599:16"
}
]
},
"documentation": "@dev Sends multiple transactions and reverts all if one fails.\n @param transactions Encoded transactions. Each transaction is encoded as\n a tuple(address,uint256,bytes). The bytes of all\n encoded transactions are concatenated to form the input.",
"id": 1613,
"id": 1774,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
@ -280,15 +280,15 @@
"name": "multiSend",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 1609,
"id": 1770,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1608,
"id": 1769,
"name": "transactions",
"nodeType": "VariableDeclaration",
"scope": 1613,
"scope": 1774,
"src": "612:18:16",
"stateVariable": false,
"storageLocation": "default",
@ -297,7 +297,7 @@
"typeString": "bytes"
},
"typeName": {
"id": 1607,
"id": 1768,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "612:5:16",
@ -314,19 +314,19 @@
},
"payable": false,
"returnParameters": {
"id": 1610,
"id": 1771,
"nodeType": "ParameterList",
"parameters": [],
"src": "651:0:16"
},
"scope": 1614,
"scope": 1775,
"src": "593:731:16",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
}
],
"scope": 1615,
"scope": 1776,
"src": "253:1073:16"
}
],
@ -334,46 +334,22 @@
},
"compiler": {
"name": "solc",
"version": "0.4.23+commit.124ca40d.Emscripten.clang"
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
},
"networks": {
"4": {
"events": {},
"links": {},
"address": "0xeb51df3ce4e31ee60ed86cc860e68a4f892960cc",
"transactionHash": "0x1a3baba678d7b4d4c2ae5d151176442d5306e7958e83cecf49a6256fdfd2f4cb"
"address": "0xa95bcb648df34c679b070cd7f5992ec4aa4e5275",
"transactionHash": "0x7260ac1ca4cdf29c28bc941de22f64e7dd24bc928841bebee1f2b4d5d84037c8"
},
"1525950336085": {
"1527420696956": {
"events": {},
"links": {},
"address": "0xa4604b882b2c10ce381c4e61ad9ac72ab32f350f",
"transactionHash": "0xf4586ae05ae02801de1759128e43658bb0439e622a5ba84ad6bb4b652d641f4f"
},
"1526283540628": {
"events": {},
"links": {},
"address": "0xf5cfa4069271285402ba2585c521c6c627810963",
"transactionHash": "0xf4586ae05ae02801de1759128e43658bb0439e622a5ba84ad6bb4b652d641f4f"
},
"1526478212260": {
"events": {},
"links": {},
"address": "0x20658014abeebf3f064bf4442a5cd160143b800e",
"transactionHash": "0xf4586ae05ae02801de1759128e43658bb0439e622a5ba84ad6bb4b652d641f4f"
},
"1526973574996": {
"events": {},
"links": {},
"address": "0xf27293ee4c8876589b0e197d3bebb2402c798e1f",
"transactionHash": "0xf4586ae05ae02801de1759128e43658bb0439e622a5ba84ad6bb4b652d641f4f"
},
"1527316019334": {
"events": {},
"links": {},
"address": "0x0f72f565275c8985a41a0ea8346420a61004771d",
"transactionHash": "0xf4586ae05ae02801de1759128e43658bb0439e622a5ba84ad6bb4b652d641f4f"
"address": "0xe423b2291101fb206218ce4eeb03150e94446086",
"transactionHash": "0xa78e4749df5af5dff57145c85a9c9ca882d3b61e6125da675388fdda421622a2"
}
},
"schemaVersion": "2.0.0",
"updatedAt": "2018-05-26T06:28:28.360Z"
"updatedAt": "2018-05-28T13:58:28.823Z"
}

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,31 +1,31 @@
{
"contractName": "SelfAuthorized",
"abi": [],
"bytecode": "0x6080604052348015600f57600080fd5b50603580601d6000396000f3006080604052600080fd00a165627a7a72305820c359a8a0df732b4d3e100e43277411dee19c572529edb454cbf1fa9ee91508150029",
"deployedBytecode": "0x6080604052600080fd00a165627a7a72305820c359a8a0df732b4d3e100e43277411dee19c572529edb454cbf1fa9ee91508150029",
"sourceMap": "152:118:8:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;152:118:8;;;;;;;",
"deployedSourceMap": "152:118:8:-;;;;;",
"source": "pragma solidity 0.4.23;\n\n\n/// @title SelfAuthorized - authorizes current contract to perform actions\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract SelfAuthorized {\n modifier authorized() {\n require(msg.sender == address(this));\n _;\n }\n}\n",
"bytecode": "0x6080604052348015600f57600080fd5b50603580601d6000396000f3006080604052600080fd00a165627a7a72305820ec80f1b4520aa5197e4181778f1e2e4fc460002d4a40e2e8e6709c8986067c220029",
"deployedBytecode": "0x6080604052600080fd00a165627a7a72305820ec80f1b4520aa5197e4181778f1e2e4fc460002d4a40e2e8e6709c8986067c220029",
"sourceMap": "152:166:13:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;152:166:13;;;;;;;",
"deployedSourceMap": "152:166:13:-;;;;;",
"source": "pragma solidity 0.4.24;\n\n\n/// @title SelfAuthorized - authorizes current contract to perform actions\n/// @author Richard Meissner - <richard@gnosis.pm>\ncontract SelfAuthorized {\n modifier authorized() {\n require(msg.sender == address(this), \"Method can only be called from this contract\");\n _;\n }\n}\n",
"sourcePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/SelfAuthorized.sol",
"ast": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/SelfAuthorized.sol",
"exportedSymbols": {
"SelfAuthorized": [
1359
1654
]
},
"id": 1360,
"id": 1655,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1345,
"id": 1639,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:8"
"src": "0:23:13"
},
{
"baseContracts": [],
@ -33,18 +33,18 @@
"contractKind": "contract",
"documentation": "@title SelfAuthorized - authorizes current contract to perform actions\n @author Richard Meissner - <richard@gnosis.pm>",
"fullyImplemented": true,
"id": 1359,
"id": 1654,
"linearizedBaseContracts": [
1359
1654
],
"name": "SelfAuthorized",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 1357,
"id": 1652,
"nodeType": "Block",
"src": "204:64:8",
"src": "204:112:13",
"statements": [
{
"expression": {
@ -56,7 +56,7 @@
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 1353,
"id": 1647,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -65,18 +65,18 @@
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1348,
"id": 1642,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2396,
"src": "222:3:8",
"referencedDeclaration": 2654,
"src": "222:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 1349,
"id": 1643,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -84,7 +84,7 @@
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "222:10:8",
"src": "222:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -97,14 +97,14 @@
"arguments": [
{
"argumentTypes": null,
"id": 1351,
"id": 1645,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2411,
"src": "244:4:8",
"referencedDeclaration": 2673,
"src": "244:4:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SelfAuthorized_$1359",
"typeIdentifier": "t_contract$_SelfAuthorized_$1654",
"typeString": "contract SelfAuthorized"
}
}
@ -112,24 +112,24 @@
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_SelfAuthorized_$1359",
"typeIdentifier": "t_contract$_SelfAuthorized_$1654",
"typeString": "contract SelfAuthorized"
}
],
"id": 1350,
"id": 1644,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "236:7:8",
"src": "236:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": "address"
},
"id": 1352,
"id": 1646,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -137,17 +137,35 @@
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "236:13:8",
"src": "236:13:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "222:27:8",
"src": "222:27:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4d6574686f642063616e206f6e6c792062652063616c6c65642066726f6d207468697320636f6e7472616374",
"id": 1648,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "251:46:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c4780ef0a1d41d59bac8c510cf9ada421bccf2b90f75a8e4ba2e8c09e8d72733",
"typeString": "literal_string \"Method can only be called from this contract\""
},
"value": "Method can only be called from this contract"
}
],
"expression": {
@ -155,23 +173,27 @@
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_c4780ef0a1d41d59bac8c510cf9ada421bccf2b90f75a8e4ba2e8c09e8d72733",
"typeString": "literal_string \"Method can only be called from this contract\""
}
],
"id": 1347,
"id": 1641,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
2399,
2400
2657,
2658
],
"referencedDeclaration": 2399,
"src": "214:7:8",
"referencedDeclaration": 2658,
"src": "214:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1354,
"id": 1649,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -179,62 +201,62 @@
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "214:36:8",
"src": "214:84:13",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1355,
"id": 1650,
"nodeType": "ExpressionStatement",
"src": "214:36:8"
"src": "214:84:13"
},
{
"id": 1356,
"id": 1651,
"nodeType": "PlaceholderStatement",
"src": "260:1:8"
"src": "308:1:13"
}
]
},
"documentation": null,
"id": 1358,
"id": 1653,
"name": "authorized",
"nodeType": "ModifierDefinition",
"parameters": {
"id": 1346,
"id": 1640,
"nodeType": "ParameterList",
"parameters": [],
"src": "201:2:8"
"src": "201:2:13"
},
"src": "182:86:8",
"src": "182:134:13",
"visibility": "internal"
}
],
"scope": 1360,
"src": "152:118:8"
"scope": 1655,
"src": "152:166:13"
}
],
"src": "0:271:8"
"src": "0:319:13"
},
"legacyAST": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/SelfAuthorized.sol",
"exportedSymbols": {
"SelfAuthorized": [
1359
1654
]
},
"id": 1360,
"id": 1655,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1345,
"id": 1639,
"literals": [
"solidity",
"0.4",
".23"
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:8"
"src": "0:23:13"
},
{
"baseContracts": [],
@ -242,18 +264,18 @@
"contractKind": "contract",
"documentation": "@title SelfAuthorized - authorizes current contract to perform actions\n @author Richard Meissner - <richard@gnosis.pm>",
"fullyImplemented": true,
"id": 1359,
"id": 1654,
"linearizedBaseContracts": [
1359
1654
],
"name": "SelfAuthorized",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 1357,
"id": 1652,
"nodeType": "Block",
"src": "204:64:8",
"src": "204:112:13",
"statements": [
{
"expression": {
@ -265,7 +287,7 @@
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 1353,
"id": 1647,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -274,18 +296,18 @@
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1348,
"id": 1642,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2396,
"src": "222:3:8",
"referencedDeclaration": 2654,
"src": "222:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 1349,
"id": 1643,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -293,7 +315,7 @@
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "222:10:8",
"src": "222:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
@ -306,14 +328,14 @@
"arguments": [
{
"argumentTypes": null,
"id": 1351,
"id": 1645,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2411,
"src": "244:4:8",
"referencedDeclaration": 2673,
"src": "244:4:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SelfAuthorized_$1359",
"typeIdentifier": "t_contract$_SelfAuthorized_$1654",
"typeString": "contract SelfAuthorized"
}
}
@ -321,24 +343,24 @@
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_SelfAuthorized_$1359",
"typeIdentifier": "t_contract$_SelfAuthorized_$1654",
"typeString": "contract SelfAuthorized"
}
],
"id": 1350,
"id": 1644,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "236:7:8",
"src": "236:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": "address"
},
"id": 1352,
"id": 1646,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -346,17 +368,35 @@
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "236:13:8",
"src": "236:13:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "222:27:8",
"src": "222:27:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4d6574686f642063616e206f6e6c792062652063616c6c65642066726f6d207468697320636f6e7472616374",
"id": 1648,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "251:46:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c4780ef0a1d41d59bac8c510cf9ada421bccf2b90f75a8e4ba2e8c09e8d72733",
"typeString": "literal_string \"Method can only be called from this contract\""
},
"value": "Method can only be called from this contract"
}
],
"expression": {
@ -364,23 +404,27 @@
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_c4780ef0a1d41d59bac8c510cf9ada421bccf2b90f75a8e4ba2e8c09e8d72733",
"typeString": "literal_string \"Method can only be called from this contract\""
}
],
"id": 1347,
"id": 1641,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
2399,
2400
2657,
2658
],
"referencedDeclaration": 2399,
"src": "214:7:8",
"referencedDeclaration": 2658,
"src": "214:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1354,
"id": 1649,
"isConstant": false,
"isLValue": false,
"isPure": false,
@ -388,48 +432,48 @@
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "214:36:8",
"src": "214:84:13",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1355,
"id": 1650,
"nodeType": "ExpressionStatement",
"src": "214:36:8"
"src": "214:84:13"
},
{
"id": 1356,
"id": 1651,
"nodeType": "PlaceholderStatement",
"src": "260:1:8"
"src": "308:1:13"
}
]
},
"documentation": null,
"id": 1358,
"id": 1653,
"name": "authorized",
"nodeType": "ModifierDefinition",
"parameters": {
"id": 1346,
"id": 1640,
"nodeType": "ParameterList",
"parameters": [],
"src": "201:2:8"
"src": "201:2:13"
},
"src": "182:86:8",
"src": "182:134:13",
"visibility": "internal"
}
],
"scope": 1360,
"src": "152:118:8"
"scope": 1655,
"src": "152:166:13"
}
],
"src": "0:271:8"
"src": "0:319:13"
},
"compiler": {
"name": "solc",
"version": "0.4.23+commit.124ca40d.Emscripten.clang"
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
},
"networks": {},
"schemaVersion": "2.0.0",
"updatedAt": "2018-05-16T10:51:14.750Z"
"updatedAt": "2018-05-28T05:59:52.707Z"
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -5,7 +5,10 @@ type Field = boolean | string
export const required = (value: Field) => (value ? undefined : 'Required')
export const mustBeNumber = (value: number) =>
export const mustBeInteger = (value: string) =>
(!Number.isInteger(Number(value)) || value.includes('.') ? 'Must be an integer' : undefined)
export const mustBeFloat = (value: number) =>
(Number.isNaN(Number(value)) ? 'Must be a number' : undefined)
export const greaterThan = (min: number) => (value: string) => {

View File

@ -2,7 +2,7 @@
import * as React from 'react'
import { Field } from 'react-final-form'
import TextField from '~/components/forms/TextField'
import { composeValidators, minValue, mustBeNumber, required } from '~/components/forms/validator'
import { composeValidators, minValue, mustBeInteger, required } from '~/components/forms/validator'
import Block from '~/components/layout/Block'
import { FIELD_CONFIRMATIONS } from '~/routes/open/components/fields'
@ -14,7 +14,7 @@ const Confirmations = () => (
type="text"
validate={composeValidators(
required,
mustBeNumber,
mustBeInteger,
minValue(1),
)}
placeholder="Required confirmations*"

View File

@ -2,7 +2,7 @@
import * as React from 'react'
import Field from '~/components/forms/Field'
import TextField from '~/components/forms/TextField'
import { composeValidators, mustBeNumber, required, minValue } from '~/components/forms/validator'
import { composeValidators, mustBeFloat, required, minValue } from '~/components/forms/validator'
import Block from '~/components/layout/Block'
import { FIELD_DAILY_LIMIT } from '~/routes/open/components/fields'
@ -12,7 +12,7 @@ const DailyLimit = () => (
name={FIELD_DAILY_LIMIT}
component={TextField}
type="text"
validate={composeValidators(required, mustBeNumber, minValue(0))}
validate={composeValidators(required, mustBeFloat, minValue(0))}
placeholder="Daily Limit*"
text="Daily Limit"
/>

View File

@ -6,7 +6,7 @@ import {
composeValidators,
minValue,
maxValue,
mustBeNumber,
mustBeInteger,
mustBeEthereumAddress,
required,
uniqueAddress,
@ -45,7 +45,7 @@ const Owners = (props: Props) => {
name={FIELD_OWNERS}
component={TextField}
type="text"
validate={composeValidators(required, mustBeNumber, maxValue(MAX_NUMBER_OWNERS), minValue(1))}
validate={composeValidators(required, mustBeInteger, maxValue(MAX_NUMBER_OWNERS), minValue(1))}
placeholder="Number of owners*"
text="Number of owners"
/>

View File

@ -2,10 +2,10 @@
import * as React from 'react'
import Field from '~/components/forms/Field'
import TextField from '~/components/forms/TextField'
import { composeValidators, inLimit, mustBeNumber, required, greaterThan, mustBeEthereumAddress } from '~/components/forms/validator'
import { composeValidators, inLimit, mustBeFloat, required, greaterThan, mustBeEthereumAddress } from '~/components/forms/validator'
import Block from '~/components/layout/Block'
import Heading from '~/components/layout/Heading'
import { TX_NAME_PARAM, TX_DESTINATION_PARAM, TX_VALUE_PARAM } from '~/routes/safe/component/AddTransaction/transactions'
import { TX_NAME_PARAM, TX_DESTINATION_PARAM, TX_VALUE_PARAM } from '~/routes/safe/component/AddTransaction/createTransactions'
export const CONFIRMATIONS_ERROR = 'Number of confirmations can not be higher than the number of owners'
@ -56,7 +56,7 @@ const WithdrawnForm = ({ balance }: Props) => () => (
name={TX_VALUE_PARAM}
component={TextField}
type="text"
validate={composeValidators(required, mustBeNumber, greaterThan(0), inLimit(balance, 0, 'available balance'))}
validate={composeValidators(required, mustBeFloat, greaterThan(0), inLimit(balance, 0, 'available balance'))}
placeholder="Amount in ETH*"
text="Amount in ETH"
/>

View File

@ -5,7 +5,7 @@ import Block from '~/components/layout/Block'
import Bold from '~/components/layout/Bold'
import Heading from '~/components/layout/Heading'
import Paragraph from '~/components/layout/Paragraph'
import { TX_NAME_PARAM, TX_DESTINATION_PARAM, TX_VALUE_PARAM } from '~/routes/safe/component/AddTransaction/transactions'
import { TX_NAME_PARAM, TX_DESTINATION_PARAM, TX_VALUE_PARAM } from '~/routes/safe/component/AddTransaction/createTransactions'
type FormProps = {
values: Object,

View File

@ -7,6 +7,7 @@ import { makeTransaction, type Transaction, type TransactionProps } from '~/rout
import { getGnosisSafeContract } from '~/wallets/safeContracts'
import { getWeb3 } from '~/wallets/getWeb3'
import { type Safe } from '~/routes/safe/store/model/safe'
import { sameAddress } from '~/wallets/ethAddresses'
export const TX_NAME_PARAM = 'txName'
export const TX_DESTINATION_PARAM = 'txDestination'
@ -21,14 +22,14 @@ export const buildConfirmationsFrom =
throw new Error('This safe has no owners')
}
if (!owners.find((owner: Owner) => owner.get('address') === creator)) {
if (!owners.find((owner: Owner) => sameAddress(owner.get('address'), creator))) {
throw new Error('The creator of the tx is not an owner')
}
return owners.map((owner: Owner) => makeConfirmation({
owner,
status: owner.get('address') === creator,
hash: owner.get('address') === creator ? confirmationHash : undefined,
status: sameAddress(owner.get('address'), creator),
hash: sameAddress(owner.get('address'), creator) ? confirmationHash : undefined,
}))
}
@ -93,7 +94,8 @@ export const createTransaction = async (
const valueInWei = web3.toWei(txValue, 'ether')
const CALL = 0
if (hasOneOwner(safe)) {
const thresholdIsOne = safe.get('confirmations') === 1
if (hasOneOwner(safe) || thresholdIsOne) {
const txReceipt = await gnosisSafe.execTransactionIfApproved(txDestination, valueInWei, '0x', CALL, nonce, { from: user, gas: '5000000' })
const executedConfirmations: List<Confirmation> = buildExecutedConfirmationFrom(safe.get('owners'), user)
return storeTransaction(txName, nonce, txDestination, txValue, user, executedConfirmations, txReceipt.tx, safeAddress, safe.get('confirmations'))

View File

@ -6,7 +6,7 @@ import { sleep } from '~/utils/timer'
import { type Safe } from '~/routes/safe/store/model/safe'
import actions, { type Actions } from './actions'
import selector, { type SelectorProps } from './selector'
import { createTransaction, TX_NAME_PARAM, TX_DESTINATION_PARAM, TX_VALUE_PARAM } from './transactions'
import { createTransaction, TX_NAME_PARAM, TX_DESTINATION_PARAM, TX_VALUE_PARAM } from './createTransactions'
import MultisigForm from './MultisigForm'
import ReviewTx from './ReviewTx'

View File

@ -1,6 +1,6 @@
// @flow
import { List, Map } from 'immutable'
import { storeTransaction, buildConfirmationsFrom, EXECUTED_CONFIRMATION_HASH, buildExecutedConfirmationFrom } from '~/routes/safe/component/AddTransaction/transactions'
import { storeTransaction, buildConfirmationsFrom, EXECUTED_CONFIRMATION_HASH, buildExecutedConfirmationFrom } from '~/routes/safe/component/AddTransaction/createTransactions'
import { type Transaction } from '~/routes/safe/store/model/transaction'
import { SafeFactory } from '~/routes/safe/store/test/builder/safe.builder'
import { type Safe } from '~/routes/safe/store/model/safe'

View File

@ -90,7 +90,7 @@ describe('React DOM TESTS > Withdrawn funds from safe', () => {
TestUtils.Simulate.click(paragraphs[2]) // expanded
await sleep(1000) // Time to expand
const paragraphsExpanded = TestUtils.scryRenderedDOMComponentsWithTag(Transaction, 'p')
const txHashParagraph = paragraphsExpanded[paragraphsExpanded.length - 1]
const txHashParagraph = paragraphsExpanded[3]
const transactions = safeTransactionsSelector(store.getState(), { safeAddress: address })
const batteryTx = transactions.get(0)

View File

@ -21,6 +21,7 @@ const styles = {
type Props = Open & WithStyles & {
confirmations: List<Confirmation>,
threshold: number,
}
const GnoConfirmation = ({ owner, status, hash }: ConfirmationProps) => {
@ -45,35 +46,31 @@ const GnoConfirmation = ({ owner, status, hash }: ConfirmationProps) => {
}
const Confirmaitons = openHoc(({
open, toggle, confirmations,
}: Props) => {
const threshold = confirmations.count()
return (
<React.Fragment>
<ListItem onClick={toggle}>
<Avatar>
<Group />
</Avatar>
<ListItemText primary="Threshold" secondary={`${threshold} confirmation${threshold === 1 ? '' : 's'} needed`} />
<ListItemIcon>
{open ? <ExpandLess /> : <ExpandMore />}
</ListItemIcon>
</ListItem>
<Collapse in={open} timeout="auto" unmountOnExit>
<List component="div" disablePadding style={{ width: '100%' }}>
{confirmations.map(confirmation => (
<GnoConfirmation
key={confirmation.get('owner').get('address')}
owner={confirmation.get('owner')}
status={confirmation.get('status')}
hash={confirmation.get('hash')}
/>
))}
</List>
</Collapse>
</React.Fragment>
)
})
open, toggle, confirmations, threshold,
}: Props) => (
<React.Fragment>
<ListItem onClick={toggle}>
<Avatar>
<Group />
</Avatar>
<ListItemText primary="Threshold" secondary={`${threshold} confirmation${threshold === 1 ? '' : 's'} needed`} />
<ListItemIcon>
{open ? <ExpandLess /> : <ExpandMore />}
</ListItemIcon>
</ListItem>
<Collapse in={open} timeout="auto" unmountOnExit>
<List component="div" disablePadding style={{ width: '100%' }}>
{confirmations.map(confirmation => (
<GnoConfirmation
key={confirmation.get('owner').get('address')}
owner={confirmation.get('owner')}
status={confirmation.get('status')}
hash={confirmation.get('hash')}
/>
))}
</List>
</Collapse>
</React.Fragment>
))
export default withStyles(styles)(Confirmaitons)

View File

@ -15,7 +15,7 @@ type Props = {
safeName: string,
confirmations: ImmutableList<Confirmation>,
destination: string,
tx: string,
threshold: number,
}
const listStyle = {
@ -25,7 +25,7 @@ const listStyle = {
class Collapsed extends React.PureComponent<Props, {}> {
render() {
const {
confirmations, destination, safeName, tx,
confirmations, destination, safeName, threshold,
} = this.props
return (
@ -36,17 +36,11 @@ class Collapsed extends React.PureComponent<Props, {}> {
<Avatar><Group /></Avatar>
<ListItemText primary={safeName} secondary="Safe Name" />
</ListItem>
<Confirmations confirmations={confirmations} />
<Confirmations confirmations={confirmations} threshold={threshold} />
<ListItem>
<Avatar><MailOutline /></Avatar>
<ListItemText primary="Destination" secondary={destination} />
</ListItem>
{ tx &&
<ListItem>
<Avatar><MailOutline /></Avatar>
<ListItemText cut primary="Transaction Hash" secondary={tx} />
</ListItem>
}
</List>
</Col>
</Row>

View File

@ -1,5 +1,6 @@
// @flow
import * as React from 'react'
import { List } from 'immutable'
import { connect } from 'react-redux'
import openHoc, { type Open } from '~/components/hoc/OpenHoc'
import ExpandLess from 'material-ui-icons/ExpandLess'
@ -11,24 +12,37 @@ import Avatar from 'material-ui/Avatar'
import AttachMoney from 'material-ui-icons/AttachMoney'
import Atm from 'material-ui-icons/LocalAtm'
import DoneAll from 'material-ui-icons/DoneAll'
import CompareArrows from 'material-ui-icons/CompareArrows'
import Collapsed from '~/routes/safe/component/Transactions/Collapsed'
import { type Transaction } from '~/routes/safe/store/model/transaction'
import Hairline from '~/components/layout/Hairline/index'
import Button from '~/components/layout/Button'
import { sameAddress } from '~/wallets/ethAddresses'
import { type Confirmation } from '~/routes/safe/store/model/confirmation'
import selector, { type SelectorProps } from './selector'
type Props = Open & SelectorProps & {
transaction: Transaction,
safeName: string,
onProcessTx: (tx: Transaction, alreadyConfirmed: number) => void,
}
export const PROCESS_TXS = 'PROCESS TRANSACTION'
class GnoTransaction extends React.PureComponent<Props, {}> {
onProccesClick = () => this.props.onProcessTx(this.props.transaction, this.props.confirmed)
hasConfirmed = (userAddress: string, confirmations: List<Confirmation>): boolean =>
confirmations.filter((conf: Confirmation) => sameAddress(userAddress, conf.get('owner').get('address')) && conf.get('status')).count() > 0
render() {
const {
open, toggle, transaction, confirmed, safeName,
open, toggle, transaction, confirmed, safeName, userAddress,
} = this.props
const txHash = transaction.get('tx')
const confirmationText = txHash ? 'Already executed' : `${confirmed} of the ${transaction.get('threshold')} confirmations needed`
const userConfirmed = this.hasConfirmed(userAddress, transaction.get('confirmations'))
return (
<React.Fragment>
@ -51,12 +65,37 @@ class GnoTransaction extends React.PureComponent<Props, {}> {
</ListItemIcon>
</ListItem>
</Row>
<Row>
<ListItem>
{ txHash &&
<React.Fragment>
<Avatar><CompareArrows /></Avatar>
<ListItemText cut primary="Transaction Hash" secondary={txHash} />
</React.Fragment>
}
{ !txHash && userConfirmed &&
<React.Fragment>
<Avatar><CompareArrows /></Avatar>
<ListItemText cut primary="Confirmed" secondary="Waiting for the rest of confirmations" />
</React.Fragment>
}
{ !txHash && !userConfirmed &&
<Button
variant="raised"
color="primary"
onClick={this.onProccesClick}
>
{PROCESS_TXS}
</Button>
}
</ListItem>
</Row>
{ open &&
<Collapsed
safeName={safeName}
confirmations={transaction.get('confirmations')}
destination={transaction.get('destination')}
tx={transaction.get('tx')}
threshold={transaction.get('threshold')}
/> }
<Hairline />
</React.Fragment>

View File

@ -1,11 +1,14 @@
// @flow
import { createStructuredSelector } from 'reselect'
import { confirmationsTransactionSelector } from '~/routes/safe/store/selectors/index'
import { userAccountSelector } from '~/wallets/store/selectors/index'
export type SelectorProps = {
confirmed: confirmationsTransactionSelector,
userAddress: userAccountSelector,
}
export default createStructuredSelector({
confirmed: confirmationsTransactionSelector,
userAddress: userAccountSelector,
})

View File

@ -0,0 +1,10 @@
// @flow
import fetchTransactions from '~/routes/safe/store/actions/fetchTransactions'
export type Actions = {
fetchTransactions: typeof fetchTransactions,
}
export default {
fetchTransactions,
}

View File

@ -4,22 +4,23 @@ import { connect } from 'react-redux'
import { type Transaction } from '~/routes/safe/store/model/transaction'
import NoTransactions from '~/routes/safe/component/Transactions/NoTransactions'
import GnoTransaction from '~/routes/safe/component/Transactions/Transaction'
import { sleep } from '~/utils/timer'
import { processTransaction } from './processTransactions'
import selector, { type SelectorProps } from './selector'
import actions, { type Actions } from './actions'
type Props = SelectorProps & {
type Props = SelectorProps & Actions & {
onAddTx: () => void,
safeName: string,
safeAddress: string,
}
class Transactions extends React.Component<Props, {}> {
onConfirm = () => {
// eslint-disable-next-line
console.log("Confirming tx")
}
onExecute = () => {
// eslint-disable-next-line
console.log("Confirming tx")
onProcessTx = async (tx: Transaction, alreadyConfirmed: number) => {
const { fetchTransactions, safeAddress, userAddress } = this.props
await processTransaction(safeAddress, tx, alreadyConfirmed, userAddress)
await sleep(1200)
fetchTransactions()
}
render() {
@ -29,7 +30,7 @@ class Transactions extends React.Component<Props, {}> {
return (
<React.Fragment>
{ hasTransactions
? transactions.map((tx: Transaction) => <GnoTransaction key={tx.get('nonce')} safeName={safeName} transaction={tx} />)
? transactions.map((tx: Transaction) => <GnoTransaction key={tx.get('nonce')} safeName={safeName} onProcessTx={this.onProcessTx} transaction={tx} />)
: <NoTransactions onAddTx={onAddTx} />
}
</React.Fragment>
@ -37,4 +38,4 @@ class Transactions extends React.Component<Props, {}> {
}
}
export default connect(selector)(Transactions)
export default connect(selector, actions)(Transactions)

View File

@ -0,0 +1,130 @@
// @flow
import { List } from 'immutable'
import { type Owner } from '~/routes/safe/store/model/owner'
import { load, TX_KEY } from '~/utils/localStorage'
import { type Confirmation, makeConfirmation } from '~/routes/safe/store/model/confirmation'
import { makeTransaction, type Transaction, type TransactionProps } from '~/routes/safe/store/model/transaction'
import { getGnosisSafeContract } from '~/wallets/safeContracts'
import { getWeb3 } from '~/wallets/getWeb3'
import { sameAddress } from '~/wallets/ethAddresses'
import { EXECUTED_CONFIRMATION_HASH } from '~/routes/safe/component/AddTransaction/createTransactions'
export const updateTransaction = (
name: string,
nonce: number,
destination: string,
value: number,
creator: string,
confirmations: List<Confirmation>,
tx: string,
safeAddress: string,
safeThreshold: number,
) => {
const transaction: Transaction = makeTransaction({
name, nonce, value, confirmations, destination, threshold: safeThreshold, tx,
})
const safeTransactions = load(TX_KEY) || {}
const transactions = safeTransactions[safeAddress]
const txsRecord = transactions ? List(transactions) : List([])
const index = txsRecord.findIndex((trans: TransactionProps) => trans.nonce === nonce)
safeTransactions[safeAddress] = txsRecord.remove(index).push(transaction)
localStorage.setItem(TX_KEY, JSON.stringify(safeTransactions))
}
const getData = () => '0x'
const getOperation = () => 0
const execTransaction = async (
gnosisSafe: any,
destination: string,
txValue: number,
nonce: number,
executor: string,
) => {
const data = getData()
const CALL = getOperation()
const web3 = getWeb3()
const valueInWei = web3.toWei(txValue, 'ether')
const txReceipt = await gnosisSafe.execTransactionIfApproved(destination, valueInWei, data, CALL, nonce, { from: executor, gas: '5000000' })
return txReceipt
}
const execConfirmation = async (
gnosisSafe: any,
txDestination: string,
txValue: number,
nonce: number,
executor: string,
) => {
const data = getData()
const CALL = getOperation()
const web3 = getWeb3()
const valueInWei = web3.toWei(txValue, 'ether')
const txConfirmationReceipt = await gnosisSafe.approveTransactionWithParameters(txDestination, valueInWei, data, CALL, nonce, { from: executor, gas: '5000000' })
return txConfirmationReceipt
}
const updateConfirmations = (confirmations: List<Confirmation>, userAddress: string, txHash: string) =>
confirmations.map((confirmation: Confirmation) => {
const owner: Owner = confirmation.get('owner')
const samePerson = sameAddress(owner.get('address'), userAddress)
const status: boolean = samePerson ? true : confirmation.get('status')
const hash: string = samePerson ? txHash : confirmation.get('hash')
return makeConfirmation({ owner, status, hash })
})
export const processTransaction = async (
safeAddress: string,
tx: Transaction,
alreadyConfirmed: number,
userAddress: string,
) => {
const web3 = getWeb3()
const GnosisSafe = await getGnosisSafeContract(web3)
const gnosisSafe = GnosisSafe.at(safeAddress)
const confirmations = tx.get('confirmations')
const userHasAlreadyConfirmed = confirmations.filter((confirmation: Confirmation) => {
const ownerAddress = confirmation.get('owner').get('address')
const samePerson = sameAddress(ownerAddress, userAddress)
return samePerson && confirmation.get('status')
}).count() > 0
if (userHasAlreadyConfirmed) {
throw new Error('Owner has already confirmed this transaction')
}
const threshold = tx.get('threshold')
const thresholdReached = threshold >= alreadyConfirmed + 1
const nonce = tx.get('nonce')
const txName = tx.get('name')
const txValue = tx.get('value')
const txDestination = tx.get('destination')
const txReceipt = thresholdReached
? await execTransaction(gnosisSafe, txDestination, txValue, nonce, userAddress)
: await execConfirmation(gnosisSafe, txDestination, txValue, nonce, userAddress)
const confirmationHash = thresholdReached ? EXECUTED_CONFIRMATION_HASH : txReceipt.tx
const executedConfirmations: List<Confirmation> = updateConfirmations(tx.get('confirmations'), userAddress, confirmationHash)
return updateTransaction(
txName,
nonce,
txDestination,
txValue,
userAddress,
executedConfirmations,
txReceipt.tx,
safeAddress,
threshold,
)
}

View File

@ -3,11 +3,14 @@ import { List } from 'immutable'
import { createStructuredSelector } from 'reselect'
import { type Transaction } from '~/routes/safe/store/model/transaction'
import { safeTransactionsSelector } from '~/routes/safe/store/selectors/index'
import { userAccountSelector } from '~/wallets/store/selectors/index'
export type SelectorProps = {
transactions: List<Transaction>,
userAddress: userAccountSelector,
}
export default createStructuredSelector({
transactions: safeTransactionsSelector,
userAddress: userAccountSelector,
})

View File

@ -2,7 +2,7 @@
import * as React from 'react'
import Field from '~/components/forms/Field'
import TextField from '~/components/forms/TextField'
import { composeValidators, inLimit, mustBeNumber, required, greaterThan, mustBeEthereumAddress } from '~/components/forms/validator'
import { composeValidators, inLimit, mustBeFloat, required, greaterThan, mustBeEthereumAddress } from '~/components/forms/validator'
import Block from '~/components/layout/Block'
import Heading from '~/components/layout/Heading'
import { DESTINATION_PARAM, VALUE_PARAM } from '~/routes/safe/component/Withdrawn/withdrawn'
@ -37,7 +37,7 @@ const WithdrawnForm = ({ limit, spentToday }: Props) => () => (
name={VALUE_PARAM}
component={TextField}
type="text"
validate={composeValidators(required, mustBeNumber, greaterThan(0), inLimit(limit, spentToday, 'daily limit'))}
validate={composeValidators(required, mustBeFloat, greaterThan(0), inLimit(limit, spentToday, 'daily limit'))}
placeholder="Amount in ETH*"
text="Amount in ETH"
/>

View File

@ -43,9 +43,9 @@ const withdrawn = async (values: Object, safeAddress: string, userAccount: strin
const value = web3.toWei(values[VALUE_PARAM], 'ether')
return dailyLimitModule.executeDailyLimit(
0,
destination,
value,
0,
{ from: userAccount, gas: '5000000' },
)
}

View File

@ -6,6 +6,7 @@ import { providerNameSelector, userAccountSelector } from '~/wallets/store/selec
import { type Safe } from '~/routes/safe/store/model/safe'
import { type Owner } from '~/routes/safe/store/model/owner'
import { type GlobalState } from '~/store/index'
import { sameAddress } from '~/wallets/ethAddresses'
export type SelectorProps = {
safe: SafeSelectorProps,
@ -30,7 +31,7 @@ export const grantedSelector: Selector<GlobalState, RouterProps, boolean> = crea
return false
}
return owners.find((owner: Owner) => owner.get('address') === userAccount) !== undefined
return owners.find((owner: Owner) => sameAddress(owner.get('address'), userAccount)) !== undefined
},
)

View File

@ -16,7 +16,7 @@ const grantedSelectorTests = () => {
})
describe('Safe Selector[grantedSelector]', () => {
it('should be granted to operate when a safe when the user is owner', () => {
it('should be granted to operate a safe when the user is owner', () => {
// GIVEN
let map: Map<string, Safe> = Map()
map = map.set('fooAddress', SafeFactory.oneOwnerSafe(provider.account))
@ -37,6 +37,27 @@ const grantedSelectorTests = () => {
expect(granted).toBe(true)
})
it('should be granted to operate a safe when the user is owner in case-insensitive', () => {
// GIVEN
let map: Map<string, Safe> = Map()
map = map.set('fooAddress', SafeFactory.oneOwnerSafe(provider.account.toUpperCase()))
const match: Match = buildMathPropsFrom('fooAddress')
const reduxStore = {
[SAFE_REDUCER_ID]: map,
providers: makeProvider(provider),
balances: undefined,
transactions: undefined,
}
// WHEN
const granted = grantedSelector(reduxStore, { match })
// THEN
expect(granted).toBe(true)
})
it('should NOT be granted to operate with a Safe when the user is NOT owner', () => {
// GIVEN
let map: Map<string, Safe> = Map()

View File

@ -5,6 +5,7 @@ import { type GlobalState } from '~/store/index'
import { type Safe } from '~/routes/safe/store/model/safe'
import { userAccountSelector } from '~/wallets/store/selectors/index'
import { type Owner } from '~/routes/safe/store/model/owner'
import { sameAddress } from '~/wallets/ethAddresses'
export const safesMapSelector = (state: GlobalState): Map<string, Safe> => state.safes
const safesListSelector: Selector<GlobalState, {}, List<Safe>> = createSelector(
@ -17,10 +18,5 @@ export const safesByOwnerSelector: Selector<GlobalState, {}, List<Safe>> = creat
safesListSelector,
(userAddress: string, safes: List<Safe>): List<Safe> =>
safes.filter((safe: Safe) =>
safe.owners.filter((owner: Owner) => {
const ownerLower = owner.get('address').toLowerCase()
const userLower = userAddress.toLowerCase()
return ownerLower === userLower
}).count() > 0),
safe.owners.filter((owner: Owner) => sameAddress(owner.get('address'), userAddress)).count() > 0),
)

View File

@ -0,0 +1,3 @@
// @flow
export const sameAddress = (firstAddress: string, secondAddress: string): boolean =>
firstAddress.toLowerCase() === secondAddress.toLowerCase()

132
yarn.lock
View File

@ -3297,6 +3297,10 @@ commander@0.6.1:
version "0.6.1"
resolved "https://registry.yarnpkg.com/commander/-/commander-0.6.1.tgz#fa68a14f6a945d54dbbe50d8cdb3320e9e3b1a06"
commander@2.11.0:
version "2.11.0"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.11.0.tgz#157152fd1e7a6c8d98a5b715cf376df928004563"
commander@2.14.x, commander@~2.14.1:
version "2.14.1"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.14.1.tgz#2235123e37af8ca3c65df45b026dbd357b01b9aa"
@ -3305,12 +3309,6 @@ commander@2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.3.0.tgz#fd430e889832ec353b9acd1de217c11cb3eef873"
commander@2.9.0:
version "2.9.0"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.9.0.tgz#9c99094176e12240cb22d6c5146098400fe0f7d4"
dependencies:
graceful-readlink ">= 1.0.0"
commander@^2.11.0, commander@^2.12.2, commander@^2.13.0, commander@^2.8.1, commander@^2.9.0:
version "2.15.0"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.15.0.tgz#ad2a23a1c3b036e392469b8012cec6b33b4c1322"
@ -3757,19 +3755,13 @@ debug@2.2.0, debug@~2.2.0:
dependencies:
ms "0.7.1"
debug@2.6.8:
version "2.6.8"
resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.8.tgz#e731531ca2ede27d188222427da17821d68ff4fc"
dependencies:
ms "2.0.0"
debug@2.6.9, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.6, debug@^2.6.8, debug@^2.6.9:
version "2.6.9"
resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f"
dependencies:
ms "2.0.0"
debug@^3.0.1, debug@^3.1.0:
debug@3.1.0, debug@^3.0.1, debug@^3.1.0:
version "3.1.0"
resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261"
dependencies:
@ -3959,9 +3951,9 @@ diff@1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/diff/-/diff-1.4.0.tgz#7f28d2eb9ee7b15a97efd89ce63dcfdaa3ccbabf"
diff@3.2.0:
version "3.2.0"
resolved "https://registry.yarnpkg.com/diff/-/diff-3.2.0.tgz#c9ce393a4b7cbd0b058a725c93df299027868ff9"
diff@3.3.1:
version "3.3.1"
resolved "https://registry.yarnpkg.com/diff/-/diff-3.3.1.tgz#aa8567a6eed03c531fc89d3f711cd0e5259dec75"
diff@^3.2.0, diff@^3.3.1, diff@^3.5.0:
version "3.5.0"
@ -5316,14 +5308,14 @@ glob@3.2.11:
inherits "2"
minimatch "0.3"
glob@7.1.1:
version "7.1.1"
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.1.tgz#805211df04faaf1c63a3600306cdf5ade50b2ec8"
glob@7.1.2, glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.1.0, glob@^7.1.1, glob@^7.1.2, glob@~7.1.1, glob@~7.1.2:
version "7.1.2"
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15"
dependencies:
fs.realpath "^1.0.0"
inflight "^1.0.4"
inherits "2"
minimatch "^3.0.2"
minimatch "^3.0.4"
once "^1.3.0"
path-is-absolute "^1.0.0"
@ -5337,17 +5329,6 @@ glob@^6.0.1:
once "^1.3.0"
path-is-absolute "^1.0.0"
glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.1.0, glob@^7.1.1, glob@^7.1.2, glob@~7.1.1, glob@~7.1.2:
version "7.1.2"
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15"
dependencies:
fs.realpath "^1.0.0"
inflight "^1.0.4"
inherits "2"
minimatch "^3.0.4"
once "^1.3.0"
path-is-absolute "^1.0.0"
global-modules@1.0.0, global-modules@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-1.0.0.tgz#6d770f0eb523ac78164d72b5e71a8877265cc3ea"
@ -5455,10 +5436,6 @@ graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9,
version "4.1.11"
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658"
"graceful-readlink@>= 1.0.0":
version "1.0.1"
resolved "https://registry.yarnpkg.com/graceful-readlink/-/graceful-readlink-1.0.1.tgz#4cafad76bc62f02fa039b2f94e9a3dd3a391a725"
graphlib@^2.0.0:
version "2.1.5"
resolved "https://registry.yarnpkg.com/graphlib/-/graphlib-2.1.5.tgz#6afe1afcc5148555ec799e499056795bd6938c87"
@ -5471,6 +5448,10 @@ grouped-queue@^0.3.3:
dependencies:
lodash "^4.17.2"
growl@1.10.3:
version "1.10.3"
resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.3.tgz#1926ba90cf3edfe2adb4927f5880bc22c66c790f"
growl@1.9.2:
version "1.9.2"
resolved "https://registry.yarnpkg.com/growl/-/growl-1.9.2.tgz#0ea7743715db8d8de2c5ede1775e1b45ac85c02f"
@ -6898,7 +6879,7 @@ json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1:
version "5.0.1"
resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb"
json3@3.3.2, json3@^3.3.2:
json3@^3.3.2:
version "3.3.2"
resolved "https://registry.yarnpkg.com/json3/-/json3-3.3.2.tgz#3c0434743df93e2f5c42aee7b19bcb483575f4e1"
@ -7263,29 +7244,10 @@ lodash-es@^4.17.4, lodash-es@^4.17.5, lodash-es@^4.2.1:
version "4.17.7"
resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.7.tgz#db240a3252c3dd8360201ac9feef91ac977ea856"
lodash._baseassign@^3.0.0:
version "3.2.0"
resolved "https://registry.yarnpkg.com/lodash._baseassign/-/lodash._baseassign-3.2.0.tgz#8c38a099500f215ad09e59f1722fd0c52bfe0a4e"
dependencies:
lodash._basecopy "^3.0.0"
lodash.keys "^3.0.0"
lodash._basecopy@^3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36"
lodash._basecreate@^3.0.0:
version "3.0.3"
resolved "https://registry.yarnpkg.com/lodash._basecreate/-/lodash._basecreate-3.0.3.tgz#1bc661614daa7fc311b7d03bf16806a0213cf821"
lodash._getnative@^3.0.0:
version "3.9.1"
resolved "https://registry.yarnpkg.com/lodash._getnative/-/lodash._getnative-3.9.1.tgz#570bc7dede46d61cdcde687d65d3eecbaa3aaff5"
lodash._isiterateecall@^3.0.0:
version "3.0.9"
resolved "https://registry.yarnpkg.com/lodash._isiterateecall/-/lodash._isiterateecall-3.0.9.tgz#5203ad7ba425fae842460e696db9cf3e6aac057c"
lodash.assign@^4.0.3, lodash.assign@^4.0.6, lodash.assign@^4.2.0:
version "4.2.0"
resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7"
@ -7298,14 +7260,6 @@ lodash.clonedeep@^4.3.2:
version "4.5.0"
resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef"
lodash.create@3.1.1:
version "3.1.1"
resolved "https://registry.yarnpkg.com/lodash.create/-/lodash.create-3.1.1.tgz#d7f2849f0dbda7e04682bb8cd72ab022461debe7"
dependencies:
lodash._baseassign "^3.0.0"
lodash._basecreate "^3.0.0"
lodash._isiterateecall "^3.0.0"
lodash.debounce@^4.0.8:
version "4.0.8"
resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af"
@ -7326,7 +7280,7 @@ lodash.isplainobject@^4.0.6:
version "4.0.6"
resolved "https://registry.yarnpkg.com/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz#7c526a52d89b45c45cc690b88163be0497f550cb"
lodash.keys@^3.0.0, lodash.keys@^3.1.2:
lodash.keys@^3.1.2:
version "3.1.2"
resolved "https://registry.yarnpkg.com/lodash.keys/-/lodash.keys-3.1.2.tgz#4dbc0472b156be50a0b286855d1bd0b0c656098a"
dependencies:
@ -7806,22 +7760,20 @@ mocha@^2.3.3, mocha@^2.4.5:
supports-color "1.2.0"
to-iso-string "0.0.2"
mocha@^3.4.2:
version "3.5.3"
resolved "https://registry.yarnpkg.com/mocha/-/mocha-3.5.3.tgz#1e0480fe36d2da5858d1eb6acc38418b26eaa20d"
mocha@^4.1.0:
version "4.1.0"
resolved "https://registry.yarnpkg.com/mocha/-/mocha-4.1.0.tgz#7d86cfbcf35cb829e2754c32e17355ec05338794"
dependencies:
browser-stdout "1.3.0"
commander "2.9.0"
debug "2.6.8"
diff "3.2.0"
commander "2.11.0"
debug "3.1.0"
diff "3.3.1"
escape-string-regexp "1.0.5"
glob "7.1.1"
growl "1.9.2"
glob "7.1.2"
growl "1.10.3"
he "1.1.1"
json3 "3.3.2"
lodash.create "3.1.1"
mkdirp "0.5.1"
supports-color "3.1.2"
supports-color "4.4.0"
module-deps@^4.0.8:
version "4.1.1"
@ -10477,9 +10429,9 @@ sockjs@0.3.19:
faye-websocket "^0.10.0"
uuid "^3.0.1"
solc@0.4.23:
version "0.4.23"
resolved "https://registry.yarnpkg.com/solc/-/solc-0.4.23.tgz#54a0ff4015827b32fddb62c0a418b5247310a58e"
solc@0.4.24:
version "0.4.24"
resolved "https://registry.yarnpkg.com/solc/-/solc-0.4.24.tgz#354f14b269b38cbaa82a47d1ff151723502b954e"
dependencies:
fs-extra "^0.30.0"
memorystream "^0.3.1"
@ -10926,11 +10878,11 @@ supports-color@1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-1.2.0.tgz#ff1ed1e61169d06b3cf2d588e188b18d8847e17e"
supports-color@3.1.2:
version "3.1.2"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.1.2.tgz#72a262894d9d408b956ca05ff37b2ed8a6e2a2d5"
supports-color@4.4.0:
version "4.4.0"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-4.4.0.tgz#883f7ddabc165142b2a61427f3352ded195d1a3e"
dependencies:
has-flag "^1.0.0"
has-flag "^2.0.0"
supports-color@^2.0.0:
version "2.0.0"
@ -11262,14 +11214,6 @@ truffle-solidity-loader@0.0.8:
truffle "^2.0.8"
web3 "^0.17.0-alpha"
truffle@4.1.8:
version "4.1.8"
resolved "https://registry.yarnpkg.com/truffle/-/truffle-4.1.8.tgz#b0b9175e0270145999567a3f0a2337c914a23a9c"
dependencies:
mocha "^3.4.2"
original-require "^1.0.1"
solc "0.4.23"
truffle@^2.0.8:
version "2.1.2"
resolved "https://registry.yarnpkg.com/truffle/-/truffle-2.1.2.tgz#1ee61b9d785f6f2edb42801579e31f15b66c3746"
@ -11302,6 +11246,14 @@ truffle@^2.0.8:
web3 "^0.16.0"
yargs "^3.27.0"
"truffle@git://github.com/trufflesuite/truffle.git#develop":
version "4.1.11"
resolved "git://github.com/trufflesuite/truffle.git#2d722ce8df62271aece9dd3f652489d50c5f7b4b"
dependencies:
mocha "^4.1.0"
original-require "^1.0.1"
solc "0.4.24"
tryer@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/tryer/-/tryer-1.0.0.tgz#027b69fa823225e551cace3ef03b11f6ab37c1d7"