Skip navigation
I made a 🦊 wallet plugin that:
0:00 / 2:29

I made a 🦊 wallet plugin that:

Patrick Collins

@PatrickAlphaC112K followers

Visit on X
851 likesDownloadOriginal post

67,952 views

I made a 🦊 wallet plugin that: 1. Decodes your calldata 2. Uses that decoded data as input to an AI 3. Which then searches the web to see if the transaction has anything "fishy" about it. Here is an example where you'd be sending money to the ByBit hackers, but it catches it!

44 Comments

Comments from the original post on X (Twitter)

  • Patrick Collins's profile picture

    @PatrickAlphaC

    I think most threat intel products can get a major upgrade with AI now (looking at you @blockaid_, feel free to hit me up with product ideas/feedback). The project is currently in beta, but you can find all the code here.

    47 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    I was able to do a lot of MVPs where this tool flags the bad transactions, but most threat intel products do not, like: - address poisoning - nested calldata stuffing - sending money to known hackers - etc The key is that AI is able to tell what your "intent" is.

    30 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    What's EXTRA crazy about the example in the video, is how obscure it is. The transaction we call is `supply` on the @aave protocol. But the simulated hacked website stuffs some bad calldata in there. The `onBehalfOf` address is swapped with the ByBit attacker!

    25 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    @aave To find this, the AI searches the web, and figures out by your calldata, chain, and address that the user is probably trying to call `supply` for themselves. Knowing this is the user's intent, the AI can pretty easily figure out what the calldata should be doing.

    21 likes

  • Build with MetaMask's profile picture

    @MetaMaskBuild

    well done 👏

    25 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    We love the fox. Sorry I didn't tag you. I didn't want to summon the bots.

    11 likes

  • Julien B.'s profile picture

    @bneiluj

    @th3nolo Amazing man! Would love to see that tool added to the @RektHQ Tools list.

    8 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    @th3nolo @RektHQ They have a list? I love rekt, can I make PR to their list?

    6 likes

  • Josep Chetrit's profile picture

    @josepchetrit

    cool work @PatrickAlphaC as always. I'd like to see wallets implementing these things by default so you don't need to use Snap. What's the next step for this tool?

    6 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    1. Get listed on the Metamask snap marketplace 2. Add support for more models 3. Limit test on how to get the API calls price down while keeping the performance up (lot of data testing here…) 4. Potentially setup server where the API keys are abstracted to make an easier experience for people who won’t bring their own API keys. Maybe setup a paid service

    4 likes

  • Vitto Rivabella's profile picture

    @VittoStack

    ❤️❤️

    6 likes

  • Suhail Kakar's profile picture

    @SuhailKakar

    you’re managing cyfrin audits, making courses and videos, sharings tips here... how do you even find time to build apps too?? 😭 mad respect 🫶

    5 likes

  • Cherry 🍒's profile picture

    @0xFeetPic

    Interesting When wallets with @AlloraNetwork inside

    4 likes

  • 𝗩𝗶𝗰𝘁𝗼𝗿_𝗧𝗵𝗲𝗢𝗿𝗮𝗰𝗹𝗲's profile picture

    @victorokpukpan_

    Our security Messiah has worked on another miracle. 🫡

    4 likes

  • Kaan's profile picture

    @kaanuzdogan

    Does it just provide the decoded calldata as context? Isn't it better to provide the full contract, if not at least the NatSpec comments?

    3 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    We could do that too! That would be a great addition! Right now, the snap decodes the calldata and provides it as context. A future improvement could/would be to see if the code is verified on etherscan/an explorer and use that as context.

    2 likes

  • Kaan's profile picture

    @kaanuzdogan

    Where do you get the signature if I may ask? We are considering building a 4-bytes DB from our @SourcifyEth verified contracts and looking into use cases and how people get this data

    3 likes

  • Patrick Collins's profile picture

    @PatrickAlphaC

    @SourcifyEth Oh that would be sick!! yeah right now we are querying 4byte to do the decoding. I'd love a more decentralized edition of this that is easier to update. If 4byte goes down a lot of the current decoding tools on the web have issues :/

    3 likes

  • Kaan's profile picture

    @kaanuzdogan

    @SourcifyEth Good to know 👍 stay tuned

  • gonzaotc.eth's profile picture

    @gonzaotc

    very cool!, cc: @josepchetrit

    2 likes