-
Notifications
You must be signed in to change notification settings - Fork 69
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
pemissionless assets ED and ratio #3702
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would be nice patch orml, and look what acala assets hub is using, and explain why new pallet and why we keed router?
other things are ok
#### orml tokens pallet EDs | ||
Currently assets are being stored in orml tokens pallet which require Existential Deposits for stored assets. | ||
|
||
**Potential Solution**: for non sufficient assets still provide non-zero Existential Deposit parameter which is similar to minimum balance in Asset Hub implementation. Then the Exitstential logic for orml tokens pallet will stay the same because account wont be able to hold a non sufficient asset without ED in parachain's native token. This will require a new field in AssetsRegistry: is_sufficient. All permissionless assets will have this field to be false by default. Assets created via permissioned extrinsic will allow to choose if asset is sufficient or not. Asset's sufficiency can be changed by governance. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AssetsRegistry: is_sufficient
should it be in assets registry or in assets? is_sufficient is required for all transactions, while symbol/name not. and foreign location only for xc tx.
i think is_sufficient should be moved as close as possible to transfer routines, ideally into orml tbh.
AR may not store field, but just deletage TX to update it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Statemine has such a field in their assets pallet. I think it will be faster to handle is sufficient on our side than in ormls and we will control exact behavior we need. Ratio is None can be an alternative to deciding if asset is nonsufficient, i think we should keep ED to not depend on orml tokens in this implementation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah. good. thank you
@kkast please
|
|
||
### ED Manipulation | ||
|
||
Existential Deposit(ED) is a safeguard against bloating storage of the chain. If a user transfers a nonvaluable asset and sets its ED to 0 or 1, this user will be able to affect performance of the parachain by transferring this asset to many accounts. Thus, to avoid this potential attack vector, we will use Asset Hub (formerly Statemine) approach of non-sufficient assets: a user to be able to recieve permissionless asset needs to hold ED in PICA on Picasso and LAYR on Composable parachains. This approach will limit the growth of the storage. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this solution
ok, but please do not create new pallet, and plese think to make is suffcient storage in assets, not in asset registrya sit will make code simpler imho. |
Signed-off-by: dzmitry-lahoda <[email protected]>
@kkast please take a look into commit about XCM/IBC permissonless asset creation. Are we ok with that? |
closing in favor of #3777 |
⛓
Design Doc how to handle ED and Ratio Parameters of permissionless assets + minatable Cosmwasm assets
misc
label if it should not be in release notespr-workflow-check / draft-release-check
to finish with success(green check mark) with my changes