Repository navigation
v0.13.0: B5-B9 host-mode state
v0.13.0 — B5–B9 host-mode state for runtime syscalls
v0.13.0 closes out the v0.7.0 audit's TIER 1+2 findings
(B1–B9). The wasm32 path for B5–B9 (get_random, get_time,
get_invocation_counter, get_gas_left, current_signers,
get_notifications) was already correct (each wrapper calls
an extern). The host-mode test framework, however, returned
0 / empty because the host had no state to return — making
it impossible to test contracts that use these syscalls.
Highlights
- B5 —
get_randomhost-mode state. New
NeoVMSyscall::set_active_random(i64)setter. - B6 —
get_time+get_invocation_counterhost-mode state.
Newset_active_time(i64)and
set_active_invocation_counter(i32)setters. - B7 —
get_gas_lefthost-mode state. New
set_active_gas_left(i64)setter. - B8 —
current_signershost-mode state. The dispatch reads
ACTIVE_WITNESSESand serialises each witness as a
[account, Global-scope]2-element array. - B9 —
get_notificationshost-mode state. The dispatch
drains the existing notification recorder.reset_host_state
now also clears the recorder. - 6 new tests in
rust-devpack/tests/b5_b9_host_state.rs.
Test status
- 67 workspace test suites (was 66 at v0.12.0)
- 0 clippy errors, 0 failures
- 4 L7 conformance tests pass
- The v0.7.0 audit's TIER 1+2 (B1–B9) is fully closed.
See CHANGELOG.md for full details.