# Using policies for compliance

> How the deposit, holder and withdrawal hooks map to onboarding, eligibility, screening, payout and integration requirements.

Source: https://docs.trusslabs.io/vaults/compliance/using-policies

Most compliance requirements come down to three questions: who may come in, who may hold, and who may be paid. Each
maps to a vault hook. This page pairs common requirements with the hook that enforces them, and says what still
works for an address the hook refuses. No holder or withdrawal policy exists today; see
[Policies that could be built](https://docs.trusslabs.io/vaults/policies/possible-policies.md).

> **Key points**
>
> - A holder policy keeps a refused address from receiving shares or pending requests, but never from sending them.
> - A withdrawal policy keeps a refused address from redeeming or being paid, but is never asked about the owner of the shares.
> - Settlement asks neither, so one refused holder never blocks a batch for everyone else.
> - A vault has one slot per policy type, so an allowlist and a denylist for holders go in one contract.

## Requirements and hooks

| Requirement | Hook | What it does | What still works for a refused address |
|---|---|---|---|
| Only verified customers | Holder allowlist | No unverified address can control a deposit request, take shares, receive a transfer or take over a request | One removed later keeps its shares and can redeem, unless the withdrawal policy refuses it |
| Only approved channels open deposits | Deposit policy on the caller or owner | Requests must come through your app or approved wallets | Who holds later is the holder policy's job |
| Jurisdiction or investor-type limits | Holder policy | Refuses addresses outside the allowed set | As for verified customers |
| Screening: no new exposure | Holder denylist | A listed address can receive nothing | It can still send its shares away; there is no freeze |
| Screening: no payouts | Withdrawal denylist | A listed address cannot control, claim or be paid by a redemption | Its requests still settle and wait unclaimed. It can send its shares, or open a redemption naming an allowed controller |
| Payouts only to verified addresses | Withdrawal policy on receivers | Every claim and instant withdrawal pays only an approved address | None |
| Closed-loop or omnibus model | Holder policy listing only your custody addresses | Customers never hold shares directly; you keep their ledgers off chain | Your custody addresses are the only holders |
| Shares used in DeFi | Holder policy admitting a protocol and every address it sends shares to | Integrations keep working under an allowlist | A liquidator not admitted makes its liquidation revert |

## Combining the hooks

A holder policy alone stops new exposure but lets a refused address leave with its value. A withdrawal policy alone
stops payouts to an address, but that address can pass its shares to another address and redeem from there. Where
both must hold, bind both. Where a position must also be moved, the vault needs forced transfers. See
[Compliance scenarios](https://docs.trusslabs.io/vaults/compliance/scenarios.md).

## What every design can rely on

- The holder policy is never asked about the sender, a burn, the vault or the fee recipient.
- Settlement never asks the holder or withdrawal policy.
- A withdrawal policy that reverts, or answers anything but a clean `true`, refuses.
- A holder refused by the holder policy cannot cancel a redemption, because the shares would return to it.
- Cancelling a deposit request refunds the USDC to its controller, and no policy is asked.
- A forced transfer asks no policy about the address moved from, so a refused address can always be moved from.

## Where to read more

| Page | What it covers |
|---|---|
| [Vault policies](https://docs.trusslabs.io/vaults/policies/vault-policies.md) | Every function that asks each hook, and about whom |
| [Forced transfers](https://docs.trusslabs.io/vaults/compliance/forced-transfers.md) | Moving a position without the holder's consent |
| [Compliance scenarios](https://docs.trusslabs.io/vaults/compliance/scenarios.md) | Step-by-step responses to common cases |
| [Using vault shares in DeFi](https://docs.trusslabs.io/vaults/overview/vault-shares-in-defi.md) | How shares work as collateral, and what an allowlist must admit |
