> For the complete documentation index, see [llms.txt](https://gabriel-j-shapiro.gitbook.io/metalex-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gabriel-j-shapiro.gitbook.io/metalex-docs/protocol-how-to-guides/restrict-transfers.md).

# Restrict cyberSCRIP transfers

cyberSCRIP is an ERC-20. You can restrict it with transfer-restriction hooks, and a cyberCORP can hold (and later renounce) compliance powers.

## Transfer-restriction hooks

Hooks implement `ITransferRestrictionHook`; CyberScrip runs every installed hook on each transfer. See [Hooks](/metalex-docs/protocol-reference/hooks.md).

Hooks are set initially when the scrip is deployed (`typeRestrictionHooks` argument of `deployCyberScrip`) and can be changed afterward through the IssuanceManager:

```solidity
// at deploy time
address cyberScrip = IIssuanceManager(issuanceManager).deployCyberScrip(
    certAddress,
    typeRestrictionHooks,   // ITransferRestrictionHook[]
    /* ...remaining args... */
);
```

On the `CyberCertPrinter` itself, the IssuanceManager can also set hooks for cyberCERT transfers: `setRestrictionHook(certAddress, id, hook)` and `setGlobalRestrictionHook(certAddress, hook)`.

Implementations in [`src/hooks/transfer/`](https://github.com/MetaLex-Tech/cybercorps-contracts/tree/develop/src/hooks/transfer): `WhitelistTransferHook` (allow only whitelisted addresses) and `ToggleTransferHook` (per-token on/off). Consult each contract's source for its admin functions.

## Compliance powers

A CyberScrip is deployed with three optional powers — the last three booleans of `deployCyberScrip`:

```solidity
    /* ... */ true /*enableForceTransfer*/, true /*enableForceBurn*/, true /*enableFreeze*/
```

There is **no blocklist** — only force transfer, force burn, and freeze.

| Power          | Exercised via (on CyberScrip)     |
| -------------- | --------------------------------- |
| Force transfer | `forceTransfer(from, to, amount)` |
| Force burn     | `forceBurn(account, amount)`      |
| Freeze         | `setFrozen(account, isFrozen)`    |

These functions are `onlyIssuanceManager`, so they are driven through the cyberCORP's IssuanceManager.

## Permanently disabling a power

Each power has a one-way disable on CyberScrip — `disableForceTransfer()`, `disableForceBurn()`, `disableFreeze()`. Once disabled, a power cannot be re-enabled; exercising it afterward reverts `ComplianceFeatureDisabled`. Like the exercise functions, the disables are `onlyIssuanceManager`.

## Holder cap

`CyberScrip.setMaxHolderCount(n)` caps the holder count (`0` = unlimited); transfers that would exceed it revert `HolderLimitExceeded`.

## Related

* [CyberScrip](/metalex-docs/protocol-reference/contracts/cyberscrip.md), [Hooks](/metalex-docs/protocol-reference/hooks.md).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://gabriel-j-shapiro.gitbook.io/metalex-docs/protocol-how-to-guides/restrict-transfers.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
