Skip to content

contract should not store full Attestation submission #1629

@DSharifi

Description

@DSharifi

Background

@barakeinav1 observed that gas usage is too high when deploying two nodes with TEE, and attempting to vote in a new node. We also observed that verify_tee is using ~270Tgas per call, which is only to verify 2-3 nodes with attestation.

We believe our current tests did not uncover this bug earlier, as all our sandbox tests that use a runtime use mocked attestations which are very cheap to verify.

The issue is that resharing votes failed due to max gas (300tgas) being exceeded. This is due to resharing votes currently re-verifying every participant + the proposed one.

User Story

No response

Acceptance Criteria

  • the contract does not store the full attestation for any participant
  • re-verifications only manually checks for expiry and the allowed hash
  • re-run @barakeinav1 's manual test and verify that gas usage is acceptable

Resources & Additional Notes

No response

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions