Introduction

Hi, I'm cardene, a software engineer and technical writer focused on blockchain and AI.

I've also authored Japanese technical books on specification-driven development with LLMs and decentralized application (DApp) development.

I also build and publish a variety of tools, libraries, and open-source projects.

This article covers ERC7518, a proposal that uses semi-fungible partitions to apply different compliance controls to different asset classes.

This explanation translates, summarizes, and expands on the following specification.

I have also written about other EIPs, BIPs, SLIPs, CAIPs, ENSIPs, RFCs, and ACPs.

Overview

This security token standard extends ERC1155 to support the management of tokenized real-world assets, such as real estate and funds, under applicable securities requirements. The original ERC1155 is a multi-token standard that manages multiple token types in one contract, but does not itself provide all the functionality required for security tokens.

For more about ERC1155, see the following article.

[ERC1155] An Introduction to the ERC1155 Multi-Token Standard

The extension introduces the concept of a partition. Each tokenId represents a partition, within which the associated rights and rules can be managed separately. Different partitions within the same contract can therefore have distinct rights, restrictions, and operational rules.

The extension focuses on semi-fungible tokens. These tokens can be treated as interchangeable units within a particular class while remaining distinguishable from other classes. For example, a game might distinguish swords, shields, and armor, with multiple interchangeable items of each type.

The standard also defines interfaces for functionality commonly required by security tokens.

  • Token locking Token locking prevents transfers of specified token amounts for a defined period. This supports requirements such as vesting and lock-up periods during which tokens cannot be sold.

  • Forced transfers (forceTransfer) A forced transfer allows an authorized issuer or administrator, rather than the holder, to move tokens to another address. Possible uses include recovering assets after private-key loss or transferring assets in response to compliance requirements.

  • Address freezing Address freezing prohibits specified wallet addresses from sending or receiving tokens, subject to the implementation's rules. It supports controls for requirements such as anti-money-laundering measures and sanctions restrictions.

  • Payout mechanisms Payouts distribute payments such as dividends, rental income, or interest to token holders. The interface supports payments to individual addresses and batch payments.

    • Dynamic compliance management Compliance management involves checking and maintaining investor eligibility and applicable regulatory conditions. Off-chain vouchers act as attestations issued by external systems, such as KYC/AML services or securities firms, that can inform whether a token transfer is permitted. This provides flexibility when rules change.

By defining these features through common interfaces, this ERC1155 extension aims to facilitate an interoperable security token ecosystem with configurable compliance controls.

Motivation

Demand for security tokens and real-world assets

Tokenization of real-world assets such as real estate, funds, and bonds is increasingly being explored. Many such tokens may be legally classified as securities. Being transferable digital assets alone is not enough: their management must account for applicable requirements, including lock-up periods, investor eligibility, and distribution of payments.

Existing token standards alone present the following challenges.

  • Managing multiple classes or categories with different properties flexibly within one contract.
  • Providing standardized mechanisms for detailed compliance rules, such as restrictions based on investor eligibility, geography, or regulatory categories.

This security token standard addresses those challenges by extending ERC1155 with security-token-specific functionality.

Introducing partitions through an ERC1155 extension

The extension uses partitions to support a semi-fungible design within one contract, combining fungibility within each class with distinct treatment across classes.

Each tokenId is treated as a separate partition. Possible uses include the following.

  • Dividing a real estate asset into partitions by floor, offering period, or investor category.
  • Defining separate partitions for share classes with different rights, such as ordinary shares, preferred shares, or regional classes.

Although the partitions share one contract, each can represent a separate category with its own rules and rights. This allows complex real-world assets to be managed together without deploying separate contracts for every class.

Supporting complex real-world assets

image.png https://eips.ethereum.org/EIPS/eip-7518

The ERC1155 security token extension is designed with assets such as the following in mind.

  • Real estate Rights and value can differ by floor or individual unit as well as by property.
  • Funds and financial instruments Different share classes may have different fees, distribution policies, or investment exposures.

Representing all of these interests as one homogeneous token may not accurately reflect the underlying structure. Conversely, deploying a separate contract for every category can complicate management. Partitions address both problems by providing a flexible representation within one standardized contract.

Additional functionality required by security tokens

Beyond partitions, the ERC1155 security token extension standardizes functions useful for operating security tokens in practice.

Representative examples follow.

  • Token locking Prevent sales or transfers during a specified period, such as a vesting or lock-up period. This allows issuance terms and contractual restrictions to be represented on-chain.

  • Forced transfers (forceTransfer) Authorized issuers or administrators can transfer tokens to another address when ordinary transfers are unavailable due to key loss, or when recovery is required because of a compliance violation. Such recovery mechanisms may support investor protection and legal compliance.

  • Address freezing If a regulator or compliance team needs to restrict a particular address, freezing can prohibit that address from sending or receiving tokens. This supports anti-money-laundering and sanctions controls.

  • Payout mechanisms Distribute rental income, dividends, interest, or other payments to token holders on a regular or ad hoc basis. The interface supports both individual and batch payments.

  • Dynamic compliance management Regulatory requirements and investor eligibility may change over time. Using off-chain vouchers, an external compliance system can issue an attestation that an investor is eligible for a transaction under specified conditions, and the contract can use that attestation when allowing or rejecting a transfer. This can facilitate adaptation to changing requirements without redeploying the token contract.

Improving interoperability through standardization

The ERC1155 security token extension aims to define common interfaces for these functions. The intended benefits include the following.

  • Issuers and service providers can develop integrations around common interfaces.
  • Wallets, custody services, and exchanges can use a common integration to support multiple security tokens, subject to their compliance requirements.
  • Compliance services and KYC/AML providers can integrate with applications using a consistent interface.

The goal is to facilitate an interoperable security token ecosystem rather than requiring a separate bespoke implementation for each project.

Specification

Interfaces

IERC7518.sol
pragma solidity ^0.8.0;

interface IERC7518 is IERC1155, IERC165{
  event TokensLocked(address indexed account, uint indexed id, uint256 amount, uint256 releaseTime);

  event TokenUnlocked(address indexed account, uint indexed id);

  event TokensForceTransferred(address indexed from, address indexed to, uint indexed id, uint256 amount);

  event AddressFrozen(address indexed account, bytes data);

  event AddressUnfrozen(address indexed account, bytes data);

  // Emitted when the transferability of tokens with a specific ID is restricted.
  event TransferRestricted(uint indexed id);

  // Emitted when the transferability restriction of tokens with a specific ID is removed.
  event TransferRestrictionRemoved(uint indexed id);

  event PayoutDelivered(address indexed from, address indexed to, uint256 amount);

  /**
  * @dev Retrieves the transferable balance of tokens for the specified account and ID.
  * @param account The address of the account.
  * @param id The token ID.
  * @return The transferable balance of tokens.
  */
  function transferableBalance(address account, uint id) external view returns (uint);

  /**
  * @dev Retrieves the locked balance of tokens for the specified account and ID.
  * @param account The address of the account.
  * @param id The token ID.
  * @return The locked balance of tokens.
  */
  function lockedBalanceOf(address account, uint256 id) external view returns (uint256);

  /**
  * @dev Restricts the transferability of tokens with the specified ID.
  * @param id The token ID.
  * @return A boolean value indicating whether the operation was successful.
  */
  function restrictTransfer(uint id) external returns (bool);

  /**
  * @dev Removes the transferability restriction of tokens with the specified ID.
  * @param id The token ID.
  * @return A boolean value indicating whether the operation was successful.
  */
  function removeRestriction(uint id) external returns (bool);

  /**
  * @notice Transfers `_value` amount of an `_id` from the `_from` address to the `_to` address specified (with safety call).
  * @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard).

  * After the above conditions are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call `onERC1155Received` on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard).  
  * @param _from    Source address
  * @param _to      Target address
  * @param _id      ID of the token type
  * @param _value   Transfer amount
  * @param _data    Additional data with no specified format, MUST be sent unaltered in call to `onERC1155Received` on `_to`
  */
  function safeTransferFrom(address _from, address _to, uint256 _id, uint256 _value, bytes calldata _data) override external;

  /**
  * @dev Checks if a transfer is allowed.
  * @param from The address to transfer tokens from.
  * @param to The address to transfer tokens to.
  * @param id The token ID.
  * @param amount The amount of tokens to transfer.
  * @param data Additional data related to the transfer.
  * @return status A boolean value indicating whether the transfer is allowed.
  */
  function canTransfer(address from, address to, uint id, uint amount, bytes calldata data) external view returns (bool status);

  /**
  * @dev lock token till a particular block time.
  * @param account The address of the account for which tokens will be locked.
  * @param id The token ID.
  * @param amount The amount of tokens to be locked for the account.
  * @param releaseTime The timestamp indicating when the locked tokens can be released.
  * @return bool Returns true if the tokens are successfully locked, otherwise false.
  */
  function lockTokens(address account, uint id, uint256 amount, uint256 releaseTime) external returns (bool);

  /**
  * @dev Unlocks tokens that have crossed the release time for a specific account and id.
  * @param account The address of the account to unlock tokens for.
  * @param id The token ID.
  */
  function unlockToken(address account, uint256 id) external;

  /**
  * @dev Force transfer in cases like recovery of tokens.
  * @param from The address to transfer tokens from.
  * @param to The address to transfer tokens to.
  * @param id The token ID.
  * @param amount The amount of tokens to transfer.
  * @param data Additional data related to the transfer.
  * @return A boolean value indicating whether the operation was successful.
  */
  function forceTransfer(address from, address to, uint256 id, uint256 amount, bytes memory data) external returns (bool);

  /**
  * @dev Freezes specified address.
  * @param account The address to be frozen.
  * @param data Additional data related to the freeze operation.
  * @return A boolean value indicating whether the operation was successful.
  */
  function freezeAddress(address account, bytes calldata data) external returns (bool);

  /**
  * @dev Unfreezes specified address.
  * @param account The address to be unfrozen.
  * @param data Additional data related to the unfreeze operation.
  * @return A boolean value indicating whether the operation was successful.
  */
  function unFreeze(address account, bytes memory data) external returns (bool);

  /**
  * @dev Sends payout to single address with corresponding amounts.
  * @param to address to send the payouts to.
  * @param amount amount representing the payouts to be sent.
  * @return A boolean indicating whether the batch payouts were successful.
  */* 
  function payout(address calldata to, uint256 calldata amount) public returns (bool);

  /**
  * @dev Sends batch payouts to multiple addresses with corresponding amounts.
  * @param to An array of addresses to send the payouts to.
  * @param amount An array of amounts representing the payouts to be sent.
  * @return A boolean indicating whether the batch payouts were successful.
  */
  function batchPayout(address[] calldata to, uint256[] calldata amount) public returns (bool);
}

Events

TokensLocked
javascript
event TokensLocked(address indexed account, uint indexed id, uint256 amount, uint256 releaseTime);

Event emitted when tokens are locked. Indicates that a specified amount of the token with the given id has been locked for an account. The locked tokens cannot be transferred through ordinary transfer operations until releaseTime is reached. The event helps external systems track and display the locking state.

Parameters

  • account Address whose tokens are locked.
  • id ID of the token being locked.
  • amount Amount of tokens locked.
  • releaseTime Unlock time (Unix timestamp).
TokenUnlocked
javascript
event TokenUnlocked(address indexed account, uint indexed id);

Event emitted when locked tokens are unlocked. Indicates that the release time has been reached and the tokens have been successfully unlocked. External systems can use this event to detect the state change.

Parameters

  • account Address whose tokens are unlocked.
  • id ID of the unlocked token.
TokensForceTransferred
javascript
event TokensForceTransferred(address indexed from, address indexed to, uint indexed id, uint256 amount);

Event emitted when a forced transfer is executed. Indicates that an authorized forced transfer has bypassed applicable ordinary transfer checks or restrictions. The mechanism is intended for special cases such as private-key loss or compliance violations.

Parameters

  • from Source address.
  • to Destination address.
  • id Token ID.
  • amount Amount of tokens transferred.
AddressFrozen
javascript
event AddressFrozen(address indexed account, bytes data);

Event emitted when an address is frozen. Indicates that the specified address has been frozen for compliance or another applicable reason. Ordinary token transfers and payouts involving that address are restricted as specified by the implementation.

Parameters

  • account Frozen address.
  • data Additional information about the freeze.
AddressUnfrozen
javascript
event AddressUnfrozen(address indexed account, bytes data);

Event emitted when an address is unfrozen. Indicates that the freeze has been removed. The data field can carry additional information for external systems tracking the unfreeze operation.

Parameters

  • account Address to unfreeze.
  • data Additional information about the unfreeze.
TransferRestricted
javascript
event TransferRestricted(uint indexed id);

Event emitted when transfers of a particular token ID are restricted. Indicates that a transfer restriction has been applied to the specified token ID. It can represent restrictions during a regulatory period or restrictions applicable to a particular partition.

Parameters

  • id Token ID subject to the transfer restriction.
TransferRestrictionRemoved
javascript
event TransferRestrictionRemoved(uint indexed id);

Event emitted when a transfer restriction on a particular token ID is removed. Indicates that the restriction previously applied to that token ID has been removed. Possible reasons include expiration of a restriction period or a change in regulatory requirements.

Parameters

  • id Token ID whose transfer restriction was removed.
PayoutDelivered
javascript
event PayoutDelivered(address indexed from, address indexed to, uint256 amount);

Event emitted when a payout is executed. Indicates that a payout has been delivered from the issuer or other funding address to a recipient. It can be used for dividends, interest, or income distributions.

Parameters

  • from Payer address.
  • to Recipient address.
  • amount Amount paid.

Functions

transferableBalance
javascript
function transferableBalance(address account, uint id) external view returns (uint);

Retrieves the token balance available for transfer. Returns balanceOf(account, id) minus the locked amount reported by lockedBalanceOf(account, id). This reports the unlocked balance. Whether a specific transfer can proceed also depends on other compliance restrictions.

Parameters

  • account Account address.
  • id Token ID.

Return value

  • uint Transferable token amount.
lockedBalanceOf
javascript
function lockedBalanceOf(address account, uint256 id) external view returns (uint256);

Retrieves the locked token balance of the specified account. Returns the amount made nontransferable by the locking mechanism. This is useful for transfer validation, interface displays, and external audits.

Parameters

  • account Account address.
  • id Token ID.

Return value

  • uint256 Locked token amount.
restrictTransfer
javascript
function restrictTransfer(uint id) external returns (bool);

Restricts transfers of the specified token ID. Applies a transfer restriction to id. The standard recommends emitting TransferRestricted on success. This can be used to manage restricted periods or nontransferable securities partitions.

Parameters

  • id Token ID to restrict.

Return value

  • bool Whether the operation succeeded.
removeRestriction
javascript
function removeRestriction(uint id) external returns (bool);

Removes the transfer restriction on the specified token ID. Removes the restriction applied to id. The function must revert if no restriction exists. Emitting TransferRestrictionRemoved is recommended upon removal.

Parameters

  • id Token ID whose restriction is to be removed.

Return value

  • bool Whether the operation succeeded.
safeTransferFrom
javascript
function safeTransferFrom(address _from, address _to, uint256 _id, uint256 _value, bytes calldata _data) external;

Transfers tokens using the safe transfer mechanism. Transfers tokens according to ERC1155 safe transfer rules. The implementation checks canTransfer before transferring, taking account of freezes, restricted IDs, locked balances, and other requirements. If the recipient is a smart contract, the appropriate onERC1155Received callback must be invoked.

Parameters

  • _from Source address.
  • _to Destination address.
  • _id Token ID.
  • _value Transfer amount.
  • _data Additional data.
canTransfer
javascript
function canTransfer(address from, address to, uint id, uint amount, bytes calldata data) external view returns (bool status);

Determines whether a particular token transfer is permitted. Checks conditions such as address freezes, transfer restrictions, and locked balances. The implementation may also consult an external compliance contract.

Parameters

  • from Transfer source address.
  • to Transfer destination address.
  • id Token ID.
  • amount Transfer amount.
  • data Additional data.

Return value

  • status Whether the transfer is permitted.
lockTokens
javascript
function lockTokens(address account, uint id, uint256 amount, uint256 releaseTime) external returns (bool);

Locks tokens until a specified time. Locks a specified amount of an account's tokens until releaseTime. The operation reverts if the amount to lock exceeds the available balance. Emitting TokensLocked is recommended after a successful lock.

Parameters

  • account Address whose tokens will be locked.
  • id Token ID.
  • amount Amount to lock.
  • releaseTime Release time.

Return value

  • bool Whether locking succeeded.
unlockToken
javascript
function unlockToken(address account, uint256 id) external;

Unlocks tokens whose release conditions have been satisfied. Unlocks the relevant token amounts for which releaseTime <= block.timestamp. The original description recommends reverting when no tokens can be unlocked. Emit TokenUnlocked when tokens are unlocked.

Parameters

  • account Address whose tokens will be unlocked.
  • id Token ID.
forceTransfer
javascript
function forceTransfer(address from, address to, uint256 id, uint256 amount, bytes memory data) external returns (bool);

Forcibly transfers tokens from a frozen address. This is a special transfer operation that bypasses applicable ordinary transfer restrictions. Under the described rule, the function reverts unless from is frozen. Only an appropriately authorized administrator must be able to execute the operation. Emitting TokensForceTransferred is recommended after execution.

Parameters

  • from Source address.
  • to Destination address.
  • id Token ID.
  • amount Transfer amount.
  • data Additional data.

Return value

  • bool Whether the operation succeeded.
freezeAddress
javascript
function freezeAddress(address account, bytes calldata data) external returns (bool);

Freezes a specified address. A frozen address is subject to restrictions on transfers and payouts. Appropriate access control is required. Emit AddressFrozen on success.

Parameters

  • account Address to freeze.
  • data Additional data, such as the reason for freezing.

Return value

  • bool Whether the operation succeeded.
unFreeze
javascript
function unFreeze(address account, bytes memory data) external returns (bool);

Removes a freeze from a specified address. The operation requires administrative authorization. Emit AddressUnfrozen to notify external systems of the state change.

Parameters

  • account Address to unfreeze.
  • data Additional information.

Return value

  • bool Whether the operation succeeded.
payout
javascript
function payout(address to, uint256 amount) external returns (bool);

Delivers a payout to an individual address. Processes payments such as dividends or income distributions. The operation reverts when the recipient is frozen. The issuer or payment source must also have sufficient funds. Emit PayoutDelivered on success.

Parameters

  • to Recipient address.
  • amount Payment amount.

Return value

  • bool Whether the operation succeeded.
batchPayout
javascript
function batchPayout(address[] calldata to, uint256[] calldata amount) external returns (bool);

Delivers payouts to multiple addresses in a batch. Used to distribute payments, such as dividends or rewards, efficiently to numerous addresses. The operation reverts if a recipient is frozen, according to the described compliance rule. Checking the issuer's available funds is recommended.

Parameters

  • to Array of payout recipient addresses.
  • amount Array of payment amounts.

Return value

  • bool Whether the operation succeeded.

Interoperability

ERC7518 aims to provide security token functionality while interoperating with existing token standards such as ERC20, ERC721, and ERC1155. The interoperability interface standardizes wrapping existing tokens into ERC7518 tokens and unwrapping them back into the original assets when permitted.

This mechanism can integrate existing assets into the ERC7518 partition model, enabling consistent management, compliance controls, and additional functionality across different Ethereum assets.

IERC1155Wrapper.sol
interface IERC1155Wrapper is IERC7518 {

/**
@dev Emitted when a new wrapped token address is added to the set.
@param wrappedTokenAddress The address of the wrapped token that was added.
*/
event WrappedTokenAddressSet(address wrappedTokenAddress);

/**
@dev Emitted when tokens are wrapped.
@param The ERC-1155 token ID of the wrapped tokens.
@param amount The amount of tokens that were wrapped.
*/
event TokensWrapped(uint indexed id, uint256 amount);

/**
@dev Emitted when tokens are unwrapped.
@param wrappedTokenId Is the ERC-1155 token ID of the wrapped tokens.
@param amount The amount of tokens that were unwrapped.
*/
event TokensUnwrapped(uint indexed wrappedTokenId, uint256 amount);

/**
* @dev Sets the wrapped token address and logic for deciding partitions.
* @param wrappedTokenAddress The address of the wrapped token contract.
* @return A boolean value indicating whether the operation was successful.
*/
function setWrappedToken(address token) external returns (bool);

/**
* @dev Wraps the specified amount of tokens by depositing the original tokens and receiving new standard tokens.
* @param amount The amount of tokens to wrap.
* @param data Additional data for partition.
* @return A boolean value indicating whether the operation was successful.
*/
function wrapToken(uint256 amount, bytes calldata data) external returns (bool);

/**
* @notice Wraps a specified amount of tokens from a given partition into the main balance.
* @dev This function allows users to convert tokens from a specific partition back to the main balance,making them fungible with tokens from other partitions.
* @param partitionId The unique identifier of the partition from which tokens will be wrapped.
* @param id The unique identifier of the token.
* @param amount The amount of tokens to be wrapped from the specified partition.
* @param data Additional data that may be used to handle the wrap process (optional).
* @return success A boolean indicating whether the wrapping operation was successful or not.
*/

function wrapTokenFromPartition(bytes32 partitionId, uint256 id, uint256 amount, bytes calldata data) external returns (bool);
/**
* @dev Unwraps the specified amount of wrapped tokens by depositing the current tokens and receiving the original tokens.
* @param wrappedTokenId internal partition id.
* @param amount The amount of wrapped tokens to unwrap.
* @param data Additional data for partition.
* @return A boolean value indicating whether the operation was successful.
*/
function unwrapToken(uint256 wrappedTokenId, uint256 amount, bytes calldata data) external returns (bool);

/**
* @dev Retrieves the balance of wrapped tokens for the specified account and ID.
* @param account The address of the account.
* @param id The token ID.
* @param data Additional data for partition.
* @return The balance of wrapped tokens.
*/
function wrappedBalanceOf(address account, uint256 id, bytes calldata data) external view returns (uint256);

/**
* @dev Retrieves the balance of original tokens for the specified account and ID.
* @param account The address of the account.
* @param id The token ID.
* @param data Additional data for partition.
* @return The balance of original tokens.
*/
function originalBalanceOf(address account, uint256 id, bytes calldata data) external view returns (uint256);
}

Events

WrappedTokenAddressSet
javascript
event WrappedTokenAddressSet(address wrappedTokenAddress);

Event emitted when a new underlying token address is registered for wrapping. Indicates that the contract address of an underlying token has been configured for wrapping. Since the extension may support multiple wrapped assets, external systems can use this event to detect changes in the underlying asset configuration.

Parameters

  • wrappedTokenAddress
    • Newly registered underlying token address.
TokensWrapped
javascript
event TokensWrapped(uint indexed id, uint256 amount);

Event emitted when tokens are wrapped. Indicates that a user has deposited underlying tokens and the corresponding ERC7518 tokens have been minted. The event supports tracking the wrapped token amounts.

Parameters

  • id
    • ID of the wrapped ERC1155-style token.
  • amount
    • Amount wrapped.
TokensUnwrapped
javascript
event TokensUnwrapped(uint indexed wrappedTokenId, uint256 amount);

Event emitted when tokens are unwrapped. Indicates that ERC7518 tokens have been burned and their underlying tokens returned to the user. This supports transparent tracking of unwrapping operations.

Parameters

  • wrappedTokenId
    • Internal partition ID associated with the wrapped token.
  • amount
    • Amount unwrapped.

Functions

setWrappedToken
javascript
function setWrappedToken(address token) external returns (bool);

Configures the underlying token address for wrapping. Registers the contract address of the token to be wrapped. The registered address identifies the underlying asset for wrapping and unwrapping. Security tokens implementing standards such as ERC3643 may also be used as underlying assets.

For more about ERC3643, see the following article.

[ERC3643] Understanding T-REX Security Tokens for Institutional Investors

Parameters

  • token Underlying token address.

Return value

  • bool Whether configuration succeeded.
wrapToken
javascript
function wrapToken(uint256 amount, bytes calldata data) external returns (bool);

Deposits underlying tokens and converts them into ERC7518 tokens. Locks the specified amount of underlying tokens in on-chain custody and mints the corresponding ERC7518 tokens. The implementation must validate the relationship between the underlying token and the ERC1155 id.

Parameters

  • amount Amount to wrap.
  • data Additional data, for example to identify the partition.

Return value

  • bool Whether wrapping succeeded.
wrapTokenFromPartition
javascript
function wrapTokenFromPartition(bytes32 partitionId, uint256 id, uint256 amount, bytes calldata data) external returns (bool);

Wraps tokens from a specified partition into ERC7518 tokens. Locks a specified quantity of semi-fungible tokens belonging to the partition and converts them into the corresponding ERC7518 tokens. The relationship between the underlying token and its partition ID must be validated, with appropriate backing for the minted tokens.

Parameters

  • partitionId Underlying token's partition identifier.
  • id Token ID.
  • amount Amount to wrap.
  • data Additional data used for wrapping.

Return value

  • success Whether wrapping succeeded.
unwrapToken
javascript
function unwrapToken(uint256 wrappedTokenId, uint256 amount, bytes calldata data) external returns (bool);

Unwraps ERC7518 tokens into the original underlying tokens. Burns the specified quantity of ERC7518 tokens and returns the corresponding locked underlying assets to the user. Tokens subject to applicable locking restrictions cannot be unwrapped.

Parameters

  • wrappedTokenId Internal partition ID.
  • amount Amount to unwrap.
  • data Additional data.

Return value

  • bool Whether unwrapping succeeded.
wrappedBalanceOf
javascript
function wrappedBalanceOf(address account, uint256 id, bytes calldata data) external view returns (uint256);

Retrieves the balance of wrapped ERC7518 tokens held by an address. Used to determine how many wrapped tokens a user holds. The data argument may carry partition-related information.

Parameters

  • account Address whose balance is queried.
  • id Token ID.
  • data Partition-related information.

Return value

  • uint256 Wrapped token balance.
originalBalanceOf
javascript
function originalBalanceOf(address account, uint256 id, bytes calldata data) external view returns (uint256);

Retrieves the underlying token balance of a specified address. Used to check the balance of the original asset before wrapping. This is useful for maintaining consistency during wrapping and unwrapping.

Parameters

  • account Address whose balance is queried.
  • id Token ID.
  • data Additional partition-related information.

Return value

  • uint256 Underlying token balance.

Partition management

Partition fundamentals

ERC7518 uses ERC1155's support for multiple token IDs to organize assets into partitions. Partitions organize securities categories with different rights, regulations, and operational rules within one contract.

Partitions have the following properties.

Property Description
Partition creation Minting tokens with a distinct tokenId creates a new partition.
Fungibility within a partition Units with the same tokenId are fungible with one another.
Relationship between partitions Different token IDs represent distinct classes that may have different treatment and rights.
Examples Fund classes, securities for investors in different jurisdictions, separate bond series, and securitized real estate by floor.

Partitions can represent complex real-world asset structures on-chain.

Compliance management with off-chain integration

A feature of ERC7518 is the ability to centralize transfer eligibility checks through the on-chain canTransfer function. Requirements involving jurisdictions, investor eligibility, or exemptions often depend on off-chain information that a smart contract cannot independently establish.

ERC7518 therefore supports a hybrid on-chain and off-chain model, as illustrated below.

Compliance workflow

image.png https://eips.ethereum.org/EIPS/eip-7518

When a client requests a token transfer, the following illustrative workflow can take place.

  1. The client sends a transfer request to an oracle or compliance service. The request includes the source, destination, amount, partition, and other relevant information.
  2. The oracle or compliance service checks KYC, jurisdiction, applicable exemptions, and custom rules. It may consult databases or external systems.
  3. If the conditions are met, the service generates a signed voucher and returns it to the client.
  4. The client supplies the signed voucher in the data argument of safeTransferFrom.
  5. The contract's canTransfer function verifies the following conditions.
    • Signature validity.
    • Whether the voucher's from/to/id/amount fields match the actual transfer arguments.
    • Whether the voucher has expired.
    • Other on-chain conditions, including locks, freezes, and transfer restrictions.
  6. If the voucher is valid and all conditions are satisfied, the function returns true and the transfer proceeds.
  7. After the transfer completes, the client can inspect its transaction status.

Dynamic compliance using vouchers

A voucher acts as a signed authorization attestation. This approach offers the following potential benefits.

Benefit Description
Flexibility Changes to off-chain rules can be handled without redeploying the smart contract, provided the verification policy supports them.
Privacy Investor attributes such as nationality, eligibility, or status need not be published directly on-chain.
Extensibility Supports additional jurisdiction-specific rules and third-party checks.

The voucher format and verification policy are implementation-dependent and can be customized for the application.

Token recovery

Investors may lose access to assets when a wallet is lost or compromised. Recovery mechanisms may be needed for securities management, depending on legal obligations and investor protection requirements.

ERC7518 provides forceTransfer for this purpose.

Forced transfers have the following characteristics.

Property Description
Bypass ordinary transfer checks forceTransfer can bypass applicable lock and freeze restrictions, but must still preserve valid token accounting and sufficient balances.
Restricted to issuers or recovery agents Strict access control is required to prevent misuse.
Move assets from compromised wallets or lost keys Provides an authorized recovery mechanism for security tokens.

This supports risk management for security tokens.

Payout management

ERC7518 standardizes mechanisms for distributing payments such as dividends, interest, and income. Payouts use the following two functions.

Function Description
payout Delivers a payment to one address.
batchPayout Delivers payments to multiple addresses in one operation.

These functions offer the following potential benefits.

Benefit Description
Operational efficiency Distribute payments to multiple investors in one transaction.
Lower fees Batch execution can reduce gas costs compared with individual payment transactions.
Consistent distribution procedure Applications can support payments through a common interface.

The described payout rules also prohibit payments to frozen addresses, supporting compliance controls.

Additional considerations

Enhanced compliance management

ERC7518 is designed around compliance checks during token transfers. The central function is canTransfer, which determines whether a proposed transfer is permitted.

There is no single mandated implementation of canTransfer. It may rely on on-chain storage, oracle-provided information, or attestations from an off-chain authorization system. This enables integration with existing KYC/AML and securities-compliance frameworks.

Supporting functions include freezeAddress, restrictTransfer, lockTokens, and forceTransfer.

  • freezeAddress freezes an address and restricts associated transfers and payouts.
  • restrictTransfer applies a restriction to a specified token ID.
  • lockTokens designates a balance that cannot be transferred during a specified period, such as a vesting or lock-up period.
  • forceTransfer provides an authorized exceptional transfer mechanism that bypasses applicable ordinary restrictions.

Tokens locked through the locking mechanism can be released through unlockToken once the required release conditions are met. Explicitly handling unlock timing and affected balances makes it easier to track when tokens were released and provides operational accountability.

Fractional ownership

ERC7518 supports fractional ownership using ERC1155's existing balance-based accounting model rather than introducing a separate fractionalization extension.

A partition is identified by tokenId, and the amount held within that partition represents a number of units or shares of the underlying security. For example, if a real estate partition has a total issuance of amount = 1000, each fungible unit can represent a 1/1000 interest.

The following table illustrates the model.

Component Description
Fractional units The amount associated with each tokenId represents units of fractional ownership within the partition.
Issuance and retirement The issuer adjusts the supply of units through minting and burning.
Transfers Use safeTransferFrom or safeBatchTransferFrom, applying the appropriate canTransfer checks before transfer.
Locks and freezes Locks reduce the transferable portion of the balance, while freezes may prohibit transfers without changing the recorded holdings.
Forced transfers forceTransfer can operate on specified quantities of fractional units.
Partition merging A possible implementation creates a new tokenId and accepts old partition tokens at a 1:1 or other specified ratio.
Partition splitting A possible implementation mints a new tokenId and allocates it under specified conversion rules.
Compliance Units within the same partition follow the same partition-level rules.

The key point is that units within a partition share the same partition-level rules. Requirements such as KYC/AML, lock-ups, and transfer restrictions are applied consistently, with additional account-specific controls where appropriate. This allows fractional economic interests to be represented using integer token units while retaining a simple compliance management model.

Interoperability with other standards

Why use ERC1155?

ERC7518 is built on ERC1155.

ERC1155 supports managing multiple token types, batch transfers, and balance-based accounting and is widely used in games, NFTs, and multi-asset applications. This foundation enables reuse of existing tooling, wallets, and marketplaces while adding security-token functionality, subject to the additional transfer restrictions.

The proposal compares the following alternative standards.

Standard Rationale and relationship to ERC7518
ERC3525 Its slot/value abstraction resembles ERC7518's partition (tokenId) and balance (amount) model. However, ERC3525 maintains state for individual positions in an ERC721-like manner, which can introduce overhead for large-scale issuance and compliance checks.
ERC6909 A minimal multi-token standard that does not itself define partition metadata or compliance hooks; regulated assets would require additional functionality.

For more about ERC3525, see the following article.

[ERC3525] Understanding Semi-Fungible Tokens Combining ERC721 and ERC20 Features

For more about ERC6909, see the following article.

[ERC6909] Understanding a Minimal Multi-Token Interface

Implementers requiring slot-style interoperability may optionally expose an ERC3525-compatible interface, detectable through ERC165, mapping slot to partition and value to amount. The internal representation can still use the ERC1155 partition model.

For more about ERC165, see the following article.

[ERC165] Detecting Supported Smart Contract Interfaces

ERC7518 combines the ERC1155 token-ID partition model with possible dynamic issuance, merging, and splitting mechanisms, as well as voucher-based compliance. The design aims to improve efficiency and extensibility while enabling compliance policy updates without redeploying the token contract where supported.

Roles of the wrap and unwrap functions

The wrapToken, wrapTokenFromPartition, and unwrapToken functions are important for interoperability.

Function Purpose
wrapToken Integrates primarily ERC20-compatible tokens into ERC7518 by locking underlying tokens and minting corresponding ERC7518 tokens.
wrapTokenFromPartition Converts NFTs or other multi-token assets into ERC7518 tokens while retaining relevant partition information, supporting more complex asset structures.
unwrapToken Converts wrapped ERC7518 tokens back into the original asset by releasing the locked underlying tokens, subject to applicable restrictions.

For more about ERC20, see the following article.

[ERC20] An Introduction to the ERC20 Token Standard

unwrapToken enables users to move between the ERC7518 representation and the underlying token standard when authorized. This can support gradual adoption of securitization, partitioning, and compliance features while maintaining existing infrastructure integrations.

Payment distribution

The payout design emphasizes operational efficiency and transparency.

Use payout for one-off payments, event-triggered distributions, or special payments to individual investors. The function pays a single address at a chosen time and can also support distributions such as airdrops or bonuses.

batchPayout is suited to recurring dividends or distributions to many recipients. Batch payments can reduce gas costs and simplify on-chain operations.

Function Primary use cases
payout One-off or individual payments, including event-triggered distributions.
batchPayout Payments to multiple addresses, such as recurring dividend or interest distributions.

Combining these functions with compliance rules, such as rejecting payments to frozen addresses, can support both operational efficiency and applicable regulatory requirements.

Compatibility

ERC7518 is designed to retain ERC1155 interface compatibility.

Its core token interface follows ERC1155, and the added functions are defined as extension interfaces. Existing ERC1155-compatible wallets and marketplaces can therefore recognize the underlying token interface, although compliance restrictions may require additional integration.

Integration Compatibility considerations
Wallets ERC1155 wallets can use basic features such as balance displays and supported transfers, subject to compliance requirements.
Marketplaces Existing ERC1155 trading logic may be reused with any necessary compliance integration.
Infrastructure, including indexers Existing ERC1155 events can be processed through current indexing infrastructure.

Clients and services can progressively add support for locking, freezing, and voucher verification; unsupported clients retain basic interface compatibility but may be unable to perform restricted transfers.

Security

The following considerations are important for securely implementing and operating ERC7518.

Access control

Functions such as forceTransfer, freezeAddress, and lockTokens significantly affect balances and holder rights. Strict access controls, such as role-based authorization, must restrict these operations to authorized issuers or administrators.

Parameter validation

Functions such as safeTransferFrom, lockTokens, and forceTransfer require checks for valid addresses, sufficient balances, and caller authorization. Omitting these checks can cause unintended transfers, accounting inconsistencies, or security vulnerabilities.

Reentrancy protection

Functions interacting with external contracts, including token transfers and payouts involving external calls, must account for reentrancy risks. Use appropriate protections, such as Checks-Effects-Interactions and nonReentrant guards, to prevent unsafe reentrant execution.

Overflow and underflow protection

Arithmetic involving token balances and payout amounts must prevent overflow and underflow. Solidity 0.8 and later provide checked arithmetic by default, and suitable SafeMath libraries can protect arithmetic in older implementations.

Payout security

The following considerations apply to payout and batchPayout.

Concern Description
Authorization Restrict payout initiation to appropriate roles to prevent unauthorized withdrawals of contract funds.
Balance checks Verify that the total payment amount does not exceed the payer's available funds.
Frozen addresses Reject prohibited payments to frozen recipients to support compliance controls.

Off-chain voucher security

Voucher-based compliance also depends on the security of off-chain systems.

  • The compliance service issuing vouchers must enforce authentication and secure signing-key management.
  • Key management, audit logging, and intrusion detection help prevent unauthorized issuance or modification of vouchers.
  • The contract must verify signatures, expiration, and the correspondence between voucher contents and transfer arguments (from/to/id/amount).

Inadequate controls can turn the compliance layer itself into an attack surface, making robust on-chain and off-chain design essential.

Operational considerations when unfreezing

When unFreeze removes an address freeze, the address can resume transfers and receive payouts, provided other applicable restrictions are satisfied.

Before unfreezing an address, operators must verify not only technical requirements but also applicable regulatory and contractual obligations. Mistakenly unfreezing a sanctioned address or an address with unresolved issues may create legal or compliance risks.

References

Abhinav (@abhinav-d3v) abhinav@zoniqx.com, Prithvish Baidya (@d4mr) pbaidya@zoniqx.com, Rajat Kumar (@rajatwasan) rwasan@zoniqx.com, Prasanth Kalangi pkalangi@zoniqx.com, "ERC-7518: Dynamic Compliant Interop Security Token [DRAFT]," Ethereum Improvement Proposals, no. 7518, September 2023. [Online serial]. Available: https://eips.ethereum.org/EIPS/eip-7518.

Conclusion

This article covered ERC7518, which proposes semi-fungible partitions with distinct compliance controls for different asset classes. I hope it helped clarify the design.

If you have questions, feel free to contact me through Twitter DM.

Twitter @cardene777

I also publish articles on the following platforms.