ETH Price: $1,857.37 (-0.01%)
Gas: 0.07 Gwei
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

More Info

Private Name Tags

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Airdrop173896462023-06-02 0:56:47998 days ago1685667407IN
0x8247BF7b...6740F5706
0 ETH0.0038623623.48329852
Airdrop173836652023-06-01 4:43:35999 days ago1685594615IN
0x8247BF7b...6740F5706
0 ETH0.0062545528.55506317
Airdrop173830032023-06-01 2:29:35999 days ago1685586575IN
0x8247BF7b...6740F5706
0 ETH0.0090023546.95033273
Airdrop173826912023-06-01 1:26:23999 days ago1685582783IN
0x8247BF7b...6740F5706
0 ETH0.0132670444.09442669
Airdrop173824302023-06-01 0:33:23999 days ago1685579603IN
0x8247BF7b...6740F5706
0 ETH0.0073945227.02705451
Airdrop173821672023-05-31 23:40:23999 days ago1685576423IN
0x8247BF7b...6740F5706
0 ETH0.0070722125.85017034
Airdrop173819052023-05-31 22:47:11999 days ago1685573231IN
0x8247BF7b...6740F5706
0 ETH0.0050318126.24096752
Airdrop173549422023-05-28 3:47:231003 days ago1685245643IN
0x8247BF7b...6740F5706
0 ETH0.0071777721.87364646
Airdrop173546772023-05-28 2:54:231003 days ago1685242463IN
0x8247BF7b...6740F5706
0 ETH0.0047464824.75143203
Airdrop173544162023-05-28 2:01:231003 days ago1685239283IN
0x8247BF7b...6740F5706
0 ETH0.0065023826.3972573
Airdrop173541532023-05-28 1:08:231003 days ago1685236103IN
0x8247BF7b...6740F5706
0 ETH0.0060235327.49880908
Airdrop173538902023-05-28 0:15:111003 days ago1685232911IN
0x8247BF7b...6740F5706
0 ETH0.0053828521.85238787
Airdrop173536302023-05-27 23:22:111003 days ago1685229731IN
0x8247BF7b...6740F5706
0 ETH0.0063695623.27981987
Airdrop173533672023-05-27 22:29:231003 days ago1685226563IN
0x8247BF7b...6740F5706
0 ETH0.007976324.30710725
Airdrop173531012023-05-27 21:36:111003 days ago1685223371IN
0x8247BF7b...6740F5706
0 ETH0.007707523.48795214
Airdrop173528392023-05-27 20:43:231003 days ago1685220203IN
0x8247BF7b...6740F5706
0 ETH0.0080592824.5590721
Airdrop173525792023-05-27 19:50:111003 days ago1685217011IN
0x8247BF7b...6740F5706
0 ETH0.0058194823.62609277
Airdrop173523152023-05-27 18:57:111003 days ago1685213831IN
0x8247BF7b...6740F5706
0 ETH0.0091441925.72987161
Airdrop173520542023-05-27 18:04:111004 days ago1685210651IN
0x8247BF7b...6740F5706
0 ETH0.0042247822.0323388
Airdrop173517942023-05-27 17:11:111004 days ago1685207471IN
0x8247BF7b...6740F5706
0 ETH0.0059102226.98154536
Airdrop173515302023-05-27 16:18:111004 days ago1685204291IN
0x8247BF7b...6740F5706
0 ETH0.0131029934.23855674
Airdrop173512692023-05-27 15:25:111004 days ago1685201111IN
0x8247BF7b...6740F5706
0 ETH0.0048821325.45880533
Airdrop173510042023-05-27 14:32:111004 days ago1685197931IN
0x8247BF7b...6740F5706
0 ETH0.0073023424.27010915
Airdrop173507412023-05-27 13:39:111004 days ago1685194751IN
0x8247BF7b...6740F5706
0 ETH0.0080578422.67159371
Airdrop173504762023-05-27 12:46:111004 days ago1685191571IN
0x8247BF7b...6740F5706
0 ETH0.0082526123.22037733
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
JustAnAirdrop

Compiler Version
v0.8.19+commit.7dd6d404

Optimization Enabled:
Yes with 20000 runs

Other Settings:
default evmVersion, MIT license
/**
 *Submitted for verification at Etherscan.io on 2023-05-10
*/

// File: @openzeppelin/contracts/token/ERC20/IERC20.sol


// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);

    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `from` to `to` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 amount
    ) external returns (bool);
}

// File: contracts/airdrop.sol


pragma solidity ^0.8.0;
/** Heavily borrowed from Wentokens
https://mirror.xyz/magnatokens.eth/mKAQOM3ntmvcSM5LjX59zFZj5-gYiyqCnEvUu6FDqvw
This is intended to be a stupid simple, opinionated airdrop contract
It should be relatively efficient, but not so advanced that it uses yul/assembly.
Because that stuff is scary.
*/


contract JustAnAirdrop {
    /** Airdrop function
    Usage:
    Include token address and matching arrays of recipients and amounts
    Include total amount of tokens available for airdrop.
    Note: If there are excess tokens, they will be returned to the user
    Note: Relies on the user approving the contract first! */

    function Airdrop (
    IERC20 _token,
    address[] calldata _recipients,
    uint256[] calldata _amounts,
    uint256 _total
    ) external {
        uint256 totalRecipients = _recipients.length; // Number of recipients passed
        require(totalRecipients == _amounts.length, "Number of recipients does not match number of amounts. Something is wrong!");
        require(_token.transferFrom(msg.sender, address(this), _total), "Unable to transfer tokens to contract. Check your balance/approval."); 
        // The dreaded for loop. If this fails due to gas break your drops into smaller batches
        for (uint256 i = 0; i < totalRecipients; i++) {
            _token.transfer(_recipients[i], _amounts[i]);
        }
        // If there are leftover tokens, return them
        // This function should never leave tokens behind, but if someone "donates" tokens it's first come first serve...
        uint256 contractTokenBalance = _token.balanceOf(address(this));
        if (contractTokenBalance > 0) {
            _token.transfer(msg.sender, contractTokenBalance);
        }
    }
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"contract IERC20","name":"_token","type":"address"},{"internalType":"address[]","name":"_recipients","type":"address[]"},{"internalType":"uint256[]","name":"_amounts","type":"uint256[]"},{"internalType":"uint256","name":"_total","type":"uint256"}],"name":"Airdrop","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b506106bb806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c806339af8c7314610030575b600080fd5b61004361003e36600461050d565b610045565b005b83828114610100576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4e756d626572206f6620726563697069656e747320646f6573206e6f74206d6160448201527f746368206e756d626572206f6620616d6f756e74732e20536f6d657468696e6760648201527f2069732077726f6e672100000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526044810183905273ffffffffffffffffffffffffffffffffffffffff8816906323b872dd906064016020604051808303816000875af1158015610179573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061019d9190610598565b61024f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f556e61626c6520746f207472616e7366657220746f6b656e7320746f20636f6e60448201527f74726163742e20436865636b20796f75722062616c616e63652f617070726f7660648201527f616c2e0000000000000000000000000000000000000000000000000000000000608482015260a4016100f7565b60005b8181101561035f578773ffffffffffffffffffffffffffffffffffffffff1663a9059cbb888884818110610288576102886105c1565b905060200201602081019061029d91906105f0565b8787858181106102af576102af6105c1565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e087901b16815273ffffffffffffffffffffffffffffffffffffffff909416600485015260200291909101356024830152506044016020604051808303816000875af1158015610328573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061034c9190610598565b50806103578161060d565b915050610252565b506040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009073ffffffffffffffffffffffffffffffffffffffff8916906370a0823190602401602060405180830381865afa1580156103cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103f1919061066c565b90508015610492576040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810182905273ffffffffffffffffffffffffffffffffffffffff89169063a9059cbb906044016020604051808303816000875af115801561046c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104909190610598565b505b5050505050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146104be57600080fd5b50565b60008083601f8401126104d357600080fd5b50813567ffffffffffffffff8111156104eb57600080fd5b6020830191508360208260051b850101111561050657600080fd5b9250929050565b6000806000806000806080878903121561052657600080fd5b86356105318161049c565b9550602087013567ffffffffffffffff8082111561054e57600080fd5b61055a8a838b016104c1565b9097509550604089013591508082111561057357600080fd5b5061058089828a016104c1565b979a9699509497949695606090950135949350505050565b6000602082840312156105aa57600080fd5b815180151581146105ba57600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561060257600080fd5b81356105ba8161049c565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610665577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b60006020828403121561067e57600080fd5b505191905056fea26469706673582212207c01707d6da4b74c92f155d747b35cd8a551abc4e8e62ac8bb7f81601e6693c264736f6c63430008130033

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061002b5760003560e01c806339af8c7314610030575b600080fd5b61004361003e36600461050d565b610045565b005b83828114610100576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4e756d626572206f6620726563697069656e747320646f6573206e6f74206d6160448201527f746368206e756d626572206f6620616d6f756e74732e20536f6d657468696e6760648201527f2069732077726f6e672100000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526044810183905273ffffffffffffffffffffffffffffffffffffffff8816906323b872dd906064016020604051808303816000875af1158015610179573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061019d9190610598565b61024f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f556e61626c6520746f207472616e7366657220746f6b656e7320746f20636f6e60448201527f74726163742e20436865636b20796f75722062616c616e63652f617070726f7660648201527f616c2e0000000000000000000000000000000000000000000000000000000000608482015260a4016100f7565b60005b8181101561035f578773ffffffffffffffffffffffffffffffffffffffff1663a9059cbb888884818110610288576102886105c1565b905060200201602081019061029d91906105f0565b8787858181106102af576102af6105c1565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e087901b16815273ffffffffffffffffffffffffffffffffffffffff909416600485015260200291909101356024830152506044016020604051808303816000875af1158015610328573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061034c9190610598565b50806103578161060d565b915050610252565b506040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009073ffffffffffffffffffffffffffffffffffffffff8916906370a0823190602401602060405180830381865afa1580156103cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103f1919061066c565b90508015610492576040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810182905273ffffffffffffffffffffffffffffffffffffffff89169063a9059cbb906044016020604051808303816000875af115801561046c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104909190610598565b505b5050505050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146104be57600080fd5b50565b60008083601f8401126104d357600080fd5b50813567ffffffffffffffff8111156104eb57600080fd5b6020830191508360208260051b850101111561050657600080fd5b9250929050565b6000806000806000806080878903121561052657600080fd5b86356105318161049c565b9550602087013567ffffffffffffffff8082111561054e57600080fd5b61055a8a838b016104c1565b9097509550604089013591508082111561057357600080fd5b5061058089828a016104c1565b979a9699509497949695606090950135949350505050565b6000602082840312156105aa57600080fd5b815180151581146105ba57600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561060257600080fd5b81356105ba8161049c565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610665577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b60006020828403121561067e57600080fd5b505191905056fea26469706673582212207c01707d6da4b74c92f155d747b35cd8a551abc4e8e62ac8bb7f81601e6693c264736f6c63430008130033

Deployed Bytecode Sourcemap

3248:1449:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3586:1108;;;;;;:::i;:::-;;:::i;:::-;;;3769:11;3837:34;;;3829:121;;;;;;;1758:2:1;3829:121:0;;;1740:21:1;1797:2;1777:18;;;1770:30;1836:34;1816:18;;;1809:62;1907:34;1887:18;;;1880:62;1979:12;1958:19;;;1951:41;2009:19;;3829:121:0;;;;;;;;;3969:54;;;;;3989:10;3969:54;;;2302:34:1;4009:4:0;2352:18:1;;;2345:43;2404:18;;;2397:34;;;3969:19:0;;;;;;2214:18:1;;3969:54:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;3961:134;;;;;;;2926:2:1;3961:134:0;;;2908:21:1;2965:2;2945:18;;;2938:30;3004:34;2984:18;;;2977:62;3075:34;3055:18;;;3048:62;3147:5;3126:19;;;3119:34;3170:19;;3961:134:0;2724:471:1;3961:134:0;4209:9;4204:117;4228:15;4224:1;:19;4204:117;;;4265:6;:15;;;4281:11;;4293:1;4281:14;;;;;;;:::i;:::-;;;;;;;;;;;;;;:::i;:::-;4297:8;;4306:1;4297:11;;;;;;;:::i;:::-;4265:44;;;;;;;;;;3853:42:1;3841:55;;;4265:44:0;;;3823:74:1;4297:11:0;;;;;;;3913:18:1;;;3906:34;-1:-1:-1;3796:18:1;;4265:44:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;-1:-1:-1;4245:3:0;;;;:::i;:::-;;;;4204:117;;;-1:-1:-1;4539:31:0;;;;;4564:4;4539:31;;;4451:74:1;4508:28:0;;4539:16;;;;;;4424:18:1;;4539:31:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;4508:62;-1:-1:-1;4585:24:0;;4581:106;;4626:49;;;;;4642:10;4626:49;;;3823:74:1;3913:18;;;3906:34;;;4626:15:0;;;;;;3796:18:1;;4626:49:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;4581:106;3732:962;;3586:1108;;;;;;:::o;14:162:1:-;108:42;101:5;97:54;90:5;87:65;77:93;;166:1;163;156:12;77:93;14:162;:::o;181:367::-;244:8;254:6;308:3;301:4;293:6;289:17;285:27;275:55;;326:1;323;316:12;275:55;-1:-1:-1;349:20:1;;392:18;381:30;;378:50;;;424:1;421;414:12;378:50;461:4;453:6;449:17;437:29;;521:3;514:4;504:6;501:1;497:14;489:6;485:27;481:38;478:47;475:67;;;538:1;535;528:12;475:67;181:367;;;;;:::o;553:998::-;706:6;714;722;730;738;746;799:3;787:9;778:7;774:23;770:33;767:53;;;816:1;813;806:12;767:53;855:9;842:23;874:39;907:5;874:39;:::i;:::-;932:5;-1:-1:-1;988:2:1;973:18;;960:32;1011:18;1041:14;;;1038:34;;;1068:1;1065;1058:12;1038:34;1107:70;1169:7;1160:6;1149:9;1145:22;1107:70;:::i;:::-;1196:8;;-1:-1:-1;1081:96:1;-1:-1:-1;1284:2:1;1269:18;;1256:32;;-1:-1:-1;1300:16:1;;;1297:36;;;1329:1;1326;1319:12;1297:36;;1368:72;1432:7;1421:8;1410:9;1406:24;1368:72;:::i;:::-;553:998;;;;-1:-1:-1;553:998:1;;;;;1541:2;1526:18;;;1513:32;;553:998;-1:-1:-1;;;;553:998:1:o;2442:277::-;2509:6;2562:2;2550:9;2541:7;2537:23;2533:32;2530:52;;;2578:1;2575;2568:12;2530:52;2610:9;2604:16;2663:5;2656:13;2649:21;2642:5;2639:32;2629:60;;2685:1;2682;2675:12;2629:60;2708:5;2442:277;-1:-1:-1;;;2442:277:1:o;3200:184::-;3252:77;3249:1;3242:88;3349:4;3346:1;3339:15;3373:4;3370:1;3363:15;3389:255;3448:6;3501:2;3489:9;3480:7;3476:23;3472:32;3469:52;;;3517:1;3514;3507:12;3469:52;3556:9;3543:23;3575:39;3608:5;3575:39;:::i;3951:349::-;3990:3;4021:66;4014:5;4011:77;4008:257;;4121:77;4118:1;4111:88;4222:4;4219:1;4212:15;4250:4;4247:1;4240:15;4008:257;-1:-1:-1;4292:1:1;4281:13;;3951:349::o;4536:184::-;4606:6;4659:2;4647:9;4638:7;4634:23;4630:32;4627:52;;;4675:1;4672;4665:12;4627:52;-1:-1:-1;4698:16:1;;4536:184;-1:-1:-1;4536:184:1:o

Swarm Source

ipfs://7c01707d6da4b74c92f155d747b35cd8a551abc4e8e62ac8bb7f81601e6693c2

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading
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.