Draft
Conversation
ksatyarth2
reviewed
Feb 17, 2026
| @@ -51,46 +56,29 @@ contract GuardianModule is AccessManaged, IGuardianModule { | |||
| */ | |||
| uint256 internal _threshold; | |||
Contributor
There was a problem hiding this comment.
a better natspec for this variable like _ejectionThreshold
ksatyarth2
reviewed
Feb 17, 2026
| import { ALGO_ID_ES256K } from "@automata-network/automata-tee-workload-measurement/types/Constants.sol"; | ||
|
|
||
| /** | ||
| * @title Guardian module |
Contributor
There was a problem hiding this comment.
change natspec description to remove enclave keys
ksatyarth2
reviewed
Feb 17, 2026
| * @notice Thrown if the Commitment does not match the workload verifier | ||
| * @dev Signature "0x5054097b" | ||
| */ | ||
| error CommitmentMismatch(); |
ksatyarth2
reviewed
Feb 17, 2026
| * @notice Thrown if the GoldenMeasurement is not valid | ||
| * @dev Signature "0x69e9d3ba" | ||
| */ | ||
| error InvalidMeasurement(); |
ksatyarth2
reviewed
Feb 17, 2026
| * @notice Thrown if the data is not valid | ||
| * @dev Signature "0x5cb045db" | ||
| */ | ||
| error InvalidData(); |
Contributor
There was a problem hiding this comment.
check for unused errors
ksatyarth2
reviewed
Feb 17, 2026
| * @dev Signature "0x6e41f97e85009a93fbd7a9e9c885b782819739d41a903d21bb4ad7a40d1af83a" | ||
| */ | ||
| event MrSignerChanged(bytes32 oldMrSigner, bytes32 newMrSigner); | ||
| event RotatedGuardianKey(bytes32 ownerFingerprint, address computedAddress); |
ksatyarth2
reviewed
Feb 17, 2026
| emit MrSignerChanged(_mrsigner, newMrSigner); | ||
| _mrenclave = newMrEnclave; | ||
| _mrsigner = newMrSigner; | ||
| function setAllowedWorkload(bytes32 workloadId, bool allowed) external restricted { |
Contributor
There was a problem hiding this comment.
check for workloadId != 0
Contributor
Author
There was a problem hiding this comment.
Check added to code and test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PRs modifies GuardianModule to use the new TDX instead of the deprecated SGX