farcasterxyz / contracts

Implementation of the Farcaster contracts
https://www.farcaster.xyz/
MIT License
340 stars 122 forks source link

feat(Signatures): support ERC1271 signatures #286

Closed horsefacts closed 1 year ago

horsefacts commented 1 year ago

Motivation

Users should be able to perform signature-authenticated actions like fid registration/transfer and key registration from smart contract wallets.

Change Summary

Replace ECDSA with OpenZeppelin SignatureChecker in the Signatures helper.

Merge Checklist

Choose all relevant options below by adding an x now or at any time before submitting for review

Additional Context

If this is a relatively large or complex change, provide more details here that will help reviewers.


PR-Codex overview

This PR focuses on replacing the usage of ECDSA library with SignatureChecker in multiple contracts.

Detailed summary

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

github-actions[bot] commented 1 year ago

Coverage after merging horsefacts/erc-1271-signatures into main will be

98.69%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   Bundler.sol100%100%100%100%
   FnameResolver.sol100%100%100%100%
   IdRegistry.sol100%100%100%100%
   KeyRegistry.sol100%100%100%100%
   StorageRent.sol100%100%100%100%
src/lib
   Signatures.sol100%100%100%100%
   TransferHelper.sol0%0%0%0%15, 15, 15, 25–26, 26, 26
   TrustedCaller.sol100%100%100%100%