Skip to the content.

Onchain Bridges - Automated Security Review (all networks: EVM + Solana + Stellar)

Date: 2026-06-17 Reviewer: RWA Bridge engineering (automated static analysis + manual triage) EVM compiler: Solc 0.8.24, optimizer on (200 runs) EVM tools (three independent free/open-source analyzers): Foundry forge lint v1.7.1, Cyfrin aderyn v0.1.9 (63 detectors), solhint (recommended ruleset) Solana tools: cargo audit (RustSec advisory DB) + structural review of the Anchor programs Raw output: aderyn-raw, forge-lint-raw, solhint-raw, solana-cargo-audit

Status: This is an automated source-based review (the same static-analysis tools a professional auditor runs as a first pass) plus manual triage of every flagged item. It is a pre-audit technical review for grant due-diligence. It does not replace a full manual smart-contract audit, which remains required before any mainnet deployment.


0. Why the “free scanner” score looks bad (and why it is the wrong tool)

The public link that returned a low score - solidityscan.com/quickscan/<addr>/etherscan/sepolia

Onchain Bridges’ RWA token (MBT) is a compliance token: owner-gated mint, pause, and an allowlist are the entire point (the Chainlink ACE compliance stack). A rug-pull detector reads every one of those controls as a red flag, so a compliance token will always score poorly on QuickScan. That score measures rug-pull surface, not code security, and is not an appropriate metric for a regulated-asset protocol. The findings below are the code-security view.


1. Scope

This review covers every live network, not just Sepolia. The EVM protocol is a single Solidity codebase deployed across all EVM chains (Sepolia, Polygon Amoy, Sonic, Soneium Minato, Plume), so the source-based EVM analysis below applies identically to every EVM deployment - the same source compiles to the same bytecode on each chain. Per-chain on-chain verification status (which explorer shows verified source for each address) is tracked in ../CONTRACT-VERIFICATION-AUDIT-LEDGER.md. Solana is a separate Rust/Anchor codebase and is reviewed in section 7.

The EVM analysis below was run against the canonical contracts (the 15 verified on Sepolia plus the per-chain equivalents).

Onchain Bridges custom code reviewed here: RWATokenCCT (MBT), CrossChainBridge, YieldIssuer, YieldToken, YTMarket, LendingVault, TLPTFaucet, ERC20MintExtractor.

Third-party audited code (in scope as deployed, but authored + audited by Chainlink), not re-audited here: BurnMintERC677 (TLPT), BurnMintTokenPool (CCIP), PolicyEngine / AllowPolicy / PausePolicy (Chainlink ACE), ERC1967Proxy (OpenZeppelin). A large majority of the deployed bytecode is audited Chainlink / OpenZeppelin library code.

Excluded: the TLPTPaymaster (v1/v2) contracts - AA Phase 2 is feature-flagged off and not live in the public dApp, so they are not part of the live surface this review certifies.


2. Result summary

Severity In live in-scope contracts Notes
Critical 0  
High 0 real 4 detector “High” items, all triaged to false-positive or out-of-scope (s.3)
Medium 0  
Low / Informational code-quality + by-design only centralization (compliance controls), style, gas (s.4)

All three EVM analyzers agree there are no security vulnerabilities:


3. Triage of Aderyn “High” findings (4)

None are exploitable vulnerabilities in the live contracts.

ID Title Where Disposition
H-1 Arbitrary from in transferFrom TLPTPaymaster, TLPTPaymasterV2 Out of scope (paymaster, flag-off). Also the intended ERC-4337 pattern: the paymaster pulls the user’s TLPT after validatePaymasterUserOp authorizes the userOp.
H-2 Contract name reused across files TLPTPaymaster(V2), TLPTFaucet, TLPTSale Not a vulnerability. A code-organization detector (same interface/contract name appears in multiple files). No security impact.
H-3 Uninitialized state variables YieldIssuer currentPeriodId, LendingVault nextPositionId, YTMarket nextListingId, LockVault lockNonce False positive. All four are auto-incrementing counters / nonces that are designed to start at 0. Zero is the correct initial value.
H-4 Locks Ether without withdraw TLPTPaymaster, TLPTPaymasterV2 Out of scope (paymaster). A 4337 paymaster intentionally holds an ETH gas deposit in the EntryPoint; withdrawal is via the EntryPoint, not the contract.

4. Low / informational findings

These are standard static-analysis quality, gas, and style notes. None is a vulnerability.


5. Per-contract posture (live Sepolia)

Contract Critical/High/Med Notes
MBT (RWATokenCCT) 0 2 benign lint items (guarded cast, feed staleness)
CrossChainBridge 0 1 benign lint item (ASCII conversion)
YieldIssuer 0 H-3 = intentional counter
YieldToken (YT-MBT) 0 lint-clean
YTMarket 0 H-3 = intentional counter
LendingVault (Meridian) 0 H-3 = intentional counter
TLPTFaucet 0 cooldown timestamps (benign)
TLPT (BurnMintERC677) n/a Chainlink-audited library code
ACE PolicyEngine/AllowPolicy/PausePolicy n/a Chainlink-audited library code
BurnMintTokenPool n/a Chainlink-audited library code

6. Solana programs (Rust / Anchor)

The Solana side is a separate Rust/Anchor codebase: three programs under solana/programs/ - mbt-defi (820 LoC), mbt-bridge-delivery (650 LoC), mbt-allowlist-hook (331 LoC) - implementing the DeFi logic, the cross-chain delivery receiver, and the Token-2022 transfer-hook compliance gate. Program IDs are in webapp/src/config/solana.ts; source is public in the repo.

Method: cargo audit (RustSec advisory database) on the locked dependency tree + a structural review of access control. (There is no free Slither-equivalent for Solana; cargo-audit + Anchor’s account-constraint model + manual review are the free-tool baseline.)

Findings:

No exploitable findings were identified in our Solana program code by this review. A professional manual audit is still recommended before mainnet, same as the EVM side.


7. Stellar programs (Rust / Soroban)

A separate Rust/Soroban codebase: six contracts (soroban/<crate>/, commit 7d46c531) - sMBT (SEP-41 compliance token), sUSDC (demo stablecoin), LendingVault (Polaris), YieldIssuer, YT, YTMarket. 36/36 native tests green. Reviewed by the Stellar session per the uniform non-EVM standard set here and recorded by session 5.

Verification: Soroban has no explorer “verified source” tab. Each contract’s source builds deterministically (stellar contract build && stellar contract optimize, stellar-cli 26.1.0, target wasm32v1-none) to a WASM whose sha256 matches the on-chain code hash; each was confirmed via stellar contract fetch + sha256. Hashes are in the ledger.

Method: cargo audit + cargo clippy --target wasm32v1-none + per-contract access-control review.

Findings (overall 0 Critical / 0 High / 0 Medium):

No exploitable findings in our Soroban contract code. The EVM-side bridge helper deployed for the Stellar lane (label “StellarLockVault”, address on Amoy) is src/bridge/LockVault.sol, already covered by the EVM analysis in sections 2-5.


8. Conclusion

Across the live EVM protocol contracts, three independent open-source analyzers (forge lint, Aderyn with 63 detectors, and solhint) agree there are no exploitable Critical, High, or Medium findings. Every “High” the tools raised is a false positive (intentional zero-initialized counters), a non-security code-org note, or an out-of-scope paymaster item. Remaining items are by-design compliance centralization plus a standard code-quality / gas backlog. The compliance-heavy machinery (token, pools, ACE policies) is audited Chainlink / OpenZeppelin code.

A full manual audit by a professional firm is still required before mainnet; this review covers the testnet surface for grant due-diligence.

Prepared 2026-06-17 by RWA Bridge session 5. All tools are free / open-source - no paid service used. Reproducible at repo HEAD: forge lint src/, FOUNDRY_EVM_VERSION=cancun aderyn ., npx solhint 'src/**/*.sol', and cd solana && cargo audit.