Skip to content

Commit

Permalink
Merge pull request #408 from vivian1912/master
Browse files Browse the repository at this point in the history
account permission management
  • Loading branch information
Benson0224 authored Feb 11, 2025
2 parents 46f3bad + dd8143d commit e9766db
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 16 deletions.
4 changes: 2 additions & 2 deletions docs/clients/wallet-cli-command.md
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down Expand Up @@ -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.
Expand Down
4 changes: 2 additions & 2 deletions docs/introduction/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
10 changes: 3 additions & 7 deletions docs/mechanism-algorithm/multi-signatures.md
Original file line number Diff line number Diff line change
@@ -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

Expand Down Expand Up @@ -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
Expand Down Expand Up @@ -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.
Expand Down
4 changes: 2 additions & 2 deletions docs/mechanism-algorithm/system-contracts.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
```
Expand Down
2 changes: 1 addition & 1 deletion docs/using_javatron/toolkit.md
Original file line number Diff line number Diff line change
Expand Up @@ -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 \
Expand Down
4 changes: 2 additions & 2 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ 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
- For java-tron Developers:
- Account Permission Management: mechanism-algorithm/multi-signatures.md
- For Java-tron Developers:
- Developer Guide: developers/java-tron.md
- TIPs Workflow: developers/tips.md
- Issue Workflow: developers/issue-workflow.md
Expand Down

0 comments on commit e9766db

Please sign in to comment.