Skip to content

Commit 0bdb198

Browse files
committed
suggestions part 1
1 parent 048686d commit 0bdb198

File tree

2 files changed

+38
-28
lines changed

2 files changed

+38
-28
lines changed

content/stellar-contracts/tokens/rwa/rwa.mdx

Lines changed: 33 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,16 @@ title: Real World Asset (RWA) Token
44

55
[Source Code](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa)
66

7-
Real World Asset (RWA) tokens are security tokens that represent ownership or rights to real-world assets
8-
such as real estate, commodities, securities, or other regulated financial instruments.
9-
These tokens must comply with various regulatory requirements including KYC/AML verification, transfer restrictions,
10-
and compliance rules. The RWA module provides a comprehensive framework based on the T-REX
11-
(Token for Regulated Exchanges) standard.
7+
Real World Asset (RWA) tokens are security tokens that represent ownership or rights to real-world assets such as
8+
real estate, commodities, securities, or other regulated financial instruments. These tokens must comply with various
9+
regulatory requirements including KYC/AML verification, transfer restrictions, and compliance rules. The RWA module
10+
provides a comprehensive framework based on the T-REX (Token for Regulated Exchanges) standard,
11+
which implements the [ERC-3643](https://docs.erc3643.org/erc-3643) specification.
1212

1313
## Overview
1414

15-
The [RWA](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa) module provides a complete implementation of regulated security tokens with built-in compliance,
15+
The [RWA](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa) module
16+
provides a complete implementation of regulated security tokens with built-in compliance,
1617
identity verification, and administrative controls. The module is designed to be flexible and extensible,
1718
allowing integration with various identity registry and compliance frameworks.
1819

@@ -37,16 +38,15 @@ The RWA module follows a modular architecture that separates concerns and allows
3738
`FungibleToken` and `Pausable` traits.
3839

3940
2. **Identity Verifier**: A separate contract responsible for verifying user identities.
40-
The RWA token expects the following function to be available:
41-
- `fn verify_identity(e: &Env, account: &Address);`
41+
The RWA token expects the following function to be available: `fn verify_identity(e: &Env, account: &Address);`.
4242

4343
3. **Compliance Contract**: A separate contract that validates transfers, minting, and burning operations.
4444
The RWA token expects the following functions to be available:
45-
- `fn can_transfer(e: &Env, from: Address, to: Address, amount: i128, token: Address) -> bool;`
46-
- `fn can_create(e: &Env, to: Address, amount: i128, token: Address) -> bool;`
47-
- `fn created(e: &Env, to: Address, amount: i128, token: Address);`
48-
- `fn destroyed(e: &Env, from: Address, amount: i128, token: Address);`
49-
- `fn transferred(e: &Env, from: Address, to: Address, amount: i128, token: Address);`
45+
- `fn can_transfer(e: &Env, from: Address, to: Address, amount: i128, token: Address) -> bool;`
46+
- `fn can_create(e: &Env, to: Address, amount: i128, token: Address) -> bool;`
47+
- `fn created(e: &Env, to: Address, amount: i128, token: Address);`
48+
- `fn destroyed(e: &Env, from: Address, amount: i128, token: Address);`
49+
- `fn transferred(e: &Env, from: Address, to: Address, amount: i128, token: Address);`
5050

5151
This loose coupling between the RWA token and the modules allows the following:
5252
- Share identity verifier and compliance contracts across multiple RWA tokens
@@ -176,12 +176,12 @@ RWA::unfreeze_partial_tokens(e, &user_address, amount, &operator);
176176

177177
### Recovery System
178178

179-
Balance Recovery System is handled on the RWA token contract, whereas Identity Recovery System is handled
180-
on a separate contract as a module (may be a part of the Identity Registry contract).
181-
182179
The recovery system allows authorized operators to transfer tokens from a lost/old account to a
183180
new account for the same verified investor:
184181

182+
Balance Recovery System is handled on the RWA token contract, whereas Identity Recovery System is handled
183+
on a separate contract as a module (may be a part of the Identity Registry contract).
184+
185185
```rust
186186
// Recover tokens from old account to new account
187187
RWA::recover_balance(e, &old_account, &new_account, &operator);
@@ -216,27 +216,30 @@ It uses a hook-based architecture where compliance modules can be registered for
216216
- **CanTransfer**: Called during transfer validation (read-only)
217217
- **CanCreate**: Called during mint validation (read-only)
218218

219-
The compliance contract is designed to be shared across multiple RWA tokens, with each hook function accepting a `token` parameter to identify the calling token.
219+
The compliance contract is designed to be shared across multiple RWA tokens, with each hook function accepting a
220+
`token` parameter to identify the calling token.
220221

221222
### - Identity Verifier
222223
[Source Code](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa/identity_verifier)
223224

224-
This is a mandatory module, since RWA token contract expects `verify_identity(e: &Env, address: Address)` function to be available.
225+
This is a mandatory module, since RWA token contract expects `verify_identity(e: &Env, address: Address)`
226+
function to be available.
225227

226228
The identity verifier module provides the interface for verifying user identities.
227-
It also supports custom implementation approaches:
229+
It can also support possible custom implementation approaches:
228230

229-
- **Claim-based**: Cryptographic claims from trusted issuers (default implementation)
231+
- **Claim-based**: Cryptographic claims from trusted issuers (provided default implementation)
230232
- **Merkle Tree**: Efficient verification using merkle proofs
231233
- **Zero-Knowledge**: Privacy-preserving verification with custom ZK circuits
232-
- **Custom approaches**: Any implementation that satisfies the `verify_identity` interface
234+
- **Other custom approaches**: Any implementation that satisfies the `verify_identity` interface
233235

234-
The default claim-based implementation integrates with the Claim Topics and Issuers module and Identity Registry Storage.
236+
The default claim-based implementation integrates with the Claim Topics and Issuers module and
237+
Identity Registry Storage.
235238

236239
### - Claim Topics and Issuers
237240
[Source Code](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa/claim_topics_and_issuers)
238241

239-
This module is an implementation detail. It is provided as the suggested implementation for the `Claim-based` approach.
242+
This module is an implementation detail. It is provided as the suggested implementation for the **Claim-based** approach.
240243

241244
Manages trusted claim issuers and claim topics (e.g., KYC=1, AML=2, Accredited Investor=3). This module:
242245

@@ -248,7 +251,7 @@ Manages trusted claim issuers and claim topics (e.g., KYC=1, AML=2, Accredited I
248251
### - Identity Registry Storage
249252
[Source Code](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa/identity_registry_storage)
250253

251-
This module is an implementation detail. It is provided as the suggested implementation for the `Claim-based` approach.
254+
This module is an implementation detail. It is provided as the suggested implementation for the **Claim-based** approach.
252255

253256
Stores identity information for verified investors, including:
254257

@@ -260,7 +263,7 @@ Stores identity information for verified investors, including:
260263
### - Identity Claims
261264
[Source Code](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa/identity_claims)
262265

263-
This module is an implementation detail. It is provided as the suggested implementation for the `Claim-based` approach.
266+
This module is an implementation detail. It is provided as the suggested implementation for the **Claim-based** approach.
264267

265268
Manages on-chain identity claims with cryptographic signatures. Claims are issued by trusted authorities and contain:
266269

@@ -272,7 +275,7 @@ Manages on-chain identity claims with cryptographic signatures. Claims are issue
272275
### - Claim Issuer
273276
[Source Code](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa/claim_issuer)
274277

275-
This module is an implementation detail. It is provided as the suggested implementation for the `Claim-based` approach.
278+
This module is an implementation detail. It is provided as the suggested implementation for the **Claim-based** approach.
276279

277280
Validates cryptographic claims with support for multiple signature schemes:
278281

@@ -289,7 +292,8 @@ The following optional extensions are provided:
289292

290293
This module is not mandatory.
291294

292-
The `DocumentManager` trait extends the `RWAToken` trait to provide document management capabilities following the ERC-1643 standard. This extension allows contracts to:
295+
The `DocumentManager` trait extends the `RWAToken` trait to provide document management capabilities following the
296+
ERC-1643 standard. This extension allows contracts to:
293297

294298
- Attach documents with URI, hash, and timestamp
295299
- Update existing document metadata
@@ -303,7 +307,8 @@ This is useful for attaching legal documents, prospectuses, or other regulatory
303307
### - Token Binder
304308
[Source Code](https://github.com/OpenZeppelin/stellar-contracts/tree/main/packages/tokens/src/rwa/utils/token_binder)
305309

306-
The `TokenBinder` trait provides a standardized interface for linking tokens to periphery contracts such as identity registries and compliance contracts. This allows a single periphery contract to serve multiple RWA tokens.
310+
The `TokenBinder` trait provides a standardized interface for linking tokens to periphery contracts such as identity
311+
registries and compliance contracts. This allows a single periphery contract to serve multiple RWA tokens.
307312

308313
Features:
309314
- Bind/unbind tokens to periphery services

src/navigation/stellar.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@
2626
"type": "page",
2727
"name": "Non-Fungible",
2828
"url": "/stellar-contracts/tokens/non-fungible/non-fungible"
29+
},
30+
{
31+
"type": "page",
32+
"name": "RWA",
33+
"url": "/stellar-contracts/tokens/rwa/rwa"
2934
}
3035
]
3136
},

0 commit comments

Comments
 (0)