You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 30, 2024. It is now read-only.
The plugins currently allow execTransaction to be called from any address, not just the 4337 entry point.
(Perhaps this should be fixed by another plugin or some other mechanism?)
This is demonstrated by the (currently) failing test added in #88:
itif("should not allow execTransaction from unrelated address",async()=>{const{ accountAddress, userWallet, provider }=awaitsetupDeployedAccount(ethers.ZeroAddress,0,"0x",);constunrelatedWallet=ethers.Wallet.createRandom(provider);awaitreceiptOf(userWallet.sendTransaction({to: unrelatedWallet.address,value: 100n*oneEther,}),);constaccount=SafeECDSAPlugin__factory.connect(accountAddress,unrelatedWallet,// <-------------------------------------- simply connect with unrelated wallet);constrecipient=ethers.Wallet.createRandom(provider);awaitexpect(receiptOf(account.execTransaction(recipient.address,oneEther,"0x")),// ~~~~~~~~~~~~~~~ <------------------------ and call execTransaction).to.eventually.rejected;// Should be rejected, but it isn'tawaitexpect(provider.getBalance(recipient)).to.eventually.equal(0n);});
The text was updated successfully, but these errors were encountered:
I ran into another stumbling block with my compression plugin (for #30). When calling a plugin method msg.sender is the safe, rather than the caller. That's a big problem for checking that the call comes from a trusted source (ie entryPoint or self). As far as I can tell, this would require changes on the safe side.
The plugins currently allow
execTransaction
to be called from any address, not just the 4337 entry point.(Perhaps this should be fixed by another plugin or some other mechanism?)
This is demonstrated by the (currently) failing test added in #88:
The text was updated successfully, but these errors were encountered: