ETH Price: $3,293.77 (+0.53%)

Contract

0xE78a692FA69c063c54F3e94b76a50ec28FA2AC53
 

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Upgrade118396392021-02-12 4:28:231430 days ago1613104103IN
0xE78a692F...28FA2AC53
0 ETH0.00332959128.7
Upgrade118396352021-02-12 4:27:151430 days ago1613104035IN
0xE78a692F...28FA2AC53
0 ETH0.01089213128.7
Upgrade118032262021-02-06 14:05:451436 days ago1612620345IN
0xE78a692F...28FA2AC53
0 ETH0.01134068134
Upgrade117460572021-01-28 18:57:171444 days ago1611860237IN
0xE78a692F...28FA2AC53
0 ETH0.0055148579.2
Upgrade117052252021-01-22 12:13:431451 days ago1611317623IN
0xE78a692F...28FA2AC53
0 ETH0.0022080885.35000011
Upgrade113967972020-12-06 3:48:121498 days ago1607226492IN
0xE78a692F...28FA2AC53
0 ETH0.0018703622.1
Upgrade112195792020-11-08 22:47:121525 days ago1604875632IN
0xE78a692F...28FA2AC53
0 ETH0.0011141116.00000145
Upgrade111342102020-10-26 20:30:431538 days ago1603744243IN
0xE78a692F...28FA2AC53
0 ETH0.0041779260
Upgrade110305962020-10-10 22:58:361554 days ago1602370716IN
0xE78a692F...28FA2AC53
0 ETH0.0024546729
Upgrade109893332020-10-04 12:19:341561 days ago1601813974IN
0xE78a692F...28FA2AC53
0 ETH0.0049093558
Upgrade109527182020-09-28 19:03:351566 days ago1601319815IN
0xE78a692F...28FA2AC53
0 ETH0.0022507787
Upgrade109527182020-09-28 19:03:351566 days ago1601319815IN
0xE78a692F...28FA2AC53
0 ETH0.0060579887
Upgrade109301182020-09-25 6:08:491570 days ago1601014129IN
0xE78a692F...28FA2AC53
0 ETH0.0072783586
Upgrade109268222020-09-24 18:05:141571 days ago1600970714IN
0xE78a692F...28FA2AC53
0 ETH0.0169264200
Upgrade108750982020-09-16 19:45:261578 days ago1600285526IN
0xE78a692F...28FA2AC53
0 ETH0.0066012978
Upgrade108421572020-09-11 18:21:181583 days ago1599848478IN
0xE78a692F...28FA2AC53
0 ETH0.0012935550
Upgrade107697862020-08-31 16:30:341595 days ago1598891434IN
0xE78a692F...28FA2AC53
0 ETH0.0208932300
Upgrade107640102020-08-30 19:11:441595 days ago1598814704IN
0xE78a692F...28FA2AC53
0 ETH0.01328722157
Upgrade107535402020-08-29 4:38:511597 days ago1598675931IN
0xE78a692F...28FA2AC53
0 ETH0.0071100984
Upgrade107457972020-08-28 0:06:221598 days ago1598573182IN
0xE78a692F...28FA2AC53
0 ETH0.0040629148
Upgrade107379502020-08-26 19:10:501599 days ago1598469050IN
0xE78a692F...28FA2AC53
0 ETH0.0068551981
Upgrade106902032020-08-19 11:05:251607 days ago1597835125IN
0xE78a692F...28FA2AC53
0 ETH0.01191618140.8
Upgrade106890212020-08-19 6:42:541607 days ago1597819374IN
0xE78a692F...28FA2AC53
0 ETH0.0104448150
Upgrade106789722020-08-17 17:51:161609 days ago1597686676IN
0xE78a692F...28FA2AC53
0 ETH0.00752284108
Upgrade106693132020-08-16 5:50:241610 days ago1597557024IN
0xE78a692F...28FA2AC53
0 ETH0.0074476188.00000145
View all transactions

Latest 1 internal transaction

Advanced mode:
Parent Transaction Hash Block
From
To
104971542020-07-20 15:29:171637 days ago1595258957  Contract Creation0 ETH
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
MeridianUpgrade

Compiler Version
v0.4.26+commit.4563c3fc

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, None license

Contract Source Code (Solidity Multiple files format)

File 1 of 3: upgrade.sol
pragma solidity 0.4.26;

//Contract for upgrading Meridian Network tokens from MRDN to LOCK

import "./IERC20.sol";
import "./SafeMath.sol";

contract MeridianUpgrade{
  using SafeMath for uint;

  ERC20 public oldToken;
  ERC20 public newToken;
  constructor(address tokenAddr1,address tokenAddr2) public{
    oldToken=ERC20(tokenAddr1);
    newToken=ERC20(tokenAddr2);
  }
  function upgrade(uint amount) public{
    //transfer old tokens
    oldToken.transferFrom(msg.sender,address(this),amount);
    //user recieves tokens at given ratio
    newToken.transfer(msg.sender,amount);
  }
}

File 2 of 3: IERC20.sol
interface ERC20 {
  function totalSupply() external view returns (uint256);
  function balanceOf(address who) external view returns (uint256);
  function allowance(address owner, address spender) external view returns (uint256);
  function transfer(address to, uint256 value) external returns (bool);
  function approve(address spender, uint256 value) external returns (bool);
  function approveAndCall(address spender, uint tokens, bytes data) external returns (bool success);
  function transferFrom(address from, address to, uint256 value) external returns (bool);
  function burn(uint256 amount) external;

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

File 3 of 3: SafeMath.sol
library SafeMath {
  function mul(uint256 a, uint256 b) internal pure returns (uint256) {
    if (a == 0) {
      return 0;
    }
    uint256 c = a * b;
    require(c / a == b);
    return c;
  }

  function div(uint256 a, uint256 b) internal pure returns (uint256) {
    uint256 c = a / b;
    return c;
  }

  function sub(uint256 a, uint256 b) internal pure returns (uint256) {
    require(b <= a);
    return a - b;
  }

  function add(uint256 a, uint256 b) internal pure returns (uint256) {
    uint256 c = a + b;
    require(c >= a);
    return c;
  }

  function ceil(uint256 a, uint256 m) internal pure returns (uint256) {
    uint256 c = add(a,m);
    uint256 d = sub(c,1);
    return mul(div(d,m),m);
  }
}

Contract Security Audit

Contract ABI

[{"constant":false,"inputs":[{"name":"amount","type":"uint256"}],"name":"upgrade","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"oldToken","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"newToken","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"tokenAddr1","type":"address"},{"name":"tokenAddr2","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"}]

608060405234801561001057600080fd5b506040516040806102e983398101604052805160209091015160008054600160a060020a03938416600160a060020a03199182161790915560018054939092169216919091179055610282806100676000396000f3006080604052600436106100565763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166345977d03811461005b578063b31c710a14610075578063c42bd05a146100b3575b600080fd5b34801561006757600080fd5b506100736004356100c8565b005b34801561008157600080fd5b5061008a61021e565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b3480156100bf57600080fd5b5061008a61023a565b60008054604080517f23b872dd00000000000000000000000000000000000000000000000000000000815233600482015230602482015260448101859052905173ffffffffffffffffffffffffffffffffffffffff909216926323b872dd926064808401936020939083900390910190829087803b15801561014957600080fd5b505af115801561015d573d6000803e3d6000fd5b505050506040513d602081101561017357600080fd5b5050600154604080517fa9059cbb00000000000000000000000000000000000000000000000000000000815233600482015260248101849052905173ffffffffffffffffffffffffffffffffffffffff9092169163a9059cbb916044808201926020929091908290030181600087803b1580156101ef57600080fd5b505af1158015610203573d6000803e3d6000fd5b505050506040513d602081101561021957600080fd5b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1681565b60015473ffffffffffffffffffffffffffffffffffffffff16815600a165627a7a72305820b5526051faf5795b554c75d7da0871af7e237bf3fe45c7add33dd250451092380029000000000000000000000000896a07e3788983ec52eaf0f9c6f6e031464ee2cc00000000000000000000000095172ccbe8344fecd73d0a30f54123652981bd6f

Deployed Bytecode

0x6080604052600436106100565763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166345977d03811461005b578063b31c710a14610075578063c42bd05a146100b3575b600080fd5b34801561006757600080fd5b506100736004356100c8565b005b34801561008157600080fd5b5061008a61021e565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b3480156100bf57600080fd5b5061008a61023a565b60008054604080517f23b872dd00000000000000000000000000000000000000000000000000000000815233600482015230602482015260448101859052905173ffffffffffffffffffffffffffffffffffffffff909216926323b872dd926064808401936020939083900390910190829087803b15801561014957600080fd5b505af115801561015d573d6000803e3d6000fd5b505050506040513d602081101561017357600080fd5b5050600154604080517fa9059cbb00000000000000000000000000000000000000000000000000000000815233600482015260248101849052905173ffffffffffffffffffffffffffffffffffffffff9092169163a9059cbb916044808201926020929091908290030181600087803b1580156101ef57600080fd5b505af1158015610203573d6000803e3d6000fd5b505050506040513d602081101561021957600080fd5b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1681565b60015473ffffffffffffffffffffffffffffffffffffffff16815600a165627a7a72305820b5526051faf5795b554c75d7da0871af7e237bf3fe45c7add33dd250451092380029

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

000000000000000000000000896a07e3788983ec52eaf0f9c6f6e031464ee2cc00000000000000000000000095172ccbe8344fecd73d0a30f54123652981bd6f

-----Decoded View---------------
Arg [0] : tokenAddr1 (address): 0x896a07e3788983ec52eaf0F9C6F6E031464Ee2CC
Arg [1] : tokenAddr2 (address): 0x95172ccBe8344fecD73D0a30F54123652981BD6F

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000896a07e3788983ec52eaf0f9c6f6e031464ee2cc
Arg [1] : 00000000000000000000000095172ccbe8344fecd73d0a30f54123652981bd6f


Deployed Bytecode Sourcemap

142:448:2:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;377:211;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;377:211:2;;;;;;;198:21;;8:9:-1;5:2;;;30:1;27;20:12;5:2;198:21:2;;;;;;;;;;;;;;;;;;;;;;;223;;8:9:-1;5:2;;;30:1;27;20:12;5:2;223:21:2;;;;377:211;445:8;;;:54;;;;;;467:10;445:54;;;;486:4;445:54;;;;;;;;;;;;:8;;;;;:21;;:54;;;;;;;;;;;;;;;;;:8;:54;;;5:2:-1;;;;30:1;27;20:12;5:2;445:54:2;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;445:54:2;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;547:8:2;;:36;;;;;;565:10;547:36;;;;;;;;;;;;:8;;;;;:17;;:36;;;;;445:54;;547:36;;;;;;;;:8;;:36;;;5:2:-1;;;;30:1;27;20:12;5:2;547:36:2;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;547:36:2;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;377:211:2:o;198:21::-;;;;;;:::o;223:::-;;;;;;:::o

Swarm Source

bzzr://b5526051faf5795b554c75d7da0871af7e237bf3fe45c7add33dd25045109238

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  ]
[ 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.