Перейти к содержимому
Проверенный контрактТочноеUNLICENSED

ToHellWithCurve

Адрес0xb7feb17fb0b0fdfbc762e1fdee5d8863f2f0a201
Баланс

0 ETH

 

Транзакций

1

 

Компилятор

solc 0.8.38

 

Тот же код

Только этот контракт

 

Подробности

Компилятор
solc 0.8.38+commit.1835d247
Язык
solidity
Оптимизация
Да, 10 000 прогонов
Версия EVM
osaka
Через IR
да
Лицензия
UNLICENSED
Совпадение
Точноекод создания: да, код в сети: да
Проверен на Sourcify
Создан в блоке
26 465 098
Транзакция создания
0x8aa5d3be3d…76cb554cba

solidity/src/modules/ToHellWithCurve.sol

// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.37;

// `PythReportBank`'s entry point, `0xb6603da5`.
interface IPythReportBank {
    function deliver_report(bytes calldata update) external payable;
}

/// @notice Routes a signed Pyth Pro update from module `0x04` to Yield Basis's
///  `PythReportBank`. `0x04` calls `deliver_oracle_report(bytes)` on whatever address
///  its instruction names; named there, this contract hands the update and the value
///  to the bank's `deliver_report`. The wire is `0x04`'s:
///  `[0x04][this:20][value:32][len:2][update:len]`. Not a module: it is deployed from
///  any key and called, never registered. See `docs/yield-basis-oracle.md`.
contract ToHellWithCurve {
    IPythReportBank public constant BANK =
        IPythReportBank(0x8a0f866de34631311b7745C5f4eec7Bf1F6849dB);
    // AmmSwapper V9: `0x04` runs under its `delegatecall`, so the call comes from it.
    address public constant AMM_SWAPPER = 0xE41698520E4817B55C1841859a36847d50F0c82F;

    /// @notice Delivers `update` to the bank with all of `msg.value`, for the swapper
    ///  only. A bank revert reverts the caller; a feed not newer than the bank's is
    ///  skipped, not reverted.
    function deliver_oracle_report(bytes calldata update) external payable {
        require(msg.sender == AMM_SWAPPER);
        BANK.deliver_report{value: msg.value}(update);
    }
}
Настройки компилятораПоказать
{
  "viaIR": true,
  "metadata": {
    "appendCBOR": true,
    "bytecodeHash": "ipfs",
    "useLiteralContent": false
  },
  "libraries": {},
  "optimizer": {
    "runs": 10000,
    "enabled": true
  },
  "viaSSACFG": false,
  "evmVersion": "osaka",
  "remappings": [
    "forge-std/=solidity/lib/forge-std/src/"
  ],
  "experimental": false
}

Исходный код и метаданные: Sourcify.

Исходный код принадлежит авторам контракта.