Commit Graph
73 Commits
Author SHA1 Message Date
moudyellaz b9173e675f Merge remote-tracking branch 'origin/dev' into moudy/cross-zone-outbox-log
# Conflicts:
#	test_fixtures/fixtures/prebuilt_sequencer_db.dump
#	tools/cross_zone_chat/src/main.rs
2026-08-13 09:35:37 +02:00
Pravdyvy f0861d2497 Merge branch 'dev' into Pravdyvy/multi-sequencer-integration-tests 2026-08-13 04:10:13 +03:00
moudyellaz ae3fd849e3 Merge remote-tracking branch 'origin/dev' into moudy/cross-zone-outbox-log
# Conflicts:
#	artifacts/lez/programs/amm.bin
#	artifacts/lez/programs/associated_token_account.bin
#	artifacts/lez/programs/authenticated_transfer.bin
#	artifacts/lez/programs/bridge.bin
#	artifacts/lez/programs/bridge_lock.bin
#	artifacts/lez/programs/clock.bin
#	artifacts/lez/programs/cross_zone_inbox.bin
#	artifacts/lez/programs/cross_zone_outbox.bin
#	artifacts/lez/programs/faucet.bin
#	artifacts/lez/programs/pinata.bin
#	artifacts/lez/programs/pinata_token.bin
#	artifacts/lez/programs/ping_receiver.bin
#	artifacts/lez/programs/ping_sender.bin
#	artifacts/lez/programs/token.bin
#	artifacts/lez/programs/vault.bin
#	artifacts/lez/programs/wrapped_token.bin
#	test_fixtures/fixtures/prebuilt_sequencer_db.dump
2026-08-12 22:37:45 +02:00
Daniil Polyakov 4ae9b30736 feat(sequencer): add RPC Server Actor 2026-08-12 22:34:14 +03:00
Pravdyvy e146f9ff5a Merge branch 'dev' into Pravdyvy/multi-sequencer-integration-tests 2026-08-12 18:43:09 +03:00
moudyellaz f8da8f40b3 Merge remote-tracking branch 'origin/dev' into moudy/cross-zone-per-block-seen-shard
# Conflicts:
#	artifacts/lez/programs/bridge_lock.bin
#	artifacts/lez/programs/cross_zone_inbox.bin
#	artifacts/lez/programs/wrapped_token.bin
#	test_fixtures/fixtures/prebuilt_sequencer_db.dump
2026-08-12 15:13:30 +02:00
moudyellaz 6a15eaec93 feat(cross-zone)!: have ping_receiver authorize its own peer sources
BREAKING CHANGE: ping_receiver gains a config PDA holding the deliverer and the
peer sources it accepts, ReceiverInstruction gains InitConfig, and Record takes
[source marker, config, record] instead of the record alone. Every emitter aimed
at ping_receiver must name its config account in target_accounts. The
ping_receiver and ping_sender image ids move, and a fresh genesis is required.
2026-08-10 13:30:28 +02:00
Pravdyvy e80c60db35 Merge branch 'dev' into Pravdyvy/multi-sequencer-integration-tests 2026-08-10 13:26:19 +03:00
moudyellaz a04b3eeaa9 feat(cross-zone)!: pin ping_sender's outbox to a genesis-seeded config
BREAKING CHANGE: SenderInstruction::Send drops outbox_program_id and takes the
sender config PDA as its first account, changing both the instruction encoding
and the account list. ping_sender's image id moves, relocating its PDAs and
requiring a fresh genesis. Sequencer, indexer and every peer zone must upgrade
together: a stale decoder re-derives a different dispatch and reports Forged.
2026-08-09 18:01:38 +02:00
moudyellaz 09c68eca86 fix(cross-zone-chat): start outbox ordinals from a free slot 2026-08-09 01:21:07 +02:00
moudyellaz 41936b658b feat(cross-zone)!: make an outbox slot a write-once log entry keyed by its emitter
Closes #675.

BREAKING CHANGE: an outbox message PDA is now derived from the emitting program
as well as the destination zone and ordinal, and the seed domain moves to
/00001/, so every outbox record address changes. `OutboxRecord` gains `emitter`
and `ordinal`, changing its borsh layout, so records written by earlier code are
orphaned at their old addresses and no longer decode. A second `Emit` at the same
(emitter, target_zone, ordinal) now fails the transaction instead of silently
overwriting the record, so a caller must choose an ordinal the chain does not
already hold rather than counting from zero. A fresh genesis is required.
2026-08-09 00:18:14 +02:00
moudyellaz bb54bd0581 docs: simplify comments 2026-08-07 18:30:14 +02:00
Pravdyvy 3cf35096d1 fix: suggestions fix 2026-08-07 14:39:06 +03:00
Artem Gureev 279a9b8313 feat!(lee): derive private authorization from an authorization secret key
BREAKING!

Before: Providing `nsk` was the same as authorizing a regular private
account.

After: A separate `ask` is required, making unauthorized private
updates possible.
2026-08-07 10:41:56 +00:00
moudyellaz e274a4b29d feat(sequencer): count and expose the cross-zone deliveries given up on 2026-08-07 10:13:30 +02:00
Daniil Polyakov 8bbce62290 chore(dashboard_gen): add quantile range check 2026-08-03 23:46:35 +03:00
Daniil Polyakov 218955dd19 feat(sequencer): add status label to transaction application time 2026-08-03 23:46:35 +03:00
Daniil Polyakov acb73dce0c fix(dashboard_gen): use RATE_WINDOW in rate_per_min calculation 2026-08-03 23:46:35 +03:00
Daniil Polyakov 037901fe94 fix(sequencer): differentiate between height and blocks produced by this sequencer 2026-08-03 23:46:35 +03:00
Daniil Polyakov 343ba0b97c feat(dashboard_gen): remove panel json to rust generator 2026-08-03 23:46:35 +03:00
Daniil Polyakov aa6969386e refactor(metrics): improve metrics setup 2026-08-03 23:46:35 +03:00
Daniil Polyakov 849bb6bbe1 feat(metrics): improve mempool and failed transaction metrics & panels 2026-08-03 23:46:35 +03:00
Daniil Polyakov ec53979442 feat(dashboard_gen): make unit an enum 2026-08-03 23:46:35 +03:00
Daniil Polyakov ea36fa2e93 refactor(metrics): move metrics into a separate crates and reuse names in dashboard generation 2026-08-03 23:46:35 +03:00
Daniil Polyakov 462de8f11d feat(tools): add grafana panel json to rust generator 2026-08-03 23:46:35 +03:00
Daniil Polyakov 008eb247e9 feat(tools): add dashboard generator 2026-08-03 23:46:34 +03:00
moudyellaz 09f4bfdd03 feat(cross-zone)!: authorize deliveries by source program and target
BREAKING CHANGE: `CrossZonePeer.allowed_targets` is replaced by `allowed_routes`,
a list of `{src_program_id, target_program_id}` pairs. `InboxConfig.allowed_peers`
is removed.
2026-08-03 04:40:05 +02:00
Artem Gureev e13b4cb237 feat!: key note encryption on the nullifier, drop the output index
BREAKING!

Before: The ciphertext key got generated via using the commmitment and
its index as the key.

After: The ciphertext key replaces the commitment dependence by a
nullifier dependence, still making the key unique by global state. The
nullifier is assumed to be the nullifier of the pre-state of the account.

Mitigation: Use the new decryption algorithm.
2026-07-28 11:09:28 +00:00
moudyellaz 72195ce09e Merge origin/dev 2026-07-23 02:43:53 +02:00
Daniil Polyakov 2d5489c04e feat(sequencer): bootstrap state from Bedrock 2026-07-21 22:46:25 +03:00
moudyellaz f4a5d85c65 refactor(cross-zone): seed cross-zone config via genesis transactions 2026-07-21 15:19:16 +02:00
moudyellaz a806ebb94a refactor(cross-zone)!: register cross-zone programs as base builtins
BREAKING CHANGE: GenesisAction::DeployProgram and IndexerConfig.deploy_programs are removed. The cross-zone programs (inbox, outbox, ping_sender, ping_receiver, bridge_lock, wrapped_token) are now base builtins in testnet_initial_state, because program bytecode exceeds the genesis block inscription limit, so they cannot be shipped through genesis transactions.
2026-07-21 10:50:41 +02:00
moudyellaz a16e22c46c refactor!(cross-zone): deploy programs at genesis instead of builtins
Cross-zone builtin programs are no longer registered in the production
genesis. A zone that participates declares the ones it uses via a new
GenesisAction::DeployProgram (sequencer) and a matching deploy_programs
list (indexer), both resolved through CrossZoneProgram and registered
with with_programs. Cross-zone genesis accounts (inbox config,
wrapped-token config) are seeded through the state constructor for a
receiving zone, and bridge-lock holdings are seeded from their actions
regardless of receiving config, dropping V03State::insert_genesis_account.
GenesisAction amounts now use the Balance alias. Documents cross_zone as
the reference LEZ adapter and the bridge demo as not production-safe.

The sequencer's DeployProgram set and the indexer's deploy_programs are
configured separately, so both nodes now log a deterministic genesis
fingerprint (V03State::genesis_fingerprint) at startup: equal values
confirm the two genesis states agree, a mismatch flags a divergent
deploy set.

BREAKING CHANGE: the genesis state root changes (cross-zone builtins are
out of production genesis) and the sequencer/indexer configs gain the
DeployProgram / deploy_programs list that cross-zone-participating zones
must set.
2026-07-13 19:12:24 +02:00
moudyellaz eff31df9ce Merge origin/dev 2026-07-11 01:12:00 +02:00
Daniil Polyakov 7408955f08 feat!(wallet): wait for deploy tx inclusion in block
Breaking:
  1. Now a lot of wallet commands return `TransactionExecuted`, instead of `Empty`.
  2. Sequencer's `getTransaction()` RPC response changed from `tx` to `(tx, block_id)`
2026-07-09 00:32:53 +03:00
moudyellaz 71c9351727 feat(cross-zone): add interactive two-zone chat demo app 2026-07-04 00:47:20 +02:00
agureev 49d3823a75 chore: remove unused deps 2026-07-02 20:43:34 +04:00
agureev 8e084e22d1 Merge remote-tracking branch 'origin/dev' into artem/viewing-key-binding 2026-07-02 20:04:30 +04:00
Daniil Polyakov d3e507f25d refactor!(artifacts): keep lee and lez artifacts separated 2026-06-24 18:10:41 +03:00
agureev 090c368c14 tests: test and flow updates 2026-06-23 15:51:58 +04:00
moudyellaz 41453fb578 feat(cycle_bench): add public-execution ms calibration for fee model 2026-06-11 03:02:19 +02:00
jonesmarvin8 2104f71e39 feat(key-protocol/nssa)!: PQ resistance primitives for vsk/vpk for shared key agreement (#474)
* initialize pq encryption changes

* key agreement update

* add test and other fixes

* ci fixes

* fix unit tests

* updates from main and ci

* added updated specs for pq encryption

* addressing comments

* addressed comments

* fix clippy errors from main merge

* Rebased to main
2026-06-03 14:40:06 -04:00
Sergio Chouhy 4bcffafe27 refactor!: rename nssa crate to lee
BREAKING CHANGE:
- Crate `nssa` renamed to `lee`; update `Cargo.toml` dependencies from `nssa = { workspace = true }` to `lee = { workspace = true }`.
- Crate `nssa_core` renamed to `lee_core`; update similarly.
- Crate `key_protocol` moved under `lee`; update `Cargo.toml` dependencies from `key_protocol = { workspace = true }` to `lee_key_protocol = { workspace = true }`.
- Type `NSSATransaction` (in `common`) renamed to `LeeTransaction`.
- Error type `nssa::error::NssaError` renamed to `lee::error::LeeError`.
- Error type `nssa_core::error::NssaCoreError` renamed to `lee_core::error::LeeCoreError`.
- All `use nssa::` and `use nssa_core::` import paths must be updated to `use lee::` and `use lee_core::` respectively.
- Guest programs must replace `write_nssa_outputs` with `write_lee_outputs`.
- The sequencer RocksDB column family for the chain state was renamed. Existing databases are incompatible and must be wiped before running the new version.
- Domain separators updated: `"NSSA_seed"` → `"LEE_seed"` (key derivation), `"NSSA/v0.2/KDF-SHA256/"` → `"LEE/v0.2/KDF-SHA256/"` (encryption KDF), `"/NSSA/v0.2/AccountId/PDA/"` →
  `"/LEE/v0.2/AccountId/PDA/"` (public PDA address derivation). All previously derived keys, encrypted outputs, and public PDA addresses are invalidated.
2026-06-01 17:11:42 -03:00
Sergio Chouhy 71be6bae32 Merge branch 'main' into schouhy/private-pdas-as-external-input 2026-05-25 16:32:11 -03:00
Moudy fdec52791d refactor(crypto_primitives_bench): derive account_id from key in encryption bench 2026-05-21 16:44:41 +02:00
Moudy d064f87ad7 refactor: lift criterion html_reports feature to workspace declaration 2026-05-21 16:44:41 +02:00
Moudy a9bf3fbfe7 feat(cycle_bench): add criterion verify bench for G_verify 2026-05-21 16:44:40 +02:00
Moudy fb89e7549b refactor(cycle_bench): split into lib + binary, drop hand-rolled verify timing 2026-05-21 16:44:40 +02:00
Moudy b608d10ca1 feat(crypto_primitives_bench): migrate to criterion harness 2026-05-21 16:44:40 +02:00
Sergio Chouhy 3c6d623c49 feat!: Add new path for externally provided seed to the circuit.
BREAKING CHANGE: add identity variants to the circuit and change semantics for `Claim::Authorized` for private PDAs
2026-05-21 11:22:31 -03:00