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

Validate Asset when wrapping a SAC #1262

Closed
dmkozh opened this issue Nov 29, 2023 · 0 comments · Fixed by #1270
Closed

Validate Asset when wrapping a SAC #1262

dmkozh opened this issue Nov 29, 2023 · 0 comments · Fixed by #1270
Assignees

Comments

@dmkozh
Copy link
Contributor

dmkozh commented Nov 29, 2023

Core enforces a set of rules on the Asset XDR structure when establishing a trustline. SAC doesn't do that, so it's possible to 'wrap' an asset that may never exist in core and then mint it on Soroban. This might be misleading/error-prone, so we should implement the same validation logic in Host as in Core.

@dmkozh dmkozh self-assigned this Nov 30, 2023
github-merge-queue bot pushed a commit that referenced this issue Nov 30, 2023
### What

Validate assets when trying to create SAC instance.

Resolves #1262

### Why

We should only create SAC instances for assets that are potentially
usable; instances based on invalid assets can never be used with classic
accounts, but can be used on Soroban, which might be a source of
confusion/bugs.

### Known limitations

N/A
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant