Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: cleanup test fixture and foundry.toml #276

Merged
merged 1 commit into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ bytecode_hash = "none"
auto_detect_remappings = false
fs_permissions = [
{ access = "read", path = "./out-optimized" },
{ access = "read-write", path = "./.forge-snapshots" },
{ access = "read", path = "./test/bin" },
]

Expand Down
12 changes: 3 additions & 9 deletions test/utils/ModuleSignatureUtils.sol
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ contract ModuleSignatureUtils {
"DeferredAction(uint256 nonce,uint48 deadline,bytes25 validationFunction,bytes call)";
bytes32 private constant _DEFERRED_ACTION_TYPEHASH =
keccak256(abi.encodePacked(_DEFERRED_ACTION_CONTENTS_TYPE));
bytes32 internal constant _REPLAY_SAFE_HASH_TYPEHASH =
0x294a8735843d4afb4f017c76faf3b7731def145ed0025fc9b1d5ce30adf113ff;

bytes32 internal constant _REPLAY_SAFE_HASH_TYPEHASH = keccak256("ReplaySafeHash(bytes32 hash)");

bytes32 internal constant _ACCOUNT_DOMAIN_SEPARATOR =
keccak256("EIP712Domain(uint256 chainId,address verifyingContract)");
Expand Down Expand Up @@ -245,12 +245,6 @@ contract ModuleSignatureUtils {

// EIP-712 helpers for acount
function _hashStruct(bytes32 hash) internal pure virtual returns (bytes32) {
bytes32 res;
assembly ("memory-safe") {
mstore(0x00, _REPLAY_SAFE_HASH_TYPEHASH)
mstore(0x20, hash)
res := keccak256(0x00, 0x40)
}
return res;
return keccak256(abi.encode(_REPLAY_SAFE_HASH_TYPEHASH, hash));
}
}
Loading