ETH Price: $2,025.67 (-0.82%)

Transaction Decoder

Block:
7563711 at Apr-14-2019 03:34:37 AM +UTC
Transaction Fee:
0.000035392375503156 ETH $0.07
Gas Used:
203,602 Gas / 0.173831178 Gwei

Account State Difference:

  Address   Before After State Difference Code
0x00000000...ecd22b376
0x1039E709...b518A2bd4
0 Eth
Nonce: 0
0 Eth
Nonce: 1
From: 0 To: 108132760409034485182117854503896066369170452324028095848840833303129709567
0x4568D8F1...CA55B9e51
0 Eth
Nonce: 0
0 Eth
Nonce: 1
From: 0 To: 108132760409034485182117854503896066369170452324028095848840833303129709567
0x75F87Fbb...dB8652034
0.178700787505318626 Eth
Nonce: 27239
0.17866539512981547 Eth
Nonce: 27240
0.000035392375503156
(MiningPoolHub: Old Address)
5,400.241415280926807219 Eth5,400.241450673302310375 Eth0.000035392375503156
0xf294C343...58d2ce881
0 Eth
Nonce: 0
0 Eth
Nonce: 1
From: 0 To: 108132760409034485182117854503896066369170452324028095848840833303129709567

Execution Trace

OwnedUpgradeabilityProxy.CALL( )
  • 0xbe9faf3015fb9efced0454450cbe2ead4dc41ca6.DELEGATECALL( )
    • 0x1039e709427cda3a87435951e445075b518a2bd4.601f8060( )
    • 0xf294c343f01df1de56583ed329e963a58d2ce881.601f8060( )
    • 0x4568d8f13270802cf7e7c445dcb0d49ca55b9e51.601f8060( )
      pragma solidity ^0.4.23;
      
      // This is the proxy contract for the TrustToken Registry
      
      // File: contracts/Proxy/Proxy.sol
      
      /**
       * @title Proxy
       * @dev Gives the possibility to delegate any call to a foreign implementation.
       */
      contract Proxy {
          
          /**
          * @dev Tells the address of the implementation where every call will be delegated.
          * @return address of the implementation to which it will be delegated
          */
          function implementation() public view returns (address);
      
          /**
          * @dev Fallback function allowing to perform a delegatecall to the given implementation.
          * This function will return whatever the implementation call returns
          */
          function() external payable {
              address _impl = implementation();
              require(_impl != address(0), "implementation contract not set");
              
              assembly {
                  let ptr := mload(0x40)
                  calldatacopy(ptr, 0, calldatasize)
                  let result := delegatecall(gas, _impl, ptr, calldatasize, 0, 0)
                  let size := returndatasize
                  returndatacopy(ptr, 0, size)
      
                  switch result
                  case 0 { revert(ptr, size) }
                  default { return(ptr, size) }
              }
          }
      }
      
      // File: contracts/Proxy/UpgradeabilityProxy.sol
      
      /**
       * @title UpgradeabilityProxy
       * @dev This contract represents a proxy where the implementation address to which it will delegate can be upgraded
       */
      contract UpgradeabilityProxy is Proxy {
          /**
          * @dev This event will be emitted every time the implementation gets upgraded
          * @param implementation representing the address of the upgraded implementation
          */
          event Upgraded(address indexed implementation);
      
          // Storage position of the address of the current implementation
          bytes32 private constant implementationPosition = keccak256("trueUSD.proxy.implementation");
      
          /**
          * @dev Tells the address of the current implementation
          * @return address of the current implementation
          */
          function implementation() public view returns (address impl) {
              bytes32 position = implementationPosition;
              assembly {
                impl := sload(position)
              }
          }
      
          /**
          * @dev Sets the address of the current implementation
          * @param newImplementation address representing the new implementation to be set
          */
          function _setImplementation(address newImplementation) internal {
              bytes32 position = implementationPosition;
              assembly {
                sstore(position, newImplementation)
              }
          }
      
          /**
          * @dev Upgrades the implementation address
          * @param newImplementation representing the address of the new implementation to be set
          */
          function _upgradeTo(address newImplementation) internal {
              address currentImplementation = implementation();
              require(currentImplementation != newImplementation);
              _setImplementation(newImplementation);
              emit Upgraded(newImplementation);
          }
      }
      
      // File: contracts/Proxy/OwnedUpgradeabilityProxy.sol
      
      /**
       * @title OwnedUpgradeabilityProxy
       * @dev This contract combines an upgradeability proxy with basic authorization control functionalities
       */
      contract OwnedUpgradeabilityProxy is UpgradeabilityProxy {
          /**
          * @dev Event to show ownership has been transferred
          * @param previousOwner representing the address of the previous owner
          * @param newOwner representing the address of the new owner
          */
          event ProxyOwnershipTransferred(address indexed previousOwner, address indexed newOwner);
      
          /**
          * @dev Event to show ownership transfer is pending
          * @param currentOwner representing the address of the current owner
          * @param pendingOwner representing the address of the pending owner
          */
          event NewPendingOwner(address currentOwner, address pendingOwner);
          
          // Storage position of the owner and pendingOwner of the contract
          bytes32 private constant proxyOwnerPosition = keccak256("trueUSD.proxy.owner");
          bytes32 private constant pendingProxyOwnerPosition = keccak256("trueUSD.pending.proxy.owner");
      
          /**
          * @dev the constructor sets the original owner of the contract to the sender account.
          */
          constructor() public {
              _setUpgradeabilityOwner(msg.sender);
          }
      
          /**
          * @dev Throws if called by any account other than the owner.
          */
          modifier onlyProxyOwner() {
              require(msg.sender == proxyOwner(), "only Proxy Owner");
              _;
          }
      
          /**
          * @dev Throws if called by any account other than the pending owner.
          */
          modifier onlyPendingProxyOwner() {
              require(msg.sender == pendingProxyOwner(), "only pending Proxy Owner");
              _;
          }
      
          /**
          * @dev Tells the address of the owner
          * @return the address of the owner
          */
          function proxyOwner() public view returns (address owner) {
              bytes32 position = proxyOwnerPosition;
              assembly {
                  owner := sload(position)
              }
          }
      
          /**
          * @dev Tells the address of the owner
          * @return the address of the owner
          */
          function pendingProxyOwner() public view returns (address pendingOwner) {
              bytes32 position = pendingProxyOwnerPosition;
              assembly {
                  pendingOwner := sload(position)
              }
          }
      
          /**
          * @dev Sets the address of the owner
          */
          function _setUpgradeabilityOwner(address newProxyOwner) internal {
              bytes32 position = proxyOwnerPosition;
              assembly {
                  sstore(position, newProxyOwner)
              }
          }
      
          /**
          * @dev Sets the address of the owner
          */
          function _setPendingUpgradeabilityOwner(address newPendingProxyOwner) internal {
              bytes32 position = pendingProxyOwnerPosition;
              assembly {
                  sstore(position, newPendingProxyOwner)
              }
          }
      
          /**
          * @dev Allows the current owner to transfer control of the contract to a newOwner.
          *changes the pending owner to newOwner. But doesn't actually transfer
          * @param newOwner The address to transfer ownership to.
          */
          function transferProxyOwnership(address newOwner) external onlyProxyOwner {
              require(newOwner != address(0));
              _setPendingUpgradeabilityOwner(newOwner);
              emit NewPendingOwner(proxyOwner(), newOwner);
          }
      
          /**
          * @dev Allows the pendingOwner to claim ownership of the proxy
          */
          function claimProxyOwnership() external onlyPendingProxyOwner {
              emit ProxyOwnershipTransferred(proxyOwner(), pendingProxyOwner());
              _setUpgradeabilityOwner(pendingProxyOwner());
              _setPendingUpgradeabilityOwner(address(0));
          }
      
          /**
          * @dev Allows the proxy owner to upgrade the current version of the proxy.
          * @param implementation representing the address of the new implementation to be set.
          */
          function upgradeTo(address implementation) external onlyProxyOwner {
              _upgradeTo(implementation);
          }
      }