Skip to content

Commit

Permalink
Merge pull request #674 from lukso-network/contracts-docs-sync
Browse files Browse the repository at this point in the history
[Auto-Sync] Update Smart Contracts Technical Docs
  • Loading branch information
CJ42 authored Oct 24, 2023
2 parents 1dc988b + 39de59d commit 9e1a28c
Show file tree
Hide file tree
Showing 29 changed files with 2,121 additions and 764 deletions.
39 changes: 20 additions & 19 deletions docs/contracts/_interface_ids_table.mdx
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
| Contract | Interface ID | Description |
| :------------------------------- | :----------: | :------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **ERC165** | `0x01ffc9a7` | Standard Interface Detection. |
| **ERC1271** | `0x1626ba7e` | Standard Signature Validation Method for Contracts. |
| **ERC725X** | `0x7545acac` | General executor. |
| **ERC725Y** | `0x629aa694` | General Data key-value store. |
| **LSP0ERC725Account** | `0x24871b3d` | Interface of the [LSP-0-ERC725Account] standard, an account based smart contract that represents an identity on-chain. |
| **LSP1UniversalReceiver** | `0x6bb56a14` | Interface of the LSP1 - Universal Receiver standard, an entry function for a contract to receive arbitrary information. |
| **LSP6KeyManager** | `0xe7424397` | Interface of the LSP6 - Key Manager standard, a contract acting as a controller of an ERC725 Account using predfined permissions. |
| **LSP7DigitalAsset** | `0x05519512` | Interface of the LSP7 - Digital Asset standard, a fungible digital asset. |
| **LSP8IdentifiableDigitalAsset** | `0x1ae9ba1f` | Interface of the LSP8 - Identifiable Digital Asset standard, a non-fungible digital asset. |
| **LSP9Vault** | `0x28af17e6` | Interface of LSP9 - Vault standard, a blockchain vault that can hold assets and interact with other smart contracts. |
| **LSP11BasicSocialRecovery** | `0x049a28f1` | Interface of the LSP11 - Basic Social Recovery standard, a contract to recover access control into an account. |
| **LSP14Ownable2Step** | `0x94be5999` | Interface of the LSP14 - Ownable 2-step standard, an extension of the [EIP173] (Ownable) standard with 2-step process to transfer or renounce ownership. |
| **LSP17Extendable** | `0xa918fa6b` | Module to add more functionalities to a contract using extensions. |
| **LSP17Extension** | `0xcee78b40` | Module to create a contract that can act as an extension. |
| **LSP20CallVerification** | `0x1a0eb6a5` | Implementation of a contract calling the verification functions according to LSP20 - Call Verification standard. |
| **LSP20CallVerifier** | `0xc9dfc532` | Interface for the LSP20 Call Verification standard, a set of functions intended to perform verifications on behalf of another contract. |
| **LSP25ExecuteRelayCall** | `0x5ac79908` | |
| Contract | Interface ID | Description |
| :-------------------------------- | :----------: | :------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **ERC165** | `0x01ffc9a7` | Standard Interface Detection. |
| **ERC1271** | `0x1626ba7e` | Standard Signature Validation Method for Contracts. |
| **ERC725X** | `0x7545acac` | General executor. |
| **ERC725Y** | `0x629aa694` | General Data key-value store. |
| **LSP0ERC725Account** | `0x24871b3d` | Interface of the [LSP-0-ERC725Account] standard, an account based smart contract that represents an identity on-chain. |
| **LSP1UniversalReceiver** | `0x6bb56a14` | Interface of the LSP1 - Universal Receiver standard, an entry function for a contract to receive arbitrary information. |
| **LSP1UniversalReceiverDelegate** | `0xa245bbda` | Interface of the LSP1 - Universal Receiver Delegate standard. |
| **LSP6KeyManager** | `0x23f34c62` | Interface of the LSP6 - Key Manager standard, a contract acting as a controller of an ERC725 Account using predfined permissions. |
| **LSP7DigitalAsset** | `0x05519512` | Interface of the LSP7 - Digital Asset standard, a fungible digital asset. |
| **LSP8IdentifiableDigitalAsset** | `0x1ae9ba1f` | Interface of the LSP8 - Identifiable Digital Asset standard, a non-fungible digital asset. |
| **LSP9Vault** | `0x28af17e6` | Interface of LSP9 - Vault standard, a blockchain vault that can hold assets and interact with other smart contracts. |
| **LSP11BasicSocialRecovery** | `0x049a28f1` | Interface of the LSP11 - Basic Social Recovery standard, a contract to recover access control into an account. |
| **LSP14Ownable2Step** | `0x94be5999` | Interface of the LSP14 - Ownable 2-step standard, an extension of the [EIP173] (Ownable) standard with 2-step process to transfer or renounce ownership. |
| **LSP17Extendable** | `0xa918fa6b` | Module to add more functionalities to a contract using extensions. |
| **LSP17Extension** | `0xcee78b40` | Module to create a contract that can act as an extension. |
| **LSP20CallVerification** | `0x1a0eb6a5` | Implementation of a contract calling the verification functions according to LSP20 - Call Verification standard. |
| **LSP20CallVerifier** | `0x0d6ecac7` | Interface for the LSP20 Call Verification standard, a set of functions intended to perform verifications on behalf of another contract. |
| **LSP25ExecuteRelayCall** | `0x5ac79908` | |
56 changes: 56 additions & 0 deletions docs/contracts/contracts/ERC725/ERC725.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,12 @@ Generic executor function to:

:::

:::caution Warning

- The `msg.value` should not be trusted for any method called with `operationType`: `DELEGATECALL` (4).

:::

```solidity
function executeBatch(
uint256[] operationsType,
Expand Down Expand Up @@ -564,6 +570,12 @@ Perform low-level staticcall (operation type = 3)

### \_executeDelegateCall

:::caution Warning

The `msg.value` should not be trusted for any method called with `operationType`: `DELEGATECALL` (4).

:::

```solidity
function _executeDelegateCall(
address target,
Expand Down Expand Up @@ -1054,6 +1066,50 @@ Reverts when sending value to the [`setData`](#setdata) or [`setDataBatch`](#set

<br/>

### OwnableCallerNotTheOwner

:::note References

- Specification details: [**ERC-725**](https://github.com/ethereum/EIPs/blob/master/EIPS/eip-725.md#ownablecallernottheowner)
- Solidity implementation: [`ERC725.sol`](https://github.com/ERC725Alliance/ERC725/blob/main/implementations/contracts/ERC725.sol)
- Error signature: `OwnableCallerNotTheOwner(address)`
- Error hash: `0xbf1169c5`

:::

```solidity
error OwnableCallerNotTheOwner(address callerAddress);
```

Reverts when only the owner is allowed to call the function.

#### Parameters

| Name | Type | Description |
| --------------- | :-------: | ---------------------------------------- |
| `callerAddress` | `address` | The address that tried to make the call. |

<br/>

### OwnableCannotSetZeroAddressAsOwner

:::note References

- Specification details: [**ERC-725**](https://github.com/ethereum/EIPs/blob/master/EIPS/eip-725.md#ownablecannotsetzeroaddressasowner)
- Solidity implementation: [`ERC725.sol`](https://github.com/ERC725Alliance/ERC725/blob/main/implementations/contracts/ERC725.sol)
- Error signature: `OwnableCannotSetZeroAddressAsOwner()`
- Error hash: `0x1ad8836c`

:::

```solidity
error OwnableCannotSetZeroAddressAsOwner();
```

Reverts when trying to set `address(0)` as the contract owner when deploying the contract, initializing it or transferring ownership of the contract.

<br/>

<!-- GLOBAL LINKS -->

<!-- prettier-ignore-start -->
Expand Down
Loading

0 comments on commit 9e1a28c

Please sign in to comment.