APE Price: $0.50 (-8.61%)

Contract

0x7664f35b6d54bCD9F7562afECF921C8f55214185

Overview

APE Balance

Apechain LogoApechain LogoApechain Logo0 APE

APE Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To

There are no matching entries

Please try again later

Parent Transaction Hash Block From To
View All Internal Transactions

Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
DixoToken

Compiler Version
v0.8.20+commit.a1b79de6

Optimization Enabled:
No with 200 runs

Other Settings:
shanghai EvmVersion, MIT license
/**
 *Submitted for verification at apescan.io on 2024-11-07
*/

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;

contract DixoToken {
    // 1. Token supply and balances
    uint256 public constant MAX_SUPPLY = 1000000 * 10 ** 18;
    mapping(address => uint256) private _balances;

    // 2. Admin variable to control sensitive actions
    address public admin;

    // 3. Event for Transfer actions
    event Transfer(address indexed from, address indexed to, uint256 value);

    // 4. Constructor to set the admin and initial supply
    constructor(address initialAdmin) {
        admin = initialAdmin;
        _balances[admin] = MAX_SUPPLY; // Assign all tokens to admin initially
    }

    // 5. Modifier to restrict actions to admin
    modifier onlyAdmin() {
        require(msg.sender == admin, "Not admin");
        _;
    }

    // 6. Transfer function to move tokens from one address to another
    function transfer(address to, uint256 amount) public returns (bool) {
        require(_balances[msg.sender] >= amount, "Insufficient balance");
        _balances[msg.sender] -= amount;
        _balances[to] += amount;
        emit Transfer(msg.sender, to, amount);
        return true;
    }
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"address","name":"initialAdmin","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"MAX_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"admin","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"}]

608060405234801561000f575f80fd5b5060405161068138038061068183398181016040528101906100319190610141565b8060015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555069d3c21bcecceda10000005f8060015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055505061016c565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f610110826100e7565b9050919050565b61012081610106565b811461012a575f80fd5b50565b5f8151905061013b81610117565b92915050565b5f60208284031215610156576101556100e3565b5b5f6101638482850161012d565b91505092915050565b610508806101795f395ff3fe608060405234801561000f575f80fd5b506004361061003f575f3560e01c806332cb6b0c14610043578063a9059cbb14610061578063f851a44014610091575b5f80fd5b61004b6100af565b604051610058919061028d565b60405180910390f35b61007b6004803603810190610076919061032e565b6100bd565b6040516100889190610386565b60405180910390f35b610099610250565b6040516100a691906103ae565b60405180910390f35b69d3c21bcecceda100000081565b5f815f803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054101561013d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161013490610421565b60405180910390fd5b815f803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f828254610188919061046c565b92505081905550815f808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8282546101da919061049f565b925050819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161023e919061028d565b60405180910390a36001905092915050565b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f819050919050565b61028781610275565b82525050565b5f6020820190506102a05f83018461027e565b92915050565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f6102d3826102aa565b9050919050565b6102e3816102c9565b81146102ed575f80fd5b50565b5f813590506102fe816102da565b92915050565b61030d81610275565b8114610317575f80fd5b50565b5f8135905061032881610304565b92915050565b5f8060408385031215610344576103436102a6565b5b5f610351858286016102f0565b92505060206103628582860161031a565b9150509250929050565b5f8115159050919050565b6103808161036c565b82525050565b5f6020820190506103995f830184610377565b92915050565b6103a8816102c9565b82525050565b5f6020820190506103c15f83018461039f565b92915050565b5f82825260208201905092915050565b7f496e73756666696369656e742062616c616e63650000000000000000000000005f82015250565b5f61040b6014836103c7565b9150610416826103d7565b602082019050919050565b5f6020820190508181035f830152610438816103ff565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f61047682610275565b915061048183610275565b92508282039050818111156104995761049861043f565b5b92915050565b5f6104a982610275565b91506104b483610275565b92508282019050808211156104cc576104cb61043f565b5b9291505056fea26469706673582212207bf851080cd43aa3236777f44e6c771a6b9f47251fdc00b6d97ab155684a57da64736f6c6343000814003300000000000000000000000079debf73df7657bb8638bd8d81b2558d70a29248

Deployed Bytecode

0x608060405234801561000f575f80fd5b506004361061003f575f3560e01c806332cb6b0c14610043578063a9059cbb14610061578063f851a44014610091575b5f80fd5b61004b6100af565b604051610058919061028d565b60405180910390f35b61007b6004803603810190610076919061032e565b6100bd565b6040516100889190610386565b60405180910390f35b610099610250565b6040516100a691906103ae565b60405180910390f35b69d3c21bcecceda100000081565b5f815f803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054101561013d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161013490610421565b60405180910390fd5b815f803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f828254610188919061046c565b92505081905550815f808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8282546101da919061049f565b925050819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161023e919061028d565b60405180910390a36001905092915050565b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f819050919050565b61028781610275565b82525050565b5f6020820190506102a05f83018461027e565b92915050565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f6102d3826102aa565b9050919050565b6102e3816102c9565b81146102ed575f80fd5b50565b5f813590506102fe816102da565b92915050565b61030d81610275565b8114610317575f80fd5b50565b5f8135905061032881610304565b92915050565b5f8060408385031215610344576103436102a6565b5b5f610351858286016102f0565b92505060206103628582860161031a565b9150509250929050565b5f8115159050919050565b6103808161036c565b82525050565b5f6020820190506103995f830184610377565b92915050565b6103a8816102c9565b82525050565b5f6020820190506103c15f83018461039f565b92915050565b5f82825260208201905092915050565b7f496e73756666696369656e742062616c616e63650000000000000000000000005f82015250565b5f61040b6014836103c7565b9150610416826103d7565b602082019050919050565b5f6020820190508181035f830152610438816103ff565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f61047682610275565b915061048183610275565b92508282039050818111156104995761049861043f565b5b92915050565b5f6104a982610275565b91506104b483610275565b92508282019050808211156104cc576104cb61043f565b5b9291505056fea26469706673582212207bf851080cd43aa3236777f44e6c771a6b9f47251fdc00b6d97ab155684a57da64736f6c63430008140033

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

00000000000000000000000079debf73df7657bb8638bd8d81b2558d70a29248

-----Decoded View---------------
Arg [0] : initialAdmin (address): 0x79DeBf73DF7657bB8638BD8d81b2558d70A29248

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 00000000000000000000000079debf73df7657bb8638bd8d81b2558d70a29248


Deployed Bytecode Sourcemap

61:1123:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;124:55;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;884:297;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;295:20;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;124:55;161:18;124:55;:::o;884:297::-;946:4;996:6;971:9;:21;981:10;971:21;;;;;;;;;;;;;;;;:31;;963:64;;;;;;;;;;;;:::i;:::-;;;;;;;;;1063:6;1038:9;:21;1048:10;1038:21;;;;;;;;;;;;;;;;:31;;;;;;;:::i;:::-;;;;;;;;1097:6;1080:9;:13;1090:2;1080:13;;;;;;;;;;;;;;;;:23;;;;;;;:::i;:::-;;;;;;;;1140:2;1119:32;;1128:10;1119:32;;;1144:6;1119:32;;;;;;:::i;:::-;;;;;;;;1169:4;1162:11;;884:297;;;;:::o;295:20::-;;;;;;;;;;;;;:::o;7:77:1:-;44:7;73:5;62:16;;7:77;;;:::o;90:118::-;177:24;195:5;177:24;:::i;:::-;172:3;165:37;90:118;;:::o;214:222::-;307:4;345:2;334:9;330:18;322:26;;358:71;426:1;415:9;411:17;402:6;358:71;:::i;:::-;214:222;;;;:::o;523:117::-;632:1;629;622:12;769:126;806:7;846:42;839:5;835:54;824:65;;769:126;;;:::o;901:96::-;938:7;967:24;985:5;967:24;:::i;:::-;956:35;;901:96;;;:::o;1003:122::-;1076:24;1094:5;1076:24;:::i;:::-;1069:5;1066:35;1056:63;;1115:1;1112;1105:12;1056:63;1003:122;:::o;1131:139::-;1177:5;1215:6;1202:20;1193:29;;1231:33;1258:5;1231:33;:::i;:::-;1131:139;;;;:::o;1276:122::-;1349:24;1367:5;1349:24;:::i;:::-;1342:5;1339:35;1329:63;;1388:1;1385;1378:12;1329:63;1276:122;:::o;1404:139::-;1450:5;1488:6;1475:20;1466:29;;1504:33;1531:5;1504:33;:::i;:::-;1404:139;;;;:::o;1549:474::-;1617:6;1625;1674:2;1662:9;1653:7;1649:23;1645:32;1642:119;;;1680:79;;:::i;:::-;1642:119;1800:1;1825:53;1870:7;1861:6;1850:9;1846:22;1825:53;:::i;:::-;1815:63;;1771:117;1927:2;1953:53;1998:7;1989:6;1978:9;1974:22;1953:53;:::i;:::-;1943:63;;1898:118;1549:474;;;;;:::o;2029:90::-;2063:7;2106:5;2099:13;2092:21;2081:32;;2029:90;;;:::o;2125:109::-;2206:21;2221:5;2206:21;:::i;:::-;2201:3;2194:34;2125:109;;:::o;2240:210::-;2327:4;2365:2;2354:9;2350:18;2342:26;;2378:65;2440:1;2429:9;2425:17;2416:6;2378:65;:::i;:::-;2240:210;;;;:::o;2456:118::-;2543:24;2561:5;2543:24;:::i;:::-;2538:3;2531:37;2456:118;;:::o;2580:222::-;2673:4;2711:2;2700:9;2696:18;2688:26;;2724:71;2792:1;2781:9;2777:17;2768:6;2724:71;:::i;:::-;2580:222;;;;:::o;2808:169::-;2892:11;2926:6;2921:3;2914:19;2966:4;2961:3;2957:14;2942:29;;2808:169;;;;:::o;2983:170::-;3123:22;3119:1;3111:6;3107:14;3100:46;2983:170;:::o;3159:366::-;3301:3;3322:67;3386:2;3381:3;3322:67;:::i;:::-;3315:74;;3398:93;3487:3;3398:93;:::i;:::-;3516:2;3511:3;3507:12;3500:19;;3159:366;;;:::o;3531:419::-;3697:4;3735:2;3724:9;3720:18;3712:26;;3784:9;3778:4;3774:20;3770:1;3759:9;3755:17;3748:47;3812:131;3938:4;3812:131;:::i;:::-;3804:139;;3531:419;;;:::o;3956:180::-;4004:77;4001:1;3994:88;4101:4;4098:1;4091:15;4125:4;4122:1;4115:15;4142:194;4182:4;4202:20;4220:1;4202:20;:::i;:::-;4197:25;;4236:20;4254:1;4236:20;:::i;:::-;4231:25;;4280:1;4277;4273:9;4265:17;;4304:1;4298:4;4295:11;4292:37;;;4309:18;;:::i;:::-;4292:37;4142:194;;;;:::o;4342:191::-;4382:3;4401:20;4419:1;4401:20;:::i;:::-;4396:25;;4435:20;4453:1;4435:20;:::i;:::-;4430:25;;4478:1;4475;4471:9;4464:16;;4499:3;4496:1;4493:10;4490:36;;;4506:18;;:::i;:::-;4490:36;4342:191;;;;:::o

Swarm Source

ipfs://7bf851080cd43aa3236777f44e6c771a6b9f47251fdc00b6d97ab155684a57da

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

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.