Skip to content

Lelantus strip#1802

Closed
levoncrypto wants to merge 1 commit into
masterfrom
remove_lelantus
Closed

Lelantus strip#1802
levoncrypto wants to merge 1 commit into
masterfrom
remove_lelantus

Conversation

@levoncrypto

Copy link
Copy Markdown
Contributor

No description provided.

@coderabbitai

coderabbitai Bot commented Mar 20, 2026

Copy link
Copy Markdown
Contributor

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 94915696-1893-4cc0-8e67-9af5599bf153

📥 Commits

Reviewing files that changed from the base of the PR and between eefaa0a and 7ae30ba.

⛔ Files ignored due to path filters (1)
  • contrib/flathub/org.firo.firo-qt.metainfo.xml is excluded by !**/*.xml
📒 Files selected for processing (144)
  • README.md
  • qa/pull-tester/rpc-tests.py
  • qa/rpc-tests/bip47-sendreceive.py
  • qa/rpc-tests/lelantus_mint.py
  • qa/rpc-tests/lelantus_mintspend.py
  • qa/rpc-tests/lelantus_setmintstatus_validation.py
  • qa/rpc-tests/lelantus_spend_gettransaction.py
  • qa/rpc-tests/llmq-is-spark.py
  • qa/rpc-tests/wallet-dump.py
  • src/CMakeLists.txt
  • src/batchproof_container.cpp
  • src/batchproof_container.h
  • src/bip47/account.cpp
  • src/bip47/secretpoint.cpp
  • src/bloom.cpp
  • src/chain.h
  • src/chainparams.cpp
  • src/coin_containers.cpp
  • src/coin_containers.h
  • src/evo/specialtx.cpp
  • src/evo/spork.cpp
  • src/evo/spork.h
  • src/hdmint/hdmint.cpp
  • src/hdmint/hdmint.h
  • src/hdmint/mintpool.cpp
  • src/hdmint/mintpool.h
  • src/hdmint/test/lelantus_tests.cpp
  • src/hdmint/tracker.cpp
  • src/hdmint/tracker.h
  • src/hdmint/wallet.cpp
  • src/hdmint/wallet.h
  • src/init.cpp
  • src/init.h
  • src/lelantus.cpp
  • src/lelantus.h
  • src/liblelantus/challenge_generator.h
  • src/liblelantus/challenge_generator_impl.h
  • src/liblelantus/coin.cpp
  • src/liblelantus/coin.h
  • src/liblelantus/innerproduct_proof.h
  • src/liblelantus/innerproduct_proof_generator.cpp
  • src/liblelantus/innerproduct_proof_generator.h
  • src/liblelantus/innerproduct_proof_verifier.cpp
  • src/liblelantus/innerproduct_proof_verifier.h
  • src/liblelantus/joinsplit.cpp
  • src/liblelantus/joinsplit.h
  • src/liblelantus/lelantus_primitives.cpp
  • src/liblelantus/lelantus_primitives.h
  • src/liblelantus/lelantus_proof.h
  • src/liblelantus/lelantus_prover.cpp
  • src/liblelantus/lelantus_prover.h
  • src/liblelantus/lelantus_verifier.cpp
  • src/liblelantus/lelantus_verifier.h
  • src/liblelantus/openssl_context.h
  • src/liblelantus/params.cpp
  • src/liblelantus/params.h
  • src/liblelantus/range_proof.h
  • src/liblelantus/range_prover.cpp
  • src/liblelantus/range_prover.h
  • src/liblelantus/range_verifier.cpp
  • src/liblelantus/range_verifier.h
  • src/liblelantus/schnorr_proof.h
  • src/liblelantus/schnorr_prover.cpp
  • src/liblelantus/schnorr_prover.h
  • src/liblelantus/schnorr_verifier.cpp
  • src/liblelantus/schnorr_verifier.h
  • src/liblelantus/sigmaextended_proof.h
  • src/liblelantus/sigmaextended_prover.cpp
  • src/liblelantus/sigmaextended_prover.h
  • src/liblelantus/sigmaextended_verifier.cpp
  • src/liblelantus/sigmaextended_verifier.h
  • src/liblelantus/spend_metadata.cpp
  • src/liblelantus/spend_metadata.h
  • src/liblelantus/test/challenge_generator_tests.cpp
  • src/liblelantus/test/coin_tests.cpp
  • src/liblelantus/test/inner_product_test.cpp
  • src/liblelantus/test/joinsplit_tests.cpp
  • src/liblelantus/test/lelantus_primitives_tests.cpp
  • src/liblelantus/test/lelantus_test.cpp
  • src/liblelantus/test/lelantus_test_fixture.cpp
  • src/liblelantus/test/lelantus_test_fixture.h
  • src/liblelantus/test/range_proof_test.cpp
  • src/liblelantus/test/schnorr_test.cpp
  • src/liblelantus/test/serialize_test.cpp
  • src/liblelantus/test/sigma_extended_test.cpp
  • src/liblelantus/threadpool.h
  • src/libspark/coin.h
  • src/libspark/grootle.h
  • src/libspark/spend_transaction.h
  • src/llmq/quorums_instantsend.cpp
  • src/miner.cpp
  • src/primitives/mint_spend.cpp
  • src/primitives/mint_spend.h
  • src/qt/bitcoin.qrc
  • src/qt/bitcoingui.cpp
  • src/qt/bitcoingui.h
  • src/qt/coincontroldialog.cpp
  • src/qt/forms/optionsdialog.ui
  • src/qt/locale/bitcoin_zh_CN.ts
  • src/qt/optionsdialog.cpp
  • src/qt/optionsmodel.cpp
  • src/qt/optionsmodel.h
  • src/qt/overviewpage.cpp
  • src/qt/overviewpage.h
  • src/qt/res/css/firo.css
  • src/qt/sendcoinsdialog.cpp
  • src/qt/sparkmodel.cpp
  • src/qt/transactiondesc.cpp
  • src/qt/transactionrecord.cpp
  • src/qt/walletmodel.cpp
  • src/qt/walletmodel.h
  • src/qt/walletmodeltransaction.cpp
  • src/qt/walletmodeltransaction.h
  • src/rpc/client.cpp
  • src/rpc/misc.cpp
  • src/rpc/rawtransaction.cpp
  • src/rpc/rpcevo.cpp
  • src/spark/sparkwallet.cpp
  • src/spark/state.cpp
  • src/spark/state.h
  • src/test/CMakeLists.txt
  • src/test/fixtures.cpp
  • src/test/fixtures.h
  • src/test/lelantus_mintspend_test.cpp
  • src/test/lelantus_state_tests.cpp
  • src/test/lelantus_tests.cpp
  • src/test/test_bitcoin.cpp
  • src/txmempool.cpp
  • src/txmempool.h
  • src/validation.cpp
  • src/validation.h
  • src/wallet/CMakeLists.txt
  • src/wallet/crypter.cpp
  • src/wallet/lelantusjoinsplitbuilder.cpp
  • src/wallet/lelantusjoinsplitbuilder.h
  • src/wallet/rpcdump.cpp
  • src/wallet/rpcwallet.cpp
  • src/wallet/test/CMakeLists.txt
  • src/wallet/test/lelantus_tests.cpp
  • src/wallet/txbuilder.cpp
  • src/wallet/wallet.cpp
  • src/wallet/wallet.h
  • src/wallet/walletdb.cpp
  • src/wallet/walletdb.h

Walkthrough

This pull request removes the entire Lelantus privacy protocol implementation and its associated wallet, consensus, RPC, and UI integration from the Firo codebase, consolidating privacy functionality around the Spark protocol instead. All Lelantus cryptographic primitives, state management, transaction validation, minting/spending flows, and related test coverage are deleted.

Changes

Cohort / File(s) Summary
Lelantus cryptographic library
src/liblelantus/*
Entirely deleted: coin types, proof generators/verifiers (Sigma extended, inner product, range, Schnorr), challenge generation, parameters, primitives, thread pool, and all supporting test files.
Lelantus wallet and HD mint tracking
src/hdmint/*, src/wallet/lelantusjoinsplitbuilder.*
Removed HD mint wallet, tracker, pool, and JoinSplit builder; all Lelantus mint generation, serialization, and spend construction logic deleted.
Lelantus consensus and state
src/lelantus.*, src/batchproof_container.*
Deleted block/transaction validation, state management (mints, spends, coin groups), mempool integration, and proof batching for Lelantus; updated batch proof container to Spark-only.
Lelantus transaction/RPC integration
src/validation.*, src/wallet/rpcwallet.cpp, src/rpc/*
Removed Lelantus transaction validation, RPC endpoints (joinsplit, mintlelantus, setlelantusmintstatus, etc.), and stripped references from core validation/mempool logic; updated function signatures.
Lelantus Qt GUI and settings
src/qt/*
Removed Lelantus UI actions, migration dialogs, options (reindexLelantus, autoAnonymize), translations, and icon resources; cleaned up options model and sendcoins flow.
Lelantus unit/integration tests
src/test/*, src/liblelantus/test/*, src/wallet/test/*
Deleted all Lelantus test suites, fixtures, and CMake entries; removed ledger tests covering mint generation, spend validation, state management.
Consensus configuration updates
src/chainparams.cpp, src/evo/spork.*
Set Lelantus start/end/graceful-period blocks to stripped values (1 or 0); removed Lelantus spork enforcement (featureLelantus, featureLelantusTransparentLimit).
Build system
src/CMakeLists.txt, src/wallet/CMakeLists.txt, src/test/CMakeLists.txt
Removed Lelantus source files (hdmint, lelantus, liblelantus, lelantusjoinsplitbuilder) from compilation targets.
Spark subsystem updates
src/spark/*.cpp/h, src/libspark/coin.h
Removed async/thread-pool proof verification in Spark state; added legacy sigma/Lelantus coin types to spark header for chain compatibility; simplified wallet sync calls to synchronous execution.
Supporting refactors
src/primitives/mint_spend.h, src/bip47/account.cpp, src/bloom.cpp, src/coin_containers.h, README.md
Updated/removed Lelantus type declarations, BIP47 masked-payload acceptance, bloom filter handling, and include dependencies; updated documentation to reference Spark only.

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120 minutes

This is a massive, heterogeneous refactor spanning consensus, wallet, RPC, validation, UI, cryptography, and test subsystems. While most changes are straightforward removals (reducing per-file review effort), the critical complexity arises from: verifying no critical dependent code paths are broken, ensuring Spark replacements are complete and correct, validating consensus parameter stripping, confirming all transaction validation/mempool integration is correctly updated, and cross-checking that block connection/disconnection logic properly excludes removed Lelantus state. The sheer breadth requires careful verification across multiple domains.

Possibly related PRs

Suggested reviewers

  • psolstice
  • aleflm

Poem

🐰 The Lelantus chapter closes now with care,
Spark ignites the path to privacy fair,
Old proofs and mints fade into the night,
As Firo's cryptography gleams new and bright! ✨
The rabbit hops onward, protocols in flight! 🚀

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch remove_lelantus

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants