-
Notifications
You must be signed in to change notification settings - Fork 18
Release: develop -> main #2936
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
Merged
Merged
Release: develop -> main #2936
Conversation
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
* Add SafeAccount multi-account system - Add SafeAccount and SafeAccountAccess entities - Add SafeAccountService with legacy mode fallback - Add SafeAccountController with CRUD endpoints - Add SafeAccountReadGuard and SafeAccountWriteGuard - Extend User, CustodyBalance, CustodyOrder with safeAccount relations - Add database migration for new tables * feat: renaming * feat: small cleanup * feat: refactoring * feat: refactoring 2 * feat: refactoring 3 * fix: fixed format --------- Co-authored-by: David May <david.leo.may@gmail.com>
Author
|
MEXC and XT were defined as LiquidityManagementSystem enums with full adapter implementations, but were missing from the LiquidityManagementExchanges array. This caused pendingExchangeOrders to not include MEXC/XT transfers, leading to temporary balance dips in FinancialDataLog when funds were transferred between exchanges (e.g., Binance → MEXC). Co-authored-by: TaprootFreak <142087526+TaprootFreak@users.noreply.github.com>
…2937) * feat: add ERC-1271 support for smart contract wallet authentication Smart contract wallets (Gnosis Safe, Argent, EIP-4337 AA wallets) cannot sign messages with ECDSA since they have no private key. ERC-1271 defines a standard interface for contract-based signature verification. Changes: - Add ERC-1271 ABI (isValidSignature function) - Extend verifyEthereumBased() to detect contracts via getCode() - Add verifyErc1271Signature() for on-chain signature verification - Initialize Ethereum provider in CryptoService for RPC calls - Add unit tests for ERC-1271 logic Flow: 1. Check if address has bytecode (is a contract) 2. If contract: call isValidSignature(hash, signature) 3. If EOA: use standard ECDSA recovery (unchanged) * refactor: add logging and document multi-chain limitation for ERC-1271 - Add DfxLogger for debugging ERC-1271 verification - Log successful/failed signature verifications at verbose level - Document that ERC-1271 currently only supports Ethereum Mainnet - Smart contract wallets on other chains (Polygon, Arbitrum, etc.) are not yet supported * fix: handle RPC failures gracefully in ERC-1271 detection If getCode() fails (network error, rate limiting), fall back to EOA verification instead of failing the entire auth flow. This prevents temporary RPC issues from blocking all EVM wallet authentication. - Wrap getCode() in try-catch - Log warning on RPC failure - Fall back to standard EOA verification * style: fix prettier formatting in test file * feat: add multi-chain support for ERC-1271 contract wallet verification - Add optional `blockchain` parameter to SignInDto for specifying which chain to use for ERC-1271 smart contract verification - Initialize EVM providers for all supported chains on startup: Ethereum, Sepolia, Arbitrum, Optimism, Polygon, Base, Gnosis, BSC, Citrea - Pass blockchain parameter through AuthService to CryptoService - Use chain-specific provider for getCode() and isValidSignature() calls When a smart contract wallet signs on Polygon/Arbitrum/etc., the frontend can now pass `blockchain: "Polygon"` to ensure verification uses the correct chain's RPC. * fix: restrict blockchain parameter validation to EVM chains only Change validation from @IsEnum(Blockchain) to @isin(EvmBlockchains) to match the API documentation. Only EVM chains are valid for ERC-1271 smart contract wallet verification. * fix: pass blockchain parameter through companySignIn flow The verifyCompanySignature method was not passing the blockchain parameter to cryptoService.verifySignature, breaking ERC-1271 support for company/KYC-client sign-ins. * feat: refactoring * feat: refactoring 2 --------- Co-authored-by: David May <david.leo.may@gmail.com>
* [DEV-4532] auto set usedRef with recommendation * [DEV-4532] Refactoring * [DEV-4532] test defaultRef as usedRef
davidleomay
approved these changes
Jan 14, 2026
TaprootFreak
approved these changes
Jan 14, 2026
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.
Automatic Release PR
This PR was automatically created after changes were pushed to develop.
Commits: 1 new commit(s)
Checklist