feat: multi-asset deposit support via shared allowlist [NF-05] - #129
Merged
wumibals merged 4 commits intoJul 17, 2026
Merged
Conversation
|
@AbdulmujibOladayo is attempting to deploy a commit to the wumibals' projects Team on Vercel. A member of the Team first needs to authorize it. |
AbdulmujibOladayo
force-pushed
the
feat/nf-05-multi-asset-deposit-allowlist
branch
from
July 17, 2026 13:51
27dd1b4 to
6ea2638
Compare
6 tasks
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
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.
Summary
Wires
shared::allowlistintoVaultRouteras a deposit-asset registry, enabling multi-asset deposits (e.g. USDC + EURC) while keeping per-asset balances independent.Changes
contracts/vault_router/Cargo.tomlshared = { path = "../shared" }dependencycontracts/vault_router/src/error.rsAssetNotAllowed = 4contracts/vault_router/src/lib.rsinitialize()now takesinitial_assets: Vec<Address>and callsshared::allowlist::init_allowlist()deposit(user, tier, asset, amount)— validatesassetagainst the allowlist before forwarding; rejects withAssetNotAllowedfor unlisted assetswithdraw(user, tier, asset)andearly_exit(user, tier, asset)— asset-aware pass-throughadd_deposit_asset(admin, asset)/remove_deposit_asset(admin, asset)— admin-gated allowlist managementis_deposit_asset_allowed(asset) -> bool— read-only queryposition(user, tier, asset)— per-asset position queryTests
test_allowed_asset_deposit_succeedstest_non_allowed_asset_deposit_rejected(#[should_panic])test_add_then_deposit_second_asset— adds EURC, verifies deposit succeedstest_remove_asset_blocks_future_depositstest_per_asset_position_is_independent— USDC and EURC positions are independentAcceptance Criteria
shared::allowlistis now imported and has active call sitesAssetNotAllowedinitial_assetsininitialize)closes #80