I have rebuilt the Docker-Compose example so that:
-
Dockerfile node adapted so that the current version 5.3.3 is used as the node
-
Dockerfile Wallet
Conversion to current git master status.
I have also installed nginx in the Docker image.
#nginx reverse proxy from outside => 0.0.0.0:13416 nginx => 127.0.0.1:13415
This means that the wallet can also be addressed in a container for the master.
Why is localhost/127.0.0.1 always static here?
I switched to the master because I noticed that the master has the new API endpoint (owner) create_mwixnet_req.
-
mwixnet-first-run-script.sh
I have also passed 0.0.0.0:3000 for the execution of the mwixnet as binding
RUST_BACKTRACE=full mwixnet --testnet --wallet_pass=$WALLET_PASSWORD --bind_addr="0.0.0.0:3000” -
mwixnet/test/docker-compose
Adaptation of the wallet port 13416
Now my nodes (main&test), the wallet with owner&foreign api and the mwixnet are running. The endpoint mentioned above (create_mwixnet_req) returns a SWAPReq object after an init_secure_api:
Parameter
- server_keys The public keys of the servers participating in the mixnet (each encoded internally as a
SecretKey
) - fee_per_hop The fee to be paid to each server for each hop in the mixnet
- commitment The commitment of the output to be mixed
- lock_output Whether to lock the referenced output after creating the request
Example:
Map params = {
‘token’: _token,
‘commitment’:
“0873492adc10c74af23bc6ee7ebab3fec0ce39379b22f39e4b30106dac62bf1e20”,
‘fee_per_hop’: “5000”,
‘lock_output’: true,
‘server_keys’: [
“89cd052dd2ef096bb197ad95d8c9bb47327c7151a3381c8da8ea053c1138221a”
]
};
dynamic resp = await postEncrypted('create_mwixnet_req', params);
Example response:
cosmig + onion,
The response can be used to trigger the mwixnet SwapApi accordingly?
Example see:
I have a small web tool with which I process the secure-api. There’s probably not much left to test the mwixnet!
Currently I still get the following incorrect response:
{
“jsonrpc": ‘2.0’,
“error": {
“code": -32602,
“message": ”Failed to peel onion layer: DeserializationError(UnsupportedProtocolVersion)”
},
“id": 1
}
Can anyone help me here?
ideas:
- Deployment of the containers in a Docker registry?
- Is it possible to create a branch of the grin-docker repo?
- A tool should be developed with which the mwixnet api can be probed, or can the grin-gui already do this?