Commit graph

499 commits

Author SHA1 Message Date
Kristaps Kaupe
b1b53a0d1a
Merge JoinMarket-Org/joinmarket-clientserver#1015: Implement address labeling
21c0e3e758 Implement address labeling (Kristaps Kaupe)

Pull request description:

  Adds new method `setlabel` to `wallet-tool.py` that allows to set label for wallet address. Setting it to empty string removes label. Labels are shown as additional column in `display` and `displayall` methods.

  Full functionality for now is cli only, in Qt GUI is only read-only displaying implemented.

Top commit has no ACKs.

Tree-SHA512: b24c96d4d57ab75a511474898e9087e8cd5faa0e1e9440ab57e6caafbc442a8b4edbbad5d3dbd67f0ed3a0cd95f9cd059924d28956869456901fb27dba0530d6
2021-11-02 11:43:36 +02:00
Kristaps Kaupe
21c0e3e758
Implement address labeling 2021-11-02 11:32:00 +02:00
Adam Gibson
d01e9bc0ca
update version to 0.9.4dev 2021-10-29 19:54:56 +01:00
Adam Gibson
fce946db75
add release notes and version for 0.9.3 2021-10-20 14:24:40 +01:00
Adam Gibson
ebd04648a9
Merge #1035: Rename yield generator's txfee settings to txfee_contribution
c2729c0 fix typo (Kristaps Kaupe)
a542680 Rename yield generator's txfee settings to txfee_contribution (Kristaps Kaupe)
2021-10-19 15:59:32 +01:00
Adam Gibson
4b8d499a90
update version to 0.9.3dev 2021-10-19 15:44:07 +01:00
Kristaps Kaupe
a5426808e3
Rename yield generator's txfee settings to txfee_contribution 2021-10-16 12:00:07 +03:00
Adam Gibson
ff10262c78
Merge #996: Rpc api 2
7e73e4c Add websocket for subscription, OpenAPI spec (Adam Gibson)
1688d2d Adds listutxos and heartbeat route, several fixes (abhishek0405)
80e17df Add jmwalletd script as RPC server. (Adam Gibson)
2021-10-10 16:49:14 +01:00
Adam Gibson
7e73e4caa9
Add websocket for subscription, OpenAPI spec
1. Moves the JMWalletDaemon service class into
the jmclient package (see the wallet_rpc.py module).
2. Adds dependencies "klein" and "autobahn" to the
jmclient package, as well as "pyjwt".
3. Adds another module websocketserver.py, using
autobahn, to allow the JMWalletDaemon service to
serve subscriptions over a websocket, for e.g.
transaction notifications.
4. Adds tests both for the websocket connection
and for the JSON-RPC HTTP connection.

JmwalletdWebSocketServerFactory.sendTxNotification
sends the json-ified transaction details using
jmbitcoin.human_readable_transaction (as is currently
used in our CLI), along with the txid.
Also adds a coinjoin state update event sent via
the websocket (switch from taker/maker/none).
Require authentication to connect to websocket.

5. Add OpenApi definition of API in yaml;
also auto-create human-readable API docs in markdown.
6. Add fidelity bond function to API
7. Add config read/write route to API
8. Remove snicker rpc calls temporarily
9. Updates to docoinjoin: corrects taker_finished
   for this custom case, does not shut down at end.
10. Address detailed review comments of @PulpCattel.
2021-10-10 16:41:02 +01:00
abhishek0405
1688d2d2dc
Adds listutxos and heartbeat route, several fixes
The /utxos route is the equivalent of the showutxos
wallet tool method.
The heartbeat route /session allows a client to
make sure the backend is still running and in the
expected state (but see later commits for the
coinjoin state update via the websocket).

Fixes to sendpayment, the maker service,
the create wallet function.
sendpayment fix
Also substantially improved and made
functional the coinjoin route, a schedule
is now created and a complete taker-side
coinjoin is now possible.
2021-10-10 10:50:00 +01:00
Adam Gibson
80e17df4a6
Add jmwalletd script as RPC server.
Uses Klein to provide HTTP server support.
Adds cookie based auth to requests (made JWT token
based in later commits).
Basic routes are: /unlock, /lock, /display,
/create of wallet.
Encapsulates WalletDaemon as a Service
Add snicker receiver service start, stop
Adds yg/maker function as stoppable service.

Adds a JMShutdown command to
the AMP protocol, allowing a clean shutdown
of a long running bot (e.g. maker) by shutting
down its message channel connections, without
shutting down the entire process.

Adds payment(direct send) request, first draft
2021-10-10 10:50:11 +01:00
Kristaps Kaupe
658952ed76
Merge JoinMarket-Org/joinmarket-clientserver#1013: Reorder the tabs in Qt
bc71997058 Reorder the tabs in Qt (Wukong)

Pull request description:

  The current ordering of the tabs in Qt feels very strange. For example, the "Settings" tab is usually the last tab in most applications, while it's the 2nd tab in JoinMarket-Qt.

  This PR reorders the tabs from "JM Wallet, Settings, Coinjoins, Tx History, Coins" to "JM Wallet, Tx History, Coinjoins, , Coins, Settings".

  I made the new ordering of the tabs by consulting the Electrum wallet, which has the tab orders of "History, Send, Coins".

ACKs for top commit:
  kristapsk:
    ACK bc71997058

Tree-SHA512: 8133764152316e31b475a80b7e55cc06f416a93fb787f08cde6935e4c2e5fc8d1b6f9245c11854bc13c8e2d274be424099bbcc07a1f5be860da3a5e4dca433d4
2021-10-09 15:42:36 +03:00
Adam Gibson
a50edfa524
add release notes and version for 0.9.2 2021-10-01 12:22:38 +01:00
Kristaps Kaupe
0e80b2dee7
Show fidelity bond value in manual order picking 2021-09-25 22:04:40 +03:00
Wukong
8085a4e86e Set fidelity_bond_weighted_order_choose as default 2021-09-18 11:28:03 -07:00
Wukong
bc71997058 Reorder the tabs in Qt 2021-09-09 13:31:06 -07:00
Kristaps Kaupe
aaebb1a506
Merge JoinMarket-Org/joinmarket-clientserver#1014: Hide the donateLayout as it is currently disabled.
6ff1a65622 Hide the donateLayout as it is currently disabled. (Wukong)

Pull request description:

  The current Coinjoins tab has a disabled donation checkbox:
  ![image](https://user-images.githubusercontent.com/87334822/132644961-225b303c-be4b-4642-ae9e-be618d6003b7.png)

  When a user click the More button, it shows the following message:
  ![image](https://user-images.githubusercontent.com/87334822/132645137-de9a9a1c-bbf5-4937-9fe6-2c27e665ff31.png)

  I think it's not a great idea to show the donation feature while it's disabled, so I propose in this PR, that we hide this section entirely until we re-enabled the donation feature.

ACKs for top commit:
  kristapsk:
    utACK 6ff1a65622

Tree-SHA512: b4a320667b67ff471a17382988cf53bd9f1b56e896adf108d0f244424249d0fb742c85003fabd478aeb22e6df1ea800473b82bb164c8f6002aceee7226dad6a4
2021-09-09 21:30:40 +03:00
Adam Gibson
14addf097a
Merge #932: Show an Open Wallet dialog upon launching the app
2ed3f21 Update the url links in setup.py files (Wukong)
1dd1679 Show an OpenWallet dialog upon launching JoinMarketQT (Wukong)
2021-09-09 10:58:19 +01:00
Wukong
6ff1a65622 Hide the donateLayout as it is currently disabled. 2021-09-09 00:47:23 -07:00
Wukong
1dd1679711 Show an OpenWallet dialog upon launching JoinMarketQT 2021-09-08 20:56:48 -07:00
Wukong
f50fa4f74f Add a menu action to force wallet refresh
Co-authored-by: Kristaps Kaupe <kristaps@blogiem.lv>
2021-09-08 20:18:30 -07:00
Kristaps Kaupe
c94404658a
chmod +x 2021-09-08 09:51:24 +03:00
Adam Gibson
7eaf368dd7
Fix ob-watcher script after dust threshold change
Before this commit, the ob-watcher.py script errored
in trying to read offers because the variable
dust_threshold of the OrderbookWatch class was not
initialized; this was because this variable is now
set by the client in the AMP message JMInit; but
ob-watcher is a script that runs without any such
client. Since the script has access to the global
configuration from the jmclient package anyway, the
fix is just to add that into the ObBasic class
constructor.
2021-09-07 09:19:50 +01:00
Adam Gibson
50f5228498
Merge #921: added opt-in replace-by-fee support for direct sends
635f3f1 Adds test case for fee bumping a tx using PSBT (Adam Gibson)
b19888e add opt-in rbf support for direct sends (Tim Akinbo)
2021-09-06 13:55:19 +01:00
Adam Gibson
cb0f75da12
Merge #972: Qt: Uppercase simple bech32 BIP21 URI's for QR code encoding
7d884da Uppercase simple bech32 BIP21 URI's for QR code encoding (Kristaps Kaupe)
2021-09-04 16:52:45 +01:00
Erik Arvstedt
53e7bf1018 genwallet.py: Add option --recovery-seed-file 2021-09-01 21:18:42 +02:00
Erik Arvstedt
e4be0343eb Extract function read_password_stdin
This ensures that `wallet_utils.py` and `genwallet.py` use the same logic for
reading the password.

The current algorithm for reading the password entails some
non-obvious details like utf-8 encoding and not stripping trailing
newlines.
2021-08-28 11:17:33 +02:00
Erik Arvstedt
c5621ad774 genwallet.py: Enable Fidelity Bonds by default
This change simply unlocks Fidelity Bonds and has no downsides for users.
2021-08-28 11:17:32 +02:00
Erik Arvstedt
91a8f7f150 genwallet.py: Minor improvments
Changes from top to bottom:
- Add header comment
- Import wallet_utils (needed for DEFAULT_MIXDEPTH)
- Make password optional in usage string
- Set variable wallet_name at the top where options are parsed
- Use DEFAULT_MIXDEPTH instead of hardcoded value
2021-08-28 11:17:31 +02:00
Tim Akinbo
b19888e24f add opt-in rbf support for direct sends
bugfix: use enumerate instead of len

reviewed estimation of transaction sizes

estimates are still a bit conservative with room for improvement;
signatures could still save up to one byte each if using low-r
values. python-bitcointx==1.1.2-dev already supports grinding for
low-r values so when it's stable and referenced version is updated,
this should be reviewed again so as to utilize that benefit.

added utility method `estimate_extra_bytes`

the purpose of this method is for the computation
of extra bytes when the coinjoin or direct send output
type is different from that of the wallet

updated tests to reflect new transaction size
computation

p2pkh transactions are now 1 byte larger for
the inputs hence the change amount should be
less 4 * 30 sats.

add private keys for utxos that we may not be
tracking

some transactions (e.g. opt-in rbf) may require signing
with private keys for utxos that we may have stopped
tracking. this commit will search through all inputs
and for those we own and retrieve their private keys
so we can sign with them.

added support for p2wsh output scripts in

refactored the estimation of the transaction size
when outputs of a different type is the target

Previously, a different method was employed which
was kind of kludgy considering the fact that the
`extra_bytes` parameter is really for `OP_RETURN`
outputs. This method modifies the `estimate_tx_size`
method to accept an optional extra parameter called
`outtype` which is used to estimate the correct
transaction size if the target output is different
from that of the wallet.

added missing import

added a note about preserving the order of wallet type constants

Fix bug with timelocked addrs in receive payjoin

Previously there would be a crash if the wallet receiving a payjoin
had a timelocked UTXO.
2021-08-25 00:35:16 +00:00
Adam Gibson
c898aafdd7
Merge #947: Consistent dust threshold in client and obwatch
24f3aab Consistent dust threshold in client and obwatch (Adam Gibson)
2021-08-23 10:19:22 +01:00
Kristaps Kaupe
a9958888cc
Merge JoinMarket-Org/joinmarket-clientserver#987: Set library file as non-executable
80d0017357 Set library file as non-executable (Erik Arvstedt)

Pull request description:

  .

ACKs for top commit:
  kristapsk:
    utACK 80d0017357

Tree-SHA512: 7c4a64940d5ad29d1ad8ff0f935268da750ccd52a9629722a1ad6e6dd9987b930d3b076e0334d226ae6d8bbb038475907399b4c9561b46a48c72ae831878fe05
2021-08-19 21:44:18 +03:00
Kristaps Kaupe
63f45941f0
Merge JoinMarket-Org/joinmarket-clientserver#945: Qt: Minor context menu improvements
dab61bb9d6 Minor context menu improvements (Kristaps Kaupe)

Pull request description:

  1) Added Ctrl+C keyboard shortcut to "Copy address to clipboard" and "Copy extended public key to clipboard" context menu actions of "JM Wallet" tab.
  2) Renamed "pubkey" to "public key" and "tx" to "transaction" in context menus.

Top commit has no ACKs.

Tree-SHA512: 7c4a64940d5ad29d1ad8ff0f935268da750ccd52a9629722a1ad6e6dd9987b930d3b076e0334d226ae6d8bbb038475907399b4c9561b46a48c72ae831878fe05
2021-08-16 22:49:37 +03:00
Adam Gibson
8b95b3ada0
update version to 0.9.2dev 2021-08-13 17:25:46 +01:00
Adam Gibson
b5c01c4c75
release notes and version 0.9.1 2021-08-13 16:25:09 +01:00
Erik Arvstedt
80d0017357 Set library file as non-executable 2021-08-12 15:25:09 +02:00
Kristaps Kaupe
7d884da1bc
Uppercase simple bech32 BIP21 URI's for QR code encoding 2021-08-06 22:47:08 +03:00
chris-belcher
ce08a0cd85
Fix year 2038 problem in ob-watcher /fidelitybonds 2021-08-04 23:56:02 +01:00
chris-belcher
58d3e596c7
Fix Export Orders page on ob-watcher 2021-08-04 23:54:48 +01:00
openoms
f9ea973be9
fix overflow error on 32bit ARM
based on #857 as discussed in #953
2021-08-02 12:52:33 +01:00
Adam Gibson
ef69ec0348
add release notes and version for 0.9.0 2021-07-31 14:51:00 +01:00
Adam Gibson
24f3aabf9e
Consistent dust threshold in client and obwatch
Fixes #899.
Before this commit, the dust threshold used to filter
orders in `jmdaemon.OrderbookWatch` was different than
that used in `jmclient`. This is corrected by setting
the threshold in client config and passing this as a
parameter in the `JMInit` command (since the daemon
does not know the client config).
2021-07-29 22:35:34 +01:00
Kristaps Kaupe
dab61bb9d6
Minor context menu improvements 2021-07-28 17:27:54 +03:00
Adam Gibson
f6eaafc31a
Merge #942: Fix Qt wallet view update to be reactive
f857e6e Fix Qt wallet view update to be reactive (Adam Gibson)
2021-07-27 16:02:48 +01:00
Adam Gibson
a9f45ed1c8
Merge #937: Support fidelity bond wallet in Qt
b27659c Support fidelity bond wallet in Qt (Wukong)
2021-07-27 15:52:56 +01:00
Adam Gibson
f857e6ef66
Fix Qt wallet view update to be reactive
Previous to this commit, the Qt app had a monitoring
loop that triggered every 5 seconds, recalculating the
wallet view; this turns out to be expensive enough to
create a CPU bound that is noticeable to the user, for
any reasonably large wallet.
After this commit, the view is only updated when a new
transaction comes into the wallet.
2021-07-25 18:50:48 +01:00
Wukong
b27659ce71 Support fidelity bond wallet in Qt 2021-07-23 10:36:41 -07:00
Kristaps Kaupe
7be5e5dfa0
By default auto-expand mixdepth 0 2021-07-23 17:47:01 +03:00
Wukong
0e2850acf2 Auto expand internal addresses that has non zero balances, and only auto expand the external addresses of mix depth 0. 2021-07-20 10:29:47 -07:00
chris-belcher
97b8b3b32a
Show fidelity bonds on orderbook watch html page
Add two new pages for the orderbook watch html server. One displays
each fidelity bond individually, the other shows calculations about
how expensive a successful sybil attack would be against the current
fidelity bonds in the orderbook.
2021-07-20 12:47:56 +01:00