Commit Graph

11 Commits (9e13034e54151bafe16b0d35d34b3efae9190a44)

Author SHA1 Message Date
Franck Royer 9e13034e54 Extract execution details from driving loop 4 years ago
Philipp Hoenisch 1a38bf57f2
Rename inner to client 4 years ago
Philipp Hoenisch f0fbe785c8
Remove Alice and Bob from utility struct 4 years ago
Philipp Hoenisch 0b9e8c145e
Update xmr-btc lib to use new monero-harness 4 years ago
rishflab c781ee949d Move storage into application crate 4 years ago
Tobin C. Harding 97363cb05c Fix build after merge 4 years ago
Tobin C. Harding f8adf6d7e0 Merge branch 'on-chain-protocol' of github.com:comit-network/xmr-btc-swap into on-chain-protocol 4 years ago
Lucas Soriano del Pino 5395303a99 Test on-chain protocol happy path 4 years ago
rishflab 39afb4196b Save and recover protocol state from disk
NOTE: This implementation saves secrets to disk! It is not
secure.

The storage API allows the caller to atomically record the state
of the protocol. The user can retrieve this recorded state and
re-commence the protocol from that point. The state is recorded
using a hard coded key, causing it to overwrite the previously
recorded state. This limitation means that this recovery
mechanism should not be used in a program that simultaneously
manages the execution of multiple swaps.

An e2e test was added to show how to save, recover and resume
protocol execution. This logic could also be integrated into the
run_until functions to automate saving but was not included at
this stage as protocol execution is currently under development.

Serialisation and deserialisation was implemented on the states
to allow the to be stored using the database. Currently the
secret's are also being stored to disk but should be recovered
from a seed or wallets.
4 years ago
rishflab bf576bf251 Move test functions out of lib 4 years ago
rishflab a759f39b1d Fix module ambiguity in tests 4 years ago