Skip to content
Merged
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -287,8 +287,7 @@ end
#! the case when it is created, or when slots are added or removed (currently unimplemented).
#! So, it should be sufficient to do this here instead of in save_account_storage_data.
#!
#! Validates that the account the transaction is being executed against satisfies the criteria
#! for a new account.
#! Validates that the native account satisfies the criteria for a new account.
#!
#! Applies the following validation to the new account:
#! - assert that the account ID uses the supported version and is otherwise valid.
Expand All @@ -305,11 +304,12 @@ end
#! Outputs: []
proc validate_new_account
# Assert the account ID of the account is valid
exec.memory::get_account_id exec.account_id::validate
exec.memory::get_native_account_id exec.account_id::validate
# => []

# Assert the account nonce is 0
exec.memory::get_account_nonce eq.0 assert.err=ERR_PROLOGUE_NEW_ACCOUNT_NONCE_MUST_BE_ZERO
exec.memory::get_native_account_nonce eq.0
assert.err=ERR_PROLOGUE_NEW_ACCOUNT_NONCE_MUST_BE_ZERO
# => []

# Assert the reserved element of the account header word is 0
Expand All @@ -320,7 +320,7 @@ proc validate_new_account
# Assert the initial vault is empty
# ---------------------------------------------------------------------------------------------
# get the account vault root
exec.memory::get_account_vault_root
exec.memory::get_native_account_vault_root
# => [ACCT_VAULT_ROOT]

# push empty vault root onto stack
Expand Down
Loading