编译器
0.8.17+commit.8df45f5f
文件 1 的 17:AccessControl.sol
pragma solidity ^0.8.0;
import "./Ownable.sol";
abstract contract AccessControl is Ownable {
mapping(bytes32 => mapping(address => bool)) private _permits;
event RoleGranted(bytes32 indexed role, address indexed grantee);
event RoleRevoked(bytes32 indexed role, address indexed revokee);
error NoPermit(bytes32 role);
constructor(address owner_) Ownable(owner_) {}
modifier onlyRole(bytes32 role) {
if (!_permits[role][msg.sender]) revert NoPermit(role);
_;
}
function _checkRole(bytes32 role_, address address_) internal virtual {
if (!_hasRole(role_, address_)) revert NoPermit(role_);
}
function grantRole(
bytes32 role_,
address grantee_
) external virtual onlyOwner {
_grantRole(role_, grantee_);
}
function revokeRole(
bytes32 role_,
address revokee_
) external virtual onlyOwner {
_revokeRole(role_, revokee_);
}
function _grantRole(bytes32 role_, address grantee_) internal {
_permits[role_][grantee_] = true;
emit RoleGranted(role_, grantee_);
}
function _revokeRole(bytes32 role_, address revokee_) internal {
_permits[role_][revokee_] = false;
emit RoleRevoked(role_, revokee_);
}
function hasRole(
bytes32 role_,
address address_
) external view returns (bool) {
return _hasRole(role_, address_);
}
function _hasRole(
bytes32 role_,
address address_
) internal view returns (bool) {
return _permits[role_][address_];
}
}
文件 2 的 17:Base.sol
pragma solidity ^0.8.0;
import "solmate/src/utils/ReentrancyGuard.sol";
import {RescueFundsLib} from "../libraries/RescueFundsLib.sol";
import {Gauge} from "../common/Gauge.sol";
import {AccessControl} from "../common/AccessControl.sol";
import "./ISuperTokenOrVault.sol";
import "./IMessageBridge.sol";
import "./ExecutionHelper.sol";
abstract contract Base is
ReentrancyGuard,
Gauge,
ISuperTokenOrVault,
AccessControl
{
struct PendingExecutionDetails {
bool isAmountPending;
uint32 siblingChainSlug;
address receiver;
bytes payload;
}
ExecutionHelper public executionHelper__;
mapping(bytes32 => PendingExecutionDetails) public pendingExecutions;
error InvalidExecutionRetry();
error PendingAmount();
error CannotExecuteOnBridgeContracts();
event ExecutionHelperUpdated(address executionHelper);
function updateExecutionHelper(
address executionHelper_
) external onlyOwner {
executionHelper__ = ExecutionHelper(executionHelper_);
emit ExecutionHelperUpdated(executionHelper_);
}
function retryPayloadExecution(bytes32 msgId_) external nonReentrant {
PendingExecutionDetails storage details = pendingExecutions[msgId_];
if (details.isAmountPending) revert PendingAmount();
if (details.receiver == address(0)) revert InvalidExecutionRetry();
bool success = executionHelper__.execute(
details.receiver,
details.payload
);
if (success) _clearPayload(msgId_);
}
function _cachePayload(
bytes32 msgId_,
bool isAmountPending_,
uint32 siblingChainSlug_,
address receiver_,
bytes memory payload_
) internal {
pendingExecutions[msgId_].receiver = receiver_;
pendingExecutions[msgId_].payload = payload_;
pendingExecutions[msgId_].siblingChainSlug = siblingChainSlug_;
pendingExecutions[msgId_].isAmountPending = isAmountPending_;
}
function _clearPayload(bytes32 msgId_) internal {
pendingExecutions[msgId_].receiver = address(0);
pendingExecutions[msgId_].payload = bytes("");
pendingExecutions[msgId_].siblingChainSlug = 0;
pendingExecutions[msgId_].isAmountPending = false;
}
}
文件 3 的 17:Context.sol
pragma solidity ^0.8.0;
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}
文件 4 的 17:ERC20.sol
pragma solidity >=0.8.0;
abstract contract ERC20 {
event Transfer(address indexed from, address indexed to, uint256 amount);
event Approval(address indexed owner, address indexed spender, uint256 amount);
string public name;
string public symbol;
uint8 public immutable decimals;
uint256 public totalSupply;
mapping(address => uint256) public balanceOf;
mapping(address => mapping(address => uint256)) public allowance;
uint256 internal immutable INITIAL_CHAIN_ID;
bytes32 internal immutable INITIAL_DOMAIN_SEPARATOR;
mapping(address => uint256) public nonces;
constructor(
string memory _name,
string memory _symbol,
uint8 _decimals
) {
name = _name;
symbol = _symbol;
decimals = _decimals;
INITIAL_CHAIN_ID = block.chainid;
INITIAL_DOMAIN_SEPARATOR = computeDomainSeparator();
}
function approve(address spender, uint256 amount) public virtual returns (bool) {
allowance[msg.sender][spender] = amount;
emit Approval(msg.sender, spender, amount);
return true;
}
function transfer(address to, uint256 amount) public virtual returns (bool) {
balanceOf[msg.sender] -= amount;
unchecked {
balanceOf[to] += amount;
}
emit Transfer(msg.sender, to, amount);
return true;
}
function transferFrom(
address from,
address to,
uint256 amount
) public virtual returns (bool) {
uint256 allowed = allowance[from][msg.sender];
if (allowed != type(uint256).max) allowance[from][msg.sender] = allowed - amount;
balanceOf[from] -= amount;
unchecked {
balanceOf[to] += amount;
}
emit Transfer(from, to, amount);
return true;
}
function permit(
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) public virtual {
require(deadline >= block.timestamp, "PERMIT_DEADLINE_EXPIRED");
unchecked {
address recoveredAddress = ecrecover(
keccak256(
abi.encodePacked(
"\x19\x01",
DOMAIN_SEPARATOR(),
keccak256(
abi.encode(
keccak256(
"Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"
),
owner,
spender,
value,
nonces[owner]++,
deadline
)
)
)
),
v,
r,
s
);
require(recoveredAddress != address(0) && recoveredAddress == owner, "INVALID_SIGNER");
allowance[recoveredAddress][spender] = value;
}
emit Approval(owner, spender, value);
}
function DOMAIN_SEPARATOR() public view virtual returns (bytes32) {
return block.chainid == INITIAL_CHAIN_ID ? INITIAL_DOMAIN_SEPARATOR : computeDomainSeparator();
}
function computeDomainSeparator() internal view virtual returns (bytes32) {
return
keccak256(
abi.encode(
keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"),
keccak256(bytes(name)),
keccak256("1"),
block.chainid,
address(this)
)
);
}
function _mint(address to, uint256 amount) internal virtual {
totalSupply += amount;
unchecked {
balanceOf[to] += amount;
}
emit Transfer(address(0), to, amount);
}
function _burn(address from, uint256 amount) internal virtual {
balanceOf[from] -= amount;
unchecked {
totalSupply -= amount;
}
emit Transfer(from, address(0), amount);
}
}
文件 5 的 17:ExcessivelySafeCall.sol
pragma solidity ^0.8.0;
library ExcessivelySafeCall {
uint constant LOW_28_MASK =
0x00000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff;
function excessivelySafeCall(
address _target,
uint _gas,
uint16 _maxCopy,
bytes memory _calldata
) internal returns (bool, bytes memory) {
uint _toCopy;
bool _success;
bytes memory _returnData = new bytes(_maxCopy);
assembly {
_success := call(
_gas,
_target,
0,
add(_calldata, 0x20),
mload(_calldata),
0,
0
)
_toCopy := returndatasize()
if gt(_toCopy, _maxCopy) {
_toCopy := _maxCopy
}
mstore(_returnData, _toCopy)
returndatacopy(add(_returnData, 0x20), 0, _toCopy)
}
return (_success, _returnData);
}
function excessivelySafeStaticCall(
address _target,
uint _gas,
uint16 _maxCopy,
bytes memory _calldata
) internal view returns (bool, bytes memory) {
uint _toCopy;
bool _success;
bytes memory _returnData = new bytes(_maxCopy);
assembly {
_success := staticcall(
_gas,
_target,
add(_calldata, 0x20),
mload(_calldata),
0,
0
)
_toCopy := returndatasize()
if gt(_toCopy, _maxCopy) {
_toCopy := _maxCopy
}
mstore(_returnData, _toCopy)
returndatacopy(add(_returnData, 0x20), 0, _toCopy)
}
return (_success, _returnData);
}
function swapSelector(
bytes4 _newSelector,
bytes memory _buf
) internal pure {
require(_buf.length >= 4);
uint _mask = LOW_28_MASK;
assembly {
let _word := mload(add(_buf, 0x20))
_word := and(_word, _mask)
_word := or(_newSelector, _word)
mstore(add(_buf, 0x20), _word)
}
}
}
文件 6 的 17:ExecutionHelper.sol
pragma solidity ^0.8.0;
import "../libraries/ExcessivelySafeCall.sol";
contract ExecutionHelper {
using ExcessivelySafeCall for address;
uint16 private constant MAX_COPY_BYTES = 0;
function execute(
address target_,
bytes memory payload_
) external returns (bool success) {
if (target_ == address(this)) return false;
(success, ) = target_.excessivelySafeCall(
gasleft(),
MAX_COPY_BYTES,
payload_
);
}
}
文件 7 的 17:Gauge.sol
pragma solidity ^0.8.0;
abstract contract Gauge {
struct LimitParams {
uint256 lastUpdateTimestamp;
uint256 ratePerSecond;
uint256 maxLimit;
uint256 lastUpdateLimit;
}
error AmountOutsideLimit();
function _getCurrentLimit(
LimitParams storage _params
) internal view returns (uint256 _limit) {
uint256 timeElapsed = block.timestamp - _params.lastUpdateTimestamp;
uint256 limitIncrease = timeElapsed * _params.ratePerSecond;
if (limitIncrease + _params.lastUpdateLimit > _params.maxLimit) {
_limit = _params.maxLimit;
} else {
_limit = limitIncrease + _params.lastUpdateLimit;
}
}
function _consumePartLimit(
uint256 amount_,
LimitParams storage _params
) internal returns (uint256 consumedAmount, uint256 pendingAmount) {
uint256 currentLimit = _getCurrentLimit(_params);
_params.lastUpdateTimestamp = block.timestamp;
if (currentLimit >= amount_) {
_params.lastUpdateLimit = currentLimit - amount_;
consumedAmount = amount_;
pendingAmount = 0;
} else {
_params.lastUpdateLimit = 0;
consumedAmount = currentLimit;
pendingAmount = amount_ - currentLimit;
}
}
function _consumeFullLimit(
uint256 amount_,
LimitParams storage _params
) internal {
uint256 currentLimit = _getCurrentLimit(_params);
if (currentLimit >= amount_) {
_params.lastUpdateTimestamp = block.timestamp;
_params.lastUpdateLimit = currentLimit - amount_;
} else {
revert AmountOutsideLimit();
}
}
}
文件 8 的 17:IERC20.sol
pragma solidity ^0.8.0;
interface IERC20 {
event Transfer(address indexed from, address indexed to, uint256 value);
event Approval(address indexed owner, address indexed spender, uint256 value);
function totalSupply() external view returns (uint256);
function balanceOf(address account) external view returns (uint256);
function transfer(address to, uint256 amount) external returns (bool);
function allowance(address owner, address spender) external view returns (uint256);
function approve(address spender, uint256 amount) external returns (bool);
function transferFrom(
address from,
address to,
uint256 amount
) external returns (bool);
}
文件 9 的 17:IERC20Metadata.sol
pragma solidity ^0.8.0;
import "../IERC20.sol";
interface IERC20Metadata is IERC20 {
function name() external view returns (string memory);
function symbol() external view returns (string memory);
function decimals() external view returns (uint8);
}
文件 10 的 17:IMessageBridge.sol
pragma solidity ^0.8.0;
interface IMessageBridge {
function outbound(
uint32 siblingChainSlug_,
uint256 msgGasLimit_,
bytes memory payload_,
bytes memory options_
) external payable returns (bytes32 messageId_);
function getMessageId(
uint32 siblingChainSlug_
) external view returns (bytes32);
}
文件 11 的 17:ISuperTokenOrVault.sol
pragma solidity ^0.8.0;
interface ISuperTokenOrVault {
function inbound(
uint32 siblingChainSlug_,
bytes memory payload_
) external payable;
}
文件 12 的 17:OseanV2.sol
pragma solidity ^0.8.0;
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "./supertoken/Base.sol";
import "./interfaces/Uniswap.sol";
contract Osean is ERC20, Base {
struct UpdateLimitParams {
bool isMint;
uint32 siblingChainSlug;
uint256 maxLimit;
uint256 ratePerSecond;
}
bytes32 constant RESCUE_ROLE = keccak256("RESCUE_ROLE");
bytes32 constant LIMIT_UPDATER_ROLE = keccak256("LIMIT_UPDATER_ROLE");
IMessageBridge public bridge__;
mapping(uint32 => LimitParams) _receivingLimitParams;
mapping(uint32 => LimitParams) _sendingLimitParams;
mapping(uint32 => mapping(address => mapping(bytes32 => uint256)))
public pendingMints;
mapping(uint32 => uint256) public siblingPendingMints;
error SiblingNotSupported();
error MessageIdMisMatched();
error ZeroAmount();
error NotMessageBridge();
error InvalidReceiver();
error InvalidSiblingChainSlug();
event LimitParamsUpdated(UpdateLimitParams[] updates);
event MessageBridgeUpdated(address newBridge);
event BridgeTokens(
uint32 siblingChainSlug,
address withdrawer,
address receiver,
uint256 bridgedAmount,
bytes32 identifier
);
event PendingTokensBridged(
uint32 siblingChainSlug,
address receiver,
uint256 mintAmount,
uint256 pendingAmount,
bytes32 identifier
);
event TokensPending(
uint32 siblingChainSlug,
address receiver,
uint256 pendingAmount,
uint256 totalPendingAmount,
bytes32 identifier
);
event TokensBridged(
uint32 siblingChainSlug,
address receiver,
uint256 mintAmount,
uint256 totalAmount,
bytes32 identifier
);
mapping (address => bool) public excludedFromFees;
address payable public oseanWalletAddress;
address payable public marketingWalletAddress;
address payable public developerWalletAddress;
address public liquidityWalletAddress;
address payable public tobeburntWalletAddress;
address public airDropWalletAddress;
address public uniswapRouterAddress;
uint256 public initialTimeStamp;
uint256 public yachtTransactionFeePercent = 1;
uint256 public developerFeePercent = 1;
uint256 public marketingFeePercent = 1;
uint256 public burnFeePercent = 1;
IUniswapV2Router02 private uniswapRouter;
address public uniswapPair;
constructor(
uint256 initialSupply,
address owner_,
address bridge_,
address payable _oseanWalletAddress,
address payable _marketingWalletAddress,
address payable _developerWalletAddress,
address _liquidityWalletAddress,
address payable _tobeburntWalletAddress,
address _airDropWalletAddress,
address _uniswapRouterAddress,
address executionHelper_
) ERC20("Osean", "OSEAN") AccessControl(owner_) {
bridge__ = IMessageBridge(bridge_);
executionHelper__ = ExecutionHelper(executionHelper_);
initialTimeStamp = block.timestamp;
oseanWalletAddress = _oseanWalletAddress;
marketingWalletAddress = _marketingWalletAddress;
developerWalletAddress = _developerWalletAddress;
liquidityWalletAddress = _liquidityWalletAddress;
tobeburntWalletAddress = _tobeburntWalletAddress;
airDropWalletAddress = _airDropWalletAddress;
uniswapRouterAddress = _uniswapRouterAddress;
excludedFromFees[oseanWalletAddress] = true;
excludedFromFees[marketingWalletAddress] = true;
excludedFromFees[developerWalletAddress] = true;
excludedFromFees[liquidityWalletAddress] = true;
excludedFromFees[tobeburntWalletAddress] = true;
excludedFromFees[airDropWalletAddress] = true;
_mint(marketingWalletAddress, (initialSupply) * 5 / 100);
_mint(developerWalletAddress, (initialSupply) * 10 / 100);
_mint(liquidityWalletAddress, (initialSupply) * 75 / 100);
_mint(airDropWalletAddress, (initialSupply) * 10 / 100);
IUniswapV2Router02 _uniswapV2Router = IUniswapV2Router02(uniswapRouterAddress);
uniswapRouter = _uniswapV2Router;
_approve(address(this), address(uniswapRouter), initialSupply);
uniswapPair = IUniswapV2Factory(_uniswapV2Router.factory()).createPair(address(this), _uniswapV2Router.WETH());
IERC20(uniswapPair).approve(address(uniswapRouter), type(uint256).max);
}
function updateMessageBridge(address bridge_) external onlyOwner {
bridge__ = IMessageBridge(bridge_);
emit MessageBridgeUpdated(bridge_);
}
function updateLimitParams(
UpdateLimitParams[] calldata updates_
) external onlyRole(LIMIT_UPDATER_ROLE) {
for (uint256 i; i < updates_.length; i++) {
if (updates_[i].isMint) {
_consumePartLimit(
0,
_receivingLimitParams[updates_[i].siblingChainSlug]
);
_receivingLimitParams[updates_[i].siblingChainSlug]
.maxLimit = updates_[i].maxLimit;
_receivingLimitParams[updates_[i].siblingChainSlug]
.ratePerSecond = updates_[i].ratePerSecond;
} else {
_consumePartLimit(
0,
_sendingLimitParams[updates_[i].siblingChainSlug]
);
_sendingLimitParams[updates_[i].siblingChainSlug]
.maxLimit = updates_[i].maxLimit;
_sendingLimitParams[updates_[i].siblingChainSlug]
.ratePerSecond = updates_[i].ratePerSecond;
}
}
emit LimitParamsUpdated(updates_);
}
function bridge(
address receiver_,
uint32 siblingChainSlug_,
uint256 sendingAmount_,
uint256 msgGasLimit_,
bytes calldata payload_,
bytes calldata options_
) external payable {
if (_sendingLimitParams[siblingChainSlug_].maxLimit == 0)
revert SiblingNotSupported();
if (sendingAmount_ == 0) revert ZeroAmount();
_consumeFullLimit(
sendingAmount_,
_sendingLimitParams[siblingChainSlug_]
);
_burn(msg.sender, sendingAmount_);
bytes32 messageId = bridge__.getMessageId(siblingChainSlug_);
bytes32 returnedMessageId = bridge__.outbound{value: msg.value}(
siblingChainSlug_,
msgGasLimit_,
abi.encode(receiver_, sendingAmount_, messageId, payload_),
options_
);
if (returnedMessageId != messageId) revert MessageIdMisMatched();
emit BridgeTokens(
siblingChainSlug_,
msg.sender,
receiver_,
sendingAmount_,
messageId
);
}
function mintPendingFor(
address receiver_,
uint32 siblingChainSlug_,
bytes32 identifier_
) external nonReentrant {
if (_receivingLimitParams[siblingChainSlug_].maxLimit == 0)
revert SiblingNotSupported();
uint256 pendingMint = pendingMints[siblingChainSlug_][receiver_][
identifier_
];
(uint256 consumedAmount, uint256 pendingAmount) = _consumePartLimit(
pendingMint,
_receivingLimitParams[siblingChainSlug_]
);
pendingMints[siblingChainSlug_][receiver_][identifier_] = pendingAmount;
siblingPendingMints[siblingChainSlug_] -= consumedAmount;
_mint(receiver_, consumedAmount);
address receiver = pendingExecutions[identifier_].receiver;
if (pendingAmount == 0 && receiver != address(0)) {
if (receiver_ != receiver) revert InvalidReceiver();
uint32 siblingChainSlug = pendingExecutions[identifier_]
.siblingChainSlug;
if (siblingChainSlug != siblingChainSlug_)
revert InvalidSiblingChainSlug();
pendingExecutions[identifier_].isAmountPending = false;
bool success = executionHelper__.execute(
receiver_,
pendingExecutions[identifier_].payload
);
if (success) _clearPayload(identifier_);
}
emit PendingTokensBridged(
siblingChainSlug_,
receiver_,
consumedAmount,
pendingAmount,
identifier_
);
}
function inbound(
uint32 siblingChainSlug_,
bytes memory payload_
) external payable override nonReentrant {
if (msg.sender != address(bridge__)) revert NotMessageBridge();
if (_receivingLimitParams[siblingChainSlug_].maxLimit == 0)
revert SiblingNotSupported();
(
address receiver,
uint256 mintAmount,
bytes32 identifier,
bytes memory execPayload
) = abi.decode(payload_, (address, uint256, bytes32, bytes));
(uint256 consumedAmount, uint256 pendingAmount) = _consumePartLimit(
mintAmount,
_receivingLimitParams[siblingChainSlug_]
);
if (receiver == address(this) || receiver == address(bridge__))
revert CannotExecuteOnBridgeContracts();
_mint(receiver, consumedAmount);
if (pendingAmount > 0) {
pendingMints[siblingChainSlug_][receiver][
identifier
] = pendingAmount;
siblingPendingMints[siblingChainSlug_] += pendingAmount;
if (execPayload.length > 0)
_cachePayload(
identifier,
true,
siblingChainSlug_,
receiver,
execPayload
);
emit TokensPending(
siblingChainSlug_,
receiver,
pendingAmount,
pendingMints[siblingChainSlug_][receiver][identifier],
identifier
);
} else if (execPayload.length > 0) {
bool success = executionHelper__.execute(receiver, execPayload);
if (!success)
_cachePayload(
identifier,
false,
siblingChainSlug_,
receiver,
execPayload
);
}
emit TokensBridged(
siblingChainSlug_,
receiver,
consumedAmount,
mintAmount,
identifier
);
}
function getCurrentReceivingLimit(
uint32 siblingChainSlug_
) external view returns (uint256) {
return _getCurrentLimit(_receivingLimitParams[siblingChainSlug_]);
}
function getCurrentSendingLimit(
uint32 siblingChainSlug_
) external view returns (uint256) {
return _getCurrentLimit(_sendingLimitParams[siblingChainSlug_]);
}
function getReceivingLimitParams(
uint32 siblingChainSlug_
) external view returns (LimitParams memory) {
return _receivingLimitParams[siblingChainSlug_];
}
function getSendingLimitParams(
uint32 siblingChainSlug_
) external view returns (LimitParams memory) {
return _sendingLimitParams[siblingChainSlug_];
}
function rescueFunds(
address token_,
address rescueTo_,
uint256 amount_
) external onlyRole(RESCUE_ROLE) {
RescueFundsLib.rescueFunds(token_, rescueTo_, amount_);
}
function getContractAddress() public view returns (address){
return address(this);
}
function excludeUserFromFees(address user) public onlyOwner {
excludedFromFees[user] = true;
}
function getCurrentTimestamp() public view returns (uint256) {
return block.timestamp;
}
function includeUsersInFees(address user) public onlyOwner {
excludedFromFees[user] = false;
}
function _transfer(address sender, address recipient, uint256 amount) internal virtual override {
if (sender != uniswapPair && recipient != uniswapPair && !excludedFromFees[sender] && !excludedFromFees[recipient]) {
require((balanceOf(recipient) + amount) < (totalSupply() / 75), "You can't have more than 1% of the total supply.");
}
if((sender == uniswapPair || recipient == uniswapPair) && !excludedFromFees[sender] && !excludedFromFees[recipient]) {
if(sender == uniswapPair && !excludedFromFees[sender] && !excludedFromFees[recipient]) {
require((balanceOf(recipient) + amount) < (totalSupply() / 75), "You can't have more than 1% of the total supply.");
}
uint256 yachtFee = (amount * yachtTransactionFeePercent) / 100;
uint256 marketingFee = (amount * marketingFeePercent) / 100;
uint256 developerFee = (amount * developerFeePercent) / 100;
uint256 burnFee = (amount * burnFeePercent) / 100;
uint256 totalFee = yachtFee + marketingFee + developerFee + burnFee;
super._transfer(sender, address(this), totalFee);
amount -= totalFee;
}
super._transfer(sender, recipient, amount);
}
function swapOSEANForETH(uint256 amount) private {
address[] memory path = new address[](2);
path[0] = address(this);
path[1] = uniswapRouter.WETH();
_approve(address(this), address(uniswapRouter), amount);
uniswapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens(
amount,
0,
path,
address(this),
block.timestamp
);
}
function sendFeesToWallets(uint256 amount) private {
uint256 totalFee = yachtTransactionFeePercent + marketingFeePercent + developerFeePercent + burnFeePercent;
oseanWalletAddress.transfer((amount * yachtTransactionFeePercent) / totalFee);
marketingWalletAddress.transfer((amount * marketingFeePercent) / totalFee);
developerWalletAddress.transfer((amount * developerFeePercent) / totalFee);
tobeburntWalletAddress.transfer((amount * burnFeePercent) / totalFee);
}
function swapFeesManually() public onlyOwner {
uint256 contractOSEANBalance = balanceOf(address(this));
if (contractOSEANBalance > 0) {
swapOSEANForETH(contractOSEANBalance);
}
}
function disperseFeesManually() public onlyOwner {
uint256 contractETHBalance = address(this).balance;
sendFeesToWallets(contractETHBalance);
}
receive() external payable {}
}
文件 13 的 17:Ownable.sol
pragma solidity ^0.8.0;
abstract contract Ownable {
address private _owner;
address private _nominee;
event OwnerNominated(address indexed nominee);
event OwnerClaimed(address indexed claimer);
error OnlyOwner();
error OnlyNominee();
constructor(address owner_) {
_claimOwner(owner_);
}
modifier onlyOwner() {
if (msg.sender != _owner) revert OnlyOwner();
_;
}
function owner() external view returns (address) {
return _owner;
}
function nominee() external view returns (address) {
return _nominee;
}
function nominateOwner(address nominee_) external {
if (msg.sender != _owner) revert OnlyOwner();
_nominee = nominee_;
emit OwnerNominated(_nominee);
}
function claimOwner() external {
if (msg.sender != _nominee) revert OnlyNominee();
_claimOwner(msg.sender);
}
function _claimOwner(address claimer_) internal {
_owner = claimer_;
_nominee = address(0);
emit OwnerClaimed(claimer_);
}
}
文件 14 的 17:ReentrancyGuard.sol
pragma solidity >=0.8.0;
abstract contract ReentrancyGuard {
uint256 private locked = 1;
modifier nonReentrant() virtual {
require(locked == 1, "REENTRANCY");
locked = 2;
_;
locked = 1;
}
}
文件 15 的 17:RescueFundsLib.sol
pragma solidity ^0.8.0;
import "solmate/src/utils/SafeTransferLib.sol";
error ZeroAddress();
library RescueFundsLib {
address public constant ETH_ADDRESS =
address(0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE);
error InvalidTokenAddress();
function rescueFunds(
address token_,
address rescueTo_,
uint256 amount_
) internal {
if (rescueTo_ == address(0)) revert ZeroAddress();
if (token_ == ETH_ADDRESS) {
SafeTransferLib.safeTransferETH(rescueTo_, amount_);
} else {
if (token_.code.length == 0) revert InvalidTokenAddress();
SafeTransferLib.safeTransfer(ERC20(token_), rescueTo_, amount_);
}
}
}
文件 16 的 17:SafeTransferLib.sol
pragma solidity >=0.8.0;
import {ERC20} from "../tokens/ERC20.sol";
library SafeTransferLib {
function safeTransferETH(address to, uint256 amount) internal {
bool success;
assembly {
success := call(gas(), to, amount, 0, 0, 0, 0)
}
require(success, "ETH_TRANSFER_FAILED");
}
function safeTransferFrom(
ERC20 token,
address from,
address to,
uint256 amount
) internal {
bool success;
assembly {
let freeMemoryPointer := mload(0x40)
mstore(freeMemoryPointer, 0x23b872dd00000000000000000000000000000000000000000000000000000000)
mstore(add(freeMemoryPointer, 4), and(from, 0xffffffffffffffffffffffffffffffffffffffff))
mstore(add(freeMemoryPointer, 36), and(to, 0xffffffffffffffffffffffffffffffffffffffff))
mstore(add(freeMemoryPointer, 68), amount)
success := and(
or(and(eq(mload(0), 1), gt(returndatasize(), 31)), iszero(returndatasize())),
call(gas(), token, 0, freeMemoryPointer, 100, 0, 32)
)
}
require(success, "TRANSFER_FROM_FAILED");
}
function safeTransfer(
ERC20 token,
address to,
uint256 amount
) internal {
bool success;
assembly {
let freeMemoryPointer := mload(0x40)
mstore(freeMemoryPointer, 0xa9059cbb00000000000000000000000000000000000000000000000000000000)
mstore(add(freeMemoryPointer, 4), and(to, 0xffffffffffffffffffffffffffffffffffffffff))
mstore(add(freeMemoryPointer, 36), amount)
success := and(
or(and(eq(mload(0), 1), gt(returndatasize(), 31)), iszero(returndatasize())),
call(gas(), token, 0, freeMemoryPointer, 68, 0, 32)
)
}
require(success, "TRANSFER_FAILED");
}
function safeApprove(
ERC20 token,
address to,
uint256 amount
) internal {
bool success;
assembly {
let freeMemoryPointer := mload(0x40)
mstore(freeMemoryPointer, 0x095ea7b300000000000000000000000000000000000000000000000000000000)
mstore(add(freeMemoryPointer, 4), and(to, 0xffffffffffffffffffffffffffffffffffffffff))
mstore(add(freeMemoryPointer, 36), amount)
success := and(
or(and(eq(mload(0), 1), gt(returndatasize(), 31)), iszero(returndatasize())),
call(gas(), token, 0, freeMemoryPointer, 68, 0, 32)
)
}
require(success, "APPROVE_FAILED");
}
}
文件 17 的 17:Uniswap.sol
pragma solidity >=0.8.0 <0.9.0;
interface IUniswapV2Factory {
function createPair(address tokenA, address tokenB) external returns (address pair);
}
interface IUniswapV2Pair {
function sync() external;
}
interface IUniswapV2Router01 {
function factory() external pure returns (address);
function WETH() external pure returns (address);
function addLiquidity(
address tokenA,
address tokenB,
uint256 amountADesired,
uint256 amountBDesired,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline
)
external
returns (
uint256 amountA,
uint256 amountB,
uint256 liquidity
);
function addLiquidityETH(
address token,
uint256 amountTokenDesired,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
)
external
payable
returns (
uint256 amountToken,
uint256 amountETH,
uint256 liquidity
);
}
interface IUniswapV2Router02 is IUniswapV2Router01 {
function removeLiquidityETHSupportingFeeOnTransferTokens(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
) external returns (uint256 amountETH);
function swapExactTokensForETHSupportingFeeOnTransferTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external;
function swapExactTokensForTokensSupportingFeeOnTransferTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external;
function swapExactETHForTokensSupportingFeeOnTransferTokens(
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external payable;
function swapExactETHForTokens(
uint amountOutMin,
address[] calldata path,
address to,
uint deadline
) external payable;
}
{
"compilationTarget": {
"contracts/OseanV2.sol": "Osean"
},
"evmVersion": "london",
"libraries": {},
"metadata": {
"bytecodeHash": "ipfs"
},
"optimizer": {
"enabled": true,
"runs": 200
},
"remappings": []
}
[{"inputs":[{"internalType":"uint256","name":"initialSupply","type":"uint256"},{"internalType":"address","name":"owner_","type":"address"},{"internalType":"address","name":"bridge_","type":"address"},{"internalType":"address payable","name":"_oseanWalletAddress","type":"address"},{"internalType":"address payable","name":"_marketingWalletAddress","type":"address"},{"internalType":"address payable","name":"_developerWalletAddress","type":"address"},{"internalType":"address","name":"_liquidityWalletAddress","type":"address"},{"internalType":"address payable","name":"_tobeburntWalletAddress","type":"address"},{"internalType":"address","name":"_airDropWalletAddress","type":"address"},{"internalType":"address","name":"_uniswapRouterAddress","type":"address"},{"internalType":"address","name":"executionHelper_","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AmountOutsideLimit","type":"error"},{"inputs":[],"name":"CannotExecuteOnBridgeContracts","type":"error"},{"inputs":[],"name":"InvalidExecutionRetry","type":"error"},{"inputs":[],"name":"InvalidReceiver","type":"error"},{"inputs":[],"name":"InvalidSiblingChainSlug","type":"error"},{"inputs":[],"name":"InvalidTokenAddress","type":"error"},{"inputs":[],"name":"MessageIdMisMatched","type":"error"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"NoPermit","type":"error"},{"inputs":[],"name":"NotMessageBridge","type":"error"},{"inputs":[],"name":"OnlyNominee","type":"error"},{"inputs":[],"name":"OnlyOwner","type":"error"},{"inputs":[],"name":"PendingAmount","type":"error"},{"inputs":[],"name":"SiblingNotSupported","type":"error"},{"inputs":[],"name":"ZeroAddress","type":"error"},{"inputs":[],"name":"ZeroAmount","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"siblingChainSlug","type":"uint32"},{"indexed":false,"internalType":"address","name":"withdrawer","type":"address"},{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"bridgedAmount","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"identifier","type":"bytes32"}],"name":"BridgeTokens","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"executionHelper","type":"address"}],"name":"ExecutionHelperUpdated","type":"event"},{"anonymous":false,"inputs":[{"components":[{"internalType":"bool","name":"isMint","type":"bool"},{"internalType":"uint32","name":"siblingChainSlug","type":"uint32"},{"internalType":"uint256","name":"maxLimit","type":"uint256"},{"internalType":"uint256","name":"ratePerSecond","type":"uint256"}],"indexed":false,"internalType":"struct Osean.UpdateLimitParams[]","name":"updates","type":"tuple[]"}],"name":"LimitParamsUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newBridge","type":"address"}],"name":"MessageBridgeUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"claimer","type":"address"}],"name":"OwnerClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"nominee","type":"address"}],"name":"OwnerNominated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"siblingChainSlug","type":"uint32"},{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"mintAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"pendingAmount","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"identifier","type":"bytes32"}],"name":"PendingTokensBridged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"grantee","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"revokee","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"siblingChainSlug","type":"uint32"},{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"mintAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalAmount","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"identifier","type":"bytes32"}],"name":"TokensBridged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"siblingChainSlug","type":"uint32"},{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"pendingAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalPendingAmount","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"identifier","type":"bytes32"}],"name":"TokensPending","type":"event"},{"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":"airDropWalletAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver_","type":"address"},{"internalType":"uint32","name":"siblingChainSlug_","type":"uint32"},{"internalType":"uint256","name":"sendingAmount_","type":"uint256"},{"internalType":"uint256","name":"msgGasLimit_","type":"uint256"},{"internalType":"bytes","name":"payload_","type":"bytes"},{"internalType":"bytes","name":"options_","type":"bytes"}],"name":"bridge","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"bridge__","outputs":[{"internalType":"contract IMessageBridge","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"burnFeePercent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"developerFeePercent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"developerWalletAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"disperseFeesManually","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"excludeUserFromFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"excludedFromFees","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"executionHelper__","outputs":[{"internalType":"contract ExecutionHelper","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getContractAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"siblingChainSlug_","type":"uint32"}],"name":"getCurrentReceivingLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"siblingChainSlug_","type":"uint32"}],"name":"getCurrentSendingLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"siblingChainSlug_","type":"uint32"}],"name":"getReceivingLimitParams","outputs":[{"components":[{"internalType":"uint256","name":"lastUpdateTimestamp","type":"uint256"},{"internalType":"uint256","name":"ratePerSecond","type":"uint256"},{"internalType":"uint256","name":"maxLimit","type":"uint256"},{"internalType":"uint256","name":"lastUpdateLimit","type":"uint256"}],"internalType":"struct Gauge.LimitParams","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"siblingChainSlug_","type":"uint32"}],"name":"getSendingLimitParams","outputs":[{"components":[{"internalType":"uint256","name":"lastUpdateTimestamp","type":"uint256"},{"internalType":"uint256","name":"ratePerSecond","type":"uint256"},{"internalType":"uint256","name":"maxLimit","type":"uint256"},{"internalType":"uint256","name":"lastUpdateLimit","type":"uint256"}],"internalType":"struct Gauge.LimitParams","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role_","type":"bytes32"},{"internalType":"address","name":"grantee_","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role_","type":"bytes32"},{"internalType":"address","name":"address_","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"siblingChainSlug_","type":"uint32"},{"internalType":"bytes","name":"payload_","type":"bytes"}],"name":"inbound","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"includeUsersInFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialTimeStamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"liquidityWalletAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"marketingFeePercent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"marketingWalletAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver_","type":"address"},{"internalType":"uint32","name":"siblingChainSlug_","type":"uint32"},{"internalType":"bytes32","name":"identifier_","type":"bytes32"}],"name":"mintPendingFor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"nominee_","type":"address"}],"name":"nominateOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"nominee","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"oseanWalletAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"pendingExecutions","outputs":[{"internalType":"bool","name":"isAmountPending","type":"bool"},{"internalType":"uint32","name":"siblingChainSlug","type":"uint32"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"bytes","name":"payload","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"},{"internalType":"address","name":"","type":"address"},{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"pendingMints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"token_","type":"address"},{"internalType":"address","name":"rescueTo_","type":"address"},{"internalType":"uint256","name":"amount_","type":"uint256"}],"name":"rescueFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"msgId_","type":"bytes32"}],"name":"retryPayloadExecution","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role_","type":"bytes32"},{"internalType":"address","name":"revokee_","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"}],"name":"siblingPendingMints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"swapFeesManually","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tobeburntWalletAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"uniswapPair","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"uniswapRouterAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"executionHelper_","type":"address"}],"name":"updateExecutionHelper","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"bool","name":"isMint","type":"bool"},{"internalType":"uint32","name":"siblingChainSlug","type":"uint32"},{"internalType":"uint256","name":"maxLimit","type":"uint256"},{"internalType":"uint256","name":"ratePerSecond","type":"uint256"}],"internalType":"struct Osean.UpdateLimitParams[]","name":"updates_","type":"tuple[]"}],"name":"updateLimitParams","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"bridge_","type":"address"}],"name":"updateMessageBridge","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"yachtTransactionFeePercent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]