Commit Graph
313 Commits
Author SHA1 Message Date
wiesche 718350ad2c fix windows test 2026-10-17 09:06:37 +02:00
wiesche 08fb43144c contracts between local accounts 2026-10-17 08:22:41 +02:00
wiesche f080323ec5 merge staging 2026-10-17 07:52:36 +02:00
wiesche 005c7e12df merge staging and resolve conflict 2026-10-15 21:20:50 +02:00
wiescheGitHubJoergardocratdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
90846a4212 Mwixnet wallet support (#783)
* Update rust edition to 2021 (#749)

* build: update rust edition 2021

* cargo: format all

* build: fix tests and warnings

* Save last scanned block info for wallet scanning (#748)

* scan: save last scanned block info for initial wallet scanning

* scan: save start height at scanned block info on outputs collecting

* scan: 10k blocks batches

* fix: include last height into batch on scan

* scan: save hash of last block

* scan: add larger window (2880 blocks) to scan outputs when updating wallet state

* add test batched scan and resume, add scan doc

* rename corrupted restore test

---------

Co-authored-by: Joerg <wiesche89@googlemail.com>

* Bump openssl from 0.10.68 to 0.10.80 (#752)

* Update lmdb (#755)

* wallet: update lmdb from store crate, migrate single backend from trait to struct, update tests cargo deps and design doc

* backend: do not panic on iter and directory creation

* return  iterator errors

* build: update to last node revision

* fix: height selection for scan, remove unused mutability for wallet

* wallet: remove unused mutability conversion

* tx: store slate state at database

* build: cargo fmt

* fix: do not return error when slate not found on tx slate state update

* lmdb: do not collect all tx log records at iterator, show read errors at log

* fix: save slate state, return error if slate not found

* tx: specify amount of bad txs on slate state update error

---------

Co-authored-by: Joerg <wiesche89@googlemail.com>

* Node submodules (#758)

* build: use node submodule as dependency

* ci: checkout submodules

* docs: add contributing and build instruction

* ci: update release build

* git: remove old submodule

* git: grin staging submodule

* git: add submodule dir

* Integrated Tor arti Client (#750)

* tor: integrated client for listener, update tokio to last version

* tor: send transaction with integrated client

* build: code format

* tor: optimize bootstrap percent check

* tor: handle config build error

* tor: do not show slatepack address if tor not launched

* tor: handle keystore errors

* tor: keep service launched

* tor: bootstrap timeout, clean cache before client launch

* tor: post request timeout

* fix: post timeout

* build: update deps after merge

* tor: store arti runtime

* tor: do not send over tor if `manual` arg presents or `skip_send_attempt` set at config

* fix: arg name

* tor: handle arti runtime creation error

* tor: handle connection error

* tor: handle bootstrap error

* tor: handle start service name error

* tor: handle service config creation error

* tor: service proxy errors

* tor: handle service key creation emptiness

* build: format code

* build: update arti to 0.43, hyper to 0.10.1

* api: start foreign listener before tor connection

* tor: handle json parse errors

* tor: prevent to create several client runtimes, ability to recreate

* tor: return bootstrap error

* tor: handle host parse error

* tor: restart proxy on error

* tor: do not use integrated client when config value use_integrated is missing, add logging

* build: update lock file

* Global Tor client state (#762)

* tor: global client state

* tor: optimize init client thread-safety

* tor: handle config change on client init

* tor: add logging for client reuse or reinit

* tor: do not reuse arti client for requests

* Optimize tor sync flow (#763)

* Connection timeout (#765)

* Update deps (#768)

* build: update grin submodule to last staging

* build: update grin submodule

* build: remove remove_dir_all dependency

* build: update rpassword

* build: update semver

* build: remove unused deps

* build: update ring

* build: update lock file deps

* build: update rustyline

* build: update ed25519-dalek

* build: update curve25519-dalek

* build: update age

* build: update uuid

* fix: uuid test

* build: update x25519-dalek

* fix: x25519-dalek build

* build: update arti

* build: update grin submodule

* build: update hyper

* fix: initialize rustls provider for tests

* build: update grin submodule

* fix: rustls install provider

* tor: share getting private key

* fix: show an error on node version parse

* cli: renamed prompt password method

* fix: replace into_boxed_slice with try_from

* fix: dalek tests for onion

* config: comment expanded secret key

* fix: import api body for controller

* password: handle prompt error

* wallet: parse node error message

* tests: do not use random values for sign messages

* build: make hook executable

* build: cargo format all

* rustls: do not install provider at tests and globally

* build: update grin submodule

* build: fix api channel from grin submodule

* args: use read_password for piped prompt

* build: remove unused dep

* test: fixed signature

* preserve piped pw input

---------

Co-authored-by: wiesche <wiesche89@googlemail.com>

* Bump lodash from 4.17.21 to 4.18.1 (#774)

* build: update lodash to 4.18.1

* fix: readme

* docs: add owner api authentication setup

* build: update package-lock.json to version 3

* fix: token result, inline some vars

---------

Co-authored-by: ardocrat <ardocrat@gri.mw>

* Global config instance (#769)

* config: global instance

* fix: cli tests

* fix: owner api tests

* config: save tor config

* fix: owner rpc tests

* fix: set config file path on init and owner api call

* tor: store launched services, get global config at command loop, remove unused listen args, check for empty global config to set default, do not save empty tor config at owner

* api: update config in memory after successful file write

* arti: restart proxy in loop

* fix: comment for tor config save

* config: set or init, update without error

* config: scoped tor config

* build: update lock file

* config: ability to store multiple configurations at memory from config path

* tor: restart service on config change

* fix: owner api test

* foreign: pass tor config from args, stop service, error handling

* arti: move runtime wrapper to single file

* config: read existing config from file at create_config

* config: handle error on read

* arti: single dir for cache

* foreign: register config listener before launch

* config: save temp

* config: remove unused error type

* config: make path and members not optional, return an error on config creation if it exists, pass default tor config to send if not set

* arti: non public runtime wrapper

* config: migrate comments

* fix: rpc tests

* config: return from cache if exists

* config: save disabled tor config when null provided at owner and tor section was not set

* config: update tor with args at listener

* config: pass pathbuf directly on creation

* config: unique tmp file name, setting permissions and providing config version

* fix global config handling

* fix config persistence

* fix tor service restart

* fix config synchronization

* require wallet close before changing data directory

* unify global config updates

---------

Co-authored-by: wiesche <wiesche89@googlemail.com>

* Wrong Slatepack address fix (#773)

* Use native tls for client (#779)

* client: use native tls and disable default features for reqwest

* build: bring back reqwest default features except tls

* client: remove tls selection

* expose mwixnet onion apis (#781)

* Update jayson and uuid (#777)

* build: update jayson and uuid

* npm: update lock file to v3

* npm: update lock file

---------

Co-authored-by: ardocrat <ardocrat@gri.mw>

* Optimize outputs scan and selection (#780)

* Make updater APIs public (#782)

* Add mwixnet wallet request support

* mwixnet key conversion tests

* validate and track mwixnet requests

* fix Arti HTTP POST request formatting

* add mwixnet wallet CLI submission

* unlock mwixnet outputs when requests are not sent

* support automatic mwixnet output selection

* move mwixnet response parsing to libwallet

* limit mwixnet hops

* centralize grin workspace dependencies

* fix tx filter

* handle unavailable terminal colors

* reject invalid invoice locking

* clarify bip32 derivation paths

* restore derivation path comments

* tor: downgrade arti to 0.43

* owner: put active account on top of list

* account table layout

* fix: some typos, imports, unwraps and formatting

* tx: lock outputs before sending with tor

* accounts: display balances at CLI and from owner API when min confirmations are set

* unpack plain slatepacks without password (#805)

* unpack plain slatepacks without password

* cli: better open wallet handling on wallet subcommand

---------

Co-authored-by: ardocrat <ardocrat@gri.mw>

* account: do not skip info from serialization, fix owner rpc test

* reject zero send amounts (#799)

* cli: fix short for min confirmations at accounts subcommand

* accounts: optimize accounts selection

* owner: document minimum_confirmations for accounts

* accounts: optimize selection

* preserve accounts api compatibi and clean up balances

* avoid empty wallet seeds (#801)

* fix empty wallet seeds

* mnemonic: return actual error with entropy size on recovering

* seed: extend mnemonic error description

* seed: clarify mnemonic errors

* seed: clarify mnemonic errors, fix missing phrase test

* Clean up seed handling add test

---------

Co-authored-by: ardocrat <ardocrat@gri.mw>

* owner: use same wallet lock for selecting and locking outputs on send

* fix: do not lock for late lock

* cli: explain how to cancel

* fix: error message for offline address and integrated tor

* test: late lock for cli and owner api

* wallet: persistence for active account

* fix: owner_rpc test

* fix: lock wallet till lock outputs on send

* fix: update docs when to call tx_lock_outputs

* build: update grin submodule

* tests: get rid of owner_single_use to use correct config path

* test: parallel send attempts

* fix: cancel hint

* fix: late lock test refresh balance

* fix: set active account at single batch

* owner: document persistence of set_active_account

* cli: error when create and active args are present at account

* fix: keep display account type as str

* restore windows test fixes

* fix locking docs cancel hint and tests

* test cli send failure

* fix current account flag

* fix active account use

* test account persistence

* fix cli account selection

* fix: cmd tests

* fix: cmd test

* fix account test

* Show HTTP status when node requests fail (#820)

* ci: cargo clippy

* fix submodule checkout

* update grin for clippy fixes

* isolate tests

* fix cli test

* fix clippy warnings

* fix mwixnet output lookup

* build: update grin submodule

* git: add clippy to hook

* fix review nits

* fix checks

* mwixnet: use MwixnetServerPublicKey wrapper for hop

* build: update grin submodule

* build: clippy fixes

* mwixnet: rename dalek public key

* simplify mwixnet keys

* clarify mwixnet docs

* clarify arti usage

* simplify mwixnet tests

* tidy mwixnet code and docs

* skip spent outputs

* simplify mwixnet send

* drop host clone

* fix mwixnet selection and arti errors

* make mwixnet fee optional

* mwixnet: use fee at amount format, show min on error

* fix: fee per hop test

* fix: fee error text check

* tor: increase circuit timeout to 60

* fix mwixnet refresh and help

* build: update grin submodule and mwixnet tests

* cli: do not update wallet state on cancellation of tx after failed mwixnet request

* mwixnet: create separate owner api method to send request, do not cancel tx on failed mwixnet request

* fix mwixnet cli args and error messages

---------

Co-authored-by: ardocrat <ardocrat@gri.mw>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-10-15 21:15:56 +02:00
ardocratandGitHub b8ddf13001 Slatepack address index on send (#821)
* Store address_index into tx log entry to get address and decrypt slatepack message, increment over all values

* Provide address index on send and issue_invoice command

* Keep 0 index for receive

* Use sender address index at payment proof

Rust API users need to update to SlatepackAddressIndex and the Slatepack methods
Keep a wallet database backup for pending transactions and saved address indices. Seed recovery alone does not restore these, and the address counter restarts at 1.
2026-10-13 16:41:29 +03:00
ardocrat ab03ccf596 Merge branch 'refs/heads/master' into merge_master_staging
# Conflicts:
#	api/src/owner.rs
#	controller/src/display.rs
#	controller/tests/accounts.rs
#	controller/tests/mwixnet.rs
#	controller/tests/revert.rs
#	controller/tests/slatepack.rs
#	controller/tests/transaction.rs
#	controller/tests/tx_list_filter.rs
#	grin
#	impls/src/lifecycle/default.rs
#	libwallet/src/api_impl/owner.rs
#	libwallet/src/internal/selection.rs
#	libwallet/src/internal/tx.rs
#	tests/cmd_line_basic.rs
2026-10-12 13:59:25 +03:00
wiescheandardocrat f097811ee9 bump to version 5.5.1 2026-10-11 00:45:56 +03:00
wiescheandardocrat 6c9c5e6b36 fix late lock self send proof (#829) 2026-10-11 00:45:56 +03:00
ardocrat fcb1d37876 Compact transaction table at CLI view (#822)
(cherry picked from commit 965e8f1667)
2026-10-11 00:45:56 +03:00
ardocrat 2302135709 Lock outputs before sending with Tor (#814)
Co-authored-by: wiesche <wiesche89@googlemail.com>
(cherry picked from commit 452a3ec51b)
2026-10-11 00:45:56 +03:00
wiescheandardocrat 90d81a856a reject zero send amounts (#799)
(cherry picked from commit 4a487390bd)
2026-10-11 00:45:56 +03:00
wiescheandardocrat 5adceaae78 fix tx filter (#795)
(cherry picked from commit 0d5ea84bfd)
2026-10-11 00:45:56 +03:00
wiescheandardocrat 78ae279bdf reject invalid invoice locking (#798)
(cherry picked from commit 645363436d)
2026-10-11 00:45:56 +03:00
wiescheandardocrat 2daa36f748 handle unavailable terminal colors (#797)
Co-authored-by: ardocrat <ardocrat@gri.mw>
(cherry picked from commit 99cca5b8bf)
2026-10-11 00:45:56 +03:00
wiescheandardocrat 4cb67d9e54 clarify bip32 derivation paths (#800)
Co-authored-by: ardocrat <ardocrat@gri.mw>
(cherry picked from commit f585c70eba)
2026-10-11 00:45:56 +03:00
wiescheandardocrat 31635576d7 display slatepack addresses (#808)
(cherry picked from commit 18da793ace)
2026-10-11 00:45:56 +03:00
wiescheandardocrat bded95e282 use current header version in new slates (#804)
* use current header version

* flip header version check and bump min node version

(cherry picked from commit 991ba1a1f7)
2026-10-11 00:45:56 +03:00
wiescheandardocrat ac4d18d6bd reject wrong slate states in receive and finalize (#807)
(cherry picked from commit e5e319b47e)
2026-10-11 00:45:56 +03:00
wiescheandGitHub d2d893da72 fix late lock self send proof (#829) 2026-10-10 12:58:07 +02:00
ardocratandGitHub 965e8f1667 Compact transaction table at CLI view (#822) 2026-10-07 22:13:12 +03:00
fe79256467 Add linter to CI (#823)
Co-authored-by: wiesche <wiesche89@googlemail.com>
2026-10-07 20:48:38 +03:00
2d87b8c894 Accounts balances (#815)
Co-authored-by: wiesche <wiesche89@googlemail.com>
2026-09-28 11:20:01 +03:00
452a3ec51b Lock outputs before sending with Tor (#814)
Co-authored-by: wiesche <wiesche89@googlemail.com>
2026-09-26 15:18:16 +03:00
wiescheandGitHub 4a487390bd reject zero send amounts (#799) 2026-09-21 20:41:34 +02:00
f31f307767 unpack plain slatepacks without password (#805)
* unpack plain slatepacks without password

* cli: better open wallet handling on wallet subcommand

---------

Co-authored-by: ardocrat <ardocrat@gri.mw>
2026-09-18 21:29:34 +02:00
wiescheandGitHub 0d5ea84bfd fix tx filter (#795) 2026-09-16 14:07:47 +03:00
wiescheandGitHub 645363436d reject invalid invoice locking (#798) 2026-09-16 14:07:21 +03:00
99cca5b8bf handle unavailable terminal colors (#797)
Co-authored-by: ardocrat <ardocrat@gri.mw>
2026-09-16 14:06:41 +03:00
wiescheandGitHub 0f7aa2f7fa centralize grin workspace dependencies (#787) 2026-09-16 14:06:12 +03:00
f585c70eba clarify bip32 derivation paths (#800)
Co-authored-by: ardocrat <ardocrat@gri.mw>
2026-09-16 13:50:51 +03:00
wiesche edb0660ea3 merge staging 2026-09-15 22:30:41 +02:00
wiesche 0683a3a307 share proof amount and drop serde defaults 2026-09-15 21:59:15 +02:00
wiescheandGitHub 18da793ace display slatepack addresses (#808) 2026-09-15 20:34:26 +02:00
wiesche a1d683294b fix early proof export and slatepack account errors 2026-09-15 20:28:20 +02:00
wiescheandGitHub 991ba1a1f7 use current header version in new slates (#804)
* use current header version

* flip header version check and bump min node version
2026-09-15 19:42:56 +02:00
wiescheandGitHub e5e319b47e reject wrong slate states in receive and finalize (#807) 2026-09-14 21:08:36 +02:00
wiesche 049e73ac07 clean up contract tests 2026-09-14 08:13:48 +02:00
wiesche cf488920db clean up wallet code 2026-09-14 07:42:44 +02:00
wiesche 2ca3637a27 clean up contracts 2026-09-13 08:20:22 +02:00
wiesche b648b65024 share status output 2026-09-12 19:31:22 +02:00
wiesche f1d11e38ab simplify contract amounts 2026-09-12 18:20:43 +02:00
wiesche a8729f525b reuse contract owner 2026-09-12 17:30:03 +02:00
wiesche d73a253903 share slatepack output 2026-09-12 15:53:22 +02:00
wiesche f64e502fcf clean up contracts 2026-09-12 11:19:57 +02:00
wiesche c030970f3e fix slatepack input 2026-09-12 09:47:21 +02:00
wiesche 1527537b57 fix contract setup retries 2026-09-12 08:45:28 +02:00
wiesche 2b6b58a093 fix contract context retries 2026-09-11 19:55:25 +02:00
wiesche d2f37192b3 clean up slatepack TODO 2026-09-08 18:09:44 +02:00
wiesche b0722adce9 infer amount when signing contracts 2026-09-08 18:03:23 +02:00