mirror of
https://github.com/Xahau/xahaud.git
synced 2026-07-23 15:10:10 +00:00
The entropy-quality requirement becomes an explicit, required argument at every call site — there is deliberately no default and no network constant: - dice(sides) -> dice(sides, min_tier, min_count) - random(ptr, len) -> random(ptr, len, min_tier, min_count) - fairRng gates on freshness && tier >= min_tier && count >= min_count; the hard-coded 'EntropyCount >= 5' network constant is deleted — the hook author states what their application needs and gets TOO_LITTLE_ENTROPY when this ledger cannot meet it - WASM imports have no default parameters, so the old no-argument shape was really a hidden constant invisible at the call site; requiring the arguments makes weak-entropy acceptance (min_tier=1) a deliberate, reviewable opt-in rather than an accident - hook/extern.h and hook/sfcodes.h regenerated (CI-verified) - test hooks updated and recompiled; new test pins the requirement gate: dice(6, 3, 21) against count=20 returns TOO_LITTLE_ENTROPY