Skip to content

Commit

Permalink
📝 plugin: document onInstall difference from MultiOwnerPlugin
Browse files Browse the repository at this point in the history
addresses quantstamp EXA-S-6
  • Loading branch information
cruzdanilo committed Jul 3, 2024
1 parent 00e9f35 commit 85e82f4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .gas-snapshot
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ MultiOwnerPluginIntegration:test_userOpValidation_owner_standardExecute() (gas:
MultiOwnerPluginTest:testFuzz_isValidSignature_ContractOwner(bytes32) (runs: 256, μ: 110067, ~: 110067)
MultiOwnerPluginTest:testFuzz_isValidSignature_ContractOwnerWithEOAOwner(bytes32) (runs: 256, μ: 120381, ~: 120381)
MultiOwnerPluginTest:testFuzz_isValidSignature_EOAOwner(string,bytes32) (runs: 256, μ: 130741, ~: 130734)
MultiOwnerPluginTest:testFuzz_isValidSignature_PasskeyOwner(bytes32) (runs: 256, μ: 365543, ~: 365705)
MultiOwnerPluginTest:testFuzz_isValidSignature_PasskeyOwner(bytes32) (runs: 256, μ: 365504, ~: 365652)
MultiOwnerPluginTest:testFuzz_runtimeValidationFunction_BadFunctionId(uint8) (runs: 256, μ: 9747, ~: 9747)
MultiOwnerPluginTest:testFuzz_userOpValidationFunction_BadFunctionId(uint8) (runs: 256, μ: 10744, ~: 10744)
MultiOwnerPluginTest:testFuzz_userOpValidationFunction_ContractOwner((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)) (runs: 256, μ: 130908, ~: 130897)
MultiOwnerPluginTest:testFuzz_userOpValidationFunction_ContractOwnerWithEOAOwner((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)) (runs: 256, μ: 144523, ~: 144512)
MultiOwnerPluginTest:testFuzz_userOpValidationFunction_EOAOwner(string,(address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)) (runs: 256, μ: 138777, ~: 138780)
MultiOwnerPluginTest:testFuzz_userOpValidationFunction_PasskeyOwner((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)) (runs: 256, μ: 373615, ~: 373631)
MultiOwnerPluginTest:testFuzz_userOpValidationFunction_PasskeyOwner((address,uint256,bytes,bytes,uint256,uint256,uint256,uint256,uint256,bytes,bytes)) (runs: 256, μ: 373691, ~: 373630)
MultiOwnerPluginTest:test_eip712Domain() (gas: 35438)
MultiOwnerPluginTest:test_isValidSignature_failMalformedAddress() (gas: 15544)
MultiOwnerPluginTest:test_isValidSignature_failWithOutOfBounds() (gas: 12319)
Expand Down
1 change: 1 addition & 0 deletions src/WebauthnOwnerPlugin.sol
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ contract WebauthnOwnerPlugin is BasePlugin, IWebauthnOwnerPlugin, IERC1271 {
}

/// @inheritdoc BasePlugin
/// @param data ABI-encoded array of `PublicKey` elements. It differs from `MultiOwnerPlugin`'s array of `address`.
function _onInstall(bytes calldata data) internal override isNotInitialized(msg.sender) {
(PublicKey[] memory initialOwners) = abi.decode(data, (PublicKey[]));
if (initialOwners.length == 0) revert EmptyOwnersNotAllowed();
Expand Down

0 comments on commit 85e82f4

Please sign in to comment.