81 Commits

Author SHA1 Message Date
Marvin Jones
0fd7e8e0f9 fix(keycard): address PR #595 review comments
- Propagate the load_mnemonic error instead of swallowing it behind
  is_ok(), matching every other command handler in this file.
- Add deny.toml allowing the keycard-rs git source, fixing the
  source-not-allowed failure in `cargo deny check`. Licenses and
  advisories checks still have pre-existing, separate failures not
  addressed here.
- Drop the pinned rev for the keycard-rs git dependency so it tracks
  the upstream default branch instead.
2026-07-08 09:49:48 -04:00
Marvin Jones
2dc114c27b docs(keycard): clarify personalization is mandatory and document default CA
Reinstalling the applet via `./gradlew install` wipes any existing
personalization regardless of firmware source, which wasn't previously
called out and is a common source of "card not available" confusion.
Also state plainly that personalization is required before any command
works, and document keycard-rs's actual baked-in default CA public key
instead of only describing the override mechanism.

Export KEYCARD_CA_PUBLIC_KEY in all keycard test scripts so they work
against the dev/test-CA personalization flow they rely on.
2026-07-07 17:04:05 -04:00
Marvin Jones
42b53c6907 Updated to v2 secure communication 2026-07-06 17:41:36 -04:00
Marvin Jones
763464d27b refactor(keycard_wallet): replace keycard-py (pyo3) with native keycard-rs
Rewrites the Keycard integration to talk to the LEE-flavored applet
directly from Rust via keycard-rs (pinned git dependency), dropping the
pyo3 shim, python_path.rs, and the vendored keycard-py Python library
entirely. Verified end-to-end against real hardware: pairing, PIN
verification, mnemonic loading, BIP340 Schnorr signing, and transfers
between keycard and public/private accounts.

Also cleans up the pyo3 usage that had leaked into wallet's signing
path (signing.rs, account_manager.rs) beyond the keycard CLI itself,
and trims wallet_with_keycard.sh's Python setup down to just pyscard,
which is only needed by the force_unpower.py test helper now.
2026-07-06 17:41:36 -04:00
Sergio Chouhy
ae0705995f fix: solve merging conflicts with main 2026-07-03 15:07:35 -03:00
jonesmarvin8
f786aca73e
refactor(lez): clean up long functions (#541)
* add helper functions

* CI fixes

* additional refactors

* fix: clarify doc comment on apply_mempool_transaction

* chore: apply nightly fmt

* fix: import missing ML_KEM_768_CIPHERTEXT_LEN in auth_transfer private test
2026-07-01 10:23:21 -04:00
jonesmarvin8
f8d859394b
refactor(privacy_preserving_circuit): introduce helper functions to shorten long functions (#545)
* refactor(privacy_preserving_circuit): extract functions for readability

* refactor(privacy_preserving_circuit): address PR review comments

Bundle shared handle_* arguments into PrivateOutputHandler struct in
output.rs and fix misplaced docstring on resolve_external_seed in
execution_state.rs.

* feat: update commitment mechanism for new private account (#546)

* refactor(privacy_preserving_circuit): extract functions for readability

* feat: update commitment mechanism for new private accounts

Allow init accounts to optionally use a real membership proof for
DUMMY_COMMITMENT instead of hardcoding DUMMY_COMMITMENT_HASH as the
CommitmentSetDigest. The wallet fetches the proof from the sequencer
and passes it through the circuit.

* fix: address clippy lints and fix integration test visibility

* add tests

* refactor: removed duplicated code

* refactor: simplify init nullifier mechanism

Replace Option<MembershipProof> with Option<CommitmentSetDigest> on init
variants (PrivateAuthorizedInit, PrivateUnauthorized, PrivatePdaInit).
The circuit now receives the commitment tree root directly instead of
recomputing it from a Merkle proof.

* refactor: use CommitmentSetDigest directly instead of Option for init commitment root

Address PR #546 review feedback: the circuit now accepts CommitmentSetDigest
directly on init variants (PrivateAuthorizedInit, PrivateUnauthorized,
PrivatePdaInit), with callers providing DUMMY_COMMITMENT_HASH as the default.
Also fixes duplicate resolve_external_seed from rebase and rebuilds artifacts.

* style: run cargo +nightly fmt
2026-07-01 10:14:32 -04:00
Pravdyvy
97aa85d123
Merge pull request #577 from logos-blockchain/Pravdyvy/wallet-ffi-labels
Wallet ffi labels
2026-07-01 15:32:16 +03:00
Pravdyvy
53ae6dcfdd fix(wallet_ffi): asref suggestion 2026-06-30 12:46:52 +03:00
Daniil Polyakov
fc800a7151 fix(sequencer): don't accept zero deposits & remove unreachable 2026-06-30 12:38:22 +03:00
Pravdyvy
fade3b488a feat(integration_tests): added integration tests for wallet ffi 2026-06-26 16:48:00 +03:00
Pravdyvy
860746dac9 feat(wallet_ffi): labels added 2026-06-25 18:29:35 +03:00
Daniil Polyakov
d11b706756 feat(sequencer): add getChannelId rpc endpoint 2026-06-25 16:47:04 +03:00
Daniil Polyakov
9977cc5374 fix(ci, programs, privacy_preserving_circuit): properly check programs ci 2026-06-24 20:20:40 +03:00
Daniil Polyakov
96b28827f6 fix(tests): fix tests 2026-06-24 20:20:40 +03:00
Daniil Polyakov
c74b03582b refactor!(wallet): pass program_id instead of program in send_pub_tx() 2026-06-24 20:19:12 +03:00
Daniil Polyakov
d3e507f25d refactor!(artifacts): keep lee and lez artifacts separated 2026-06-24 18:10:41 +03:00
Pravdyvy
d8c50ceb59 Merge branch 'main' into Pravdyvy/ffi-mnemonic 2026-06-24 13:02:12 +03:00
Sergio Chouhy
47a94ac7e4 feat(wallet-ffi): add vault claim ffi 2026-06-24 10:35:31 +02:00
erhant
7f0714a79e fix(indexer): the latest docker fix updated bedrock ports, this small commit fixes those 2026-06-23 17:02:47 +03:00
erhant
c7336c3216 fix(indexer): tiny comment link fix [skip ci] 2026-06-23 15:57:33 +03:00
erhant
735235efa1 fix(indexer)!: address @Arjentix comments on IndexerStatus 2026-06-23 15:57:33 +03:00
erhant
2195937400 fix(indexer_ffi): use already FFI-safe Runtime 2026-06-23 15:57:33 +03:00
erhant
5d51e0b59c fix(indexer): use /var/lib/indexer_service volume path in Dockerfile
+ add `*` wildcard for rocksdb ignore
2026-06-23 15:57:33 +03:00
erhant
0bb7b30d63 fix: rm comments, add cpp_compat to cbindgen 2026-06-23 15:57:33 +03:00
erhant
c57bf16d15 feat: added status reporter for indexer (for UI) 2026-06-23 15:57:33 +03:00
erhant
c0fbaaf08e refactor: use channel id for rocksdb filename [skip ci] 2026-06-23 15:57:33 +03:00
erhant
1c1e80f646 feat(indexer)!: make storage location caller-driven, not config-driven
The indexer's storage location was the `home` field of IndexerConfig, used only to derive the RocksDB dir. Defaulting to "." meant it landed in the process CWD — fine for the standalone service, but wrong when the indexer runs embedded in a logos_host subprocess (RocksDB ended up in an arbitrary/unwritable dir). Storage location is an operational concern the host should own, not something baked into a user-editable config.

Remove `home` from IndexerConfig and pass the storage directory explicitly:

  - core: `IndexerCore::new(config, storage_dir)` derives `<storage_dir>/rocksdb`.
  - ffi: `start_indexer(runtime, config_path, storage_dir)`; null/empty storage_dir falls back to ".". Lets a host (e.g. a Logos module's instance persistence path) own where state lives.
  - service: `run_server(config, storage_dir, port)` + a `--data-dir` flag (default ".") on the binary, preserving current behaviour.
  - drop `home` from the committed indexer config JSONs and the test fixtures.

BREAKING CHANGE: `start_indexer` gains a `storage_dir` parameter and IndexerConfig no longer has a `home` field.
2026-06-23 15:57:33 +03:00
erhant
0db82d2344 refactor: better runtime handling + logger lint fix 2026-06-23 15:57:33 +03:00
erhant
4a3fa1d4be refactor: logger now only enables for indexer crates + takes in a loglevel option 2026-06-23 15:57:33 +03:00
erhant
956dc6278a fix!(indexer_ffi): fix 3 existing issues, refactor the runtime handling, rm unused cbindgen.toml 2026-06-23 15:57:33 +03:00
Daniil Polyakov
a6d2241519 fix(docker): tweak some port numbers for better consistency 2026-06-23 15:24:03 +03:00
Daniil Polyakov
cd06f7c0f7 feat(docker): extract risc0 installation into a separate image 2026-06-23 15:24:03 +03:00
Daniil Polyakov
972a7f981b fix(docker): fix dockerfiles to properly build images 2026-06-23 15:24:03 +03:00
Pravdyvy
5c28acc961 fix(wallet_ffi): suggestion fix 2026-06-23 11:10:53 +03:00
Pravdyvy
ca64789a90 Merge branch 'main' into Pravdyvy/ffi-mnemonic 2026-06-22 14:00:08 +03:00
Sergio Chouhy
32c6b9e5fc feat: add withdraw ffi 2026-06-18 16:35:44 -03:00
Pravdyvy
c6d7f37a1a Merge branch 'main' into Pravdyvy/ffi-mnemonic 2026-06-18 18:44:00 +03:00
moudyellaz
87d6869e15 fix(wallet): reset last_synced_block on storage restore so notes re-scan from genesis 2026-06-18 13:33:09 +02:00
Pravdyvy
4185599df6 remove(logos-blockchain-circuits): removed logos blockchains circuits mentions 2026-06-17 13:31:35 +03:00
Pravdyvy
855788c2ea fix(ci): ci fix 2026-06-17 12:54:27 +03:00
Pravdyvy
0fae6aada2 Merge branch 'main' into Pravdyvy/programs-elfs-deployments 2026-06-17 10:36:19 +03:00
Daniil Polyakov
e5ca40c0f9 feat: add bedrock withdraw events validation 2026-06-16 22:10:11 +03:00
Daniil Polyakov
77f1fb3f21 feat(wallet): add bridge withdraw command 2026-06-16 22:10:11 +03:00
Daniil Polyakov
d6e68a52ca feat(state): forbid private bridge withdrawals 2026-06-16 22:10:11 +03:00
Daniil Polyakov
e9e30ff019 feat(sequencer): implement bridge withdraw flow 2026-06-16 22:10:11 +03:00
Pravdyvy
819604d223 Merge branch 'main' into Pravdyvy/programs-elfs-deployments 2026-06-16 09:13:06 +03:00
Pravdyvy
a8c81f5445
Merge pull request #491 from logos-blockchain/Pravdyvy/wallet-ffi-extension
feat(wallet_ffi): wallet ffi generic transactions
2026-06-16 09:11:38 +03:00
Daniil Polyakov
1c7711c10e feat(wallet): add vault cli commands 2026-06-15 21:53:15 +03:00
Pravdyvy
93feaba5de Merge branch 'main' into Pravdyvy/programs-elfs-deployments 2026-06-15 14:15:33 +03:00