Skip to content

Document crypto wallet address detection and the crypto_addresses selector - #121

Merged
vstakhov merged 2 commits into
rspamd:masterfrom
c-rosenberg:feature/rules_crypto
Oct 17, 2026
Merged

vstakhov merged 2 commits into
rspamd:masterfrom
c-rosenberg:feature/rules_crypto

Conversation

@c-rosenberg

Copy link
Copy Markdown
Contributor

Summary

Documents the new cryptocurrency wallet address detection in Rspamd. The code change replaces rules/bitcoin.lua with a shared lua_crypto_addresses library, per-currency symbols and a crypto_addresses selector. Link the Rspamd PR here: .

Changes

  • New guide docs/tutorials/crypto_addresses.md, "Detecting crypto wallet addresses":
    • the 12 supported currencies and their symbols, and what is validated;
    • the _MAYBE symbols (Ethereum and EVM chains, Monero), which are format-only;
    • the CRYPTO_ADDR_CHECK parent symbol and the default score of 0;
    • the broader LEAKED_PASSWORD_SCAM composite;
    • the crypto_addresses selector, with a multimap example that sets combinator = "array";
    • the scan limits and the lua_crypto_addresses API, including add_from_string.
  • Selectors reference: adds the crypto_addresses extractor row.
  • Navigation: the guide is listed under How-To Guides in the sidebar and in the tutorials index. It is not listed as a module, since there is nothing to configure.
  • Examples: the SAVE_MAILDIR example now saves to crypto_scam instead of bitcoin, since the composite covers every currency.
  • Cleanup: removes the stale rules/bitcoin.lua references in writing_rules.md, tool-selection.md and regexp.md, because that file no longer exists.

Notes for reviewers

  • The Version column for crypto_addresses in the selectors table is —. Please fill in the release once it is known.
  • No changelog entry is added, since the changelog files are per released version.
  • The site was not built locally, so the sidebar and links are unchecked.

rules/bitcoin.lua was replaced by rules/crypto.lua, which no longer uses
the regexp/re_conditions technique these pages cited as a live example.
Add a how-to guide for the new wallet address rules: supported currencies
and their symbols, what is validated, how CRYPTO_ADDR_CHECK and the
per-currency symbols behave, the broader LEAKED_PASSWORD_SCAM composite,
the crypto_addresses selector with a multimap example, scan limits and
the lua_crypto_addresses API.

List the crypto_addresses extractor in the selectors reference, link the
guide from the tutorials index and the sidebar, and rename the 'bitcoin'
save directory in the SAVE_MAILDIR example, since the scam composite now
covers every currency.
@vstakhov
vstakhov merged commit f93a10e into rspamd:master Oct 17, 2026
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