Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
5fc552c
refactor(iota-types): AuthenticatorInfoV1 now follows expected type c…
TheMrAI Sep 3, 2025
336dd74
feat(iota-verifier): Add account `authenticate` verifier
TheMrAI Sep 4, 2025
8baa24c
feat(iota-framework): Add `create_auth_info_v1` native function
TheMrAI Sep 4, 2025
9fb710b
fix(iota-execution): Make CreateAuthInfoV1ImplCostParams with Optiona…
TheMrAI Sep 5, 2025
3b36b75
fix(iota-json-rpc-tests): Add new framework module names to the test
TheMrAI Sep 5, 2025
59f6f35
fix(iota-swarm-config): Update populated_genesis_snapshot_matches tes…
TheMrAI Sep 5, 2025
0ad82a7
Fix typos and remove confusing doc section in create_auth_info_v1
TheMrAI Sep 8, 2025
8b57209
Add copy, drop to AuthenticatorInfoV1
TheMrAI Sep 9, 2025
82eda5b
Rename the authenticateor info constant to include the version number
TheMrAI Sep 9, 2025
458aa71
Fix CI pipeline
TheMrAI Sep 9, 2025
df1d8fa
feat(iota_account): implementation of a Move package to represent a b…
Dkwcs Aug 19, 2025
23c5e07
fix: the example is fixed to be compilable
valeriyr Sep 9, 2025
698b676
feat: add `iota_account2`
valeriyr Sep 9, 2025
36227e0
refactor: leave only `iota_account2` example, improve the implementation
valeriyr Sep 9, 2025
1463f49
feat: update compiled move framework
valeriyr Sep 9, 2025
eb7e1b6
fix: update snapshots
valeriyr Sep 9, 2025
90accdd
fix: make dprint happy
valeriyr Sep 9, 2025
e537b79
refactor: code cleanup, add a df name checking, add errors
valeriyr Sep 10, 2025
aaa3a95
feat: improve tests
valeriyr Sep 10, 2025
f9f4fec
fix: after rebase
valeriyr Sep 11, 2025
f8eaed8
Merge branch 'vm-lang/aa-auth/8116-feature-branch' into vm-lang/aa-au…
valeriyr Sep 11, 2025
84c670b
fix: update snapshots
valeriyr Sep 11, 2025
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
Binary file not shown.
2 changes: 1 addition & 1 deletion crates/iota-framework-snapshot/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@
]
},
"12": {
"git_revision": "6ac6db501d0baf15a3528ef82af63be25256333e",
"git_revision": "f8eaed84f74559e1588c79c7addc1d51f44319c5",
"packages": [
{
"name": "MoveStdlib",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ use std::ascii;

/// Dynamic field key, where the system will look for a potential
/// authenticate function.
#[allow(unused_const)]
const AUTHENTICATOR_ID: vector<u8> = b"IOTA_AUTHENTICATION";
const AUTHENTICATOR_DF_NAME: vector<u8> = b"IOTA_AUTHENTICATION";

#[allow(unused_field)]
public struct AuthenticatorInfoV1 has copy, drop, store {
Expand Down Expand Up @@ -41,3 +40,18 @@ native fun create_auth_info_v1_impl(
module_name: &vector<u8>,
function_name: &vector<u8>,
): AuthenticatorInfoV1;

/// Returns the dynamic field name where the system will look for an authenticate function.
public fun authenticator_df_name(): vector<u8> {
AUTHENTICATOR_DF_NAME
}

/// Creates an `AuthenticatorInfoV1` instance for testing, skipping validation.
#[test_only]
public fun create_auth_info_v1_for_testing(
package: address,
module_name: ascii::String,
function_name: ascii::String,
): AuthenticatorInfoV1 {
AuthenticatorInfoV1{ package: package.to_id(), module_name, function_name }
}
Binary file modified crates/iota-framework/packages_compiled/iota-framework
Binary file not shown.
3 changes: 3 additions & 0 deletions crates/iota-framework/published_api.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1273,6 +1273,9 @@ create_auth_info_v1
create_auth_info_v1_impl
fun
0x2::account
authenticator_df_name
public fun
0x2::account
ProgrammableMoveCall
public struct
0x2::programmable_transaction
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ system_state_version: 1
iota_treasury_cap:
inner:
id:
id: "0x46781695e9849203cc8fe122246bd36a56b5e7ed5cf3d1a7dbf73b3fdbbc4a08"
id: "0xd852e5ea2b27042864078481d68a4ab84d1d581608994bf66c3c9cbc7c643897"
total_supply:
value: "751500000000000000"
validators:
Expand Down Expand Up @@ -244,56 +244,56 @@ validators:
next_epoch_primary_address: ~
extra_fields:
id:
id: "0x2aa7c1e0fbe49cbc7372703177a10c073597b7580c915577098d8b040e20eb7b"
id: "0x6898a9b7cc2af743b6ed0cd32435d14114f95466e6e13badde1e88edff5639fe"
size: 0
voting_power: 10000
operation_cap_id: "0x23d5db42bc7b0fc9373e2c723301e32ef6e52c16aaba30dbc15c1fbf405e7a8c"
operation_cap_id: "0xf14b806a893a663b11594026e22674b3c225c60445849c5a9dcf52012bbeaf2c"
gas_price: 1000
staking_pool:
id: "0xe4a65901c2ea28ef0693ebfdf8c3ebe2296193a5f1d899f67b2101b0246152f5"
id: "0xf1fbb033da4a875b71fd580b3ad8e8805603d5696cfb17b5e20317c4eb6572d6"
activation_epoch: 0
deactivation_epoch: ~
iota_balance: 1500000000000000
rewards_pool:
value: 0
pool_token_balance: 1500000000000000
exchange_rates:
id: "0x5afc020eaa1ef02deace359aaf2304382a5a81434f5d7f798db5b8b485e75310"
id: "0x0f962129e10b1fef4b58279cea5ea716c64a7dedced5f9f2a674067727c61032"
size: 1
pending_stake: 0
pending_total_iota_withdraw: 0
pending_pool_token_withdraw: 0
extra_fields:
id:
id: "0xde0c13305094e6ce7651414e2b8039414cff203299da84f61394d6eebaa249c4"
id: "0x7fc6bb07595cd4396222124d158a0d28a3aaed7bc7510a826a6e4270561157b3"
size: 0
commission_rate: 200
next_epoch_stake: 1500000000000000
next_epoch_gas_price: 1000
next_epoch_commission_rate: 200
extra_fields:
id:
id: "0x3ae93351e6304de8027a86df4e46df29c0eeb8167ec3e3b412d96ea8c0972e53"
id: "0xedddc1fd70dd5b0c4573e86cbf9e44e125afa8c294820098e33fbf12e868113a"
size: 0
pending_active_validators:
contents:
id: "0x5b0584210ae0672ee90ed9e5d74c9211942b11262fbdf7044e06e58179548b9b"
id: "0xd281062f8ca0830392f7bc28eff94b1f48d8ebf4ad117f2a406b807da40845b0"
size: 0
pending_removals: []
staking_pool_mappings:
id: "0x17591563df6e79f881775c76ea220fcb59c3d900b6d745288340f9d25b501a8e"
id: "0xd5843427bf47a797a277eba481f1a6e0b278893b8008017cf77a9d0efc99269f"
size: 1
inactive_validators:
id: "0xfbc66435fa6d70256beec41a40d271d32eada88a66aced1d24ce38dc9b699e70"
id: "0x011d114fdc1da19f7b3476201d06776e45f2084fdf50c2bb142262a7d6e44a74"
size: 0
validator_candidates:
id: "0x6aa1d289535ca32d76eeaaf7bd69a20477abbe6ba10669ba7e46d690392b32fb"
id: "0x32429678e849828240dbea3c6f07150b34c048e5dfd41c92fa08d82d94ecd6fd"
size: 0
at_risk_validators:
contents: []
extra_fields:
id:
id: "0x6f5adf68a2074503511017a7ba234ef2ac4646e9a11d0d29eeda7547163f886e"
id: "0x937091036bf111e639c02b46841b154a7b57ff22f1d5f6124af4f46101c2d22c"
size: 0
storage_fund:
total_object_storage_rebates:
Expand All @@ -310,7 +310,7 @@ parameters:
validator_low_stake_grace_period: 7
extra_fields:
id:
id: "0xaf21f3d64a64f5e2b6b51ff56860eb94835a8d28bc2b6fa90feacdef94c0d335"
id: "0x6cfb90cffe027a74d4ac9ec46ab08d777efe7fb52835272c95017f9e0a2a7249"
size: 0
iota_system_admin_cap:
dummy_field: false
Expand All @@ -327,5 +327,5 @@ safe_mode_non_refundable_storage_fee: 0
epoch_start_timestamp_ms: 10
extra_fields:
id:
id: "0x9d10f5b958a28b180f92678cc2fd78dd3a2f03dfd6eb773b72af5e8d2fd0d3d6"
id: "0xa252463fecc87098f017c8d4f751c94eb78a058c1a277ac25f798e661afe6c85"
size: 0
36 changes: 36 additions & 0 deletions examples/move/iota_account/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
[package]
name = "iota_account"
edition = "2024"
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith ([email protected])", "John Snow ([email protected])"]

[dependencies]
Iota = { local = "../../../crates/iota-framework/packages/iota-framework" }

# For remote import, use the `{ git = "...", subdir = "...", rev = "..." }`.
# Revision can be a branch, a tag, and a commit hash.
# MyRemotePackage = { git = "https://some.remote/host.git", subdir = "remote/path", rev = "main" }

# For local dependencies use `local = path`. Path is relative to the package root
# Local = { local = "../path/to" }

# To resolve a version conflict and force a specific version for dependency
# override use `override = true`
# Override = { local = "../conflicting/version", override = true }

[addresses]
iota_account = "0x0"

# Named addresses will be accessible in Move as `@name`. They're also exported:
# for example, `std = "0x1"` is exported by the Standard Library.
# alice = "0xA11CE"

[dev-dependencies]
# The dev-dependencies section allows overriding dependencies for `--test` and
# `--dev` modes. You can introduce test-only dependencies here.
# Local = { local = "../path/to/dev-build" }

[dev-addresses]
# The dev-addresses section allows overwriting named addresses for the `--test`
# and `--dev` modes.
# alice = "0xB0B"
Loading
Loading