logo
logo
Menu
Signatures and Approvals

Safe Signing 101

4 minutes

Available In:

Oct 9th, 2022 - 10:16 am

Edited By:

Understanding The Message Signature

There are a lot of misconceptions about signatures. In this article I want to go over four types of message signatures to help users understand the risks associated with signing messages (also sometimes referred to as gasless signatures) on Ethereum or other EVM compatible blockchains.

The Four Types of Signatures

These signature types are absolutely critical for all Ethereans in web3 to understand.

Type #1 - The Identity Proof (Safe)

This is mainly what signatures in web3 are used for. Although there is no unifying standard on what these look like, some common things include a Terms of Service, your Wallet address, and sometimes a nonce to prevent replay attacks, and potentially a short string to ensure the message you are signing on the software wallet is the same on the hardware wallet. See a couple examples below:

NormalSign2.png
NormalSign1.png

Type #2 - The Typed Signature [Smart Contract Interaction] (Use Caution)

Often some part of smart contracts rely on signatures off-chain to make things happen. These types of signatures will break down all the inputs that will be part of the contract interaction. Quite handy, but this is where if you have open approvals you need to be careful. As we discussed in our approvals article, although you can tell exactly what they are doing in this example, you need to ensure the source in which is surfacing these kinds of signature requests is reputable. 

For example, if you got the pictured signature approval request outside of Opensea, you should be very worried, and never sign it. This is particularly true if you are using your “Sell” wallet address, as we introduced in our “Wallet For Every Occasion” article.

Boringsec.png

Type #3 - The Obfuscated Hex Signature (Use Extreme Caution!)

Now just because something doesn't have a beautifully typed signature in accordance with the EIP-712 standard above, doesn't mean its a scam. However, it does mean that you are trusting the counterparty with whatever kind of message you may be signing, as you are essentially “Blind Signing” a message. Although we are not seeing these leveraged on Opensea these days due to upgrades in the Seaport contract, I would still give pause before signing these types of messages, particularly if you are on a wallet address with open approvals. Not sure? Check out our article on revoking approvals and see what approvals you have open on that wallet address!

signaturestuff.jpg

Type #4 - ETH_Sign - Outdated & Well, A Little Bit Scary (Dangerous!)

This is a very dangerous signature type, basically the “blank check” of Ethereum. The requester can use it sign any transaction with your private key. The good news is that Metamask shows a big red warning if it is ever requested. It effectively allows someone, if they properly craft the signature payload, to be able to “replay” a transaction to their own benefit, such as sending themselves ETH. This does not rely on approvals as stolen wETH, NFTs and other tokens do. This is the only signature type that runs this kind of risk, and should generally be avoided at all costs, as it is rare for services to use this legitimately!

ML311.png

UPDATE: Based on our feedback and others in the community, ETH_SIGN is now disabled by default in Metamask (but you can enable it in the advanced settings), so we are leaving this here for completeness! We view this as a huge UI/UX win in the space and simplifies our messaging regarding signatures.


Additional Resources

We understand that we are simplifying some of the technical terms here, so before you say “You guys are using the wrong words for this!” just know that we are trying to simplify the framework to make this more understandable for all! Below are more resources and more technical explanations of signatures, signature types and their implementations!

More information on the technicals here:

Some more helpful articles on Signatures:

Have any questions or want to learn more about web3 security and stay up to date on the most current security information, scams, and tactics? Join us in our discord at https://discord.gg/boringsecurity . BoringSecurityicon.png