From 0808be75464d3e277cf7a6c898cfdbd84b3fb314 Mon Sep 17 00:00:00 2001 From: yingying Date: Tue, 11 Feb 2025 12:40:50 +0800 Subject: [PATCH 1/2] account permission management --- docs/clients/wallet-cli-command.md | 4 ++-- docs/introduction/overview.md | 4 ++-- docs/mechanism-algorithm/multi-signatures.md | 10 +++------- docs/mechanism-algorithm/system-contracts.md | 4 ++-- mkdocs.yml | 2 +- 5 files changed, 10 insertions(+), 14 deletions(-) diff --git a/docs/clients/wallet-cli-command.md b/docs/clients/wallet-cli-command.md index 1a5cd043..6fde21a5 100644 --- a/docs/clients/wallet-cli-command.md +++ b/docs/clients/wallet-cli-command.md @@ -203,7 +203,7 @@ Balance = 2665198240 ```shell wallet>UpdateAccountPermission [ownerAddress] [permissions] ``` -This command is used to assign permissions to other accounts, is utilized for **multi-signature** transactions, which allows other users to access the account with paritcular permission in order to better manage it. There are three types of permissions: +This command is used to manage account permissions, assign permissions to other accounts, is utilized for multi-signature transactions, which allows other users to access the account with paritcular permission in order to better manage it. There are three types of permissions: * owner: access to the owner of account * active: access to other features of accounts, and access that authorizes a certain feature. Block production authorization is not included if it's for SR purposes. @@ -861,7 +861,7 @@ In the example, we picked the account `TB9qhqbev6DpX8mxdf3zDdtSQ6GC6Vb6Ej` to si after that, it asks you if want to add another sign ,enter y and pick the account `TXBpeye7UQ4dDZEnmGDv4vX37mBYDo1tUE` to finish multi-signing. -The weight of each account is 1 and the granting threshold is 2. When the requirements are met, the transaction is done successfully! This is how multiple accounts user multi-signature when using the same cli. +The weight of each account is 1 and the granting threshold is 2. When the requirements are met, the transaction is done successfully! This example shows how to complete a multi-signed transaction using the same client. When using multiple clients, please refer to the following command. ### AddTransactionSign Use the instruction addTransactionSign according to the obtained transaction hex string if signing at multiple cli. diff --git a/docs/introduction/overview.md b/docs/introduction/overview.md index 8ffa79a5..07dcfc6e 100644 --- a/docs/introduction/overview.md +++ b/docs/introduction/overview.md @@ -1082,9 +1082,9 @@ supplyQuant = -supply * (1.0 - Math.pow(1.0 + (double) sellTokenQuant/(firstToke buyTokenQuant = (long)balance * (Math.pow(1.0 + (double) supplyQuant / supply, 2000.0) - 1.0); -# 10. Multi-Signatures +# 10. Account Permission Management Please refer to: -[Multi-signatures](../mechanism-algorithm/multi-signatures.md) +[Account Permission Management](../mechanism-algorithm/multi-signatures.md) # 11. Shielded Transaction Please refer to: diff --git a/docs/mechanism-algorithm/multi-signatures.md b/docs/mechanism-algorithm/multi-signatures.md index d02b20e7..d71d3db1 100644 --- a/docs/mechanism-algorithm/multi-signatures.md +++ b/docs/mechanism-algorithm/multi-signatures.md @@ -1,10 +1,8 @@ -# Multi-signature +# Account Permission Management ## Background -Multiple signature functions allow for permission grading, and each permission can correspond to multiple private keys. This makes it possible to achieve multi-person joint control of accounts. This guide walks the user through TRON's multi-signature implementation and design. - -Reference: [TIP-16: Account Multi-signature](https://github.com/tronprotocol/TIPs/blob/master/tip-16.md) +[Account permission management](https://github.com/tronprotocol/TIPs/blob/master/tip-16.md) functions allow for permission grading, and each permission can correspond to multiple private keys. This makes it possible to achieve multi-person joint control of accounts. This guide walks the user through TRON's account permission management implementation and design. ## Concept @@ -52,7 +50,7 @@ message AccountPermissionUpdateContract { } ``` -- `owner_address`: The account applies multi-signatures +- `owner_address`: The address of the account whose permissions are to be modified - `owner`: Owner permission - `witness`: Witness permission (if the account is a SR(Super Representative)) - `actives`: Active permission @@ -277,8 +275,6 @@ public static void main(String[] args) { (n+1). The node will verify if the sum of the weight of all signatures is bigger than threshold, if true, the transaction is accepted, otherwise, is rejected -Demo: [MultiSignDemo.java](https://github.com/tronprotocol/wallet-cli/blob/multi_sign_V2/src/main/java/org/tron/demo/MultiSignDemo.java) - ### Other APIs Please refer to [HTTP API](../api/http.md) and [RPC API](../api/rpc.md) for more information. diff --git a/docs/mechanism-algorithm/system-contracts.md b/docs/mechanism-algorithm/system-contracts.md index 7d2c5e21..a688d0fe 100644 --- a/docs/mechanism-algorithm/system-contracts.md +++ b/docs/mechanism-algorithm/system-contracts.md @@ -432,9 +432,9 @@ message ReceiveDescription { - `c_out`: part of note ciphertext, encryption of the receiver's public key and ephemeral private key. - `zkproof`: zero-knowledge proof of the receiver's note. -## 27. Multi Signature +## 27. Account Permission Management -[Multi-Signature](./multi-signatures.md) +[Account Permission Management](./multi-signatures.md) ## 28. ClearABIContract ``` diff --git a/mkdocs.yml b/mkdocs.yml index 7a882bbe..09b77a0f 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -26,7 +26,7 @@ nav: - Smart Contract: contracts/contract.md - System Contract: mechanism-algorithm/system-contracts.md - Decentralized Exchange: mechanism-algorithm/dex.md - - Multi-Signature: mechanism-algorithm/multi-signatures.md + - Account Permission Management: mechanism-algorithm/multi-signatures.md - For Java-tron Developers: - Developer Guide: developers/java-tron.md - TIPs Workflow: developers/tips.md From 1243e5721a76cbfbdea005ac759d3574710edd3d Mon Sep 17 00:00:00 2001 From: yingying Date: Tue, 11 Feb 2025 12:51:13 +0800 Subject: [PATCH 2/2] Update toolkit.md --- docs/using_javatron/toolkit.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/using_javatron/toolkit.md b/docs/using_javatron/toolkit.md index 4e885ab2..c43f868a 100644 --- a/docs/using_javatron/toolkit.md +++ b/docs/using_javatron/toolkit.md @@ -113,7 +113,7 @@ $ nohup java -Xms9G -Xmx9G -XX:ReservedCodeCacheSize=256m \ -XX:+UseCMSInitiatingOccupancyOnly -XX:CMSInitiatingOccupancyFraction=70 \ -jar FullNode.jar -c main_net_config.conf >> start.log 2>&1 & -# Super representitive's FullNode +# Super representative's FullNode $ nohup java -Xms9G -Xmx9G -XX:ReservedCodeCacheSize=256m \ -XX:MetaspaceSize=256m -XX:MaxMetaspaceSize=512m \ -XX:MaxDirectMemorySize=1G -XX:+PrintGCDetails \