Method to enable EIP 155 on individual Infura Project

With the Berlin hard-fork, EIP-155 violating transactions are supposed to be deprecated.
However, Infura is still allowing “unprotected” pre-EIP-155 style transactions as per the recent announcement.

Since EIP-155 compliance, affects my app, I wanted to know whether there is a way to toggle “unprotected transactions” on/off?

I need to enable EIP-155 checking on my Infura project to reproduce the issue on my app and check whether my patch is working. Please let me know if there are any settings available. Thanks!

@sahashuvo this is great idea and we are considering it internally. In the mean time, you can easily check your transactions to see if they are EIP-155 compliant or not.

  • Send a transaction through your app.
  • After the transaction is mined, lookup the transaction data via eth_getTransactionByHash.
  • Look at the v value.

On mainnet, EIP-155 compliant transactions will have a v of either 0x25 or 0x26 (37 or 28 in decimal). “Unprotected” txs will have a v of either 0x1b or 0x1c (27 or 28). Additionally, once Berlin goes live on mainnet, EIP-2930 transactions (which are always protected) will have a v of 0x0 or 0x1.

If your transactions have a v of 0x1b or 0x1c then you should upgrade to a newer EIP-155 compatible library for creating your transactions, or enable EIP-155 options. This will depend on how you are creating/signing your transactions.

1 Like