ETH Price: $3,087.85 (-1.99%)
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Transfer Ownersh...114482502020-12-14 2:01:151507 days ago1607911275IN
0xd9cF4cA7...b848b7A1B
0 ETH0.0023198275
Update Registry114159702020-12-09 2:29:211512 days ago1607480961IN
0xd9cF4cA7...b848b7A1B
0 ETH0.0032582275

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
RegistryHolder

Compiler Version
v0.5.17+commit.d19bba13

Optimization Enabled:
Yes with 100 runs

Other Settings:
default evmVersion, Apache-2.0 license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2021-01-22
*/

// File: @openzeppelin/contracts/GSN/Context.sol

pragma solidity ^0.5.0;

/*
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with GSN meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
contract Context {
    // Empty internal constructor, to prevent people from mistakenly deploying
    // an instance of this contract, which should be used via inheritance.
    constructor () internal { }
    // solhint-disable-previous-line no-empty-blocks

    function _msgSender() internal view returns (address payable) {
        return msg.sender;
    }

    function _msgData() internal view returns (bytes memory) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}

// File: @openzeppelin/contracts/ownership/Ownable.sol

pragma solidity ^0.5.0;

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor () internal {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(isOwner(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Returns true if the caller is the current owner.
     */
    function isOwner() public view returns (bool) {
        return _msgSender() == _owner;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public onlyOwner {
        emit OwnershipTransferred(_owner, address(0));
        _owner = address(0);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public onlyOwner {
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     */
    function _transferOwnership(address newOwner) internal {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

// File: contracts/registry/IRegistry.sol

pragma solidity ^0.5.17;

contract IRegistry {
    function getVotingAddress() public view returns (address);

    function getExchangeFactoryAddress() public view returns (address);

    function getWethAddress() public view returns (address);

    function getMessageProcessorAddress() public view returns (address);

    function getFsTokenAddress() public view returns (address);

    function getFsTokenProxyAdminAddress() public view returns (address);

    function getIncentivesAddress() public view returns (address);

    function getWalletAddress() public view returns (address payable);

    function getReplayTrackerAddress() public view returns (address);

    function getLiquidityTokenFactoryAddress() public view returns (address);

    function hasLiquidityTokensnapshotAccess(address sender) public view returns (bool);

    function hasWalletAccess(address sender) public view returns (bool);

    function removeWalletAccess(address _walletAccessor) public;

    function isValidOracleAddress(address oracleAddress) public view returns (bool);

    function isValidVerifierAddress(address verifierAddress) public view returns (bool);

    function isValidStamperAddress(address stamperAddress) public view returns (bool);

    function isExchange(address exchangeAddress) public view returns (bool);

    function addExchange(address _exchange) public;

    function removeExchange(address _exchange) public;

    function updateVotingAddress(address _address) public;
}

// File: contracts/registry/RegistryHolder.sol

pragma solidity ^0.5.17;



// Holds a reference to the registry
// Eventually Ownership will be renounced
contract RegistryHolder is Ownable {
    address private registryAddress;

    function getRegistryAddress() public view returns (address) {
        return registryAddress;
    }

    // Change the address of registry, if the caller is the voting system as identified by the old
    // registry.
    function updateRegistry(address _newAddress) public {
        require(isOwner() || isVotingSystem(), "Only owner or voting system");
        require(_newAddress != address(0), "Zero address");
        registryAddress = _newAddress;
    }

    function isVotingSystem() private view returns (bool) {
        if (registryAddress == address(0)) {
            return false;
        }
        return IRegistry(registryAddress).getVotingAddress() == msg.sender;
    }
}

Contract Security Audit

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"constant":true,"inputs":[],"name":"getRegistryAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"isOwner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"renounceOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_newAddress","type":"address"}],"name":"updateRegistry","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"}]

608060405260006100176001600160e01b0361006616565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a35061006a565b3390565b6104bc806100796000396000f3fe608060405234801561001057600080fd5b50600436106100625760003560e01c80631a5da6c814610067578063715018a61461008f5780638da5cb5b146100975780638f32d59b146100bb578063f21de1e8146100d7578063f2fde38b146100df575b600080fd5b61008d6004803603602081101561007d57600080fd5b50356001600160a01b0316610105565b005b61008d6101d8565b61009f61027b565b604080516001600160a01b039092168252519081900360200190f35b6100c361028b565b604080519115158252519081900360200190f35b61009f6102af565b61008d600480360360208110156100f557600080fd5b50356001600160a01b03166102be565b61010d61028b565b8061011b575061011b610323565b61016c576040805162461bcd60e51b815260206004820152601b60248201527f4f6e6c79206f776e6572206f7220766f74696e672073797374656d0000000000604482015290519081900360640190fd5b6001600160a01b0381166101b6576040805162461bcd60e51b815260206004820152600c60248201526b5a65726f206164647265737360a01b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b6101e061028b565b610231576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b03165b90565b600080546001600160a01b03166102a06103bd565b6001600160a01b031614905090565b6001546001600160a01b031690565b6102c661028b565b610317576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610320816103c1565b50565b6001546000906001600160a01b031661033e57506000610288565b6001546040805163f037ee7160e01b8152905133926001600160a01b03169163f037ee71916004808301926020929190829003018186803b15801561038257600080fd5b505afa158015610396573d6000803e3d6000fd5b505050506040513d60208110156103ac57600080fd5b50516001600160a01b031614905090565b3390565b6001600160a01b0381166104065760405162461bcd60e51b81526004018080602001828103825260268152602001806104626026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b039290921691909117905556fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373a265627a7a723158203bfe708a2eb300028c260af12c516f2dea8059f930302335af35bd700064496564736f6c63430005110032

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100625760003560e01c80631a5da6c814610067578063715018a61461008f5780638da5cb5b146100975780638f32d59b146100bb578063f21de1e8146100d7578063f2fde38b146100df575b600080fd5b61008d6004803603602081101561007d57600080fd5b50356001600160a01b0316610105565b005b61008d6101d8565b61009f61027b565b604080516001600160a01b039092168252519081900360200190f35b6100c361028b565b604080519115158252519081900360200190f35b61009f6102af565b61008d600480360360208110156100f557600080fd5b50356001600160a01b03166102be565b61010d61028b565b8061011b575061011b610323565b61016c576040805162461bcd60e51b815260206004820152601b60248201527f4f6e6c79206f776e6572206f7220766f74696e672073797374656d0000000000604482015290519081900360640190fd5b6001600160a01b0381166101b6576040805162461bcd60e51b815260206004820152600c60248201526b5a65726f206164647265737360a01b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b6101e061028b565b610231576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b03165b90565b600080546001600160a01b03166102a06103bd565b6001600160a01b031614905090565b6001546001600160a01b031690565b6102c661028b565b610317576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610320816103c1565b50565b6001546000906001600160a01b031661033e57506000610288565b6001546040805163f037ee7160e01b8152905133926001600160a01b03169163f037ee71916004808301926020929190829003018186803b15801561038257600080fd5b505afa158015610396573d6000803e3d6000fd5b505050506040513d60208110156103ac57600080fd5b50516001600160a01b031614905090565b3390565b6001600160a01b0381166104065760405162461bcd60e51b81526004018080602001828103825260268152602001806104626026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b039290921691909117905556fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373a265627a7a723158203bfe708a2eb300028c260af12c516f2dea8059f930302335af35bd700064496564736f6c63430005110032

Deployed Bytecode Sourcemap

5454:784:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5454:784:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5763:241;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;5763:241:0;-1:-1:-1;;;;;5763:241:0;;:::i;:::-;;2963:140;;;:::i;2152:79::-;;;:::i;:::-;;;;-1:-1:-1;;;;;2152:79:0;;;;;;;;;;;;;;2518:94;;;:::i;:::-;;;;;;;;;;;;;;;;;;5536:101;;;:::i;3258:109::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;3258:109:0;-1:-1:-1;;;;;3258:109:0;;:::i;5763:241::-;5834:9;:7;:9::i;:::-;:29;;;;5847:16;:14;:16::i;:::-;5826:69;;;;;-1:-1:-1;;;5826:69:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;5914:25:0;;5906:50;;;;;-1:-1:-1;;;5906:50:0;;;;;;;;;;;;-1:-1:-1;;;5906:50:0;;;;;;;;;;;;;;;5967:15;:29;;-1:-1:-1;;;;;;5967:29:0;-1:-1:-1;;;;;5967:29:0;;;;;;;;;;5763:241::o;2963:140::-;2364:9;:7;:9::i;:::-;2356:54;;;;;-1:-1:-1;;;2356:54:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3062:1;3046:6;;3025:40;;-1:-1:-1;;;;;3046:6:0;;;;3025:40;;3062:1;;3025:40;3093:1;3076:19;;-1:-1:-1;;;;;;3076:19:0;;;2963:140::o;2152:79::-;2190:7;2217:6;-1:-1:-1;;;;;2217:6:0;2152:79;;:::o;2518:94::-;2558:4;2598:6;;-1:-1:-1;;;;;2598:6:0;2582:12;:10;:12::i;:::-;-1:-1:-1;;;;;2582:22:0;;2575:29;;2518:94;:::o;5536:101::-;5614:15;;-1:-1:-1;;;;;5614:15:0;5536:101;:::o;3258:109::-;2364:9;:7;:9::i;:::-;2356:54;;;;;-1:-1:-1;;;2356:54:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3331:28;3350:8;3331:18;:28::i;:::-;3258:109;:::o;6012:223::-;6081:15;;6060:4;;-1:-1:-1;;;;;6081:15:0;6077:74;;-1:-1:-1;6134:5:0;6127:12;;6077:74;6178:15;;6168:45;;;-1:-1:-1;;;6168:45:0;;;;6217:10;;-1:-1:-1;;;;;6178:15:0;;6168:43;;:45;;;;;;;;;;;;;;6178:15;6168:45;;;5:2:-1;;;;30:1;27;20:12;5:2;6168:45:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6168:45:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;6168:45:0;-1:-1:-1;;;;;6168:59:0;;;-1:-1:-1;6012:223:0;:::o;858:98::-;938:10;858:98;:::o;3473:229::-;-1:-1:-1;;;;;3547:22:0;;3539:73;;;;-1:-1:-1;;;3539:73:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3649:6;;;3628:38;;-1:-1:-1;;;;;3628:38:0;;;;3649:6;;;3628:38;;;3677:6;:17;;-1:-1:-1;;;;;;3677:17:0;-1:-1:-1;;;;;3677:17:0;;;;;;;;;;3473:229::o

Swarm Source

bzzr://3bfe708a2eb300028c260af12c516f2dea8059f930302335af35bd7000644965

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.