safe-react/safe-contracts/build/contracts/SocialRecoveryModule.json

7299 lines
327 KiB
JSON

{
"contractName": "SocialRecoveryModule",
"abi": [
{
"constant": true,
"inputs": [],
"name": "threshold",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "manager",
"outputs": [
{
"name": "",
"type": "address"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "address"
}
],
"name": "isFriend",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_masterCopy",
"type": "address"
}
],
"name": "changeMasterCopy",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "NAME",
"outputs": [
{
"name": "",
"type": "string"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "bytes32"
},
{
"name": "",
"type": "address"
}
],
"name": "isConfirmed",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "uint256"
}
],
"name": "friends",
"outputs": [
{
"name": "",
"type": "address"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "bytes32"
}
],
"name": "isExecuted",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "VERSION",
"outputs": [
{
"name": "",
"type": "string"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_friends",
"type": "address[]"
},
{
"name": "_threshold",
"type": "uint256"
}
],
"name": "setup",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "dataHash",
"type": "bytes32"
}
],
"name": "confirmTransaction",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "prevOwner",
"type": "address"
},
{
"name": "oldOwner",
"type": "address"
},
{
"name": "newOwner",
"type": "address"
}
],
"name": "recoverAccess",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "dataHash",
"type": "bytes32"
}
],
"name": "isConfirmedByRequiredFriends",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "data",
"type": "bytes"
}
],
"name": "getDataHash",
"outputs": [
{
"name": "",
"type": "bytes32"
}
],
"payable": false,
"stateMutability": "pure",
"type": "function"
}
],
"bytecode": "0x608060405234801561001057600080fd5b50611790806100206000396000f3006080604052600436106100d0576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806342cde4e8146100d5578063481c6a75146101005780634ab884271461015757806368125a1b146101c757806377231eaa1461022257806379716e43146102a55780637de7edef146102d65780639ca89d0d14610319578063a3f4df7e14610362578063ae68b056146103f2578063b79ffaff14610477578063ce146828146104e0578063e52cb36a1461054d578063ffa1ad7414610596575b600080fd5b3480156100e157600080fd5b506100ea610626565b6040518082815260200191505060405180910390f35b34801561010c57600080fd5b5061011561062c565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561016357600080fd5b506101c56004803603810190808035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437820191505050505050919291929080359060200190929190505050610652565b005b3480156101d357600080fd5b50610208600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061099d565b604051808215151515815260200191505060405180910390f35b34801561022e57600080fd5b506102a3600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506109bd565b005b3480156102b157600080fd5b506102d46004803603810190808035600019169060200190929190505050610f6e565b005b3480156102e257600080fd5b50610317600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611167565b005b34801561032557600080fd5b50610348600480360381019080803560001916906020019092919050505061134a565b604051808215151515815260200191505060405180910390f35b34801561036e57600080fd5b50610377611439565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156103b757808201518184015260208101905061039c565b50505050905090810190601f1680156103e45780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103fe57600080fd5b50610459600480360381019080803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509192919290505050611472565b60405180826000191660001916815260200191505060405180910390f35b34801561048357600080fd5b506104c66004803603810190808035600019169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506114de565b604051808215151515815260200191505060405180910390f35b3480156104ec57600080fd5b5061050b6004803603810190808035906020019092919050505061150d565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561055957600080fd5b5061057c600480360381019080803560001916906020019092919050505061154b565b604051808215151515815260200191505060405180910390f35b3480156105a257600080fd5b506105ab61156b565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156105eb5780820151818401526020810190506105d0565b50505050905090810190601f1680156106185780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b60025481565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080835183111515156106f4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f5468726573686f6c642063616e6e6f742065786365656420667269656e64732081526020017f636f756e7400000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b6002831015151561076d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f4174206c65617374203220667269656e6473207265717569726564000000000081525060200191505060405180910390fd5b6107756115a4565b600091505b835182101561097957838281518110151561079157fe5b90602001906020020151905060008173ffffffffffffffffffffffffffffffffffffffff161415151561082c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f496e76616c696420667269656e6420616464726573732070726f76696465640081525060200191505060405180910390fd5b600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16151515610914576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001807f4475706c696361746520667269656e6420616464726573732070726f7669646581526020017f640000000000000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b6001600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550818060010192505061077a565b836003908051906020019061098f929190611697565b508260028190555050505050565b60046020528060005260406000206000915054906101000a900460ff1681565b60606000600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161515610aa8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642062792061206681526020017f7269656e6400000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b848484604051602401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200193505050506040516020818303038152906040527fe318b52b000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050509150610bd582611472565b905060056000826000191660001916815260200190815260200160002060009054906101000a900460ff16151515610c75576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f5265636f7665727920616c72656164792065786563757465640000000000000081525060200191505060405180910390fd5b610c7e8161134a565b1515610d18576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f5265636f7665727920686173206e6f7420656e6f75676820636f6e6669726d6181526020017f74696f6e7300000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b600160056000836000191660001916815260200190815260200160002060006101000a81548160ff021916908315150217905550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663468721a7600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1660008560006040518563ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200180602001836002811115610e2957fe5b60ff168152602001828103825284818151815260200191508051906020019080838360005b83811015610e69578082015181840152602081019050610e4e565b50505050905090810190601f168015610e965780820380516001836020036101000a031916815260200191505b5095505050505050602060405180830381600087803b158015610eb857600080fd5b505af1158015610ecc573d6000803e3d6000fd5b505050506040513d6020811015610ee257600080fd5b81019080805190602001909291905050501515610f67576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f436f756c64206e6f742065786563757465207265636f7665727900000000000081525060200191505060405180910390fd5b5050505050565b600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161515611055576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642062792061206681526020017f7269656e6400000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b60056000826000191660001916815260200190815260200160002060009054906101000a900460ff161515156110f3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f5265636f7665727920616c72656164792065786563757465640000000000000081525060200191505060405180910390fd5b600160066000836000191660001916815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611252576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642066726f6d206d81526020017f616e61676572000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b60008173ffffffffffffffffffffffffffffffffffffffff1614151515611307576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001807f496e76616c6964206d617374657220636f707920616464726573732070726f7681526020017f696465640000000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60008060008090505b60038054905081101561142d57600660008560001916600019168152602001908152602001600020600060038381548110151561138c57fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161561140d5781806001019250505b6002548214156114205760019250611432565b8080600101915050611353565b600092505b5050919050565b6040805190810160405280601681526020017f536f6369616c205265636f76657279204d6f64756c650000000000000000000081525081565b6000816040518082805190602001908083835b6020831015156114aa5780518252602082019150602081019050602083039250611485565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390209050919050565b60066020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b60038181548110151561151c57fe5b906000526020600020016000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60056020528060005260406000206000915054906101000a900460ff1681565b6040805190810160405280600581526020017f302e302e3200000000000000000000000000000000000000000000000000000081525081565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16141515611654576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601c8152602001807f4d616e616765722068617320616c7265616479206265656e207365740000000081525060200191505060405180910390fd5b33600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b828054828255906000526020600020908101928215611710579160200282015b8281111561170f5782518260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550916020019190600101906116b7565b5b50905061171d9190611721565b5090565b61176191905b8082111561175d57600081816101000a81549073ffffffffffffffffffffffffffffffffffffffff021916905550600101611727565b5090565b905600a165627a7a7230582056674b0a048c9eb59cf0ed9e3af92ae17e0c455580386c7ab34db9e8f16583b80029",
"deployedBytecode": "0x6080604052600436106100d0576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806342cde4e8146100d5578063481c6a75146101005780634ab884271461015757806368125a1b146101c757806377231eaa1461022257806379716e43146102a55780637de7edef146102d65780639ca89d0d14610319578063a3f4df7e14610362578063ae68b056146103f2578063b79ffaff14610477578063ce146828146104e0578063e52cb36a1461054d578063ffa1ad7414610596575b600080fd5b3480156100e157600080fd5b506100ea610626565b6040518082815260200191505060405180910390f35b34801561010c57600080fd5b5061011561062c565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561016357600080fd5b506101c56004803603810190808035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437820191505050505050919291929080359060200190929190505050610652565b005b3480156101d357600080fd5b50610208600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061099d565b604051808215151515815260200191505060405180910390f35b34801561022e57600080fd5b506102a3600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506109bd565b005b3480156102b157600080fd5b506102d46004803603810190808035600019169060200190929190505050610f6e565b005b3480156102e257600080fd5b50610317600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611167565b005b34801561032557600080fd5b50610348600480360381019080803560001916906020019092919050505061134a565b604051808215151515815260200191505060405180910390f35b34801561036e57600080fd5b50610377611439565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156103b757808201518184015260208101905061039c565b50505050905090810190601f1680156103e45780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103fe57600080fd5b50610459600480360381019080803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509192919290505050611472565b60405180826000191660001916815260200191505060405180910390f35b34801561048357600080fd5b506104c66004803603810190808035600019169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506114de565b604051808215151515815260200191505060405180910390f35b3480156104ec57600080fd5b5061050b6004803603810190808035906020019092919050505061150d565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561055957600080fd5b5061057c600480360381019080803560001916906020019092919050505061154b565b604051808215151515815260200191505060405180910390f35b3480156105a257600080fd5b506105ab61156b565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156105eb5780820151818401526020810190506105d0565b50505050905090810190601f1680156106185780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b60025481565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080835183111515156106f4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f5468726573686f6c642063616e6e6f742065786365656420667269656e64732081526020017f636f756e7400000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b6002831015151561076d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f4174206c65617374203220667269656e6473207265717569726564000000000081525060200191505060405180910390fd5b6107756115a4565b600091505b835182101561097957838281518110151561079157fe5b90602001906020020151905060008173ffffffffffffffffffffffffffffffffffffffff161415151561082c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f496e76616c696420667269656e6420616464726573732070726f76696465640081525060200191505060405180910390fd5b600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16151515610914576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001807f4475706c696361746520667269656e6420616464726573732070726f7669646581526020017f640000000000000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b6001600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550818060010192505061077a565b836003908051906020019061098f929190611697565b508260028190555050505050565b60046020528060005260406000206000915054906101000a900460ff1681565b60606000600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161515610aa8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642062792061206681526020017f7269656e6400000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b848484604051602401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200193505050506040516020818303038152906040527fe318b52b000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050509150610bd582611472565b905060056000826000191660001916815260200190815260200160002060009054906101000a900460ff16151515610c75576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f5265636f7665727920616c72656164792065786563757465640000000000000081525060200191505060405180910390fd5b610c7e8161134a565b1515610d18576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f5265636f7665727920686173206e6f7420656e6f75676820636f6e6669726d6181526020017f74696f6e7300000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b600160056000836000191660001916815260200190815260200160002060006101000a81548160ff021916908315150217905550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663468721a7600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1660008560006040518563ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200180602001836002811115610e2957fe5b60ff168152602001828103825284818151815260200191508051906020019080838360005b83811015610e69578082015181840152602081019050610e4e565b50505050905090810190601f168015610e965780820380516001836020036101000a031916815260200191505b5095505050505050602060405180830381600087803b158015610eb857600080fd5b505af1158015610ecc573d6000803e3d6000fd5b505050506040513d6020811015610ee257600080fd5b81019080805190602001909291905050501515610f67576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f436f756c64206e6f742065786563757465207265636f7665727900000000000081525060200191505060405180910390fd5b5050505050565b600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161515611055576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642062792061206681526020017f7269656e6400000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b60056000826000191660001916815260200190815260200160002060009054906101000a900460ff161515156110f3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f5265636f7665727920616c72656164792065786563757465640000000000000081525060200191505060405180910390fd5b600160066000836000191660001916815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515611252576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001807f4d6574686f642063616e206f6e6c792062652063616c6c65642066726f6d206d81526020017f616e61676572000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b60008173ffffffffffffffffffffffffffffffffffffffff1614151515611307576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001807f496e76616c6964206d617374657220636f707920616464726573732070726f7681526020017f696465640000000000000000000000000000000000000000000000000000000081525060400191505060405180910390fd5b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60008060008090505b60038054905081101561142d57600660008560001916600019168152602001908152602001600020600060038381548110151561138c57fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161561140d5781806001019250505b6002548214156114205760019250611432565b8080600101915050611353565b600092505b5050919050565b6040805190810160405280601681526020017f536f6369616c205265636f76657279204d6f64756c650000000000000000000081525081565b6000816040518082805190602001908083835b6020831015156114aa5780518252602082019150602081019050602083039250611485565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390209050919050565b60066020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b60038181548110151561151c57fe5b906000526020600020016000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60056020528060005260406000206000915054906101000a900460ff1681565b6040805190810160405280600581526020017f302e302e3200000000000000000000000000000000000000000000000000000081525081565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16141515611654576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601c8152602001807f4d616e616765722068617320616c7265616479206265656e207365740000000081525060200191505060405180910390fd5b33600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b828054828255906000526020600020908101928215611710579160200282015b8281111561170f5782518260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550916020019190600101906116b7565b5b50905061171d9190611721565b5090565b61176191905b8082111561175d57600081816101000a81549073ffffffffffffffffffffffffffffffffffffffff021916905550600101611727565b5090565b905600a165627a7a7230582056674b0a048c9eb59cf0ed9e3af92ae17e0c455580386c7ab34db9e8f16583b80029",
"sourceMap": "328:3660:18:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;328:3660:18;;;;;;;",
"deployedSourceMap": "328:3660:18:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;482:24;;8:9:-1;5:2;;;30:1;27;20:12;5:2;482:24:18;;;;;;;;;;;;;;;;;;;;;;;270:28:4;;8:9:-1;5:2;;;30:1;27;20:12;5:2;270:28:4;;;;;;;;;;;;;;;;;;;;;;;;;;;1240:640:18;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1240:640:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;607:41;;8:9:-1;5:2;;;30:1;27;20:12;5:2;607:41:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2536:625;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2536:625:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1993:210;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1993:210:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;626:248:9;;8:9:-1;5:2;;;30:1;27;20:12;5:2;626:248:9;;;;;;;;;;;;;;;;;;;;;;;;;;;;3322:405:18;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3322:405:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;375:54;;8:9:-1;5:2;;;30:1;27;20:12;5:2;375:54:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;375:54:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3856:130;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3856:130:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;851:65;;8:9:-1;5:2;;;30:1;27;20:12;5:2;851:65:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;512:24;;8:9:-1;5:2;;;30:1;27;20:12;5:2;512:24:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;716:43;;8:9:-1;5:2;;;30:1;27;20:12;5:2;716:43:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;435:40;;8:9:-1;5:2;;;30:1;27;20:12;5:2;435:40:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;435:40:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;482:24;;;;:::o;270:28:4:-;;;;;;;;;;;;;:::o;1240:640:18:-;1537:9;1592:14;1346:8;:15;1332:10;:29;;1324:79;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1435:1;1421:10;:15;;1413:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1478:12;:10;:12::i;:::-;1549:1;1537:13;;1532:282;1556:8;:15;1552:1;:19;1532:282;;;1609:8;1618:1;1609:11;;;;;;;;;;;;;;;;;;1592:28;;1652:1;1642:6;:11;;;;1634:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1712:8;:16;1721:6;1712:16;;;;;;;;;;;;;;;;;;;;;;;;;1711:17;1703:63;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1799:4;1780:8;:16;1789:6;1780:16;;;;;;;;;;;;;;;;:23;;;;;;;;;;;;;;;;;;1573:3;;;;;;;1532:282;;;1833:8;1823:7;:18;;;;;;;;;;;;:::i;:::-;;1863:10;1851:9;:22;;;;1240:640;;;;:::o;607:41::-;;;;;;;;;;;;;;;;;;;;;;:::o;2536:625::-;2662:17;2784:16;963:8;:20;972:10;963:20;;;;;;;;;;;;;;;;;;;;;;;;;955:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2744:9;2755:8;2765;2682:92;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;2682:92:18;;;;;;;38:4:-1;29:7;25:18;67:10;61:17;96:58;199:8;192:4;186;182:15;179:29;167:10;160:49;0:215;;;2682:92:18;2662:112;;2803:17;2815:4;2803:11;:17::i;:::-;2784:36;;2839:10;:20;2850:8;2839:20;;;;;;;;;;;;;;;;;;;;;;;;;;;2838:21;2830:59;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2907:38;2936:8;2907:28;:38::i;:::-;2899:88;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3020:4;2997:10;:20;3008:8;2997:20;;;;;;;;;;;;;;;;;;:27;;;;;;;;;;;;;;;;;;3042:7;;;;;;;;;;;:33;;;3084:7;;;;;;;;;;;3094:1;3097:4;3103:19;3042:81;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3042:81:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3042:81:18;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3042:81:18;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3042:81:18;;;;;;;;;;;;;;;;3034:120;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2536:625;;;;;:::o;1993:210::-;963:8;:20;972:10;963:20;;;;;;;;;;;;;;;;;;;;;;;;;955:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2096:10;:20;2107:8;2096:20;;;;;;;;;;;;;;;;;;;;;;;;;;;2095:21;2087:59;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2192:4;2156:11;:21;2168:8;2156:21;;;;;;;;;;;;;;;;;:33;2178:10;2156:33;;;;;;;;;;;;;;;;:40;;;;;;;;;;;;;;;;;;1993:210;:::o;626:248:9:-;367:7:4;;;;;;;;;;;345:30;;:10;:30;;;337:81;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;791:1:9;776:11;:16;;;;768:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;856:11;843:10;;:24;;;;;;;;;;;;;;;;;;626:248;:::o;3322:405:18:-;3423:4;3443:25;3483:9;3495:1;3483:13;;3478:221;3502:7;:14;;;;3498:1;:18;3478:221;;;3541:11;:21;3553:8;3541:21;;;;;;;;;;;;;;;;;:33;3563:7;3571:1;3563:10;;;;;;;;;;;;;;;;;;;;;;;;;;;3541:33;;;;;;;;;;;;;;;;;;;;;;;;;3537:74;;;3592:19;;;;;;;3537:74;3650:9;;3629:17;:30;3625:63;;;3684:4;3677:11;;;;3625:63;3518:3;;;;;;;3478:221;;;3715:5;3708:12;;3322:405;;;;;;:::o;375:54::-;;;;;;;;;;;;;;;;;;;;:::o;3856:130::-;3934:7;3974:4;3964:15;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;51:19;36:153;;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;3964:15:18;;;;;;;;;;;;;;;;3957:22;;3856:130;;;:::o;851:65::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;512:24::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;716:43::-;;;;;;;;;;;;;;;;;;;;;;:::o;435:40::-;;;;;;;;;;;;;;;;;;;;:::o;442:300:4:-;656:1;644:7;;;;;;;;;;;636:21;;;628:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;724:10;700:7;;:35;;;;;;;;;;;;;;;;;;442:300::o;328:3660:18:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o",
"source": "pragma solidity 0.4.24;\nimport \"../base/Module.sol\";\nimport \"../base/ModuleManager.sol\";\nimport \"../base/OwnerManager.sol\";\nimport \"../common/Enum.sol\";\n\n\n/// @title Social Recovery Module - Allows to replace an owner without Safe confirmations if friends approve the replacement.\n/// @author Stefan George - <stefan@gnosis.pm>\ncontract SocialRecoveryModule is Module {\n\n string public constant NAME = \"Social Recovery Module\";\n string public constant VERSION = \"0.0.2\";\n\n uint256 public threshold;\n address[] public friends;\n\n // isFriend mapping maps friend's address to friend status.\n mapping (address => bool) public isFriend;\n // isExecuted mapping maps data hash to execution status.\n mapping (bytes32 => bool) public isExecuted;\n // isConfirmed mapping maps data hash to friend's address to confirmation status.\n mapping (bytes32 => mapping (address => bool)) public isConfirmed;\n\n modifier onlyFriend() {\n require(isFriend[msg.sender], \"Method can only be called by a friend\");\n _;\n }\n\n /// @dev Setup function sets initial storage of contract.\n /// @param _friends List of friends' addresses.\n /// @param _threshold Required number of friends to confirm replacement.\n function setup(address[] _friends, uint256 _threshold)\n public\n {\n require(_threshold <= _friends.length, \"Threshold cannot exceed friends count\");\n require(_threshold >= 2, \"At least 2 friends required\");\n setManager();\n // Set allowed friends.\n for (uint256 i = 0; i < _friends.length; i++) {\n address friend = _friends[i];\n require(friend != 0, \"Invalid friend address provided\");\n require(!isFriend[friend], \"Duplicate friend address provided\");\n isFriend[friend] = true;\n }\n friends = _friends;\n threshold = _threshold;\n }\n\n /// @dev Allows a friend to confirm a Safe transaction.\n /// @param dataHash Safe transaction hash.\n function confirmTransaction(bytes32 dataHash)\n public\n onlyFriend\n {\n require(!isExecuted[dataHash], \"Recovery already executed\");\n isConfirmed[dataHash][msg.sender] = true;\n }\n\n /// @dev Returns if Safe transaction is a valid owner replacement transaction.\n /// @param prevOwner Owner that pointed to the owner to be replaced in the linked list\n /// @param oldOwner Owner address to be replaced.\n /// @param newOwner New owner address.\n /// @return Returns if transaction can be executed.\n function recoverAccess(address prevOwner, address oldOwner, address newOwner)\n public\n onlyFriend\n {\n bytes memory data = abi.encodeWithSignature(\"swapOwner(address,address,address)\", prevOwner, oldOwner, newOwner);\n bytes32 dataHash = getDataHash(data);\n require(!isExecuted[dataHash], \"Recovery already executed\");\n require(isConfirmedByRequiredFriends(dataHash), \"Recovery has not enough confirmations\");\n isExecuted[dataHash] = true;\n require(manager.execTransactionFromModule(address(manager), 0, data, Enum.Operation.Call), \"Could not execute recovery\");\n }\n\n /// @dev Returns if Safe transaction is a valid owner replacement transaction.\n /// @param dataHash Data hash.\n /// @return Confirmation status.\n function isConfirmedByRequiredFriends(bytes32 dataHash)\n public\n view\n returns (bool)\n {\n uint256 confirmationCount;\n for (uint256 i = 0; i < friends.length; i++) {\n if (isConfirmed[dataHash][friends[i]])\n confirmationCount++;\n if (confirmationCount == threshold)\n return true;\n }\n return false;\n }\n\n /// @dev Returns hash of data encoding owner replacement.\n /// @param data Data payload.\n /// @return Data hash.\n function getDataHash(bytes data)\n public\n pure\n returns (bytes32)\n {\n return keccak256(data);\n }\n}\n",
"sourcePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/modules/SocialRecoveryModule.sol",
"ast": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/modules/SocialRecoveryModule.sol",
"exportedSymbols": {
"SocialRecoveryModule": [
2375
]
},
"id": 2376,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 2112,
"literals": [
"solidity",
"0.4",
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:18"
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/base/Module.sol",
"file": "../base/Module.sol",
"id": 2113,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 936,
"src": "24:28:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/base/ModuleManager.sol",
"file": "../base/ModuleManager.sol",
"id": 2114,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 1213,
"src": "53:35:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/base/OwnerManager.sol",
"file": "../base/OwnerManager.sol",
"id": 2115,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 1653,
"src": "89:34:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/common/Enum.sol",
"file": "../common/Enum.sol",
"id": 2116,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 1660,
"src": "124:28:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2117,
"name": "Module",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 935,
"src": "361:6:18",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Module_$935",
"typeString": "contract Module"
}
},
"id": 2118,
"nodeType": "InheritanceSpecifier",
"src": "361:6:18"
}
],
"contractDependencies": [
935,
1693,
1735
],
"contractKind": "contract",
"documentation": "@title Social Recovery Module - Allows to replace an owner without Safe confirmations if friends approve the replacement.\n @author Stefan George - <stefan@gnosis.pm>",
"fullyImplemented": true,
"id": 2375,
"linearizedBaseContracts": [
2375,
935,
1693,
1735
],
"name": "SocialRecoveryModule",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": true,
"id": 2121,
"name": "NAME",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "375:54:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_memory",
"typeString": "string"
},
"typeName": {
"id": 2119,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "375:6:18",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": {
"argumentTypes": null,
"hexValue": "536f6369616c205265636f76657279204d6f64756c65",
"id": 2120,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "405:24:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_8f499aea563eae5544b16c9123d6c7c8537a7d9dd86296aa60c65de194207230",
"typeString": "literal_string \"Social Recovery Module\""
},
"value": "Social Recovery Module"
},
"visibility": "public"
},
{
"constant": true,
"id": 2124,
"name": "VERSION",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "435:40:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_memory",
"typeString": "string"
},
"typeName": {
"id": 2122,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "435:6:18",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": {
"argumentTypes": null,
"hexValue": "302e302e32",
"id": 2123,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "468:7:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_b30367effb941b728181f67f3bd24a38a4fff408ee7fb3b074425c9fb5e9be74",
"typeString": "literal_string \"0.0.2\""
},
"value": "0.0.2"
},
"visibility": "public"
},
{
"constant": false,
"id": 2126,
"name": "threshold",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "482:24:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2125,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "482:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2129,
"name": "friends",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "512:24:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 2127,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "512:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2128,
"length": null,
"nodeType": "ArrayTypeName",
"src": "512:9:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2133,
"name": "isFriend",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "607:41:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"typeName": {
"id": 2132,
"keyType": {
"id": 2130,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "616:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "607:25:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"valueType": {
"id": 2131,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "627:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2137,
"name": "isExecuted",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "716:43:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
},
"typeName": {
"id": 2136,
"keyType": {
"id": 2134,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "725:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"nodeType": "Mapping",
"src": "716:25:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
},
"valueType": {
"id": 2135,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "736:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2143,
"name": "isConfirmed",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "851:65:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
},
"typeName": {
"id": 2142,
"keyType": {
"id": 2138,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "860:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"nodeType": "Mapping",
"src": "851:46:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
},
"valueType": {
"id": 2141,
"keyType": {
"id": 2139,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "880:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "871:25:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"valueType": {
"id": 2140,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "891:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
}
},
"value": null,
"visibility": "public"
},
{
"body": {
"id": 2154,
"nodeType": "Block",
"src": "945:98:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2146,
"name": "isFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2133,
"src": "963:8:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2149,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2147,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4491,
"src": "972:3:18",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2148,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "972:10:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "963:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4d6574686f642063616e206f6e6c792062652063616c6c6564206279206120667269656e64",
"id": 2150,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "985:39:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_b1b9fb59ab33eb5ed22c2a9ea6a84e946973f30df026a85494e13c73883cce0a",
"typeString": "literal_string \"Method can only be called by a friend\""
},
"value": "Method can only be called by a friend"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_b1b9fb59ab33eb5ed22c2a9ea6a84e946973f30df026a85494e13c73883cce0a",
"typeString": "literal_string \"Method can only be called by a friend\""
}
],
"id": 2145,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "955:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2151,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "955:70:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2152,
"nodeType": "ExpressionStatement",
"src": "955:70:18"
},
{
"id": 2153,
"nodeType": "PlaceholderStatement",
"src": "1035:1:18"
}
]
},
"documentation": null,
"id": 2155,
"name": "onlyFriend",
"nodeType": "ModifierDefinition",
"parameters": {
"id": 2144,
"nodeType": "ParameterList",
"parameters": [],
"src": "942:2:18"
},
"src": "923:120:18",
"visibility": "internal"
},
{
"body": {
"id": 2229,
"nodeType": "Block",
"src": "1314:566:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2167,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2164,
"name": "_threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2160,
"src": "1332:10:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<=",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2165,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1346:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 2166,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "1346:15:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1332:29:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5468726573686f6c642063616e6e6f742065786365656420667269656e647320636f756e74",
"id": 2168,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1363:39:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_8268a65eab991df6bae5d0e671467a9ef945396e4d495dc52153cedea41ef257",
"typeString": "literal_string \"Threshold cannot exceed friends count\""
},
"value": "Threshold cannot exceed friends count"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_8268a65eab991df6bae5d0e671467a9ef945396e4d495dc52153cedea41ef257",
"typeString": "literal_string \"Threshold cannot exceed friends count\""
}
],
"id": 2163,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1324:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2169,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1324:79:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2170,
"nodeType": "ExpressionStatement",
"src": "1324:79:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2174,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2172,
"name": "_threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2160,
"src": "1421:10:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "32",
"id": 2173,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1435:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_2_by_1",
"typeString": "int_const 2"
},
"value": "2"
},
"src": "1421:15:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4174206c65617374203220667269656e6473207265717569726564",
"id": 2175,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1438:29:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_2dca24eb5124987015b2480219c9ac2baf747f0e8ae6537e9852d3e3b2773773",
"typeString": "literal_string \"At least 2 friends required\""
},
"value": "At least 2 friends required"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_2dca24eb5124987015b2480219c9ac2baf747f0e8ae6537e9852d3e3b2773773",
"typeString": "literal_string \"At least 2 friends required\""
}
],
"id": 2171,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1413:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2176,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1413:55:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2177,
"nodeType": "ExpressionStatement",
"src": "1413:55:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 2178,
"name": "setManager",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 934,
"src": "1478:10:18",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
"typeString": "function ()"
}
},
"id": 2179,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1478:12:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2180,
"nodeType": "ExpressionStatement",
"src": "1478:12:18"
},
{
"body": {
"id": 2219,
"nodeType": "Block",
"src": "1578:236:18",
"statements": [
{
"assignments": [
2193
],
"declarations": [
{
"constant": false,
"id": 2193,
"name": "friend",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1592:14:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2192,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1592:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2197,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2194,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1609:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 2196,
"indexExpression": {
"argumentTypes": null,
"id": 2195,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2182,
"src": "1618:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "1609:11:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "1592:28:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2201,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2199,
"name": "friend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2193,
"src": "1642:6:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 2200,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1652:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "1642:11:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "496e76616c696420667269656e6420616464726573732070726f7669646564",
"id": 2202,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1655:33:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_5d50911068dfec2dd53f3e08d7dec23b50affd69b91cf3e5d1e699c56bca7a55",
"typeString": "literal_string \"Invalid friend address provided\""
},
"value": "Invalid friend address provided"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_5d50911068dfec2dd53f3e08d7dec23b50affd69b91cf3e5d1e699c56bca7a55",
"typeString": "literal_string \"Invalid friend address provided\""
}
],
"id": 2198,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1634:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2203,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1634:55:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2204,
"nodeType": "ExpressionStatement",
"src": "1634:55:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2209,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "1711:17:18",
"subExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2206,
"name": "isFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2133,
"src": "1712:8:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2208,
"indexExpression": {
"argumentTypes": null,
"id": 2207,
"name": "friend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2193,
"src": "1721:6:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "1712:16:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4475706c696361746520667269656e6420616464726573732070726f7669646564",
"id": 2210,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1730:35:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_78a0468a6f4bfa8018f886880a93f836f50f407cd02c2e42c43779f87d3af4d3",
"typeString": "literal_string \"Duplicate friend address provided\""
},
"value": "Duplicate friend address provided"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_78a0468a6f4bfa8018f886880a93f836f50f407cd02c2e42c43779f87d3af4d3",
"typeString": "literal_string \"Duplicate friend address provided\""
}
],
"id": 2205,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1703:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2211,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1703:63:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2212,
"nodeType": "ExpressionStatement",
"src": "1703:63:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2217,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2213,
"name": "isFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2133,
"src": "1780:8:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2215,
"indexExpression": {
"argumentTypes": null,
"id": 2214,
"name": "friend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2193,
"src": "1789:6:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "1780:16:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2216,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1799:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "1780:23:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2218,
"nodeType": "ExpressionStatement",
"src": "1780:23:18"
}
]
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2188,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2185,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2182,
"src": "1552:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2186,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1556:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 2187,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "1556:15:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1552:19:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2220,
"initializationExpression": {
"assignments": [
2182
],
"declarations": [
{
"constant": false,
"id": 2182,
"name": "i",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1537:9:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2181,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1537:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2184,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 2183,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1549:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "1537:13:18"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 2190,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": false,
"src": "1573:3:18",
"subExpression": {
"argumentTypes": null,
"id": 2189,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2182,
"src": "1573:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2191,
"nodeType": "ExpressionStatement",
"src": "1573:3:18"
},
"nodeType": "ForStatement",
"src": "1532:282:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2223,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 2221,
"name": "friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2129,
"src": "1823:7:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2222,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1833:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"src": "1823:18:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"id": 2224,
"nodeType": "ExpressionStatement",
"src": "1823:18:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2227,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 2225,
"name": "threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2126,
"src": "1851:9:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2226,
"name": "_threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2160,
"src": "1863:10:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1851:22:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2228,
"nodeType": "ExpressionStatement",
"src": "1851:22:18"
}
]
},
"documentation": "@dev Setup function sets initial storage of contract.\n @param _friends List of friends' addresses.\n @param _threshold Required number of friends to confirm replacement.",
"id": 2230,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "setup",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2161,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2158,
"name": "_friends",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1255:18:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 2156,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1255:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2157,
"length": null,
"nodeType": "ArrayTypeName",
"src": "1255:9:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2160,
"name": "_threshold",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1275:18:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2159,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1275:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1254:40:18"
},
"payable": false,
"returnParameters": {
"id": 2162,
"nodeType": "ParameterList",
"parameters": [],
"src": "1314:0:18"
},
"scope": 2375,
"src": "1240:640:18",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2254,
"nodeType": "Block",
"src": "2077:126:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2241,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "2095:21:18",
"subExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2238,
"name": "isExecuted",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "2096:10:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
}
},
"id": 2240,
"indexExpression": {
"argumentTypes": null,
"id": 2239,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2232,
"src": "2107:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2096:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5265636f7665727920616c7265616479206578656375746564",
"id": 2242,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2118:27:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
},
"value": "Recovery already executed"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
}
],
"id": 2237,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "2087:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2243,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2087:59:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2244,
"nodeType": "ExpressionStatement",
"src": "2087:59:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2252,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2245,
"name": "isConfirmed",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2143,
"src": "2156:11:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
}
},
"id": 2249,
"indexExpression": {
"argumentTypes": null,
"id": 2246,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2232,
"src": "2168:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2156:21:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2250,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2247,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4491,
"src": "2178:3:18",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2248,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "2178:10:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "2156:33:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2251,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2192:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "2156:40:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2253,
"nodeType": "ExpressionStatement",
"src": "2156:40:18"
}
]
},
"documentation": "@dev Allows a friend to confirm a Safe transaction.\n @param dataHash Safe transaction hash.",
"id": 2255,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [
{
"arguments": null,
"id": 2235,
"modifierName": {
"argumentTypes": null,
"id": 2234,
"name": "onlyFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2155,
"src": "2062:10:18",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "2062:10:18"
}
],
"name": "confirmTransaction",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2233,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2232,
"name": "dataHash",
"nodeType": "VariableDeclaration",
"scope": 2255,
"src": "2021:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2231,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "2021:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2020:18:18"
},
"payable": false,
"returnParameters": {
"id": 2236,
"nodeType": "ParameterList",
"parameters": [],
"src": "2077:0:18"
},
"scope": 2375,
"src": "1993:210:18",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2318,
"nodeType": "Block",
"src": "2652:509:18",
"statements": [
{
"assignments": [
2267
],
"declarations": [
{
"constant": false,
"id": 2267,
"name": "data",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2662:17:18",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 2266,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "2662:5:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2275,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "737761704f776e657228616464726573732c616464726573732c6164647265737329",
"id": 2270,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2706:36:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_e318b52b9bee2870ac7ee0af86866eb2e8f9569b34de6028eb487e7983ba6df8",
"typeString": "literal_string \"swapOwner(address,address,address)\""
},
"value": "swapOwner(address,address,address)"
},
{
"argumentTypes": null,
"id": 2271,
"name": "prevOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2257,
"src": "2744:9:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2272,
"name": "oldOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2259,
"src": "2755:8:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2273,
"name": "newOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2261,
"src": "2765:8:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_stringliteral_e318b52b9bee2870ac7ee0af86866eb2e8f9569b34de6028eb487e7983ba6df8",
"typeString": "literal_string \"swapOwner(address,address,address)\""
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 2268,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4478,
"src": "2682:3:18",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 2269,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "encodeWithSignature",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "2682:23:18",
"typeDescriptions": {
"typeIdentifier": "t_function_abiencodewithsignature_pure$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (string memory) pure returns (bytes memory)"
}
},
"id": 2274,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2682:92:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2662:112:18"
},
{
"assignments": [
2277
],
"declarations": [
{
"constant": false,
"id": 2277,
"name": "dataHash",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2784:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2276,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "2784:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2281,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2279,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2267,
"src": "2815:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 2278,
"name": "getDataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2374,
"src": "2803:11:18",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_bytes_memory_ptr_$returns$_t_bytes32_$",
"typeString": "function (bytes memory) pure returns (bytes32)"
}
},
"id": 2280,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2803:17:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2784:36:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2286,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "2838:21:18",
"subExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2283,
"name": "isExecuted",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "2839:10:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
}
},
"id": 2285,
"indexExpression": {
"argumentTypes": null,
"id": 2284,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2277,
"src": "2850:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2839:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5265636f7665727920616c7265616479206578656375746564",
"id": 2287,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2861:27:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
},
"value": "Recovery already executed"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
}
],
"id": 2282,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "2830:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2288,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2830:59:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2289,
"nodeType": "ExpressionStatement",
"src": "2830:59:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2292,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2277,
"src": "2936:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
],
"id": 2291,
"name": "isConfirmedByRequiredFriends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2362,
"src": "2907:28:18",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_bool_$",
"typeString": "function (bytes32) view returns (bool)"
}
},
"id": 2293,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2907:38:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5265636f7665727920686173206e6f7420656e6f75676820636f6e6669726d6174696f6e73",
"id": 2294,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2947:39:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_cb12b81371f920ba15a762526f9a95cbe925aecb372a64dbeac8ce5c02e0c0e8",
"typeString": "literal_string \"Recovery has not enough confirmations\""
},
"value": "Recovery has not enough confirmations"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_cb12b81371f920ba15a762526f9a95cbe925aecb372a64dbeac8ce5c02e0c0e8",
"typeString": "literal_string \"Recovery has not enough confirmations\""
}
],
"id": 2290,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "2899:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2295,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2899:88:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2296,
"nodeType": "ExpressionStatement",
"src": "2899:88:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2301,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2297,
"name": "isExecuted",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "2997:10:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
}
},
"id": 2299,
"indexExpression": {
"argumentTypes": null,
"id": 2298,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2277,
"src": "3008:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "2997:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2300,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3020:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "2997:27:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2302,
"nodeType": "ExpressionStatement",
"src": "2997:27:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2307,
"name": "manager",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 900,
"src": "3084:7:18",
"typeDescriptions": {
"typeIdentifier": "t_contract$_ModuleManager_$1212",
"typeString": "contract ModuleManager"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_ModuleManager_$1212",
"typeString": "contract ModuleManager"
}
],
"id": 2306,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "3076:7:18",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": "address"
},
"id": 2308,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3076:16:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"hexValue": "30",
"id": 2309,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3094:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
{
"argumentTypes": null,
"id": 2310,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2267,
"src": "3097:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2311,
"name": "Enum",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1659,
"src": "3103:4:18",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_Enum_$1659_$",
"typeString": "type(contract Enum)"
}
},
"id": 2312,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "Operation",
"nodeType": "MemberAccess",
"referencedDeclaration": 1658,
"src": "3103:14:18",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_enum$_Operation_$1658_$",
"typeString": "type(enum Enum.Operation)"
}
},
"id": 2313,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "Call",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3103:19:18",
"typeDescriptions": {
"typeIdentifier": "t_enum$_Operation_$1658",
"typeString": "enum Enum.Operation"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_enum$_Operation_$1658",
"typeString": "enum Enum.Operation"
}
],
"expression": {
"argumentTypes": null,
"id": 2304,
"name": "manager",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 900,
"src": "3042:7:18",
"typeDescriptions": {
"typeIdentifier": "t_contract$_ModuleManager_$1212",
"typeString": "contract ModuleManager"
}
},
"id": 2305,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "execTransactionFromModule",
"nodeType": "MemberAccess",
"referencedDeclaration": 1138,
"src": "3042:33:18",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_bytes_memory_ptr_$_t_enum$_Operation_$1658_$returns$_t_bool_$",
"typeString": "function (address,uint256,bytes memory,enum Enum.Operation) external returns (bool)"
}
},
"id": 2314,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3042:81:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "436f756c64206e6f742065786563757465207265636f76657279",
"id": 2315,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3125:28:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_3515587d60c3ee9920dfa4bee22a25e99aacbb3cec35d7cbe6c839f5b9ffdff1",
"typeString": "literal_string \"Could not execute recovery\""
},
"value": "Could not execute recovery"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_3515587d60c3ee9920dfa4bee22a25e99aacbb3cec35d7cbe6c839f5b9ffdff1",
"typeString": "literal_string \"Could not execute recovery\""
}
],
"id": 2303,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "3034:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2316,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3034:120:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2317,
"nodeType": "ExpressionStatement",
"src": "3034:120:18"
}
]
},
"documentation": "@dev Returns if Safe transaction is a valid owner replacement transaction.\n @param prevOwner Owner that pointed to the owner to be replaced in the linked list\n @param oldOwner Owner address to be replaced.\n @param newOwner New owner address.\n @return Returns if transaction can be executed.",
"id": 2319,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [
{
"arguments": null,
"id": 2264,
"modifierName": {
"argumentTypes": null,
"id": 2263,
"name": "onlyFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2155,
"src": "2637:10:18",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "2637:10:18"
}
],
"name": "recoverAccess",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2262,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2257,
"name": "prevOwner",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2559:17:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2256,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2559:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2259,
"name": "oldOwner",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2578:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2258,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2578:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2261,
"name": "newOwner",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2596:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2260,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2596:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2558:55:18"
},
"payable": false,
"returnParameters": {
"id": 2265,
"nodeType": "ParameterList",
"parameters": [],
"src": "2652:0:18"
},
"scope": 2375,
"src": "2536:625:18",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2361,
"nodeType": "Block",
"src": "3433:294:18",
"statements": [
{
"assignments": [],
"declarations": [
{
"constant": false,
"id": 2327,
"name": "confirmationCount",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3443:25:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2326,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3443:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2328,
"initialValue": null,
"nodeType": "VariableDeclarationStatement",
"src": "3443:25:18"
},
{
"body": {
"id": 2357,
"nodeType": "Block",
"src": "3523:176:18",
"statements": [
{
"condition": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2340,
"name": "isConfirmed",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2143,
"src": "3541:11:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
}
},
"id": 2342,
"indexExpression": {
"argumentTypes": null,
"id": 2341,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2321,
"src": "3553:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3541:21:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2346,
"indexExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2343,
"name": "friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2129,
"src": "3563:7:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"id": 2345,
"indexExpression": {
"argumentTypes": null,
"id": 2344,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2330,
"src": "3571:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3563:10:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3541:33:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 2350,
"nodeType": "IfStatement",
"src": "3537:74:18",
"trueBody": {
"expression": {
"argumentTypes": null,
"id": 2348,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": false,
"src": "3592:19:18",
"subExpression": {
"argumentTypes": null,
"id": 2347,
"name": "confirmationCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2327,
"src": "3592:17:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2349,
"nodeType": "ExpressionStatement",
"src": "3592:19:18"
}
},
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2353,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2351,
"name": "confirmationCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2327,
"src": "3629:17:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2352,
"name": "threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2126,
"src": "3650:9:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3629:30:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 2356,
"nodeType": "IfStatement",
"src": "3625:63:18",
"trueBody": {
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2354,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3684:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 2325,
"id": 2355,
"nodeType": "Return",
"src": "3677:11:18"
}
}
]
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2336,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2333,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2330,
"src": "3498:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2334,
"name": "friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2129,
"src": "3502:7:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"id": 2335,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3502:14:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3498:18:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2358,
"initializationExpression": {
"assignments": [
2330
],
"declarations": [
{
"constant": false,
"id": 2330,
"name": "i",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3483:9:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2329,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3483:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2332,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 2331,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3495:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "3483:13:18"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 2338,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": false,
"src": "3518:3:18",
"subExpression": {
"argumentTypes": null,
"id": 2337,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2330,
"src": "3518:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2339,
"nodeType": "ExpressionStatement",
"src": "3518:3:18"
},
"nodeType": "ForStatement",
"src": "3478:221:18"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 2359,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3715:5:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
},
"functionReturnParameters": 2325,
"id": 2360,
"nodeType": "Return",
"src": "3708:12:18"
}
]
},
"documentation": "@dev Returns if Safe transaction is a valid owner replacement transaction.\n @param dataHash Data hash.\n @return Confirmation status.",
"id": 2362,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": true,
"modifiers": [],
"name": "isConfirmedByRequiredFriends",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2322,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2321,
"name": "dataHash",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3360:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2320,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "3360:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3359:18:18"
},
"payable": false,
"returnParameters": {
"id": 2325,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2324,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3423:4:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2323,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3423:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3422:6:18"
},
"scope": 2375,
"src": "3322:405:18",
"stateMutability": "view",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2373,
"nodeType": "Block",
"src": "3947:39:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2370,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2364,
"src": "3974:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 2369,
"name": "keccak256",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4485,
"src": "3964:9:18",
"typeDescriptions": {
"typeIdentifier": "t_function_sha3_pure$__$returns$_t_bytes32_$",
"typeString": "function () pure returns (bytes32)"
}
},
"id": 2371,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3964:15:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"functionReturnParameters": 2368,
"id": 2372,
"nodeType": "Return",
"src": "3957:22:18"
}
]
},
"documentation": "@dev Returns hash of data encoding owner replacement.\n @param data Data payload.\n @return Data hash.",
"id": 2374,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": true,
"modifiers": [],
"name": "getDataHash",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2365,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2364,
"name": "data",
"nodeType": "VariableDeclaration",
"scope": 2374,
"src": "3877:10:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 2363,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "3877:5:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3876:12:18"
},
"payable": false,
"returnParameters": {
"id": 2368,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2367,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 2374,
"src": "3934:7:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2366,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "3934:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3933:9:18"
},
"scope": 2375,
"src": "3856:130:18",
"stateMutability": "pure",
"superFunction": null,
"visibility": "public"
}
],
"scope": 2376,
"src": "328:3660:18"
}
],
"src": "0:3989:18"
},
"legacyAST": {
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/modules/SocialRecoveryModule.sol",
"exportedSymbols": {
"SocialRecoveryModule": [
2375
]
},
"id": 2376,
"nodeType": "SourceUnit",
"nodes": [
{
"id": 2112,
"literals": [
"solidity",
"0.4",
".24"
],
"nodeType": "PragmaDirective",
"src": "0:23:18"
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/base/Module.sol",
"file": "../base/Module.sol",
"id": 2113,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 936,
"src": "24:28:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/base/ModuleManager.sol",
"file": "../base/ModuleManager.sol",
"id": 2114,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 1213,
"src": "53:35:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/base/OwnerManager.sol",
"file": "../base/OwnerManager.sol",
"id": 2115,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 1653,
"src": "89:34:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/common/Enum.sol",
"file": "../common/Enum.sol",
"id": 2116,
"nodeType": "ImportDirective",
"scope": 2376,
"sourceUnit": 1660,
"src": "124:28:18",
"symbolAliases": [],
"unitAlias": ""
},
{
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2117,
"name": "Module",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 935,
"src": "361:6:18",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Module_$935",
"typeString": "contract Module"
}
},
"id": 2118,
"nodeType": "InheritanceSpecifier",
"src": "361:6:18"
}
],
"contractDependencies": [
935,
1693,
1735
],
"contractKind": "contract",
"documentation": "@title Social Recovery Module - Allows to replace an owner without Safe confirmations if friends approve the replacement.\n @author Stefan George - <stefan@gnosis.pm>",
"fullyImplemented": true,
"id": 2375,
"linearizedBaseContracts": [
2375,
935,
1693,
1735
],
"name": "SocialRecoveryModule",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": true,
"id": 2121,
"name": "NAME",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "375:54:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_memory",
"typeString": "string"
},
"typeName": {
"id": 2119,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "375:6:18",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": {
"argumentTypes": null,
"hexValue": "536f6369616c205265636f76657279204d6f64756c65",
"id": 2120,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "405:24:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_8f499aea563eae5544b16c9123d6c7c8537a7d9dd86296aa60c65de194207230",
"typeString": "literal_string \"Social Recovery Module\""
},
"value": "Social Recovery Module"
},
"visibility": "public"
},
{
"constant": true,
"id": 2124,
"name": "VERSION",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "435:40:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_memory",
"typeString": "string"
},
"typeName": {
"id": 2122,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "435:6:18",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": {
"argumentTypes": null,
"hexValue": "302e302e32",
"id": 2123,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "468:7:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_b30367effb941b728181f67f3bd24a38a4fff408ee7fb3b074425c9fb5e9be74",
"typeString": "literal_string \"0.0.2\""
},
"value": "0.0.2"
},
"visibility": "public"
},
{
"constant": false,
"id": 2126,
"name": "threshold",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "482:24:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2125,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "482:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2129,
"name": "friends",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "512:24:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 2127,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "512:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2128,
"length": null,
"nodeType": "ArrayTypeName",
"src": "512:9:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2133,
"name": "isFriend",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "607:41:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"typeName": {
"id": 2132,
"keyType": {
"id": 2130,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "616:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "607:25:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"valueType": {
"id": 2131,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "627:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2137,
"name": "isExecuted",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "716:43:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
},
"typeName": {
"id": 2136,
"keyType": {
"id": 2134,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "725:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"nodeType": "Mapping",
"src": "716:25:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
},
"valueType": {
"id": 2135,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "736:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
},
"value": null,
"visibility": "public"
},
{
"constant": false,
"id": 2143,
"name": "isConfirmed",
"nodeType": "VariableDeclaration",
"scope": 2375,
"src": "851:65:18",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
},
"typeName": {
"id": 2142,
"keyType": {
"id": 2138,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "860:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"nodeType": "Mapping",
"src": "851:46:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
},
"valueType": {
"id": 2141,
"keyType": {
"id": 2139,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "880:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "871:25:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"valueType": {
"id": 2140,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "891:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
}
},
"value": null,
"visibility": "public"
},
{
"body": {
"id": 2154,
"nodeType": "Block",
"src": "945:98:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2146,
"name": "isFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2133,
"src": "963:8:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2149,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2147,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4491,
"src": "972:3:18",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2148,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "972:10:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "963:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4d6574686f642063616e206f6e6c792062652063616c6c6564206279206120667269656e64",
"id": 2150,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "985:39:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_b1b9fb59ab33eb5ed22c2a9ea6a84e946973f30df026a85494e13c73883cce0a",
"typeString": "literal_string \"Method can only be called by a friend\""
},
"value": "Method can only be called by a friend"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_b1b9fb59ab33eb5ed22c2a9ea6a84e946973f30df026a85494e13c73883cce0a",
"typeString": "literal_string \"Method can only be called by a friend\""
}
],
"id": 2145,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "955:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2151,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "955:70:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2152,
"nodeType": "ExpressionStatement",
"src": "955:70:18"
},
{
"id": 2153,
"nodeType": "PlaceholderStatement",
"src": "1035:1:18"
}
]
},
"documentation": null,
"id": 2155,
"name": "onlyFriend",
"nodeType": "ModifierDefinition",
"parameters": {
"id": 2144,
"nodeType": "ParameterList",
"parameters": [],
"src": "942:2:18"
},
"src": "923:120:18",
"visibility": "internal"
},
{
"body": {
"id": 2229,
"nodeType": "Block",
"src": "1314:566:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2167,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2164,
"name": "_threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2160,
"src": "1332:10:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<=",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2165,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1346:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 2166,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "1346:15:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1332:29:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5468726573686f6c642063616e6e6f742065786365656420667269656e647320636f756e74",
"id": 2168,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1363:39:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_8268a65eab991df6bae5d0e671467a9ef945396e4d495dc52153cedea41ef257",
"typeString": "literal_string \"Threshold cannot exceed friends count\""
},
"value": "Threshold cannot exceed friends count"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_8268a65eab991df6bae5d0e671467a9ef945396e4d495dc52153cedea41ef257",
"typeString": "literal_string \"Threshold cannot exceed friends count\""
}
],
"id": 2163,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1324:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2169,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1324:79:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2170,
"nodeType": "ExpressionStatement",
"src": "1324:79:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2174,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2172,
"name": "_threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2160,
"src": "1421:10:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "32",
"id": 2173,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1435:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_2_by_1",
"typeString": "int_const 2"
},
"value": "2"
},
"src": "1421:15:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4174206c65617374203220667269656e6473207265717569726564",
"id": 2175,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1438:29:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_2dca24eb5124987015b2480219c9ac2baf747f0e8ae6537e9852d3e3b2773773",
"typeString": "literal_string \"At least 2 friends required\""
},
"value": "At least 2 friends required"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_2dca24eb5124987015b2480219c9ac2baf747f0e8ae6537e9852d3e3b2773773",
"typeString": "literal_string \"At least 2 friends required\""
}
],
"id": 2171,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1413:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2176,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1413:55:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2177,
"nodeType": "ExpressionStatement",
"src": "1413:55:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 2178,
"name": "setManager",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 934,
"src": "1478:10:18",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
"typeString": "function ()"
}
},
"id": 2179,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1478:12:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2180,
"nodeType": "ExpressionStatement",
"src": "1478:12:18"
},
{
"body": {
"id": 2219,
"nodeType": "Block",
"src": "1578:236:18",
"statements": [
{
"assignments": [
2193
],
"declarations": [
{
"constant": false,
"id": 2193,
"name": "friend",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1592:14:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2192,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1592:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2197,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2194,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1609:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 2196,
"indexExpression": {
"argumentTypes": null,
"id": 2195,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2182,
"src": "1618:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "1609:11:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "1592:28:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2201,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2199,
"name": "friend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2193,
"src": "1642:6:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 2200,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1652:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "1642:11:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "496e76616c696420667269656e6420616464726573732070726f7669646564",
"id": 2202,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1655:33:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_5d50911068dfec2dd53f3e08d7dec23b50affd69b91cf3e5d1e699c56bca7a55",
"typeString": "literal_string \"Invalid friend address provided\""
},
"value": "Invalid friend address provided"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_5d50911068dfec2dd53f3e08d7dec23b50affd69b91cf3e5d1e699c56bca7a55",
"typeString": "literal_string \"Invalid friend address provided\""
}
],
"id": 2198,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1634:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2203,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1634:55:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2204,
"nodeType": "ExpressionStatement",
"src": "1634:55:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2209,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "1711:17:18",
"subExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2206,
"name": "isFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2133,
"src": "1712:8:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2208,
"indexExpression": {
"argumentTypes": null,
"id": 2207,
"name": "friend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2193,
"src": "1721:6:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "1712:16:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4475706c696361746520667269656e6420616464726573732070726f7669646564",
"id": 2210,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1730:35:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_78a0468a6f4bfa8018f886880a93f836f50f407cd02c2e42c43779f87d3af4d3",
"typeString": "literal_string \"Duplicate friend address provided\""
},
"value": "Duplicate friend address provided"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_78a0468a6f4bfa8018f886880a93f836f50f407cd02c2e42c43779f87d3af4d3",
"typeString": "literal_string \"Duplicate friend address provided\""
}
],
"id": 2205,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "1703:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2211,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "1703:63:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2212,
"nodeType": "ExpressionStatement",
"src": "1703:63:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2217,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2213,
"name": "isFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2133,
"src": "1780:8:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2215,
"indexExpression": {
"argumentTypes": null,
"id": 2214,
"name": "friend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2193,
"src": "1789:6:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "1780:16:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2216,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1799:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "1780:23:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2218,
"nodeType": "ExpressionStatement",
"src": "1780:23:18"
}
]
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2188,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2185,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2182,
"src": "1552:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2186,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1556:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 2187,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "1556:15:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1552:19:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2220,
"initializationExpression": {
"assignments": [
2182
],
"declarations": [
{
"constant": false,
"id": 2182,
"name": "i",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1537:9:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2181,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1537:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2184,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 2183,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "1549:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "1537:13:18"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 2190,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": false,
"src": "1573:3:18",
"subExpression": {
"argumentTypes": null,
"id": 2189,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2182,
"src": "1573:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2191,
"nodeType": "ExpressionStatement",
"src": "1573:3:18"
},
"nodeType": "ForStatement",
"src": "1532:282:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2223,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 2221,
"name": "friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2129,
"src": "1823:7:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2222,
"name": "_friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2158,
"src": "1833:8:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"src": "1823:18:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"id": 2224,
"nodeType": "ExpressionStatement",
"src": "1823:18:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2227,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 2225,
"name": "threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2126,
"src": "1851:9:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2226,
"name": "_threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2160,
"src": "1863:10:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "1851:22:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2228,
"nodeType": "ExpressionStatement",
"src": "1851:22:18"
}
]
},
"documentation": "@dev Setup function sets initial storage of contract.\n @param _friends List of friends' addresses.\n @param _threshold Required number of friends to confirm replacement.",
"id": 2230,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [],
"name": "setup",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2161,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2158,
"name": "_friends",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1255:18:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 2156,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1255:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2157,
"length": null,
"nodeType": "ArrayTypeName",
"src": "1255:9:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2160,
"name": "_threshold",
"nodeType": "VariableDeclaration",
"scope": 2230,
"src": "1275:18:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2159,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1275:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1254:40:18"
},
"payable": false,
"returnParameters": {
"id": 2162,
"nodeType": "ParameterList",
"parameters": [],
"src": "1314:0:18"
},
"scope": 2375,
"src": "1240:640:18",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2254,
"nodeType": "Block",
"src": "2077:126:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2241,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "2095:21:18",
"subExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2238,
"name": "isExecuted",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "2096:10:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
}
},
"id": 2240,
"indexExpression": {
"argumentTypes": null,
"id": 2239,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2232,
"src": "2107:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2096:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5265636f7665727920616c7265616479206578656375746564",
"id": 2242,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2118:27:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
},
"value": "Recovery already executed"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
}
],
"id": 2237,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "2087:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2243,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2087:59:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2244,
"nodeType": "ExpressionStatement",
"src": "2087:59:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2252,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2245,
"name": "isConfirmed",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2143,
"src": "2156:11:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
}
},
"id": 2249,
"indexExpression": {
"argumentTypes": null,
"id": 2246,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2232,
"src": "2168:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2156:21:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2250,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2247,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4491,
"src": "2178:3:18",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2248,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "2178:10:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "2156:33:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2251,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2192:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "2156:40:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2253,
"nodeType": "ExpressionStatement",
"src": "2156:40:18"
}
]
},
"documentation": "@dev Allows a friend to confirm a Safe transaction.\n @param dataHash Safe transaction hash.",
"id": 2255,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [
{
"arguments": null,
"id": 2235,
"modifierName": {
"argumentTypes": null,
"id": 2234,
"name": "onlyFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2155,
"src": "2062:10:18",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "2062:10:18"
}
],
"name": "confirmTransaction",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2233,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2232,
"name": "dataHash",
"nodeType": "VariableDeclaration",
"scope": 2255,
"src": "2021:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2231,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "2021:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2020:18:18"
},
"payable": false,
"returnParameters": {
"id": 2236,
"nodeType": "ParameterList",
"parameters": [],
"src": "2077:0:18"
},
"scope": 2375,
"src": "1993:210:18",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2318,
"nodeType": "Block",
"src": "2652:509:18",
"statements": [
{
"assignments": [
2267
],
"declarations": [
{
"constant": false,
"id": 2267,
"name": "data",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2662:17:18",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 2266,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "2662:5:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2275,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "737761704f776e657228616464726573732c616464726573732c6164647265737329",
"id": 2270,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2706:36:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_e318b52b9bee2870ac7ee0af86866eb2e8f9569b34de6028eb487e7983ba6df8",
"typeString": "literal_string \"swapOwner(address,address,address)\""
},
"value": "swapOwner(address,address,address)"
},
{
"argumentTypes": null,
"id": 2271,
"name": "prevOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2257,
"src": "2744:9:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2272,
"name": "oldOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2259,
"src": "2755:8:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2273,
"name": "newOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2261,
"src": "2765:8:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_stringliteral_e318b52b9bee2870ac7ee0af86866eb2e8f9569b34de6028eb487e7983ba6df8",
"typeString": "literal_string \"swapOwner(address,address,address)\""
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 2268,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4478,
"src": "2682:3:18",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 2269,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "encodeWithSignature",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "2682:23:18",
"typeDescriptions": {
"typeIdentifier": "t_function_abiencodewithsignature_pure$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (string memory) pure returns (bytes memory)"
}
},
"id": 2274,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2682:92:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2662:112:18"
},
{
"assignments": [
2277
],
"declarations": [
{
"constant": false,
"id": 2277,
"name": "dataHash",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2784:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2276,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "2784:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2281,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2279,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2267,
"src": "2815:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 2278,
"name": "getDataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2374,
"src": "2803:11:18",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_bytes_memory_ptr_$returns$_t_bytes32_$",
"typeString": "function (bytes memory) pure returns (bytes32)"
}
},
"id": 2280,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2803:17:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "2784:36:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2286,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "2838:21:18",
"subExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2283,
"name": "isExecuted",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "2839:10:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
}
},
"id": 2285,
"indexExpression": {
"argumentTypes": null,
"id": 2284,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2277,
"src": "2850:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "2839:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5265636f7665727920616c7265616479206578656375746564",
"id": 2287,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2861:27:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
},
"value": "Recovery already executed"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_c2f19da1619c37eda5c6f4f3abcc466ec30065da4e2523bb6c81cc850dedac38",
"typeString": "literal_string \"Recovery already executed\""
}
],
"id": 2282,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "2830:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2288,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2830:59:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2289,
"nodeType": "ExpressionStatement",
"src": "2830:59:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2292,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2277,
"src": "2936:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
],
"id": 2291,
"name": "isConfirmedByRequiredFriends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2362,
"src": "2907:28:18",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_bool_$",
"typeString": "function (bytes32) view returns (bool)"
}
},
"id": 2293,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2907:38:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5265636f7665727920686173206e6f7420656e6f75676820636f6e6669726d6174696f6e73",
"id": 2294,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "2947:39:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_cb12b81371f920ba15a762526f9a95cbe925aecb372a64dbeac8ce5c02e0c0e8",
"typeString": "literal_string \"Recovery has not enough confirmations\""
},
"value": "Recovery has not enough confirmations"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_cb12b81371f920ba15a762526f9a95cbe925aecb372a64dbeac8ce5c02e0c0e8",
"typeString": "literal_string \"Recovery has not enough confirmations\""
}
],
"id": 2290,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "2899:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2295,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "2899:88:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2296,
"nodeType": "ExpressionStatement",
"src": "2899:88:18"
},
{
"expression": {
"argumentTypes": null,
"id": 2301,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2297,
"name": "isExecuted",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "2997:10:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_bool_$",
"typeString": "mapping(bytes32 => bool)"
}
},
"id": 2299,
"indexExpression": {
"argumentTypes": null,
"id": 2298,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2277,
"src": "3008:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "2997:20:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2300,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3020:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "2997:27:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2302,
"nodeType": "ExpressionStatement",
"src": "2997:27:18"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2307,
"name": "manager",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 900,
"src": "3084:7:18",
"typeDescriptions": {
"typeIdentifier": "t_contract$_ModuleManager_$1212",
"typeString": "contract ModuleManager"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_ModuleManager_$1212",
"typeString": "contract ModuleManager"
}
],
"id": 2306,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "3076:7:18",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": "address"
},
"id": 2308,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3076:16:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"hexValue": "30",
"id": 2309,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3094:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
{
"argumentTypes": null,
"id": 2310,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2267,
"src": "3097:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2311,
"name": "Enum",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1659,
"src": "3103:4:18",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_Enum_$1659_$",
"typeString": "type(contract Enum)"
}
},
"id": 2312,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "Operation",
"nodeType": "MemberAccess",
"referencedDeclaration": 1658,
"src": "3103:14:18",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_enum$_Operation_$1658_$",
"typeString": "type(enum Enum.Operation)"
}
},
"id": 2313,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "Call",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3103:19:18",
"typeDescriptions": {
"typeIdentifier": "t_enum$_Operation_$1658",
"typeString": "enum Enum.Operation"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_enum$_Operation_$1658",
"typeString": "enum Enum.Operation"
}
],
"expression": {
"argumentTypes": null,
"id": 2304,
"name": "manager",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 900,
"src": "3042:7:18",
"typeDescriptions": {
"typeIdentifier": "t_contract$_ModuleManager_$1212",
"typeString": "contract ModuleManager"
}
},
"id": 2305,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "execTransactionFromModule",
"nodeType": "MemberAccess",
"referencedDeclaration": 1138,
"src": "3042:33:18",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_bytes_memory_ptr_$_t_enum$_Operation_$1658_$returns$_t_bool_$",
"typeString": "function (address,uint256,bytes memory,enum Enum.Operation) external returns (bool)"
}
},
"id": 2314,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3042:81:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "436f756c64206e6f742065786563757465207265636f76657279",
"id": 2315,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3125:28:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_3515587d60c3ee9920dfa4bee22a25e99aacbb3cec35d7cbe6c839f5b9ffdff1",
"typeString": "literal_string \"Could not execute recovery\""
},
"value": "Could not execute recovery"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_3515587d60c3ee9920dfa4bee22a25e99aacbb3cec35d7cbe6c839f5b9ffdff1",
"typeString": "literal_string \"Could not execute recovery\""
}
],
"id": 2303,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
4494,
4495
],
"referencedDeclaration": 4495,
"src": "3034:7:18",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 2316,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3034:120:18",
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2317,
"nodeType": "ExpressionStatement",
"src": "3034:120:18"
}
]
},
"documentation": "@dev Returns if Safe transaction is a valid owner replacement transaction.\n @param prevOwner Owner that pointed to the owner to be replaced in the linked list\n @param oldOwner Owner address to be replaced.\n @param newOwner New owner address.\n @return Returns if transaction can be executed.",
"id": 2319,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": false,
"modifiers": [
{
"arguments": null,
"id": 2264,
"modifierName": {
"argumentTypes": null,
"id": 2263,
"name": "onlyFriend",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2155,
"src": "2637:10:18",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "2637:10:18"
}
],
"name": "recoverAccess",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2262,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2257,
"name": "prevOwner",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2559:17:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2256,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2559:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2259,
"name": "oldOwner",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2578:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2258,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2578:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2261,
"name": "newOwner",
"nodeType": "VariableDeclaration",
"scope": 2319,
"src": "2596:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2260,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2596:7:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2558:55:18"
},
"payable": false,
"returnParameters": {
"id": 2265,
"nodeType": "ParameterList",
"parameters": [],
"src": "2652:0:18"
},
"scope": 2375,
"src": "2536:625:18",
"stateMutability": "nonpayable",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2361,
"nodeType": "Block",
"src": "3433:294:18",
"statements": [
{
"assignments": [],
"declarations": [
{
"constant": false,
"id": 2327,
"name": "confirmationCount",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3443:25:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2326,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3443:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2328,
"initialValue": null,
"nodeType": "VariableDeclarationStatement",
"src": "3443:25:18"
},
{
"body": {
"id": 2357,
"nodeType": "Block",
"src": "3523:176:18",
"statements": [
{
"condition": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2340,
"name": "isConfirmed",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2143,
"src": "3541:11:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes32_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(bytes32 => mapping(address => bool))"
}
},
"id": 2342,
"indexExpression": {
"argumentTypes": null,
"id": 2341,
"name": "dataHash",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2321,
"src": "3553:8:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3541:21:18",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2346,
"indexExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2343,
"name": "friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2129,
"src": "3563:7:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"id": 2345,
"indexExpression": {
"argumentTypes": null,
"id": 2344,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2330,
"src": "3571:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3563:10:18",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "3541:33:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 2350,
"nodeType": "IfStatement",
"src": "3537:74:18",
"trueBody": {
"expression": {
"argumentTypes": null,
"id": 2348,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": false,
"src": "3592:19:18",
"subExpression": {
"argumentTypes": null,
"id": 2347,
"name": "confirmationCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2327,
"src": "3592:17:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2349,
"nodeType": "ExpressionStatement",
"src": "3592:19:18"
}
},
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2353,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2351,
"name": "confirmationCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2327,
"src": "3629:17:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2352,
"name": "threshold",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2126,
"src": "3650:9:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3629:30:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 2356,
"nodeType": "IfStatement",
"src": "3625:63:18",
"trueBody": {
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2354,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3684:4:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 2325,
"id": 2355,
"nodeType": "Return",
"src": "3677:11:18"
}
}
]
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2336,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2333,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2330,
"src": "3498:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2334,
"name": "friends",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2129,
"src": "3502:7:18",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage",
"typeString": "address[] storage ref"
}
},
"id": 2335,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "3502:14:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3498:18:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2358,
"initializationExpression": {
"assignments": [
2330
],
"declarations": [
{
"constant": false,
"id": 2330,
"name": "i",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3483:9:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2329,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3483:7:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2332,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 2331,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3495:1:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "3483:13:18"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 2338,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": false,
"src": "3518:3:18",
"subExpression": {
"argumentTypes": null,
"id": 2337,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2330,
"src": "3518:1:18",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2339,
"nodeType": "ExpressionStatement",
"src": "3518:3:18"
},
"nodeType": "ForStatement",
"src": "3478:221:18"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 2359,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3715:5:18",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
},
"functionReturnParameters": 2325,
"id": 2360,
"nodeType": "Return",
"src": "3708:12:18"
}
]
},
"documentation": "@dev Returns if Safe transaction is a valid owner replacement transaction.\n @param dataHash Data hash.\n @return Confirmation status.",
"id": 2362,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": true,
"modifiers": [],
"name": "isConfirmedByRequiredFriends",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2322,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2321,
"name": "dataHash",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3360:16:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2320,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "3360:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3359:18:18"
},
"payable": false,
"returnParameters": {
"id": 2325,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2324,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 2362,
"src": "3423:4:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2323,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3423:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3422:6:18"
},
"scope": 2375,
"src": "3322:405:18",
"stateMutability": "view",
"superFunction": null,
"visibility": "public"
},
{
"body": {
"id": 2373,
"nodeType": "Block",
"src": "3947:39:18",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2370,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2364,
"src": "3974:4:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 2369,
"name": "keccak256",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4485,
"src": "3964:9:18",
"typeDescriptions": {
"typeIdentifier": "t_function_sha3_pure$__$returns$_t_bytes32_$",
"typeString": "function () pure returns (bytes32)"
}
},
"id": 2371,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3964:15:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"functionReturnParameters": 2368,
"id": 2372,
"nodeType": "Return",
"src": "3957:22:18"
}
]
},
"documentation": "@dev Returns hash of data encoding owner replacement.\n @param data Data payload.\n @return Data hash.",
"id": 2374,
"implemented": true,
"isConstructor": false,
"isDeclaredConst": true,
"modifiers": [],
"name": "getDataHash",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 2365,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2364,
"name": "data",
"nodeType": "VariableDeclaration",
"scope": 2374,
"src": "3877:10:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 2363,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "3877:5:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3876:12:18"
},
"payable": false,
"returnParameters": {
"id": 2368,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2367,
"name": "",
"nodeType": "VariableDeclaration",
"scope": 2374,
"src": "3934:7:18",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 2366,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "3934:7:18",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3933:9:18"
},
"scope": 2375,
"src": "3856:130:18",
"stateMutability": "pure",
"superFunction": null,
"visibility": "public"
}
],
"scope": 2376,
"src": "328:3660:18"
}
],
"src": "0:3989:18"
},
"compiler": {
"name": "solc",
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
},
"networks": {
"4": {
"events": {},
"links": {},
"address": "0xefa8938e615a8188b94523cc8b3de02454077715",
"transactionHash": "0x0a75701ead1faf11206be9dc47f5bf1e0364234af2b86103a476b1ce9a4142f4"
}
},
"schemaVersion": "2.0.0",
"updatedAt": "2018-09-26T08:56:03.727Z"
}