ETH Price: $1,982.37 (-4.38%)

Transaction Decoder

Block:
18784053 at Dec-14-2023 11:21:47 AM +UTC
Transaction Fee:
0.002011840824246734 ETH $3.99
Gas Used:
53,378 Gas / 37.690449703 Gwei

Emitted Events:

443 DSToken.Transfer( src=[Receiver] 0x1cd2fee164bc6b143fd9588f022949e2edb024db, dst=[Sender] 0xd063f25fdd885b2eb2d71fbd1b26f48f03bf50da, wad=24661411663679808841100 )
444 0x1cd2fee164bc6b143fd9588f022949e2edb024db.0xc7798891864187665ac6dd119286e44ec13f014527aeeb2b8eb3fd413df93179( 0xc7798891864187665ac6dd119286e44ec13f014527aeeb2b8eb3fd413df93179, 00000000000000000000000056ebdae96d179549f279ea0cfea3b3432b8cd2bc, 000000000000000000000000000000000000000000000538e5d68e5b9e23a58c )

Account State Difference:

  Address   Before After State Difference Code
0x1Cd2Fee1...2eDb024DB
0x56EBDaE9...32B8Cd2bC
(beaverbuild)
12.835835835090774792 Eth12.835841172890774792 Eth0.0000053378
0xd063f25F...f03bf50da
5.147675753327192312 Eth
Nonce: 197
5.145663912502945578 Eth
Nonce: 198
0.002011840824246734

Execution Trace

0x1cd2fee164bc6b143fd9588f022949e2edb024db.19165587( )
  • DSToken.balanceOf( 0x1Cd2Fee164bC6B143Fd9588f022949E2eDb024DB ) => ( 24661411663679808841100 )
  • DSToken.transfer( dst=0xd063f25FdD885B2Eb2D71fBD1B26F48f03bf50da, wad=24661411663679808841100 ) => ( True )
    // SPDX-License-Identifier: GPL-3.0-or-later
    
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    // GNU General Public License for more details.
    
    // You should have received a copy of the GNU General Public License
    // along with this program.  If not, see <http://www.gnu.org/licenses/>.
    
    pragma solidity ^0.7.4;
    
    interface DSAuthority {
        function canCall(
            address src, address dst, bytes4 sig
        ) external view returns (bool);
    }
    
    contract DSAuthEvents {
        event LogSetAuthority (address indexed authority);
        event LogSetOwner     (address indexed owner);
    }
    
    contract DSAuth is DSAuthEvents {
        DSAuthority  public  authority;
        address      public  owner;
    
        constructor() {
            owner = msg.sender;
            emit LogSetOwner(msg.sender);
        }
    
        function setOwner(address owner_)
            public
            auth
        {
            owner = owner_;
            emit LogSetOwner(owner);
        }
    
        function setAuthority(DSAuthority authority_)
            public
            auth
        {
            authority = authority_;
            emit LogSetAuthority(address(authority));
        }
    
        modifier auth {
            require(isAuthorized(msg.sender, msg.sig), "ds-auth-unauthorized");
            _;
        }
    
        function isAuthorized(address src, bytes4 sig) internal view returns (bool) {
            if (src == address(this)) {
                return true;
            } else if (src == owner) {
                return true;
            } else if (authority == DSAuthority(address(0))) {
                return false;
            } else {
                return authority.canCall(src, address(this), sig);
            }
        }
    }
    
    contract DSMath {
        function add(uint x, uint y) internal pure returns (uint z) {
            require((z = x + y) >= x, "ds-math-add-overflow");
        }
        function sub(uint x, uint y) internal pure returns (uint z) {
            require((z = x - y) <= x, "ds-math-sub-underflow");
        }
        function mul(uint x, uint y) internal pure returns (uint z) {
            require(y == 0 || (z = x * y) / y == x, "ds-math-mul-overflow");
        }
    
        function min(uint x, uint y) internal pure returns (uint z) {
            return x <= y ? x : y;
        }
        function max(uint x, uint y) internal pure returns (uint z) {
            return x >= y ? x : y;
        }
        function imin(int x, int y) internal pure returns (int z) {
            return x <= y ? x : y;
        }
        function imax(int x, int y) internal pure returns (int z) {
            return x >= y ? x : y;
        }
    
        uint constant WAD = 10 ** 18;
        uint constant RAY = 10 ** 27;
    
        //rounds to zero if x*y < WAD / 2
        function wmul(uint x, uint y) internal pure returns (uint z) {
            z = add(mul(x, y), WAD / 2) / WAD;
        }
        //rounds to zero if x*y < WAD / 2
        function rmul(uint x, uint y) internal pure returns (uint z) {
            z = add(mul(x, y), RAY / 2) / RAY;
        }
        //rounds to zero if x*y < WAD / 2
        function wdiv(uint x, uint y) internal pure returns (uint z) {
            z = add(mul(x, WAD), y / 2) / y;
        }
        //rounds to zero if x*y < RAY / 2
        function rdiv(uint x, uint y) internal pure returns (uint z) {
            z = add(mul(x, RAY), y / 2) / y;
        }
    
        // This famous algorithm is called "exponentiation by squaring"
        // and calculates x^n with x as fixed-point and n as regular unsigned.
        //
        // It's O(log n), instead of O(n) for naive repeated multiplication.
        //
        // These facts are why it works:
        //
        //  If n is even, then x^n = (x^2)^(n/2).
        //  If n is odd,  then x^n = x * x^(n-1),
        //   and applying the equation for even x gives
        //    x^n = x * (x^2)^((n-1) / 2).
        //
        //  Also, EVM division is flooring and
        //    floor[(n-1) / 2] = floor[n / 2].
        //
        function rpow(uint x, uint n) internal pure returns (uint z) {
            z = n % 2 != 0 ? x : RAY;
    
            for (n /= 2; n != 0; n /= 2) {
                x = rmul(x, x);
    
                if (n % 2 != 0) {
                    z = rmul(z, x);
                }
            }
        }
    }
    
    contract DSToken is DSMath, DSAuth {
        bool                                              public  stopped;
        uint256                                           public  totalSupply;
        mapping (address => uint256)                      public  balanceOf;
        mapping (address => mapping (address => uint256)) public  allowance;
        string                                            public  symbol;
        uint256                                           public  decimals = 18; // standard token precision. override to customize
        string                                            public  name = "";     // Optional token name
    
        constructor(string memory symbol_) {
            symbol = symbol_;
        }
    
        event Approval(address indexed src, address indexed guy, uint wad);
        event Transfer(address indexed src, address indexed dst, uint wad);
        event Mint(address indexed guy, uint wad);
        event Burn(address indexed guy, uint wad);
        event Stop();
        event Start();
    
        modifier stoppable {
            require(!stopped, "ds-stop-is-stopped");
            _;
        }
    
        function approve(address guy, uint wad) public stoppable returns (bool) {
            allowance[msg.sender][guy] = wad;
    
            emit Approval(msg.sender, guy, wad);
    
            return true;
        }
    
        function transfer(address dst, uint wad) external returns (bool) {
            return transferFrom(msg.sender, dst, wad);
        }
    
        function transferFrom(address src, address dst, uint wad)
            public
            stoppable
            returns (bool)
        {
            if (src != msg.sender && allowance[src][msg.sender] != uint(-1)) {
                require(allowance[src][msg.sender] >= wad, "ds-token-insufficient-approval");
                allowance[src][msg.sender] = sub(allowance[src][msg.sender], wad);
            }
    
            require(balanceOf[src] >= wad, "ds-token-insufficient-balance");
            balanceOf[src] = sub(balanceOf[src], wad);
            balanceOf[dst] = add(balanceOf[dst], wad);
    
            emit Transfer(src, dst, wad);
    
            return true;
        }
    
        function mint(address guy, uint wad) public auth stoppable {
            balanceOf[guy] = add(balanceOf[guy], wad);
            totalSupply = add(totalSupply, wad);
            emit Mint(guy, wad);
        }
    
        function burn(address guy, uint wad) public auth stoppable {
            if (guy != msg.sender && allowance[guy][msg.sender] != uint(-1)) {
                require(allowance[guy][msg.sender] >= wad, "ds-token-insufficient-approval");
                allowance[guy][msg.sender] = sub(allowance[guy][msg.sender], wad);
            }
    
            require(balanceOf[guy] >= wad, "ds-token-insufficient-balance");
            balanceOf[guy] = sub(balanceOf[guy], wad);
            totalSupply = sub(totalSupply, wad);
            emit Burn(guy, wad);
        }
    
        function stop() public auth {
            stopped = true;
            emit Stop();
        }
    
        function start() public auth {
            stopped = false;
            emit Start();
        }
    
        function setName(string memory name_) external auth {
            name = name_;
        }
    
        function setSymbol(string memory symbol_) external auth {
            symbol = symbol_;
        }
    }