ETH Price: $3,102.33 (-2.54%)

Contract

0x1863D1351fc3003F1Ad361939248E3a3a114958e
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Set Rate146351472022-04-22 14:13:17937 days ago1650636797IN
0x1863D135...3a114958e
0 ETH0.0003600510.7
Set Rate137629912021-12-08 5:24:011072 days ago1638941041IN
0x1863D135...3a114958e
0 ETH0.0018837256
Set Rate136421482021-11-18 23:02:481091 days ago1637276568IN
0x1863D135...3a114958e
0 ETH0.003365100
Set Rate136261932021-11-16 10:52:371094 days ago1637059957IN
0x1863D135...3a114958e
0 ETH0.0033301699
Set Rate136242562021-11-16 3:24:191094 days ago1637033059IN
0x1863D135...3a114958e
0 ETH0.0033638100
Set Rate135734302021-11-08 3:30:411102 days ago1636342241IN
0x1863D135...3a114958e
0 ETH0.0033638100
Set Rate135427932021-11-03 8:22:511107 days ago1635927771IN
0x1863D135...3a114958e
0 ETH0.0033638100
Set Rate134954682021-10-26 21:45:051115 days ago1635284705IN
0x1863D135...3a114958e
0 ETH0.0033638100
Set Rate134554282021-10-20 15:30:521121 days ago1634743852IN
0x1863D135...3a114958e
0 ETH0.003365100
Set Rate134264142021-10-16 2:41:401125 days ago1634352100IN
0x1863D135...3a114958e
0 ETH0.0028602585
Set Rate134136772021-10-14 2:26:061127 days ago1634178366IN
0x1863D135...3a114958e
0 ETH0.003365100
Set Rate133932892021-10-10 21:22:401131 days ago1633900960IN
0x1863D135...3a114958e
0 ETH0.0025237575
Set Rate133722682021-10-07 14:15:041134 days ago1633616104IN
0x1863D135...3a114958e
0 ETH0.003365100
Set Rate133584152021-10-05 9:58:581136 days ago1633427938IN
0x1863D135...3a114958e
0 ETH0.0020526561
Set Rate133375852021-10-02 3:53:191139 days ago1633146799IN
0x1863D135...3a114958e
0 ETH0.0017161551
Set Rate133247512021-09-30 3:50:381141 days ago1632973838IN
0x1863D135...3a114958e
0 ETH0.003365100
Set Rate132991022021-09-26 3:44:171145 days ago1632627857IN
0x1863D135...3a114958e
0 ETH0.001615248
Set Rate132861482021-09-24 3:39:341147 days ago1632454774IN
0x1863D135...3a114958e
0 ETH0.0016488549
Set Rate132731952021-09-22 3:37:271149 days ago1632281847IN
0x1863D135...3a114958e
0 ETH0.001884456
Set Rate132602422021-09-20 3:29:521151 days ago1632108592IN
0x1863D135...3a114958e
0 ETH0.0017834553
Set Rate132269692021-09-15 0:03:401156 days ago1631664220IN
0x1863D135...3a114958e
0 ETH0.0015815547
Set Rate132037762021-09-11 9:54:331160 days ago1631354073IN
0x1863D135...3a114958e
0 ETH0.0017834553
Set Rate131908082021-09-09 9:47:221162 days ago1631180842IN
0x1863D135...3a114958e
0 ETH0.003297798
Set Rate131778932021-09-07 9:42:321164 days ago1631007752IN
0x1863D135...3a114958e
0 ETH0.003230496
Set Rate131544712021-09-03 18:49:011168 days ago1630694941IN
0x1863D135...3a114958e
0 ETH0.003365100
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Oracle

Compiler Version
v0.5.7+commit.6da8b019

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
/**
 *Submitted for verification at Etherscan.io on 2019-06-15
*/

/*
Implements a rate oracle (for EUR/ETH)
Operated by Capacity Blockchain Solutions GmbH.
No warranties.
*/
// File: openzeppelin-solidity\contracts\token\ERC20\IERC20.sol

pragma solidity ^0.5.2;

/**
 * @title ERC20 interface
 * @dev see https://eips.ethereum.org/EIPS/eip-20
 */
interface IERC20 {
    function transfer(address to, uint256 value) external returns (bool);

    function approve(address spender, uint256 value) external returns (bool);

    function transferFrom(address from, address to, uint256 value) external returns (bool);

    function totalSupply() external view returns (uint256);

    function balanceOf(address who) external view returns (uint256);

    function allowance(address owner, address spender) external view returns (uint256);

    event Transfer(address indexed from, address indexed to, uint256 value);

    event Approval(address indexed owner, address indexed spender, uint256 value);
}

// File: openzeppelin-solidity\contracts\math\SafeMath.sol

pragma solidity ^0.5.2;

/**
 * @title SafeMath
 * @dev Unsigned math operations with safety checks that revert on error
 */
library SafeMath {
    /**
     * @dev Multiplies two unsigned integers, reverts on overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b);

        return c;
    }

    /**
     * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        // Solidity only automatically asserts when dividing by 0
        require(b > 0);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

    /**
     * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend).
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        require(b <= a);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Adds two unsigned integers, reverts on overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a);

        return c;
    }

    /**
     * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo),
     * reverts when dividing by zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        require(b != 0);
        return a % b;
    }
}

// File: contracts\OracleRequest.sol

/*
Interface for requests to the rate oracle (for EUR/ETH)
Copy this to projects that need to access the oracle.
See rate-oracle project for implementation.
*/
pragma solidity ^0.5.0;


contract OracleRequest {

    uint256 public EUR_WEI; //number of wei per EUR

    uint256 public lastUpdate; //timestamp of when the last update occurred

    function ETH_EUR() public view returns (uint256); //number of EUR per ETH (rounded down!)

    function ETH_EURCENT() public view returns (uint256); //number of EUR cent per ETH (rounded down!)

}

// File: contracts\Oracle.sol

/*
Implements a rate oracle (for EUR/ETH)
*/
pragma solidity ^0.5.0;




contract Oracle is OracleRequest {
    using SafeMath for uint256;

    address public rateControl;

    address public tokenAssignmentControl;

    constructor(address _rateControl, address _tokenAssignmentControl)
    public
    {
        lastUpdate = 0;
        rateControl = _rateControl;
        tokenAssignmentControl = _tokenAssignmentControl;
    }

    modifier onlyRateControl()
    {
        require(msg.sender == rateControl, "rateControl key required for this function.");
        _;
    }

    modifier onlyTokenAssignmentControl() {
        require(msg.sender == tokenAssignmentControl, "tokenAssignmentControl key required for this function.");
        _;
    }

    function setRate(uint256 _new_EUR_WEI)
    public
    onlyRateControl
    {
        lastUpdate = now;
        require(_new_EUR_WEI > 0, "Please assign a valid rate.");
        EUR_WEI = _new_EUR_WEI;
    }

    function ETH_EUR()
    public view
    returns (uint256)
    {
        return uint256(1 ether).div(EUR_WEI);
    }

    function ETH_EURCENT()
    public view
    returns (uint256)
    {
        return uint256(100 ether).div(EUR_WEI);
    }

    /*** Make sure currency doesn't get stranded in this contract ***/

    // If this contract gets a balance in some ERC20 contract after it's finished, then we can rescue it.
    function rescueToken(IERC20 _foreignToken, address _to)
    public
    onlyTokenAssignmentControl
    {
        _foreignToken.transfer(_to, _foreignToken.balanceOf(address(this)));
    }

    // Make sure this contract cannot receive ETH.
    function() external
    payable
    {
        revert("The contract cannot receive ETH payments.");
    }
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"ETH_EURCENT","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_new_EUR_WEI","type":"uint256"}],"name":"setRate","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_foreignToken","type":"address"},{"name":"_to","type":"address"}],"name":"rescueToken","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"EUR_WEI","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"rateControl","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"lastUpdate","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"tokenAssignmentControl","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"ETH_EUR","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_rateControl","type":"address"},{"name":"_tokenAssignmentControl","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"}]

608060405234801561001057600080fd5b506040516040806105768339810180604052604081101561003057600080fd5b5080516020909101516000600155600280546001600160a01b039384166001600160a01b031991821617909155600380549390921692169190911790556104fa8061007c6000396000f3fe60806040526004361061007b5760003560e01c8063a48e77f61161004e578063a48e77f614610158578063c046371114610189578063c8c2ed541461019e578063f8c439dc146101b35761007b565b8063093ae918146100b557806334fcf437146100dc5780634707d0001461010857806354a4adc214610143575b604051600160e51b62461bcd0281526004018080602001828103825260298152602001806104706029913960400191505060405180910390fd5b3480156100c157600080fd5b506100ca6101c8565b60408051918252519081900360200190f35b3480156100e857600080fd5b50610106600480360360208110156100ff57600080fd5b50356101eb565b005b34801561011457600080fd5b506101066004803603604081101561012b57600080fd5b506001600160a01b0381358116916020013516610295565b34801561014f57600080fd5b506100ca6103db565b34801561016457600080fd5b5061016d6103e1565b604080516001600160a01b039092168252519081900360200190f35b34801561019557600080fd5b506100ca6103f0565b3480156101aa57600080fd5b5061016d6103f6565b3480156101bf57600080fd5b506100ca610405565b600080546101e69068056bc75e2d631000009063ffffffff61042216565b905090565b6002546001600160a01b0316331461023757604051600160e51b62461bcd02815260040180806020018281038252602b815260200180610445602b913960400191505060405180910390fd5b42600155806102905760408051600160e51b62461bcd02815260206004820152601b60248201527f506c656173652061737369676e20612076616c696420726174652e0000000000604482015290519081900360640190fd5b600055565b6003546001600160a01b031633146102e157604051600160e51b62461bcd0281526004018080602001828103825260368152602001806104996036913960400191505060405180910390fd5b60408051600160e01b6370a0823102815230600482015290516001600160a01b0384169163a9059cbb91849184916370a0823191602480820192602092909190829003018186803b15801561033557600080fd5b505afa158015610349573d6000803e3d6000fd5b505050506040513d602081101561035f57600080fd5b50516040805163ffffffff851660e01b81526001600160a01b03909316600484015260248301919091525160448083019260209291908290030181600087803b1580156103ab57600080fd5b505af11580156103bf573d6000803e3d6000fd5b505050506040513d60208110156103d557600080fd5b50505050565b60005481565b6002546001600160a01b031681565b60015481565b6003546001600160a01b031681565b600080546101e690670de0b6b3a76400009063ffffffff61042216565b600080821161043057600080fd5b600082848161043b57fe5b0494935050505056fe72617465436f6e74726f6c206b657920726571756972656420666f7220746869732066756e6374696f6e2e54686520636f6e74726163742063616e6e6f74207265636569766520455448207061796d656e74732e746f6b656e41737369676e6d656e74436f6e74726f6c206b657920726571756972656420666f7220746869732066756e6374696f6e2ea165627a7a7230582041d7d59457952a40fc0aca9489ca3e12cb9a518ebf25d5cb25d44062baa5429a00290000000000000000000000003d1e63803d9214bd9b7047677816f763aab3ae3600000000000000000000000087dfc885358187337000c8977f5aaed0544d7b32

Deployed Bytecode

0x60806040526004361061007b5760003560e01c8063a48e77f61161004e578063a48e77f614610158578063c046371114610189578063c8c2ed541461019e578063f8c439dc146101b35761007b565b8063093ae918146100b557806334fcf437146100dc5780634707d0001461010857806354a4adc214610143575b604051600160e51b62461bcd0281526004018080602001828103825260298152602001806104706029913960400191505060405180910390fd5b3480156100c157600080fd5b506100ca6101c8565b60408051918252519081900360200190f35b3480156100e857600080fd5b50610106600480360360208110156100ff57600080fd5b50356101eb565b005b34801561011457600080fd5b506101066004803603604081101561012b57600080fd5b506001600160a01b0381358116916020013516610295565b34801561014f57600080fd5b506100ca6103db565b34801561016457600080fd5b5061016d6103e1565b604080516001600160a01b039092168252519081900360200190f35b34801561019557600080fd5b506100ca6103f0565b3480156101aa57600080fd5b5061016d6103f6565b3480156101bf57600080fd5b506100ca610405565b600080546101e69068056bc75e2d631000009063ffffffff61042216565b905090565b6002546001600160a01b0316331461023757604051600160e51b62461bcd02815260040180806020018281038252602b815260200180610445602b913960400191505060405180910390fd5b42600155806102905760408051600160e51b62461bcd02815260206004820152601b60248201527f506c656173652061737369676e20612076616c696420726174652e0000000000604482015290519081900360640190fd5b600055565b6003546001600160a01b031633146102e157604051600160e51b62461bcd0281526004018080602001828103825260368152602001806104996036913960400191505060405180910390fd5b60408051600160e01b6370a0823102815230600482015290516001600160a01b0384169163a9059cbb91849184916370a0823191602480820192602092909190829003018186803b15801561033557600080fd5b505afa158015610349573d6000803e3d6000fd5b505050506040513d602081101561035f57600080fd5b50516040805163ffffffff851660e01b81526001600160a01b03909316600484015260248301919091525160448083019260209291908290030181600087803b1580156103ab57600080fd5b505af11580156103bf573d6000803e3d6000fd5b505050506040513d60208110156103d557600080fd5b50505050565b60005481565b6002546001600160a01b031681565b60015481565b6003546001600160a01b031681565b600080546101e690670de0b6b3a76400009063ffffffff61042216565b600080821161043057600080fd5b600082848161043b57fe5b0494935050505056fe72617465436f6e74726f6c206b657920726571756972656420666f7220746869732066756e6374696f6e2e54686520636f6e74726163742063616e6e6f74207265636569766520455448207061796d656e74732e746f6b656e41737369676e6d656e74436f6e74726f6c206b657920726571756972656420666f7220746869732066756e6374696f6e2ea165627a7a7230582041d7d59457952a40fc0aca9489ca3e12cb9a518ebf25d5cb25d44062baa5429a0029

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

0000000000000000000000003d1e63803d9214bd9b7047677816f763aab3ae3600000000000000000000000087dfc885358187337000c8977f5aaed0544d7b32

-----Decoded View---------------
Arg [0] : _rateControl (address): 0x3d1E63803D9214bd9b7047677816F763AaB3ae36
Arg [1] : _tokenAssignmentControl (address): 0x87dfC885358187337000C8977F5AAeD0544d7B32

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 0000000000000000000000003d1e63803d9214bd9b7047677816f763aab3ae36
Arg [1] : 00000000000000000000000087dfc885358187337000c8977f5aaed0544d7b32


Deployed Bytecode Sourcemap

3673:1732:0:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5343:51;;-1:-1:-1;;;;;5343:51:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4729:125;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4729:125:0;;;:::i;:::-;;;;;;;;;;;;;;;;4382:212;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4382:212:0;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;4382:212:0;;:::i;:::-;;5043:191;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5043:191:0;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;5043:191:0;;;;;;;;;;:::i;3221:22::-;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3221:22:0;;;:::i;3748:26::-;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3748:26:0;;;:::i;:::-;;;;-1:-1:-1;;;;;3748:26:0;;;;;;;;;;;;;;3276:25;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3276:25:0;;;:::i;3783:37::-;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3783:37:0;;;:::i;4602:119::-;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4602:119:0;;;:::i;4729:125::-;4783:7;4838;;4815:31;;4823:9;;4815:31;:22;:31;:::i;:::-;4808:38;;4729:125;:::o;4382:212::-;4115:11;;-1:-1:-1;;;;;4115:11:0;4101:10;:25;4093:81;;;;-1:-1:-1;;;;;4093:81:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4483:3;4470:10;:16;4505;4497:56;;;;;-1:-1:-1;;;;;4497:56:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;4564:7;:22;4382:212::o;5043:191::-;4273:22;;-1:-1:-1;;;;;4273:22:0;4259:10;:36;4251:103;;;;-1:-1:-1;;;;;4251:103:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5187:38;;;-1:-1:-1;;;;;5187:38:0;;5219:4;5187:38;;;;;;-1:-1:-1;;;;;5159:22:0;;;;;5182:3;;5159:22;;5187:23;;:38;;;;;;;;;;;;;;;5159:22;5187:38;;;5:2:-1;;;;30:1;27;20:12;5:2;5187:38:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5187:38:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;5187:38:0;5159:67;;;;;;;;;;-1:-1:-1;;;;;5159:67:0;;;;;;;;;;;;;;;;;;;;5187:38;;5159:67;;;;;;;-1:-1:-1;5159:67:0;;;;5:2:-1;;;;30:1;27;20:12;5:2;5159:67:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5159:67:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;5043:191:0:o;3221:22::-;;;;:::o;3748:26::-;;;-1:-1:-1;;;;;3748:26:0;;:::o;3276:25::-;;;;:::o;3783:37::-;;;-1:-1:-1;;;;;3783:37:0;;:::o;4602:119::-;4652:7;4705;;4684:29;;4692:7;;4684:29;:20;:29;:::i;1834:303::-;1892:7;1991:1;1987;:5;1979:14;;;;;;2004:9;2020:1;2016;:5;;;;;;;1834:303;-1:-1:-1;;;;1834:303:0:o

Swarm Source

bzzr://41d7d59457952a40fc0aca9489ca3e12cb9a518ebf25d5cb25d44062baa5429a

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.