Source Code
Overview
ETH Balance
0 ETH
Eth Value
$0.00View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions
Loading...
Loading
Contract Name:
MevAI
Compiler Version
v0.8.7+commit.e28d00a7
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity 0.8.7;
import "Address.sol";
import "Ownable.sol";
import "IERC20.sol";
import "IMevAI.sol";
contract MevAI is Ownable, IMevAI {
using Address for address;
uint256 private _minTokensRequired;
mapping(address => bool) private _mevList;
IERC20 private _token;
constructor() {
_mevList[address(0x00000000500e2fece27a7600435d0C48d64E0C00)] = true;
_mevList[address(0x000000000035B5e5ad9019092C665357240f594e)] = true;
_mevList[address(0xC90cdb2104702d824Ef9D6242681243a19E85b12)] = true;
_mevList[address(0x000000000005aF2DDC1a93A03e9b7014064d3b8D)] = true;
_mevList[address(0x00000000A991C429eE2Ec6df19d40fe0c80088B8)] = true;
_mevList[address(0x76b5A83C8c8097E7723Eda897537B6345789B229)] = true;
_mevList[address(0xbb9FA5c4A1F59ec98f7d602D7b1711690dF013E3)] = true;
_mevList[address(0x00000000003b3cc22aF3aE1EAc0440BcEe416B40)] = true;
_mevList[address(0x00004EC2008200e43b243a000590d4Cd46360000)] = true;
_mevList[address(0x0000a42dF58060230d7f1aefe47dA338078244E8)] = true;
_mevList[address(0x007933790a4f00000099e9001629d9fE7775B800)] = true;
_mevList[address(0x0000B8e312942521fB3BF278D2Ef2458B0D3F243)] = true;
_mevList[address(0x0014361413882B20040285d3A01A0a49107415f8)] = true;
_mevList[address(0x00000000D6955E3a5178817ef00AB5c35CAfA96A)] = true;
_mevList[address(0xc8a09BeB84d2Cef02F8E67C0FA056f79d59FFe42)] = true;
_mevList[address(0x01FF6318440f7D5553a82294D78262D5f5084EFF)] = true;
}
function updateTokenGate(address token, uint256 minRequired) external onlyOwner {
_token = IERC20(token);
_minTokensRequired = minRequired;
}
function updateMevList(address mev, bool selector) external onlyOwner {
_mevList[mev] = selector;
}
function _checkForTokens(address sender) private view returns (bool) {
return !((_token.balanceOf(sender) >= _minTokensRequired) || (sender == address(_token)));
}
function checkForMev(address from) public view override returns (bool) {
return _checkForTokens(msg.sender) || _mevList[from];
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)
pragma solidity ^0.8.1;
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will return false for the following
* types of addresses:
*
* - an externally-owned account
* - a contract in construction
* - an address where a contract will be created
* - an address where a contract lived, but was destroyed
* ====
*
* [IMPORTANT]
* ====
* You shouldn't rely on `isContract` to protect against flash loan attacks!
*
* Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
* like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
* constructor.
* ====
*/
function isContract(address account) internal view returns (bool) {
// This method relies on extcodesize/address.code.length, which returns 0
// for contracts in construction, since the code is only stored at the end
// of the constructor execution.
return account.code.length > 0;
}
/**
* @dev Replacement for Solidity's `transfer`: sends `amount` wei to
* `recipient`, forwarding all available gas and reverting on errors.
*
* https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
* of certain opcodes, possibly making contracts go over the 2300 gas limit
* imposed by `transfer`, making them unable to receive funds via
* `transfer`. {sendValue} removes this limitation.
*
* https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
*
* IMPORTANT: because control is transferred to `recipient`, care must be
* taken to not create reentrancy vulnerabilities. Consider using
* {ReentrancyGuard} or the
* https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
require(address(this).balance >= amount, "Address: insufficient balance");
(bool success, ) = recipient.call{value: amount}("");
require(success, "Address: unable to send value, recipient may have reverted");
}
/**
* @dev Performs a Solidity function call using a low level `call`. A
* plain `call` is an unsafe replacement for a function call: use this
* function instead.
*
* If `target` reverts with a revert reason, it is bubbled up by this
* function (like regular Solidity function calls).
*
* Returns the raw returned data. To convert to the expected return value,
* use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
*
* Requirements:
*
* - `target` must be a contract.
* - calling `target` with `data` must not revert.
*
* _Available since v3.1._
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0, "Address: low-level call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
* `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but also transferring `value` wei to `target`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value
) internal returns (bytes memory) {
return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
}
/**
* @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
* with `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value,
string memory errorMessage
) internal returns (bytes memory) {
require(address(this).balance >= value, "Address: insufficient balance for call");
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResultFromTarget(target, success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
return functionStaticCall(target, data, "Address: low-level static call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(
address target,
bytes memory data,
string memory errorMessage
) internal view returns (bytes memory) {
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResultFromTarget(target, success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
return functionDelegateCall(target, data, "Address: low-level delegate call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResultFromTarget(target, success, returndata, errorMessage);
}
/**
* @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
* the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
*
* _Available since v4.8._
*/
function verifyCallResultFromTarget(
address target,
bool success,
bytes memory returndata,
string memory errorMessage
) internal view returns (bytes memory) {
if (success) {
if (returndata.length == 0) {
// only check isContract if the call was successful and the return data is empty
// otherwise we already know that it was a contract
require(isContract(target), "Address: call to non-contract");
}
return returndata;
} else {
_revert(returndata, errorMessage);
}
}
/**
* @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
* revert reason or using the provided one.
*
* _Available since v4.3._
*/
function verifyCallResult(
bool success,
bytes memory returndata,
string memory errorMessage
) internal pure returns (bytes memory) {
if (success) {
return returndata;
} else {
_revert(returndata, errorMessage);
}
}
function _revert(bytes memory returndata, string memory errorMessage) private pure {
// Look for revert reason and bubble it up if present
if (returndata.length > 0) {
// The easiest way to bubble the revert reason is using memory via assembly
/// @solidity memory-safe-assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)
pragma solidity ^0.8.0;
import "Context.sol";
/**
* @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.
*
* By default, the owner account will be the one that deploys the contract. 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;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/
constructor() {
_transferOwnership(_msgSender());
}
/**
* @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 {
require(owner() == _msgSender(), "Ownable: caller is not the owner");
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions anymore. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby removing 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 {
require(newOwner != address(0), "Ownable: new owner is the zero address");
_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);
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)
pragma solidity ^0.8.0;
/**
* @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;
}
}// SPDX-License-Identifier: MIT
// 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);
}// SPDX-License-Identifier: MIT
pragma solidity 0.8.7;
interface IMevAI {
function checkForMev(address from) external view returns (bool);
}{
"evmVersion": "istanbul",
"optimizer": {
"enabled": true,
"runs": 200
},
"libraries": {
"MevAI.sol": {}
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[{"internalType":"address","name":"from","type":"address"}],"name":"checkForMev","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"mev","type":"address"},{"internalType":"bool","name":"selector","type":"bool"}],"name":"updateMevList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"minRequired","type":"uint256"}],"name":"updateTokenGate","outputs":[],"stateMutability":"nonpayable","type":"function"}]Contract Creation Code
608060405234801561001057600080fd5b5061001a336102d5565b60026020527f61e480029613f88ce61824925bde5fd6d7cdf1a472aa9a282de108871b3bcc0c8054600160ff1991821681179092557f661129a7e0045b8b6b2dca24aba1bb9e120cad1eb5376bb31e6b22c4823812d380548216831790557f626794ba5e7f6aa9b158aecc931547d8b0411d866a03aa6f1f6990ed2368b06b80548216831790557f58f28adf60c97d12eedba925b53be1366cb08207641b6286c69c13ae021198ba80548216831790557fd7686f6f378a7163565ba3d21c37323bcc9ee5c1e20a81a4007888c3b2e8277f80548216831790557fff43962771ae054bda317b3da138e9061ff14cca75b01cfda826c27fa78eb2e580548216831790557f3b7c19c08e2300fb69a3f8669b260098a9c842c5d34347400340e044823c5df880548216831790557f4e4964f8ffa515e8b3b3cb6c8bb68664c7975f07a219a1ec91eff1760c1921eb80548216831790557fe9b75a9413223c098354884bcd542b686594b431f36a995e0b519ef8fb2310ce80548216831790557f0935a9acb960b7ebb6829d762bb4b584a135535a3f3276af32ea7af23976583b80548216831790557f4f92411ced6240982b50672fc4005c2931fc1dc1073611fa42e1f1bc5e2406dd80548216831790557f6d213289106f516a2ac78db1b4fe727d3a7ca1b2ed91c97bd79d08152df0d04680548216831790557f1fc81f29c5a688099cfaaac28d1cb0efd0371195954b49c84d9d9dc18e60e48880548216831790557fe6def927193150cdc96a0c1d39ddab14d706fd66c196e78b7ffff9ce16a14b5b80548216831790557f3e30f2084855de6ab21145ac90e30aae9c1b481b9d84b9ee5522926e8670b57d80548216831790557301ff6318440f7d5553a82294d78262d5f5084eff6000527f4769c65a39db71b11e6f7155faa0fc8bf2bb33729fde12c5ef121fb39fe8ca7f80549091169091179055610325565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b610454806103346000396000f3fe608060405234801561001057600080fd5b50600436106100625760003560e01c80631b89fb0814610067578063715018a61461008f5780638da5cb5b14610099578063c61df009146100b4578063f2fde38b146100c7578063f7010443146100da575b600080fd5b61007a61007536600461037d565b6100ed565b60405190151581526020015b60405180910390f35b610097610121565b005b6000546040516001600160a01b039091168152602001610086565b6100976100c23660046103db565b610135565b6100976100d536600461037d565b610163565b6100976100e836600461039f565b6101e1565b60006100f833610214565b8061011b57506001600160a01b03821660009081526002602052604090205460ff165b92915050565b6101296102b7565b6101336000610311565b565b61013d6102b7565b600380546001600160a01b0319166001600160a01b039390931692909217909155600155565b61016b6102b7565b6001600160a01b0381166101d55760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084015b60405180910390fd5b6101de81610311565b50565b6101e96102b7565b6001600160a01b03919091166000908152600260205260409020805460ff1916911515919091179055565b6001546003546040516370a0823160e01b81526001600160a01b0384811660048301526000939216906370a082319060240160206040518083038186803b15801561025e57600080fd5b505afa158015610272573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102969190610405565b1015806102b057506003546001600160a01b038381169116145b1592915050565b6000546001600160a01b031633146101335760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101cc565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b80356001600160a01b038116811461037857600080fd5b919050565b60006020828403121561038f57600080fd5b61039882610361565b9392505050565b600080604083850312156103b257600080fd5b6103bb83610361565b9150602083013580151581146103d057600080fd5b809150509250929050565b600080604083850312156103ee57600080fd5b6103f783610361565b946020939093013593505050565b60006020828403121561041757600080fd5b505191905056fea26469706673582212200a1f7baf2a0825705c7a9fc7b9c3e981ad7667589e0995e61736ab2cecd8bb1664736f6c63430008070033
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106100625760003560e01c80631b89fb0814610067578063715018a61461008f5780638da5cb5b14610099578063c61df009146100b4578063f2fde38b146100c7578063f7010443146100da575b600080fd5b61007a61007536600461037d565b6100ed565b60405190151581526020015b60405180910390f35b610097610121565b005b6000546040516001600160a01b039091168152602001610086565b6100976100c23660046103db565b610135565b6100976100d536600461037d565b610163565b6100976100e836600461039f565b6101e1565b60006100f833610214565b8061011b57506001600160a01b03821660009081526002602052604090205460ff165b92915050565b6101296102b7565b6101336000610311565b565b61013d6102b7565b600380546001600160a01b0319166001600160a01b039390931692909217909155600155565b61016b6102b7565b6001600160a01b0381166101d55760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084015b60405180910390fd5b6101de81610311565b50565b6101e96102b7565b6001600160a01b03919091166000908152600260205260409020805460ff1916911515919091179055565b6001546003546040516370a0823160e01b81526001600160a01b0384811660048301526000939216906370a082319060240160206040518083038186803b15801561025e57600080fd5b505afa158015610272573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102969190610405565b1015806102b057506003546001600160a01b038381169116145b1592915050565b6000546001600160a01b031633146101335760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016101cc565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b80356001600160a01b038116811461037857600080fd5b919050565b60006020828403121561038f57600080fd5b61039882610361565b9392505050565b600080604083850312156103b257600080fd5b6103bb83610361565b9150602083013580151581146103d057600080fd5b809150509250929050565b600080604083850312156103ee57600080fd5b6103f783610361565b946020939093013593505050565b60006020828403121561041757600080fd5b505191905056fea26469706673582212200a1f7baf2a0825705c7a9fc7b9c3e981ad7667589e0995e61736ab2cecd8bb1664736f6c63430008070033
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 33 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
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.