Address Contract Partially Verified
Address
0x007900054D0557E64F46552a2B5C86f7Fc9b88da
Balance
0.000300000 ETH ($0.62)
Nonce
1
Code Size
2117 bytes
Creator
0x9e57674F...25cc at tx 0xee2ded25...3c3bff
Indexed Transactions
0
Contract Bytecode
2117 bytes
0x60806040526004361061007a575f3560e01c806379f0fac01161004d57806379f0fac0146100fe5780638da5cb5b14610108578063c5c4744c14610132578063f2fde38b1461015c5761007a565b806312065fe01461007e5780633ccfd60b146100a85780636c7f3f17146100be578063715018a6146100e8575b5f5ffd5b348015610089575f5ffd5b50610092610184565b60405161009f919061057d565b60405180910390f35b3480156100b3575f5ffd5b506100bc61018b565b005b3480156100c9575f5ffd5b506100d26102d7565b6040516100df919061057d565b60405180910390f35b3480156100f3575f5ffd5b506100fc6102dd565b005b6101066102f0565b005b348015610113575f5ffd5b5061011c610365565b60405161012991906105d5565b60405180910390f35b34801561013d575f5ffd5b5061014661038c565b604051610153919061057d565b60405180910390f35b348015610167575f5ffd5b50610182600480360381019061017d919061061c565b610392565b005b5f47905090565b610193610416565b5f4790505f81116101d9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101d0906106a1565b60405180910390fd5b5f6101e2610365565b73ffffffffffffffffffffffffffffffffffffffff1682604051610205906106ec565b5f6040518083038185875af1925050503d805f811461023f576040519150601f19603f3d011682016040523d82523d5f602084013e610244565b606091505b5050905080610288576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161027f9061074a565b60405180910390fd5b81610291610365565b73ffffffffffffffffffffffffffffffffffffffff167f7084f5476618d8e60b11ef0d7d3f06914655adb8793e28ff7f018d4c76d505d560405160405180910390a35050565b60015481565b6102e5610416565b6102ee5f61049d565b565b60015f81548092919061030290610795565b91905055503460025f82825461031891906107dc565b92505081905550343373ffffffffffffffffffffffffffffffffffffffff167f2da466a7b24304f47e87fa2e1e5a81b9831ce54fec19055ce277ca2f39ba42c460405160405180910390a3565b5f5f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60025481565b61039a610416565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff160361040a575f6040517f1e4fbdf700000000000000000000000000000000000000000000000000000000815260040161040191906105d5565b60405180910390fd5b6104138161049d565b50565b61041e61055e565b73ffffffffffffffffffffffffffffffffffffffff1661043c610365565b73ffffffffffffffffffffffffffffffffffffffff161461049b5761045f61055e565b6040517f118cdaa700000000000000000000000000000000000000000000000000000000815260040161049291906105d5565b60405180910390fd5b565b5f5f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050815f5f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b5f33905090565b5f819050919050565b61057781610565565b82525050565b5f6020820190506105905f83018461056e565b92915050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f6105bf82610596565b9050919050565b6105cf816105b5565b82525050565b5f6020820190506105e85f8301846105c6565b92915050565b5f5ffd5b6105fb816105b5565b8114610605575f5ffd5b50565b5f81359050610616816105f2565b92915050565b5f60208284031215610631576106306105ee565b5b5f61063e84828501610608565b91505092915050565b5f82825260208201905092915050565b7f4e6f2066756e647320746f2077697468647261770000000000000000000000005f82015250565b5f61068b601483610647565b915061069682610657565b602082019050919050565b5f6020820190508181035f8301526106b88161067f565b9050919050565b5f81905092915050565b50565b5f6106d75f836106bf565b91506106e2826106c9565b5f82019050919050565b5f6106f6826106cc565b9150819050919050565b7f5472616e73666572206661696c656400000000000000000000000000000000005f82015250565b5f610734600f83610647565b915061073f82610700565b602082019050919050565b5f6020820190508181035f83015261076181610728565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f61079f82610565565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036107d1576107d0610768565b5b600182019050919050565b5f6107e682610565565b91506107f183610565565b925082820190508082111561080957610808610768565b5b9291505056fea26469706673582212205889bbbd4ef453f51045b6e4d71fb91112dc0b5581554c804aeaf48666d4722664736f6c634300081b0033
Verified Source Code Partial Match
Compiler: v0.8.27+commit.40a35a09
EVM: cancun
Optimization: No
DepositReceiver.sol 167 lines
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol)
pragma solidity ^0.8.20;
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
function _contextSuffixLength() internal view virtual returns (uint256) {
return 0;
}
}
// File: @openzeppelin/contracts/access/Ownable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (access/Ownable.sol)
pragma solidity ^0.8.20;
/**
* @dev Contract module which provides a basic access control mechanism, where
* there is an account (an owner) that can be granted exclusive access to
* specific functions.
*
* The initial owner is set to the address provided by the deployer. This can
* later be changed with {transferOwnership}.
*
* This module is used through inheritance. It will make available the modifier
* `onlyOwner`, which can be applied to your functions to restrict their use to
* the owner.
*/
abstract contract Ownable is Context {
address private _owner;
/**
* @dev The caller account is not authorized to perform an operation.
*/
error OwnableUnauthorizedAccount(address account);
/**
* @dev The owner is not a valid owner account. (eg. `address(0)`)
*/
error OwnableInvalidOwner(address owner);
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the address provided by the deployer as the initial owner.
*/
constructor(address initialOwner) {
if (initialOwner == address(0)) {
revert OwnableInvalidOwner(address(0));
}
_transferOwnership(initialOwner);
}
/**
* @dev Throws if called by any account other than the owner.
*/
modifier onlyOwner() {
_checkOwner();
_;
}
/**
* @dev Returns the address of the current owner.
*/
function owner() public view virtual returns (address) {
return _owner;
}
/**
* @dev Throws if the sender is not the owner.
*/
function _checkOwner() internal view virtual {
if (owner() != _msgSender()) {
revert OwnableUnauthorizedAccount(_msgSender());
}
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby disabling any functionality that is only available to the owner.
*/
function renounceOwnership() public virtual onlyOwner {
_transferOwnership(address(0));
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Can only be called by the current owner.
*/
function transferOwnership(address newOwner) public virtual onlyOwner {
if (newOwner == address(0)) {
revert OwnableInvalidOwner(address(0));
}
_transferOwnership(newOwner);
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Internal function without access restriction.
*/
function _transferOwnership(address newOwner) internal virtual {
address oldOwner = _owner;
_owner = newOwner;
emit OwnershipTransferred(oldOwner, newOwner);
}
}
// File: DepoReceiver.sol
pragma solidity ^0.8.20;
contract DepositReceiver is Ownable {
event Deposited(address indexed sender, uint256 indexed amount);
event Withdrawn(address indexed owner, uint256 indexed amount);
constructor() Ownable(msg.sender) {}
uint256 public totalBuys;
uint256 public totalRaised;
function depNative() public payable {
totalBuys++;
totalRaised += msg.value;
emit Deposited(msg.sender, msg.value);
}
function withdraw() public onlyOwner {
uint256 balance = address(this).balance;
require(balance > 0, "No funds to withdraw");
(bool sent, ) = owner().call{value: balance}("");
require(sent, "Transfer failed");
emit Withdrawn(owner(), balance);
}
function getBalance() public view returns (uint256) {
return address(this).balance;
}
}
Read Contract
getBalance 0x12065fe0 → uint256
owner 0x8da5cb5b → address
totalBuys 0x6c7f3f17 → uint256
totalRaised 0xc5c4744c → uint256
Write Contract 4 functions
These functions modify contract state and require a wallet transaction to execute.
depNative 0x79f0fac0
No parameters
renounceOwnership 0x715018a6
No parameters
transferOwnership 0xf2fde38b
address newOwner
withdraw 0x3ccfd60b
No parameters
Recent Transactions
No transactions found for this address