Intent-based lending reshapes DeFi’s threat model. Learn about solver risks, off-chain execution flaws and new protocol attack surfaces.

Pooled lending defined DeFi’s first era. In early lending and borrowing protocols, users deposited assets into shared vaults while borrowers drew over-collateralized loans, with interest rates adjusting algorithmically. Settlement was synchronous and fully on-chain. The model was simple and liquid, but capital often sat idle, risk was socialized across participants, and pricing remained constrained by governance decisions and utilization curves.
Intent-based lending replaces pooled capital with signed constraints. Instead of depositing funds, users sign off-chain EIP-712 intents specifying principal, rate bounds, duration, collateral, LTV limits, and execution conditions. Borrowers submit symmetric intents. A competitive solver network matches these off-chain and submits a single atomic on-chain settlement transaction that transfers assets directly between counterparties or into isolated CREATE2 loan contracts.
Capital remains in user custody until settlement. Terms are fixed at the constraint level. Risk is isolated per match.
But this shift moves discovery, matching, and routing off-chain. Execution becomes asynchronous. Solvers become economically powerful actors. Oracle freshness, nonce management, and settlement-time validation become critical security boundaries.
The attack surface is no longer pool accounting, it is the intent-to-settlement pipeline.
This guide dissects that pipeline in detail, including architecture, exploit vectors, and production-grade mitigations for teams building or auditing intent-based lending systems.
At its core, an intent is a signed EIP-712 message that encodes the user’s desired final state rather than a rigid transaction path. A representative LendIntent struct (generalized from current high-performance implementations) looks like this:
1struct LendIntent {
2 address signer;
3 uint256 amount; // principal to lend
4 address asset; // e.g., USDC
5 uint256 minRateBps; // annualized fixed or variable flag
6 uint256 durationSeconds;
7 address collateralAsset;
8 uint256 maxLTVBps;
9 uint256 nonce; // per-signer replay protection
10 uint256 deadline; // absolute Unix timestamp
11 bytes32 conditionsHash; // keccak256 of oracle requirements, whitelists, hooks, chainId, minFillAmount, maxSlippageBps
12 uint256 minFillAmount;
13 uint256 maxSlippageBps;
14}The borrower signs a symmetric BorrowIntent. Both are broadcast to a public or permissioned solver network. Solvers high-performance Rust or Go binaries run by professional market makers or specialized entities, perform the following off-chain computation:
DOMAIN_SEPARATOR (which includes chainId and contract version).eth_call bundles to check current oracle medians, LTV feasibility, rate overlap, and hook execution.The winning solver submits a single atomic on-chain fulfill transaction that:
_hashTypedDataV4.lastUpdate + MAX_STALENESS >= block.timestamp, typically ≤ 300 seconds).SafeERC20 transfers with strict minFillAmount and post-execution slippage recalculation.CREATE2 (salt = keccak of intent hash) containing deterministic liquidation logic, repayment schedules, and custom hooks.
This flow achieves several breakthroughs impossible in pooled designs:
The architecture deliberately keeps asset custody with users until the final atomic settlement. This is the source of both its power and its novel security challenges.
The shift from synchronous pooled accounting to asynchronous off-chain matching followed by on-chain settlement introduces new trust boundaries and timing windows that do not exist in traditional pooled protocols. Because discovery and matching occur off-chain while final execution occurs on-chain, the system depends on signatures, solvers, and delayed settlement steps. This separation creates new attack surfaces. Below are the primary vectors, each illustrated with concrete failure modes, Mermaid attack sequences, and code patterns observed in early implementations.
Solvers control match selection and settlement submission with no native on-chain slashing in most designs.
A compromised solver (key theft, RCE on cloud infrastructure, or insider) can:
Exploit Example
Solver sees $10M borrow intent. Submits fake lend intent from controlled address, settles, then immediately liquidates after price movement, pocketing fees while locking borrower collateral.

Vulnerable Pattern (no bond, no challenge window)
1function fulfill(LendIntent calldata i, bytes calldata sig) external {
2 address recovered = _hashTypedDataV4(hashIntent(i)).recover(sig);
3 require(recovered == i.signer);
4 // No solver bond or dispute period
5 transferAssets(...);
6}
Intent discovery occurs off-chain before any transaction hits the mempool. Attackers monitor public relays or run their own solver.
Upon seeing a large borrow intent against volatile collateral, the attacker:
The window spans minutes far longer than transaction-level MEV.

Assets remain in user custody until fulfillment. Borrowers can flashloan-pump collateral valuation, partially sell on external venues, or double-pledge across protocols.
Settlement succeeds on inflated value, immediate bad debt post-reversion.

Vulnerable Check
1uint256 price = oracle.latestAnswer(); // snapshot only at fulfill
2require(collateralBalance * price * 10000 / debt >= intent.maxLTVBps);Intents lock in price constraints at the time of signing, while settlement happens later. If lastUpdate + MAX_STALENESS isn’t enforced, trades can settle using outdated prices, leading to bad debt or unfair liquidations. In multi-oracle setups without per-source freshness checks, malicious solvers can deliberately route through the stalest oracle to exploit pricing gaps.

Vulnerable check:
1uint256 price = oracle.latestAnswer(); // no timestamp
2require(price >= intent.minPrice);Users sign exactly 100 000 USDC at exactly 8.5 %. Solver delivers 98 400 USDC after routing fees and impact. Without strict on-chain enforcement after all hooks, users suffer silent degradation and dust griefing.

Vulnerable Enforcement
1require(receivedAmount >= intent.amount); // no minFill, no post-hook slippage bufferRaw keccak256 hashes, missing chainId, or nonce marking before external calls enable replay across forks, ECDSA malleability, and reentrancy drains.

Vulnerable Pattern
1bytes32 hash = keccak256(abi.encode(intent)); // no domain separator
2address signer = ECDSA.recover(hash, sig); // malleable s-value
3require(!usedNonces[signer][intent.nonce]);
4usedNonces[signer][intent.nonce] = true; // BEFORE transfer → reentrancy windowBecause intents are created off-chain without mandatory upfront on-chain validation or escrow, a malicious actor can flood the solver network with thousands of fake or non-viable intents. These intents may reference wallets that hold insufficient balances or have never approved the protocol for transferFrom. Even if solvers perform off-chain balance/allowance checks, the repeated evaluation and discarding of junk intents degrades matching efficiency, inflates operational costs for honest solvers, and can slow or stall legitimate matching for all users.

A second DoS variant, an attacker intentionally matches a borrower's intent as the lender, then front-runs the settlement transaction by withdrawing or spending the promised funds beforehand. The on-chain transferFrom reverts, the match fails, and the borrower’s intent remains unfulfilled. Repeating this griefing across multiple matches can effectively halt protocol operation without direct profit to the attacker, pure disruption at the settlement layer.

Vulnerable Off-Chain Solver Pseudocode (Rust-style)
1// VULNERABLE — no rate-limiting or proof-of-funds requirement
2fn process_intent(intent: Intent) -> bool {
3 if !verify_signature(&intent) { return false; }
4 // No mandatory pre-check bond or reservation tx
5 if simulate_fulfill(&intent).is_ok() {
6 submit_onchain(); // but funds may be gone by then
7 }
8 true
9}updatedAt checks (≤ 300 s). Timestamp-weighted median for multi-oracle.SafeERC20.safeTransferFrom + post-all-hooks slippage buffer (value * (10000 - maxSlippageBps)) / 10000.Immediate 2026 Audit Checklist
nonReentrant?minFillAmount and maxSlippageBps validated after every hook?Intent-based lending replaces pooled liquidity with constraint-based execution, unlocking capital efficiency and isolated risk, but shifting critical trust boundaries off-chain. The security model is no longer about pool accounting, it is about signatures, solver incentives, oracle freshness, and settlement-time validation. Every exploit vector stems from that asynchronous gap between intent and execution. Teams building in this paradigm must treat the intent-to-settlement pipeline as a first-class security surface. In the next cycle of DeFi, failures won’t come from utilization curves, they will come from improperly secured matching engines and settlement logic.
Contents


From day-zero risk mapping to exchange-ready audits — QuillAudits helps projects grow with confidence. Smart contracts, dApps, infrastructure, compliance — secured end-to-end.