GitHub repository
Source code, issues, and release artifacts at stakekit/shield
npm package
TypeScript library: @yieldxyz/shield
What Shield checks
Shield covers EVM, Solana and Tron transactions for the yields it has validators for, including more than 1,600 ERC-4626 vaults across 18 networks. Check coverage per yield with
isSupported(yieldId) or list it with getSupportedYieldIds(); see Shield features for the validator matrix. In the client library, unsupported or unrecognized transactions fail validation rather than passing; server-side, yields without a validator are currently skipped.
Where it runs
Client-side and server-side Shield check different things: client-side validation covers the path from the API to your signing flow, server-side validation covers the API itself. They can run together.

Defense Mode
Defense Mode is Shield running inside the Earn API’s transaction pipeline, so every unsigned transaction the API builds for a supported yield is validated before it is returned. In Monitor mode, the default, a failed validation is logged and the transaction is returned as normal. In Block mode, the transaction is rejected and you receive an error instead. Yield.xyz enables Block for a project after a Monitor period on live traffic. Yields without a registered validator are currently skipped server-side rather than blocked. Defense Mode needs no changes to your integration code. In Block mode, a rejected transaction returns HTTP 500 with the messageTransaction blocked by security validation. The detailed reason is logged server-side and not returned, so Shield’s logic can’t be probed through error messages. If you believe a block is incorrect, contact Yield.xyz with the request timestamp and your project.
What each layer covers
The call
validate returns isValid, a human-readable reason when it fails, optional details, and the detectedType it identified. Your integration decides what to do with a failure: block signing, warn the user, or log it for review.
Why zero trust
Every step between building a transaction and signing it is a point where the transaction could be altered. An attacker who changed an API response could, for example, point a deposit at their own address, and the transaction would still be a valid ERC-4626 call that executes on-chain. Shield checks each transaction independently of the system that built it, so a tampered transaction fails validation before anyone signs it.Next steps
Security overview
How Shield fits into the wider security suite
Shield features
Coverage matrix, validators, decoding, and validation errors
Shield integration
TypeScript library, standalone binaries, and Go/Python/Rust guides

