Skip to content

Refund CTX to Smart Contract that issued CTX #2491

Description

@PropzSaladaz

Description

Smart Contract (SC) that calls submitCTX() & funds the ephemeral account created (will have .to field set to this SC address) should receive the refund from the CTX execution:

  • remaining gas from onDecrypt() execution should be moved into ctx.to.balance
  • ephemeral account responsible for onDecrypt() call should be cleaned both in balance (moved into SC balance) and in nonce to clean up state usage
  • Responsibility of tracking user - CTX correspondence, and its respective refund is left to SC developer. Protocol side only enforces the refund goes back to SC.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

Status
In Progress

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions