Background
@gorman-jacob has requested this functionality so that we can implement protection against test-and-abort attacks against our native VRF feature, which will be integrated in the near future.
Requirements
- Add a Move enum to represent the different variants of
TransactionPayload in the Move state.
- Add a new native function called
transaction_type to expose the variant of the TransactionPayload of the transaction under execution to the Move layer during its execution. The native variant should be converted to the corresponding variant of the new Move enum as a result of this process.
- Implement integration tests that only succeed if the payload type of the executed transaction matches the variant specified in the Move state.