Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separation of issuer and admin for fungible tokens #805

Merged
merged 42 commits into from
May 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
a92292d
Draft implementation of separation of issuer and admin for fungible t…
masihyeganeh Apr 17, 2024
35c4865
Fix unit tests
masihyeganeh Apr 17, 2024
f2adcc6
Fix integration tests
masihyeganeh Apr 17, 2024
acdb5bc
Fix integration test
masihyeganeh Apr 17, 2024
304819b
Fix linting
masihyeganeh Apr 17, 2024
70df679
Fix keeper
masihyeganeh Apr 17, 2024
9fd267e
Fix deterministic gas price
masihyeganeh Apr 18, 2024
6278eaa
Add admin migration script
masihyeganeh Apr 18, 2024
e5d04c1
Fix token tests
masihyeganeh Apr 18, 2024
59a897a
Add event for TransferAdmin
masihyeganeh Apr 18, 2024
b355df1
Temporary fix wasm test
masihyeganeh Apr 18, 2024
bc8bb25
Fix wasm tests
masihyeganeh Apr 18, 2024
1c95305
Add extensive unit tests
masihyeganeh Apr 19, 2024
7d8f97a
Add integration-test for minting after transferring admin
masihyeganeh Apr 19, 2024
f884d0f
Add more integration-test for features after transferring admin
masihyeganeh Apr 19, 2024
c603dda
Fix linting problems
masihyeganeh Apr 19, 2024
b3db1ad
Add more integration tests
masihyeganeh Apr 19, 2024
d1de385
Fix TestAssetFTTransferAdminFreeze bug 1
masihyeganeh Apr 19, 2024
93d7641
Fix integration tests round 1
masihyeganeh Apr 19, 2024
87f579e
Fix integration tests round 2
masihyeganeh Apr 19, 2024
4b32326
Removing checks that don't belong to ValidateBasic
masihyeganeh Apr 21, 2024
bff9120
Fix integration tests round 3
masihyeganeh Apr 21, 2024
a5d04cf
Fix integration tests round 4
masihyeganeh Apr 21, 2024
89254a1
Fix integration tests round 5
masihyeganeh Apr 21, 2024
31759ed
Fix integration tests round 6
masihyeganeh Apr 21, 2024
702122a
Fix integration tests round 7
masihyeganeh Apr 21, 2024
4a6a590
Fix integration tests round 8
masihyeganeh Apr 21, 2024
59d2379
Fix integration tests round 9
masihyeganeh Apr 21, 2024
ee05a42
Fix integration tests round 10
masihyeganeh Apr 21, 2024
6de7a26
Fix integration tests
masihyeganeh Apr 21, 2024
c8bb2c1
Fix all integration tests
masihyeganeh Apr 21, 2024
b715aec
Fix comment
masihyeganeh Apr 25, 2024
75610f6
Add upgrade test
masihyeganeh Apr 29, 2024
cea8a83
Add drop admin functionality
masihyeganeh Apr 29, 2024
e5e50a5
Fix error messages
masihyeganeh Apr 29, 2024
63e64ec
Fix conflicts
masihyeganeh Apr 29, 2024
789e1eb
Rename DropAdmin to ClearAdmin
masihyeganeh Apr 29, 2024
078f885
Add tests for clawback after transferring admin
masihyeganeh Apr 29, 2024
9c49448
Fix conflicts
masihyeganeh May 1, 2024
44f7da8
Fix protos
masihyeganeh May 1, 2024
8d73459
Fix commission rate
masihyeganeh May 2, 2024
0b18889
Fix TestDeterministicGas_DeterministicMessages
masihyeganeh May 3, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
75 changes: 75 additions & 0 deletions docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
- [MintAuthorization](#coreum.asset.ft.v1.MintAuthorization)

- [coreum/asset/ft/v1/event.proto](#coreum/asset/ft/v1/event.proto)
- [EventAdminCleared](#coreum.asset.ft.v1.EventAdminCleared)
- [EventAdminTransferred](#coreum.asset.ft.v1.EventAdminTransferred)
- [EventAmountClawedBack](#coreum.asset.ft.v1.EventAmountClawedBack)
- [EventFrozenAmountChanged](#coreum.asset.ft.v1.EventFrozenAmountChanged)
- [EventIssued](#coreum.asset.ft.v1.EventIssued)
Expand Down Expand Up @@ -59,13 +61,15 @@
- [ExtensionIssueSettings](#coreum.asset.ft.v1.ExtensionIssueSettings)
- [MsgBurn](#coreum.asset.ft.v1.MsgBurn)
- [MsgClawback](#coreum.asset.ft.v1.MsgClawback)
- [MsgClearAdmin](#coreum.asset.ft.v1.MsgClearAdmin)
- [MsgFreeze](#coreum.asset.ft.v1.MsgFreeze)
- [MsgGloballyFreeze](#coreum.asset.ft.v1.MsgGloballyFreeze)
- [MsgGloballyUnfreeze](#coreum.asset.ft.v1.MsgGloballyUnfreeze)
- [MsgIssue](#coreum.asset.ft.v1.MsgIssue)
- [MsgMint](#coreum.asset.ft.v1.MsgMint)
- [MsgSetFrozen](#coreum.asset.ft.v1.MsgSetFrozen)
- [MsgSetWhitelistedLimit](#coreum.asset.ft.v1.MsgSetWhitelistedLimit)
- [MsgTransferAdmin](#coreum.asset.ft.v1.MsgTransferAdmin)
- [MsgUnfreeze](#coreum.asset.ft.v1.MsgUnfreeze)
- [MsgUpdateParams](#coreum.asset.ft.v1.MsgUpdateParams)
- [MsgUpgradeTokenV1](#coreum.asset.ft.v1.MsgUpgradeTokenV1)
Expand Down Expand Up @@ -1600,6 +1604,39 @@ the granter's account.



<a name="coreum.asset.ft.v1.EventAdminCleared"></a>

### EventAdminCleared



| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| `denom` | [string](#string) | | |
| `previous_admin` | [string](#string) | | |






<a name="coreum.asset.ft.v1.EventAdminTransferred"></a>

### EventAdminTransferred



| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| `denom` | [string](#string) | | |
| `previous_admin` | [string](#string) | | |
| `current_admin` | [string](#string) | | |






<a name="coreum.asset.ft.v1.EventAmountClawedBack"></a>

### EventAmountClawedBack
Expand Down Expand Up @@ -1659,6 +1696,7 @@ EventIssued is emitted on MsgIssue.
| `send_commission_rate` | [string](#string) | | |
| `uri` | [string](#string) | | |
| `uri_hash` | [string](#string) | | |
| `admin` | [string](#string) | | |



Expand Down Expand Up @@ -2159,6 +2197,7 @@ Definition defines the fungible token settings to store.
| `uri` | [string](#string) | | |
| `uri_hash` | [string](#string) | | |
| `extension_cw_address` | [string](#string) | | |
| `admin` | [string](#string) | | |



Expand Down Expand Up @@ -2210,6 +2249,7 @@ Token is a full representation of the fungible token.
| `uri` | [string](#string) | | |
| `uri_hash` | [string](#string) | | |
| `extension_cw_address` | [string](#string) | | |
| `admin` | [string](#string) | | |



Expand Down Expand Up @@ -2360,6 +2400,22 @@ the source code for the extension.



<a name="coreum.asset.ft.v1.MsgClearAdmin"></a>

### MsgClearAdmin



| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| `sender` | [string](#string) | | |
| `denom` | [string](#string) | | |






<a name="coreum.asset.ft.v1.MsgFreeze"></a>

### MsgFreeze
Expand Down Expand Up @@ -2490,6 +2546,23 @@ MsgIssue defines message to issue new fungible token.



<a name="coreum.asset.ft.v1.MsgTransferAdmin"></a>

### MsgTransferAdmin



| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| `sender` | [string](#string) | | |
| `account` | [string](#string) | | |
| `denom` | [string](#string) | | |






<a name="coreum.asset.ft.v1.MsgUnfreeze"></a>

### MsgUnfreeze
Expand Down Expand Up @@ -2571,6 +2644,8 @@ Msg defines the Msg service.
| `GloballyUnfreeze` | [MsgGloballyUnfreeze](#coreum.asset.ft.v1.MsgGloballyUnfreeze) | [EmptyResponse](#coreum.asset.ft.v1.EmptyResponse) | `GloballyUnfreeze unfreezes fungible token and unblocks basic operations on it. This operation is idempotent so global unfreezing of non-frozen token does nothing.` | |
| `Clawback` | [MsgClawback](#coreum.asset.ft.v1.MsgClawback) | [EmptyResponse](#coreum.asset.ft.v1.EmptyResponse) | `Clawback confiscates a part of fungible tokens from an account to the admin, only if the clawback feature is enabled on that token.` | |
| `SetWhitelistedLimit` | [MsgSetWhitelistedLimit](#coreum.asset.ft.v1.MsgSetWhitelistedLimit) | [EmptyResponse](#coreum.asset.ft.v1.EmptyResponse) | `SetWhitelistedLimit sets the limit of how many tokens a specific account may hold.` | |
| `TransferAdmin` | [MsgTransferAdmin](#coreum.asset.ft.v1.MsgTransferAdmin) | [EmptyResponse](#coreum.asset.ft.v1.EmptyResponse) | `TransferAdmin changes admin of a fungible token.` | |
| `ClearAdmin` | [MsgClearAdmin](#coreum.asset.ft.v1.MsgClearAdmin) | [EmptyResponse](#coreum.asset.ft.v1.EmptyResponse) | `ClearAdmin removes admin of a fungible token.` | |
| `UpgradeTokenV1` | [MsgUpgradeTokenV1](#coreum.asset.ft.v1.MsgUpgradeTokenV1) | [EmptyResponse](#coreum.asset.ft.v1.EmptyResponse) | `TokenUpgradeV1 upgrades token to version V1.` | |
| `UpdateParams` | [MsgUpdateParams](#coreum.asset.ft.v1.MsgUpdateParams) | [EmptyResponse](#coreum.asset.ft.v1.EmptyResponse) | `UpdateParams is a governance operation to modify the parameters of the module. NOTE: all parameters must be provided.` | |

Expand Down
3 changes: 3 additions & 0 deletions docs/static/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -9281,6 +9281,9 @@
},
"extension_cw_address": {
"type": "string"
},
"admin": {
"type": "string"
}
},
"description": "Token is a full representation of the fungible token."
Expand Down
Loading
Loading