README.md 2.99 KB
Newer Older
zeroleak's avatar
zeroleak committed
1 2 3
[![Build Status](https://travis-ci.org/Samourai-Wallet/whirlpool-server.svg?branch=develop)](https://travis-ci.org/Samourai-Wallet/whirlpool-server)
[![](https://jitpack.io/v/Samourai-Wallet/whirlpool-server.svg)](https://jitpack.io/#Samourai-Wallet/whirlpool-server)

TDevD's avatar
TDevD committed
4
# whirlpool-server
zeroleak's avatar
zeroleak committed
5 6 7

Server for [Whirlpool](https://github.com/Samourai-Wallet/Whirlpool) by Samourai-Wallet.

zeroleak's avatar
zeroleak committed
8 9
## Installation
See [README-install.md](README-install.md)
zeroleak's avatar
zeroleak committed
10 11 12

## Configuration
### RPC client
zeroleak's avatar
zeroleak committed
13
```
14
server.rpc-client.protocol = http
zeroleak's avatar
zeroleak committed
15
server.rpc-client.host = CONFIGURE-ME
16
server.rpc-client.port = CONFIGURE-ME
zeroleak's avatar
zeroleak committed
17 18 19
server.rpc-client.user = CONFIGURE-ME
server.rpc-client.password = CONFIGURE-ME
```
zeroleak's avatar
zeroleak committed
20 21
The bitcoin node should be running on the same network (main or test).<br/>
The node will be used to verify UTXO and broadcast tx.
zeroleak's avatar
zeroleak committed
22

zeroleak's avatar
zeroleak committed
23
### UTXO amounts
zeroleak's avatar
zeroleak committed
24
```
zeroleak's avatar
zeroleak committed
25
server.mix.denomination: amount in satoshis
26 27
server.mix.miner-fee-min: minimum miner-fee to pay by mustMix
server.mix.miner-fee-max: maximum miner-fee to pay
zeroleak's avatar
zeroleak committed
28
```
29 30 31
UTXO should be founded with:<br/>
for mustMix: (*server.mix.denomination* + *server.mix.miner-fee-min*) to (*server.mix.denomination* + *server.mix.miner-fee-max*)<br/>
for liquidities: (*server.mix.denomination*) to (*server.mix.denomination* + *server.mix.miner-fee-max*)
zeroleak's avatar
zeroleak committed
32

33 34 35 36 37 38
### UTXO confirmations
```
server.register-input.min-confirmations-must-mix: minimum confirmations for mustMix inputs
server.register-input.min-confirmations-liquidity: minimum confirmations for liquidity inputs
```

39 40 41 42 43
### UTXO rules
```
server.register-input.max-inputs-same-hash: max inputs with same hash (same origin tx) allowed to register to a mix
```

zeroleak's avatar
zeroleak committed
44
### Mix limits
zeroleak's avatar
zeroleak committed
45
```
zeroleak's avatar
zeroleak committed
46 47 48 49
server.mix.anonymity-set-target = 10
server.mix.anonymity-set-min = 6
server.mix.anonymity-set-max = 20
server.mix.anonymity-set-adjust-timeout = 120
zeroleak's avatar
zeroleak committed
50

zeroleak's avatar
zeroleak committed
51 52
server.mix.must-mix-min = 1
server.mix.liquidity-timeout = 60
zeroleak's avatar
zeroleak committed
53
```
zeroleak's avatar
zeroleak committed
54 55
Mix will start when *server.mix.anonymity-set-target* (mustMix + liquidities) are registered.<br/>
If this target is not met after *server.mix.anonymity-set-adjust-timeout*, it will be gradually decreased to *server.mix.anonymity-set-min*.<br/>
zeroleak's avatar
zeroleak committed
56

zeroleak's avatar
zeroleak committed
57 58
At the beginning of the mix, only mustMix can register. Meanwhile, liquidities connecting are placed on a waiting pool.<br/>
After *server.mix.liquidity-timeout* or when current *anonymity-set-target* is reached, liquidities are added as soon as *server.mix.must-mix-min* is reached, up to *server.mix.anonymity-set-max* inputs for the mix.
59

60 61 62 63 64 65 66
### Exports
Each mix success/fail is appended to a CSV file:
```
server.export.mixs.directory
server.export.mixs.filename
```

67 68 69
### Testing
```
server.rpc-client.mock-tx-broadcast = false
zeroleak's avatar
zeroleak committed
70
server.test-mode = false
71
```
72
For testing purpose, *server.rpc-client.mock-tx-broadcast* can be enabled to mock txs instead of broadcasting it.
zeroleak's avatar
zeroleak committed
73
When enabled, *server.test-mode* allows client to bypass tx0 checks.
74

zeroleak's avatar
zeroleak committed
75 76 77 78
## Resources
 * [whirlpool](https://github.com/Samourai-Wallet/Whirlpool)
 * [whirlpool-protocol](https://github.com/Samourai-Wallet/whirlpool-protocol)
 * [whirlpool-client](https://github.com/Samourai-Wallet/whirlpool-client)