Should fee estimation in transactions going trough accounts require a valid signature? #541
Replies: 2 comments 4 replies
-
Note that when using other curves, namely secp256r1 for mobile-based hardware signing, the signature verification itself uses a considerable amount of gas. Just dropping signature verification will reduce the fee estimation and not reflect to the user the actual fee when using hardware signer. |
Beta Was this translation helpful? Give feedback.
-
In 0.11.0 we'll add a skip validation option to estimate fee. It's up to the wallet to handle the account for validate itself. If you think it's negligible or has a simple approximation (e.g. offset by some constant), you don't have to bother going through the signing flow. |
Beta Was this translation helpful? Give feedback.
-
Currently, fee estimation requires a valid signature, because the account contract itself will revert if not received (even with the transaction query version).
This could be a UX issue for example for hardware wallets when the user would need to sign two messages to send a transaction: one for fee estimation (with max_fee equal to 0), and a different one for execution (with the actual max_fee).
A potential solution for this could be to bypass the signature for transactions with an id greater than the query version offset.
Beta Was this translation helpful? Give feedback.
All reactions