<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
    <channel>
        <title>xwal</title>
        <link>https://paragraph.com/@xwave</link>
        <description>undefined</description>
        <lastBuildDate>Wed, 02 Sep 2026 01:15:29 GMT</lastBuildDate>
        <docs>https://validator.w3.org/feed/docs/rss2.html</docs>
        <generator>https://github.com/jpmonette/feed</generator>
        <language>en</language>
        <image>
            <title>xwal</title>
            <url>https://storage.googleapis.com/papyrus_images/7da02bdded0dab5e7ad0e0c1d9d0cd64e045d212840844aac12e03bc3dfb15c3.jpg</url>
            <link>https://paragraph.com/@xwave</link>
        </image>
        <copyright>All rights reserved</copyright>
        <item>
            <title><![CDATA[What is keeping you motivated?]]></title>
            <link>https://paragraph.com/@xwave/what-is-keeping-you-motivated</link>
            <guid>cQk0Q8w9c6kgnRSgpXri</guid>
            <pubDate>Fri, 12 Aug 2022 02:56:32 GMT</pubDate>
            <description><![CDATA[Web3 is Future. Web3 can change everything. Web3 can create value.]]></description>
            <content:encoded><![CDATA[<p>Web3 is Future.</p><p>Web3 can change everything.</p><p>Web3 can create value.</p>]]></content:encoded>
            <author>xwave@newsletter.paragraph.com (xwal)</author>
        </item>
        <item>
            <title><![CDATA[26. DoubleEntryPoint]]></title>
            <link>https://paragraph.com/@xwave/26-doubleentrypoint</link>
            <guid>2sqhTx1Ih2D92QXPLTrl</guid>
            <pubDate>Sat, 07 May 2022 10:19:31 GMT</pubDate>
            <description><![CDATA[Difficulty: 4/10 Level: https://ethernaut.openzeppelin.com/level/0x128BA32Ec698610f2fF8f010A7b74f9985a6D17c 先看通关介绍： 该合约具有 Forta 合约，任何用户都可以在其中注册自己的检测机器人合约。 Forta 是一个去中心化的、基于社区的监控网络，用于尽快检测 DeFi、NFT、治理、桥梁和其他 Web3 系统上的威胁和异常。您的工作是实施检测机器人并将其注册到 Forta 合同中。机器人的实施将需要发出正确的警报，以防止潜在的攻击或漏洞利用。 按 Get new instance 开始闯关。MetaMask 会弹出交易请求，确认以部署关卡合约，关卡正式开始。创建 Bot 合约打开 Remix IDE: https://remix.ethereum.org/ 创建 workspace。新建 Bot.sol 文件拷贝代码到 Bot.solpragma solidity 0.8.7; interface IDetectionBot { function handleTran...]]></description>
            <content:encoded><![CDATA[<p>Difficulty: 4/10</p><p>Level: <a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://ethernaut.openzeppelin.com/level/0x128BA32Ec698610f2fF8f010A7b74f9985a6D17c">https://ethernaut.openzeppelin.com/level/0x128BA32Ec698610f2fF8f010A7b74f9985a6D17c</a></p><p>先看通关介绍：</p><p>该合约具有 Forta 合约，任何用户都可以在其中注册自己的检测机器人合约。 Forta 是一个去中心化的、基于社区的监控网络，用于尽快检测 DeFi、NFT、治理、桥梁和其他 Web3 系统上的威胁和异常。您的工作是实施检测机器人并将其注册到 Forta 合同中。机器人的实施将需要发出正确的警报，以防止潜在的攻击或漏洞利用。</p><p>按 Get new instance 开始闯关。MetaMask 会弹出交易请求，确认以部署关卡合约，关卡正式开始。</p><h2 id="h-bot" class="text-3xl font-header !mt-8 !mb-4 first:!mt-0 first:!mb-0">创建 Bot 合约</h2><ol><li><p>打开 Remix IDE: <a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://www.youtube.com/redirect?event=video_description&amp;redir_token=QUFFLUhqbWdtMTk1UGRpRnRGMUN3Tm1EX1ZWallTTXVmZ3xBQ3Jtc0trUWlwMnQxbzRkZUlSTVdzbVZsaHQwRkp4cmJtSnAtMmpLY3RtcHUtNXBEWDYxNFRkdDVvWGNwU2hjd3JzbVc3b3Z2MkF5TW9xLWl4OFdJd1RsTTZ4Zm1PY00taDFtTFNGbGJ6Y2wzTFpvODV5Rm5VVQ&amp;q=https%3A%2F%2Fremix.ethereum.org%2F&amp;v=M7Sv7I9hF70">https://remix.ethereum.org/</a> 创建 workspace。</p></li><li><p>新建 <code>Bot.sol</code> 文件</p></li><li><p>拷贝代码到 <code>Bot.sol</code></p><pre data-type="codeBlock" text="pragma solidity 0.8.7;

interface IDetectionBot {
    function handleTransaction(address user, bytes calldata msgData) external;
}

interface IForta {
    function setDetectionBot(address detectionBotAddress) external;
    function notify(address user, bytes calldata msgData) external;
    function raiseAlert(address user) external;
}

contract Bot is IDetectionBot {

    address fortaContract = 0xD386F824FabC0bB1e85a2AD1D24642C9BaAa231A; // 通过 await contract.forta() 获得

    function handleTransaction(address user, bytes calldata msgData) override external {
        require(msg.sender == fortaContract);
        IForta(fortaContract).raiseAlert(user);
    }

}
"><code><span class="hljs-meta"><span class="hljs-keyword">pragma</span> <span class="hljs-keyword">solidity</span> 0.8.7;</span>

<span class="hljs-class"><span class="hljs-keyword">interface</span> <span class="hljs-title">IDetectionBot</span> </span>{
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">handleTransaction</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user, <span class="hljs-keyword">bytes</span> <span class="hljs-keyword">calldata</span> msgData</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
}

<span class="hljs-class"><span class="hljs-keyword">interface</span> <span class="hljs-title">IForta</span> </span>{
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">setDetectionBot</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> detectionBotAddress</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">notify</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user, <span class="hljs-keyword">bytes</span> <span class="hljs-keyword">calldata</span> msgData</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">raiseAlert</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
}

<span class="hljs-class"><span class="hljs-keyword">contract</span> <span class="hljs-title">Bot</span> <span class="hljs-keyword">is</span> <span class="hljs-title">IDetectionBot</span> </span>{

    <span class="hljs-keyword">address</span> fortaContract <span class="hljs-operator">=</span> <span class="hljs-number">0xD386F824FabC0bB1e85a2AD1D24642C9BaAa231A</span>; <span class="hljs-comment">// 通过 await contract.forta() 获得</span>

    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">handleTransaction</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user, <span class="hljs-keyword">bytes</span> <span class="hljs-keyword">calldata</span> msgData</span>) <span class="hljs-title"><span class="hljs-keyword">override</span></span> <span class="hljs-title"><span class="hljs-keyword">external</span></span> </span>{
        <span class="hljs-built_in">require</span>(<span class="hljs-built_in">msg</span>.<span class="hljs-built_in">sender</span> <span class="hljs-operator">=</span><span class="hljs-operator">=</span> fortaContract);
        IForta(fortaContract).raiseAlert(user);
    }

}
</code></pre></li><li><p>编译，部署。</p><ol><li><p>在 <code>Solidity compiler</code> 中选择 <code>Compile Bot.sol</code></p></li><li><p>在 <code>DEPLOY &amp; RUN TRANSACTIONS</code> 中 <code>ENVIRONMENT</code> 中选择 <code>Injected Web3</code> ，选择 <code>CONTRACT</code> 为 <code>Bot.sol</code>。</p></li><li><p>部署完成后，会在下方显示 <code>Deployed Contracts</code>。</p></li></ol></li></ol><h2 id="h-forta" class="text-3xl font-header !mt-8 !mb-4 first:!mt-0 first:!mb-0">交互 Forta 合约</h2><ol><li><p>新建 <code>Forta.sol</code> 文件</p></li><li><p>拷贝代码到 <code>Forta.sol</code></p><pre data-type="codeBlock" text="pragma solidity 0.8.7;

interface IDetectionBot {
    function handleTransaction(address user, bytes calldata msgData) external;
}

interface IForta {
    function setDetectionBot(address detectionBotAddress) external;
    function notify(address user, bytes calldata msgData) external;
    function raiseAlert(address user) external;
}

contract Forta is IForta {
  mapping(address =&gt; IDetectionBot) public usersDetectionBots;
  mapping(address =&gt; uint256) public botRaisedAlerts;

  function setDetectionBot(address detectionBotAddress) external override {
      require(address(usersDetectionBots[msg.sender]) == address(0), &quot;DetectionBot already set&quot;);
      usersDetectionBots[msg.sender] = IDetectionBot(detectionBotAddress);
  }

  function notify(address user, bytes calldata msgData) external override {
    if(address(usersDetectionBots[user]) == address(0)) return;
    try usersDetectionBots[user].handleTransaction(user, msgData) {
        return;
    } catch {}
  }

  function raiseAlert(address user) external override {
      if(address(usersDetectionBots[user]) != msg.sender) return;
      botRaisedAlerts[msg.sender] += 1;
  } 
}
"><code><span class="hljs-meta"><span class="hljs-keyword">pragma</span> <span class="hljs-keyword">solidity</span> 0.8.7;</span>

<span class="hljs-class"><span class="hljs-keyword">interface</span> <span class="hljs-title">IDetectionBot</span> </span>{
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">handleTransaction</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user, <span class="hljs-keyword">bytes</span> <span class="hljs-keyword">calldata</span> msgData</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
}

<span class="hljs-class"><span class="hljs-keyword">interface</span> <span class="hljs-title">IForta</span> </span>{
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">setDetectionBot</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> detectionBotAddress</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">notify</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user, <span class="hljs-keyword">bytes</span> <span class="hljs-keyword">calldata</span> msgData</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
    <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">raiseAlert</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span></span>;
}

<span class="hljs-class"><span class="hljs-keyword">contract</span> <span class="hljs-title">Forta</span> <span class="hljs-keyword">is</span> <span class="hljs-title">IForta</span> </span>{
  <span class="hljs-keyword">mapping</span>(<span class="hljs-keyword">address</span> <span class="hljs-operator">=</span><span class="hljs-operator">></span> IDetectionBot) <span class="hljs-keyword">public</span> usersDetectionBots;
  <span class="hljs-keyword">mapping</span>(<span class="hljs-keyword">address</span> <span class="hljs-operator">=</span><span class="hljs-operator">></span> <span class="hljs-keyword">uint256</span>) <span class="hljs-keyword">public</span> botRaisedAlerts;

  <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">setDetectionBot</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> detectionBotAddress</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span> <span class="hljs-title"><span class="hljs-keyword">override</span></span> </span>{
      <span class="hljs-built_in">require</span>(<span class="hljs-keyword">address</span>(usersDetectionBots[<span class="hljs-built_in">msg</span>.<span class="hljs-built_in">sender</span>]) <span class="hljs-operator">=</span><span class="hljs-operator">=</span> <span class="hljs-keyword">address</span>(<span class="hljs-number">0</span>), <span class="hljs-string">"DetectionBot already set"</span>);
      usersDetectionBots[<span class="hljs-built_in">msg</span>.<span class="hljs-built_in">sender</span>] <span class="hljs-operator">=</span> IDetectionBot(detectionBotAddress);
  }

  <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">notify</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user, <span class="hljs-keyword">bytes</span> <span class="hljs-keyword">calldata</span> msgData</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span> <span class="hljs-title"><span class="hljs-keyword">override</span></span> </span>{
    <span class="hljs-keyword">if</span>(<span class="hljs-keyword">address</span>(usersDetectionBots[user]) <span class="hljs-operator">=</span><span class="hljs-operator">=</span> <span class="hljs-keyword">address</span>(<span class="hljs-number">0</span>)) <span class="hljs-keyword">return</span>;
    <span class="hljs-keyword">try</span> usersDetectionBots[user].handleTransaction(user, msgData) {
        <span class="hljs-keyword">return</span>;
    } <span class="hljs-keyword">catch</span> {}
  }

  <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">raiseAlert</span>(<span class="hljs-params"><span class="hljs-keyword">address</span> user</span>) <span class="hljs-title"><span class="hljs-keyword">external</span></span> <span class="hljs-title"><span class="hljs-keyword">override</span></span> </span>{
      <span class="hljs-keyword">if</span>(<span class="hljs-keyword">address</span>(usersDetectionBots[user]) <span class="hljs-operator">!</span><span class="hljs-operator">=</span> <span class="hljs-built_in">msg</span>.<span class="hljs-built_in">sender</span>) <span class="hljs-keyword">return</span>;
      botRaisedAlerts[<span class="hljs-built_in">msg</span>.<span class="hljs-built_in">sender</span>] <span class="hljs-operator">+</span><span class="hljs-operator">=</span> <span class="hljs-number">1</span>;
  } 
}
</code></pre></li><li><p>编译 <code>Forta.sol</code></p></li><li><p>在 <code>DEPLOY &amp; RUN TRANSACTIONS</code> 中 <code>CONTRACT</code> 选择 <code>Forta.sol</code> ；在 <code>At Address</code> 中填入 <code>0xD386F824FabC0bB1e85a2AD1D24642C9BaAa231A</code> ；展开下方的 <code>Deployed Contracts</code>。</p></li></ol><figure float="none" data-type="figure" class="img-center" style="max-width: null;"><img src="https://storage.googleapis.com/papyrus_images/c46967ee84c683bb25af900eb5e9e8c9780a164b9c56a7b7171ae0aeb6260a06.png" alt="" blurdataurl="data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAAAAAQABAAACAkQBADs=" nextheight="600" nextwidth="800" class="image-node embed"><figcaption HTMLAttributes="[object Object]" class="hide-figcaption"></figcaption></figure><ol start="5"><li><p>点开 <code>setDetectionBot</code> ，传入上一步部署 bot 合约的地址，点击 <code>transct</code> 。</p></li></ol><figure float="none" data-type="figure" class="img-center" style="max-width: null;"><img src="https://storage.googleapis.com/papyrus_images/423480580c1f8e81fe4fdda1f96d378551ee918365a4337acce54c3b0e248785.png" alt="" blurdataurl="data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAAAAAQABAAACAkQBADs=" nextheight="600" nextwidth="800" class="image-node embed"><figcaption HTMLAttributes="[object Object]" class="hide-figcaption"></figcaption></figure><p>点击提交，本关完成。</p>]]></content:encoded>
            <author>xwave@newsletter.paragraph.com (xwal)</author>
            <enclosure url="https://storage.googleapis.com/papyrus_images/f119f6a214d3210214ee84fb759d02739051b12b9edc6f0675a077a46d640a33.jpg" length="0" type="image/jpg"/>
        </item>
        <item>
            <title><![CDATA[The Ethernaut 解析]]></title>
            <link>https://paragraph.com/@xwave/the-ethernaut</link>
            <guid>CFqHoFWqnf3sXh3myShb</guid>
            <pubDate>Thu, 05 May 2022 11:43:09 GMT</pubDate>
            <description><![CDATA[Ethernaut 是一个基于 Web3/Solidity 的对抗游戏，每一关都有一个带有安全问题的智能合约供玩家去模拟攻击。 游戏要求玩家具备 JavaScript、MetaMask和Solidity 智能合约相关知识，所有合约均为开源，玩家可以浏览 Ethernaut 网站 在 Rinkeby 测试网络中游玩。或者到 Github 下载源代码。相关知识储备JavaScriptChrome DevToolsMetaMaskEthereumEthereum Developer准备工作Get Rinkeby Test ETH题目解析https://mirror.xyz/0xE407D650Db255A3F1509e6ABb2a254F28993526c/m_yuSsKdFtD9T8i5E1owO588olqldnB9VaOMgQOKgc0]]></description>
            <content:encoded><![CDATA[<p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://ethernaut.openzeppelin.com/">Ethernaut</a> 是一个基于 Web3/Solidity 的对抗游戏，每一关都有一个带有安全问题的智能合约供玩家去模拟攻击。</p><p>游戏要求玩家具备 JavaScript、MetaMask和Solidity 智能合约相关知识，所有合约均为开源，玩家可以浏览 <a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://ethernaut.openzeppelin.com/">Ethernaut 网站</a> 在 Rinkeby 测试网络中游玩。或者到 <a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://github.com/OpenZeppelin/ethernaut">Github</a> 下载源代码。</p><h3 id="h-" class="text-2xl font-header !mt-6 !mb-4 first:!mt-0 first:!mb-0">相关知识储备</h3><ol><li><p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://developer.mozilla.org/zh-CN/docs/Web/JavaScript">JavaScript</a></p></li><li><p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://developer.chrome.com/docs/devtools/">Chrome DevTools</a></p></li><li><p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://metamask.io/">MetaMask</a></p></li><li><p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://ethereum.org/zh/what-is-ethereum/">Ethereum</a></p></li><li><p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://ethereum.org/zh/developers/">Ethereum Developer</a></p></li></ol><h3 id="h-" class="text-2xl font-header !mt-6 !mb-4 first:!mt-0 first:!mb-0">准备工作</h3><ol><li><p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://michael-blau.gitbook.io/x0r-resources/rinkeby-test-network/rinkeby-test-ether">Get Rinkeby Test ETH</a></p></li></ol><h3 id="h-" class="text-2xl font-header !mt-6 !mb-4 first:!mt-0 first:!mb-0">题目解析</h3><p><a target="_blank" rel="noopener noreferrer nofollow ugc" class="dont-break-out" href="https://mirror.xyz/0xE407D650Db255A3F1509e6ABb2a254F28993526c/m_yuSsKdFtD9T8i5E1owO588olqldnB9VaOMgQOKgc0">https://mirror.xyz/0xE407D650Db255A3F1509e6ABb2a254F28993526c/m_yuSsKdFtD9T8i5E1owO588olqldnB9VaOMgQOKgc0</a></p>]]></content:encoded>
            <author>xwave@newsletter.paragraph.com (xwal)</author>
        </item>
        <item>
            <title><![CDATA[0. Hello Ethernaut]]></title>
            <link>https://paragraph.com/@xwave/0-hello-ethernaut</link>
            <guid>yWooNkRpFr9qlieMzbWs</guid>
            <pubDate>Thu, 05 May 2022 11:39:24 GMT</pubDate>
            <description><![CDATA[本节主要就是一个新手教学，让人先了解游戏玩法及闯关模式，需要对 MetaMask、JavaScript、console等有基本了解。 打开 Developer Console (F12) ，输入会打印当前钱包地址。 依步骤了解指令用法，按 Get new instance 开始闯关。MetaMask 会弹出交易请求，确认以部署关卡合约，关卡正式开始。 打开 Developer Console (F12) ，依次输入:> await contract.info() &#x3C; "You will find what you need in info1()." > await contract.info1() &#x3C; "Try info2(), but with "hello" as a parameter." > await contract.info2("hello") &#x3C; "The property infoNum holds the number of the next info method to call." > await contract.infoN...]]></description>
            <content:encoded><![CDATA[<p>本节主要就是一个新手教学，让人先了解游戏玩法及闯关模式，需要对 MetaMask、JavaScript、console等有基本了解。</p><p>打开 Developer Console (F12) ，输入</p><pre data-type="codeBlock" text="player
"><code></code></pre><p>会打印当前钱包地址。</p><p>依步骤了解指令用法，按 Get new instance 开始闯关。MetaMask 会弹出交易请求，确认以部署关卡合约，关卡正式开始。</p><p>打开 Developer Console (F12) ，依次输入:</p><pre data-type="codeBlock" text="&gt; await contract.info()
&lt; &quot;You will find what you need in info1().&quot;

&gt; await contract.info1()
&lt; &quot;Try info2(), but with &quot;hello&quot; as a parameter.&quot;

&gt; await contract.info2(&quot;hello&quot;)
&lt; &quot;The property infoNum holds the number of the next info method to call.&quot;

&gt; await contract.infoNum()
&lt; BN {negative: 0, words: [42, empty], length: 1, red: null}

&gt; await contract.info42()
&lt; &quot;theMethodName is the name of the next method.&quot;

&gt; await contract.theMethodName()
&lt; &quot;The method name is method7123949.&quot;

&gt; await contract.method7123949()
&lt; &quot;If you know the password, submit it to authenticate().&quot;

&gt; await contract.password()
&lt; &quot;ethernaut0&quot;

&gt; await contract.authenticate(&quot;ethernaut0&quot;)
"><code><span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.info()
<span class="hljs-operator">&#x3C;</span> <span class="hljs-string">"You will find what you need in info1()."</span>

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.info1()
<span class="hljs-operator">&#x3C;</span> <span class="hljs-string">"Try info2(), but with "</span>hello<span class="hljs-string">" as a parameter."</span>

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.info2(<span class="hljs-string">"hello"</span>)
<span class="hljs-operator">&#x3C;</span> <span class="hljs-string">"The property infoNum holds the number of the next info method to call."</span>

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.infoNum()
<span class="hljs-operator">&#x3C;</span> BN {negative: <span class="hljs-number">0</span>, words: [<span class="hljs-number">42</span>, empty], length: <span class="hljs-number">1</span>, red: null}

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.info42()
<span class="hljs-operator">&#x3C;</span> <span class="hljs-string">"theMethodName is the name of the next method."</span>

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.theMethodName()
<span class="hljs-operator">&#x3C;</span> <span class="hljs-string">"The method name is method7123949."</span>

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.method7123949()
<span class="hljs-operator">&#x3C;</span> <span class="hljs-string">"If you know the password, submit it to authenticate()."</span>

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.password()
<span class="hljs-operator">&#x3C;</span> <span class="hljs-string">"ethernaut0"</span>

<span class="hljs-operator">></span> await <span class="hljs-keyword">contract</span>.authenticate(<span class="hljs-string">"ethernaut0"</span>)
</code></pre><p>最后会弹出一个 MetaMask 的交易请求，确认后再按 Submit instance，再确认后 Console 会弹出 “You have completed this level!!!” 即本关完成。</p>]]></content:encoded>
            <author>xwave@newsletter.paragraph.com (xwal)</author>
        </item>
    </channel>
</rss>