151 Commits
0.0.31 ... firo

Author SHA1 Message Date
tecnovert
601d469801 test: Fix test class inheritance 2022-11-10 23:41:59 +02:00
tecnovert
f65ae07cf9 docker: Add PIVX, Dash and Firo to isolated config
Changed pivx-params location to PIVX datadir.

Still need a way to set the Firo wallet seed.
2022-11-09 19:10:17 +02:00
tecnovert
ae2ddc4049 Log events for all sent transactions. 2022-11-08 23:07:58 +02:00
tecnovert
8b2d2b446b api: Add show_extra parameter to bids endpoint
Add itx_refund_tx_est_final and ptx_refund_tx_est_final to bid extra data
2022-11-08 22:30:28 +02:00
tecnovert
5a73fab045 coins: Add temporary firo release. 2022-11-08 16:48:25 +02:00
tecnovert
c440f9e3a3 coins: Fix Firo seedid 2022-11-08 16:43:44 +02:00
tecnovert
ca264db0d0 Add non-segwit Firo support.
Rework tests to combine atomic and xmr test cases.
Modify btc interface to support P2WSH_nested_in_BIP16_P2SH
Add coin feature tests to test_btc_xmr.py
2022-11-08 13:14:03 +02:00
tecnovert
c0c2c8b9bb ui: Combine viewkeys sections. 2022-10-26 21:13:29 +02:00
tecnovert
515e6655e8 Disable HttpServer log messages. 2022-10-26 18:15:09 +02:00
tecnovert
f210024e93 coins: Decode pivx v3 transactions correctly. 2022-10-26 17:47:30 +02:00
tecnovert
45d6b9ecbf ui: Show red clock for revoked offers. 2022-10-25 23:41:51 +02:00
tecnovert
50ed1bfccf For CLTV coins check the lock value relative to the current time rather than the bid creation time. 2022-10-25 23:28:02 +02:00
tecnovert
18974d9458 test: Fix RESET_TEST=false 2022-10-25 21:51:54 +02:00
gerlofvanek
65183133d8 ui: Expired flag colors + GUI updates/tweaks. 2022-10-25 20:24:18 +02:00
tecnovert
9da907aa1e ui: Add expired flag to offers. 2022-10-24 21:34:12 +02:00
tecnovert
59fb6c18ed coins: Rename Pivx -> PIVX 2022-10-24 20:49:36 +02:00
tecnovert
e46fd193fe ui: Restore xmr bid sequence diagrams. 2022-10-23 16:07:32 +02:00
gerlofvanek
4fc68b5717 ui: Fixes global (GUI v.0.1.1)
- Dash icon and Coin icon updates.
- Removed withids.
- ui: Notification drop-down update.
- ui: Global GUI layout and bug fixes/features.
- ui: Updated New Offer templates.
- ui: Fixed close on messages/error messages.
- ui: Start on new settings page.
- ui: Removed TV chart.
- ui: Drop-down filter with Coin icons.
2022-10-23 13:59:06 +02:00
tecnovert
9557da8714 ui: Add spaces in coin names. 2022-10-23 10:54:02 +02:00
tecnovert
a9f3eeefff ui: Fix notifications. 2022-10-21 21:05:46 +02:00
tecnovert
3c2eb5f9f8 ui: Format notification timestamps. 2022-10-21 20:51:50 +02:00
tecnovert
5701f6e830 Freeze SQLAlchemy version. 2022-10-21 19:00:13 +02:00
tecnovert
aa14da27af dash: Fix initialiseWallet
Only the upgradetohd command sets the hdseed
upgradetohd can only run once the chain is synced

Basicswap stores the hash of the root_key in it's db to check for the expected seed.
Prefer not to store the real key.
2022-10-21 18:39:19 +02:00
tecnovert
4866ff4db8 dash: Add tests. 2022-10-21 00:37:45 +02:00
tecnovert
7298867e18 dash: Add to prepare script. 2022-10-20 22:23:25 +02:00
tecnovert
9fc4fe3b79 debug: Reduce default min_sequence_lock_seconds when debug mode is active. 2022-10-18 21:18:18 +02:00
tecnovert
468d8c5cc1 xmr swap: Set correct block height on refund_tx. 2022-10-18 19:59:46 +02:00
tecnovert
3c84f0230e ui: Inject ids for messages. 2022-10-14 14:22:11 +02:00
tecnovert
842027f114 pivx: Add expected error string for stopDaemon when .cookie exists. 2022-10-14 00:58:54 +02:00
tecnovert
6ae8651d1b ui: Hide all except 'Reseed Wallet' button if expected_seed is false. 2022-10-13 23:16:43 +02:00
tecnovert
eb9eb49bd9 Persistent notifications. 2022-10-13 22:32:53 +02:00
gerlofvanek
7e4dd125e1 ui: Table fix 2022-10-13 19:53:34 +02:00
gerlofvanek
18e89a3c44 ui: Fixes global 2022-10-13 13:52:50 +02:00
gerlofvanek
3f628026ae ui: Stepper 2022-10-13 00:28:59 +02:00
gerlofvanek
e29e43821e ui: Fixed offers table layout, hide chart on Sent Offers page. 2022-10-12 23:33:48 +02:00
tecnovert
c7bbdc7022 Fail with more descriptive error when processing message involving inactive coin. 2022-10-12 22:37:35 +02:00
tecnovert
3ed6781c9f Ignore undecryptable messages when expiring. 2022-10-12 20:48:26 +02:00
tecnovert
5f0e708812 Merge remote-tracking branch 'crz/GUI' into GUI 2022-10-12 20:19:45 +02:00
gerlofvanek
9d8fe87fc3 ui: Better visibility of create an offer 2022-10-12 20:14:19 +02:00
gerlofvanek
58c9006a01 ui: Fix disabled / opacity on inputs (offer_confirm) 2022-10-12 19:57:55 +02:00
tecnovert
b0f6865c90 tests: Add pivx withdrawal test. 2022-10-12 19:19:23 +02:00
tecnovert
7d0cd6d08d Merge remote-tracking branch 'crz/GUI' into GUI 2022-10-12 09:54:54 +02:00
tecnovert
ea52ff67c2 Fix pivx withdrawals and install typo. 2022-10-12 00:59:30 +02:00
tecnovert
d6e0b4d2b2 ui: Separate error messages on offer page. (#3) 2022-10-11 23:04:25 +02:00
tecnovert
bdcf6ce91b ui: Separate error messages on offer page. 2022-10-11 22:44:57 +02:00
Gerlof van Ek
9e042200f3 Merge pull request #2 from tecnovert/repeat_offer
Repeat offer
2022-10-11 22:14:48 +02:00
tecnovert
a6a6865e95 ui: Add repeat offer feature.
Does not transfer the fee values yet.
2022-10-11 22:09:20 +02:00
gerlofvanek
1dc626e305 ui: Start of notifications (styling) 2022-10-11 20:16:02 +02:00
gerlofvanek
c87f66a041 ui: Update trading chart 2022-10-11 12:29:51 +02:00
gerlofvanek
c1482a8280 ui: Add trading chart 2022-10-11 12:20:47 +02:00
gerlofvanek
1987931332 ui: Add 404 page 2022-10-11 11:38:20 +02:00
Gerlof van Ek
e0b575b50e Merge pull request #1 from tecnovert/GUI
merge: Fix merge and lint issues.
2022-10-11 09:35:45 +02:00
tecnovert
5738cdd825 ui: Fix missing post_string on page_error 2022-10-11 08:32:48 +02:00
tecnovert
58a2707526 merge: Fix merge and lint issues. 2022-10-11 07:55:35 +02:00
gerlofvanek
e913957e41 Fixed withdraw issue 2022-10-11 01:43:16 +02:00
gerlofvanek
0472958fc2 Fixed events table bid_xmr template 2022-10-11 01:31:18 +02:00
gerlofvanek
1ea73a7917 Update footer & index 2022-10-11 01:27:20 +02:00
gerlofvanek
9102efecb6 Styled sent_bid_id
-
2022-10-11 00:35:45 +02:00
gerlofvanek
a040a6172a Refactor
-
2022-10-11 00:05:39 +02:00
gerlofvanek
9495249e70 GUI v.01
-
2022-10-10 23:44:14 +02:00
tecnovert
af766876a1 ui: Add tor info to page header 2022-10-08 14:37:22 +02:00
tecnovert
7319d46988 doc: Add private offer notes. 2022-10-06 22:27:51 +02:00
tecnovert
c4457ca400 ui: Display XMR view key on bid page
https://monerohash.com/explorer/myoutputs

Shared view key is for the chain B lock tx.

To find the view key for the lock spend tx:
http://localhost:12700/rpc
Monero Wallet
    getaddress
    query_key {"key_type":"view_key"}
2022-10-05 20:15:43 +02:00
tecnovert
a4f4a411a9 refactor: Move bid page logic 2022-10-05 19:30:52 +02:00
tecnovert
f29eac0eb5 ui: Handle missing txn gracefully on bid page. 2022-10-05 16:55:09 +02:00
tecnovert
eb30369bd4 refactor: Avoid importing all js functions. 2022-09-28 21:42:38 +02:00
tecnovert
ef0f5ea1ea protocol: Validate CLTV block values 2022-09-26 19:20:52 +02:00
tecnovert
46d1856f71 ui: Render 404 for unknown pages.
Wait for wallet update to complete, to handle corner case where user opens wallet page before refreshing.
Withdraw txn in selenium test.
2022-09-23 22:07:41 +02:00
tecnovert
6b4666d632 ui: Add error and info templates and display debug mode. 2022-09-15 21:54:15 +02:00
tecnovert
afba673085 refactor: Use persistent connection when expiring messages. 2022-09-11 17:35:18 +02:00
tecnovert
1694e73f92 ui: Fix bid state filter selection. 2022-09-10 13:50:40 +02:00
tecnovert
146698425d tests: Fix test_xmr_persistent
basicswap_prepare env vars are initialised when importing downloadPIVXParams
Fixed by reloading module
2022-09-10 13:47:48 +02:00
tecnovert
b89f94f0cc pivx: Download osx hashes file. 2022-09-09 16:47:01 +02:00
tecnovert
b5a009d3f9 preparescript: Add temporary pivx release. 2022-09-01 12:37:22 +02:00
tecnovert
d74699992b coins: Add PIVX
No CSV or segwit.
sethdseed requires a fully synced chain, manual intervention required to set a key derived from the master mnemonic.
Requires a pivxd version with a backported scantxoutset command.
2022-09-01 12:37:18 +02:00
tecnovert
cacd29130e Raise Particl version to 0.21.2.11 2022-09-01 12:32:35 +02:00
tecnovert
e4e35b0d89 preparescript: Fix addcoin 2022-08-18 00:23:51 +02:00
tecnovert
48e5dcbcc9 refactor: Add createRawSignedTransaction to interface 2022-08-16 20:53:58 +02:00
tecnovert
b179667cc5 ui: Fix missing coin from data. 2022-08-10 23:58:53 +02:00
tecnovert
85bbccf82a preparescript: with_coins should be a set. 2022-08-09 01:29:51 +02:00
tecnovert
20c0c372d0 refactor: Move all coin interfaces to a dir 2022-08-09 00:10:37 +02:00
tecnovert
80f0098a3d ui: Rates table example 2022-08-04 11:47:27 +02:00
tecnovert
412770d399 ui: rateslist returns js list of rates. 2022-08-03 23:59:57 +02:00
tecnovert
1ee2db137b ui: Expose min bid amount. 2022-07-31 23:40:58 +02:00
tecnovert
1c4f208d27 refactor: E275 missing whitespace after keyword 2022-07-31 20:09:43 +02:00
tecnovert
1601a57aed ui: Add websocket notifications. 2022-07-31 19:33:01 +02:00
tecnovert
6cc54d9c61 server: Serve more static directories. 2022-07-30 19:00:53 +02:00
tecnovert
7a3b41a11b ui: Fix js value updates when sending bid. 2022-07-29 00:47:32 +02:00
tecnovert
871bdb918e ui: Update to bittrex v3 api. 2022-07-28 17:01:11 +02:00
tecnovert
cbcf90c492 coins: Raise Monero version to 0.18.0.0 2022-07-28 11:23:45 +02:00
tecnovert
2f1a9cbfae tests: Fix tests 2022-07-26 23:23:49 +02:00
tecnovert
cd5af7032f ui: Use coin tickers as wallet keys in json/wallets 2022-07-25 23:10:58 +02:00
tecnovert
18a444b071 ui: Add json endpoint to list all coin types. 2022-07-25 12:55:55 +02:00
tecnovert
8b09607083 tests: Prevent out of sequence refund in test_13_itx_refund 2022-07-21 00:27:22 +02:00
tecnovert
fa74b9982c tests: Add xmr swap failure states to tests. 2022-07-20 00:24:14 +02:00
tecnovert
2c49d13aa0 tests: Add non xmr swap failure states to tests. 2022-07-18 22:57:16 +02:00
tecnovert
3ad87df844 tests: Add swap to wallet restore test. 2022-07-17 22:34:39 +02:00
tecnovert
ede01d3fc8 tests: Start wallet restore test.
Fix LTC pidfile in config.
Update LTC onion port for core version 21.
2022-07-15 17:04:24 +02:00
tecnovert
a2830afc06 tests: Deduplicate setup code. 2022-07-13 23:28:38 +02:00
tecnovert
e03f32ea5f docker: Fix and document isolated coins config. 2022-07-11 23:36:28 +02:00
tecnovert
48e0cac5ab refactor: Prepare script uses swap_client to create all wallets. 2022-07-09 23:58:40 +02:00
tecnovert
585bef6076 tests: return mnemonic from prepare script. 2022-07-08 18:41:01 +02:00
tecnovert
868dc27d64 ui: Add indication when XMR node is bootstrapping 2022-07-06 15:32:44 +02:00
tecnovert
1b7550ff76 ui: Add XMR rpc variant options. 2022-07-06 13:16:18 +02:00
tecnovert
91e285bf4a ui: Split wallet cached data into balance and blockchain state.
Add XMR synced indicator.
2022-07-06 00:46:37 +02:00
tecnovert
0580f9ebac tests: Fix NMC tests. 2022-07-04 22:29:49 +02:00
tecnovert
02bd90053a refactor: Use read_json_api in more tests. 2022-07-04 00:47:30 +02:00
tecnovert
0c620ea388 doc, tests: Test sequence diagrams are accurate.
Add delay between detecting PTX and redeeming ITX.
Add bid state history to json api.
Hide Tx none states in bid state history.
2022-07-03 23:58:16 +02:00
tecnovert
a2afd3f00f refactor: Separate MSG4F and lock txn sending 2022-07-01 16:37:10 +02:00
tecnovert
43048cffc0 doc, docker: Pin coincurve src to tag. 2022-06-29 15:11:11 +02:00
tecnovert
3976b9c203 tests: Fix ci tests. 2022-06-29 13:46:25 +02:00
tecnovert
d5e35b8168 doc, ui: Add sequence diagrams 2022-06-29 01:45:46 +02:00
tecnovert
f7aadd1b9d doc: Update docker install notes. 2022-06-27 22:29:16 +02:00
tecnovert
beaff23ac3 osx: Embed install_certifi.py script. 2022-06-26 02:17:59 +02:00
tecnovert
e7a62a6a82 debug: Log auto accepting event. 2022-06-22 22:51:39 +02:00
tecnovert
d2324ad097 preparescript: Fix missing btc wallet with --addcoin=bitcoin and --usebtcfastsync
doc: Fetch latest xmr chain height
2022-06-18 19:28:40 +02:00
tecnovert
f787bdb203 ui: Add refresh link to bids page. 2022-06-16 23:31:30 +02:00
tecnovert
b64437db84 coins: Raise Litecoin version to 0.21.2 2022-06-16 15:58:59 +02:00
tecnovert
844db9c541 coins: Raise Monero version to 0.17.3.2 2022-06-16 14:45:56 +02:00
tecnovert
a51a895141 docker: Manually install protobuf to avoid error.
Error: "TypeError: Descriptors cannot not be created directly"

Use pycryptodome ripemd160 implementation else it must be manually enabled in hashlib/openssl.
2022-06-16 14:28:52 +02:00
tecnovert
cddc4daf70 ui: Show offer amount swapped. 2022-06-16 00:19:06 +02:00
tecnovert
3ed6eca95f ui: Show bids that can be accepted. 2022-06-15 00:35:33 +02:00
tecnovert
0edcf249aa refactor: Add bid states to db. 2022-06-11 23:56:21 +02:00
tecnovert
89c60851ac automation: Accept multiple concurrent bids. 2022-06-08 22:23:44 +02:00
tecnovert
d909115ea4 refactor: Rename EventQueue table to Action 2022-06-06 23:03:31 +02:00
tecnovert
d47a69c7cb preparescript: Add expected keyids. 2022-06-05 11:38:14 +02:00
tecnovert
0c2c86070f preparescript: --usebtcfastsync option will initialise the BTC datadir from a chain snapshot. 2022-06-04 23:08:22 +02:00
tecnovert
a659eb3931 preparescript: Core versions can be set by env vars.
Use no usb variant of Particl for linux.
2022-06-03 21:31:07 +02:00
tecnovert
6153b76ec0 ui: Allow selecting automation strategy when creating offer.
Add alternate pgp key urls.
2022-06-01 00:38:50 +02:00
tecnovert
08c10bc69e Raise Particl version to 0.21.2.9 2022-05-23 23:51:48 +02:00
tecnovert
8daa76f937 refactor: Add automation tables. 2022-05-23 23:51:06 +02:00
tecnovert
f4649d34b2 Raise Particl version to 0.21.2.8 2022-04-13 20:59:41 +02:00
tecnovert
88c94c4acd Set default anon tx ring size to 12 and add setting. 2022-04-11 00:11:51 +02:00
tecnovert
a4683c8450 ui: Add sent filter to offers page. 2022-04-10 22:24:56 +02:00
tecnovert
7bc9d64233 ui: Display sent status on offers page. 2022-04-10 22:08:05 +02:00
tecnovert
12bae95e7d coins: Raise Bitcoin version to 22.0 2022-03-27 13:57:32 +02:00
tecnovert
6b063d0582 docker: Use static ip for tor container. 2022-03-27 11:32:29 +02:00
tecnovert
a5b192b931 Tor working for Bitcoin forks. 2022-03-27 00:08:15 +02:00
tecnovert
d1e015962c basicswap-prepare can enable and disable tor config. 2022-03-24 00:00:35 +02:00
tecnovert
cf797afae9 Raise Particl version to 0.21.2.7 2022-03-02 17:03:00 +02:00
tecnovert
843379325f tests: Add use_segwit to required settings. 2022-02-05 01:16:04 +02:00
tecnovert
d6f6a73324 tests: Allow passing extra config to Particl nodes. 2022-02-01 21:05:34 +02:00
tecnovert
67518efcad ui: Add option to create sized utxo. 2022-01-24 23:32:48 +02:00
tecnovert
0fbdd32908 coins: Raise Monero version to 0.17.3.0 2022-01-23 14:12:27 +02:00
tecnovert
f90a96d9ca ui: Split wallet page 2022-01-23 14:01:01 +02:00
tecnovert
1c09a8b79e coins: Raise Particl version 2022-01-13 11:09:25 +02:00
tecnovert
ea347093c2 Always use subprocess without shell 2022-01-03 13:23:02 +02:00
tecnovert
76c7a281bb Fix getProofOfFunds failure. 2022-01-03 12:05:44 +02:00
tecnovert
1658a6fc54 Fix refunding Particl Anon lock tx. 2022-01-02 01:42:49 +02:00
tecnovert
ce5aa0a13b Fix load bid failure case. 2022-01-02 00:20:30 +02:00
tecnovert
3e5c3e1e6a Make errors in activateBid non fatal. 2022-01-02 00:08:09 +02:00
219 changed files with 444001 additions and 5960 deletions

View File

@@ -7,8 +7,8 @@ lint_task:
- pip install codespell
script:
- flake8 --version
- PYTHONWARNINGS="ignore" flake8 --ignore=E501,F841,W503 --exclude=basicswap/contrib,messages_pb2.py,.eggs,.tox
- codespell --check-filenames --disable-colors --quiet-level=7 --ignore-words=tests/lint/spelling.ignore-words.txt -S .git,.eggs,.tox,gitianpubkeys,*.pyc,*basicswap/contrib,*mnemonics.py
- PYTHONWARNINGS="ignore" flake8 --ignore=E501,F841,W503 --exclude=basicswap/contrib,basicswap/interface/contrib,messages_pb2.py,.eggs,.tox,bin/install_certifi.py
- codespell --check-filenames --disable-colors --quiet-level=7 --ignore-words=tests/lint/spelling.ignore-words.txt -S .git,.eggs,.tox,pgp,*.pyc,*basicswap/contrib,*basicswap/interface/contrib,*mnemonics.py,bin/install_certifi.py,*basicswap/static
test_task:
environment:
@@ -24,8 +24,9 @@ test_task:
- apt-get install -y wget python3-pip gnupg unzip protobuf-compiler automake libtool pkg-config
- pip install tox pytest
- python3 setup.py install
- wget -O coincurve-anonswap.zip https://github.com/tecnovert/coincurve/archive/anonswap.zip
- unzip coincurve-anonswap.zip
- wget -O coincurve-anonswap.zip https://github.com/tecnovert/coincurve/archive/refs/tags/anonswap_v0.1.zip
- unzip -d coincurve-anonswap coincurve-anonswap.zip
- mv ./coincurve-anonswap/*/{.,}* ./coincurve-anonswap || true
- cd coincurve-anonswap
- python3 setup.py install --force
bins_cache:

View File

@@ -22,8 +22,9 @@ before_install:
install:
- travis_retry pip install tox pytest
before_script:
- wget -O coincurve-anonswap.zip https://github.com/tecnovert/coincurve/archive/anonswap.zip
- unzip coincurve-anonswap.zip
- wget -O coincurve-anonswap.zip https://github.com/tecnovert/coincurve/archive/refs/tags/anonswap_v0.1.zip
- unzip -d coincurve-anonswap coincurve-anonswap.zip
- mv ./coincurve-anonswap/*/{.,}* ./coincurve-anonswap || true
- cd coincurve-anonswap
- python3 setup.py install --force
script:
@@ -51,8 +52,8 @@ jobs:
- travis_retry pip install codespell==1.15.0
before_script:
script:
- PYTHONWARNINGS="ignore" flake8 --ignore=E501,F841,W503 --exclude=basicswap/contrib,messages_pb2.py,.eggs,.tox
- codespell --check-filenames --disable-colors --quiet-level=7 --ignore-words=tests/lint/spelling.ignore-words.txt -S .git,.eggs,.tox,gitianpubkeys,*.pyc,*basicswap/contrib,*mnemonics.py
- PYTHONWARNINGS="ignore" flake8 --ignore=E501,F841,W503 --exclude=basicswap/contrib,basicswap/interface/contrib,messages_pb2.py,.eggs,.tox,bin/install_certifi.py
- codespell --check-filenames --disable-colors --quiet-level=7 --ignore-words=tests/lint/spelling.ignore-words.txt -S .git,.eggs,.tox,pgp,*.pyc,*basicswap/contrib,*basicswap/interface/contrib,*mnemonics.py,bin/install_certifi.py,*basicswap/static
after_success:
- echo "End lint"
- stage: test

View File

@@ -1,14 +1,24 @@
FROM ubuntu:20.04
FROM ubuntu:22.04
ENV LANG=C.UTF-8 \
DEBIAN_FRONTEND=noninteractive \
DATADIRS="/coindata"
RUN apt-get update; \
apt-get install -y wget python3-pip gnupg unzip protobuf-compiler automake libtool pkg-config gosu tzdata;
apt-get install -y wget python3-pip gnupg unzip make g++ autoconf automake libtool pkg-config gosu tzdata;
RUN wget -O coincurve-anonswap.zip https://github.com/tecnovert/coincurve/archive/anonswap.zip && \
# Must install protoc directly as latest package is only on 3.12
RUN wget -O protobuf_src.tar.gz https://github.com/protocolbuffers/protobuf/releases/download/v21.1/protobuf-python-4.21.1.tar.gz && \
tar xvf protobuf_src.tar.gz && \
cd protobuf-3.21.1 && \
./configure --prefix=/usr && \
make -j$(nproc) install && \
ldconfig
ARG COINCURVE_VERSION=v0.1
RUN wget -O coincurve-anonswap.zip https://github.com/tecnovert/coincurve/archive/refs/tags/anonswap_$COINCURVE_VERSION.zip && \
unzip coincurve-anonswap.zip && \
mv ./coincurve-anonswap_$COINCURVE_VERSION ./coincurve-anonswap && \
cd coincurve-anonswap && \
python3 setup.py install --force
@@ -24,8 +34,10 @@ RUN cd basicswap-master; \
RUN useradd -ms /bin/bash swap_user && \
mkdir /coindata && chown swap_user -R /coindata
# Expose html port
# html port
EXPOSE 12700
# websocket port
EXPOSE 11700
VOLUME /coindata

View File

@@ -1,3 +1,3 @@
name = "basicswap"
__version__ = "0.0.31"
__version__ = "0.11.45"

View File

@@ -1,16 +1,20 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2019-2021 tecnovert
# Copyright (c) 2019-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import os
import shlex
import socks
import socket
import urllib
import logging
import threading
import traceback
import subprocess
import basicswap.config as cfg
import basicswap.contrib.segwit_addr as segwit_addr
from .rpc import (
callrpc,
@@ -24,6 +28,10 @@ from .chainparams import (
)
def getaddrinfo_tor(*args):
return [(socket.AF_INET, socket.SOCK_STREAM, 6, "", (args[0], args[1]))]
class BaseApp:
def __init__(self, fp, data_dir, settings, chain, log_name='BasicSwap'):
self.log_name = log_name
@@ -43,6 +51,15 @@ class BaseApp:
self.prepareLogging()
self.log.info('Network: {}'.format(self.chain))
self.use_tor_proxy = self.settings.get('use_tor', False)
self.tor_proxy_host = self.settings.get('tor_proxy_host', '127.0.0.1')
self.tor_proxy_port = self.settings.get('tor_proxy_port', 9050)
self.tor_control_password = self.settings.get('tor_control_password', None)
self.tor_control_port = self.settings.get('tor_control_port', 9051)
self.default_socket = socket.socket
self.default_socket_timeout = socket.getdefaulttimeout()
self.default_socket_getaddrinfo = socket.getaddrinfo
def stopRunning(self, with_code=0):
self.fail_code = with_code
with self.mxDB:
@@ -94,24 +111,21 @@ class BaseApp:
return c
raise ValueError('Unknown coin: {}'.format(coin_name))
def encodeSegwit(self, coin_type, raw):
return segwit_addr.encode(chainparams[coin_type][self.chain]['hrp'], 0, raw)
def decodeSegwit(self, coin_type, addr):
return bytes(segwit_addr.decode(chainparams[coin_type][self.chain]['hrp'], addr)[1])
def callrpc(self, method, params=[], wallet=None):
return callrpc(self.coin_clients[Coins.PART]['rpcport'], self.coin_clients[Coins.PART]['rpcauth'], method, params, wallet)
cc = self.coin_clients[Coins.PART]
return callrpc(cc['rpcport'], cc['rpcauth'], method, params, wallet, cc['rpchost'])
def callcoinrpc(self, coin, method, params=[], wallet=None):
return callrpc(self.coin_clients[coin]['rpcport'], self.coin_clients[coin]['rpcauth'], method, params, wallet)
cc = self.coin_clients[coin]
return callrpc(cc['rpcport'], cc['rpcauth'], method, params, wallet, cc['rpchost'])
def calltx(self, cmd):
bindir = self.coin_clients[Coins.PART]['bindir']
command_tx = os.path.join(bindir, cfg.PARTICL_TX)
chainname = '' if self.chain == 'mainnet' else (' -' + self.chain)
args = command_tx + chainname + ' ' + cmd
p = subprocess.Popen(args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)
args = [os.path.join(bindir, cfg.PARTICL_TX), ]
if self.chain != 'mainnet':
args.append('-' + self.chain)
args += shlex.split(cmd)
p = subprocess.Popen(args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
out = p.communicate()
if len(out[1]) > 0:
raise ValueError('TX error ' + str(out[1]))
@@ -121,9 +135,12 @@ class BaseApp:
bindir = self.coin_clients[coin_type]['bindir']
datadir = self.coin_clients[coin_type]['datadir']
command_cli = os.path.join(bindir, chainparams[coin_type]['name'] + '-cli' + ('.exe' if os.name == 'nt' else ''))
chainname = '' if self.chain == 'mainnet' else (' -' + self.chain)
args = command_cli + chainname + ' ' + '-datadir=' + datadir + ' ' + params
p = subprocess.Popen(args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)
args = [command_cli, ]
if self.chain != 'mainnet':
args.append('-' + self.chain)
args.append('-datadir=' + datadir)
args += shlex.split(params)
p = subprocess.Popen(args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
out = p.communicate(timeout=timeout)
if len(out[1]) > 0:
raise ValueError('CLI error ' + str(out[1]))
@@ -134,3 +151,43 @@ class BaseApp:
return True
str_error = str(ex).lower()
return 'read timed out' in str_error or 'no connection to daemon' in str_error
def setConnectionParameters(self, timeout=120):
opener = urllib.request.build_opener()
opener.addheaders = [('User-agent', 'Mozilla/5.0')]
urllib.request.install_opener(opener)
if self.use_tor_proxy:
socks.setdefaultproxy(socks.PROXY_TYPE_SOCKS5, self.tor_proxy_host, self.tor_proxy_port, rdns=True)
socket.socket = socks.socksocket
socket.getaddrinfo = getaddrinfo_tor # Without this accessing .onion links would fail
socket.setdefaulttimeout(timeout)
def popConnectionParameters(self):
if self.use_tor_proxy:
socket.socket = self.default_socket
socket.getaddrinfo = self.default_socket_getaddrinfo
socket.setdefaulttimeout(self.default_socket_timeout)
def logException(self, message):
self.log.error(message)
if self.debug:
self.log.error(traceback.format_exc())
def torControl(self, query):
try:
command = 'AUTHENTICATE "{}"\r\n{}\r\nQUIT\r\n'.format(self.tor_control_password, query).encode('utf-8')
c = socket.create_connection((self.tor_proxy_host, self.tor_control_port))
c.send(command)
response = bytearray()
while True:
rv = c.recv(1024)
if not rv:
break
response += rv
c.close()
return response
except Exception as e:
self.log.error(f'torControl {e}')
return

File diff suppressed because it is too large Load Diff

View File

@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2021 tecnovert
# Copyright (c) 2021-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
@@ -8,7 +8,7 @@
import struct
import hashlib
from enum import IntEnum, auto
from .util import (
from .util.address import (
encodeAddress,
decodeAddress,
)
@@ -64,38 +64,40 @@ class SwapTypes(IntEnum):
class OfferStates(IntEnum):
OFFER_SENT = auto()
OFFER_RECEIVED = auto()
OFFER_ABANDONED = auto()
OFFER_SENT = 1
OFFER_RECEIVED = 2
OFFER_ABANDONED = 3
class BidStates(IntEnum):
BID_SENT = auto()
BID_RECEIVING = auto() # Partially received
BID_RECEIVED = auto()
BID_RECEIVING_ACC = auto() # Partially received accept message
BID_ACCEPTED = auto() # BidAcceptMessage received/sent
SWAP_INITIATED = auto() # Initiate txn validated
SWAP_PARTICIPATING = auto() # Participate txn validated
SWAP_COMPLETED = auto() # All swap txns spent
XMR_SWAP_SCRIPT_COIN_LOCKED = auto()
XMR_SWAP_HAVE_SCRIPT_COIN_SPEND_TX = auto()
XMR_SWAP_NOSCRIPT_COIN_LOCKED = auto()
XMR_SWAP_LOCK_RELEASED = auto()
XMR_SWAP_SCRIPT_TX_REDEEMED = auto()
XMR_SWAP_SCRIPT_TX_PREREFUND = auto() # script txo moved into pre-refund tx
XMR_SWAP_NOSCRIPT_TX_REDEEMED = auto()
XMR_SWAP_NOSCRIPT_TX_RECOVERED = auto()
XMR_SWAP_FAILED_REFUNDED = auto()
XMR_SWAP_FAILED_SWIPED = auto()
XMR_SWAP_FAILED = auto()
SWAP_DELAYING = auto()
SWAP_TIMEDOUT = auto()
BID_ABANDONED = auto() # Bid will no longer be processed
BID_ERROR = auto() # An error occurred
BID_STALLED_FOR_TEST = auto()
BID_REJECTED = auto()
BID_STATE_UNKNOWN = auto()
BID_SENT = 1
BID_RECEIVING = 2 # Partially received
BID_RECEIVED = 3
BID_RECEIVING_ACC = 4 # Partially received accept message
BID_ACCEPTED = 5 # BidAcceptMessage received/sent
SWAP_INITIATED = 6 # Initiate txn validated
SWAP_PARTICIPATING = 7 # Participate txn validated
SWAP_COMPLETED = 8 # All swap txns spent
XMR_SWAP_SCRIPT_COIN_LOCKED = 9
XMR_SWAP_HAVE_SCRIPT_COIN_SPEND_TX = 10
XMR_SWAP_NOSCRIPT_COIN_LOCKED = 11
XMR_SWAP_LOCK_RELEASED = 12
XMR_SWAP_SCRIPT_TX_REDEEMED = 13
XMR_SWAP_SCRIPT_TX_PREREFUND = 14 # script txo moved into pre-refund tx
XMR_SWAP_NOSCRIPT_TX_REDEEMED = 15
XMR_SWAP_NOSCRIPT_TX_RECOVERED = 16
XMR_SWAP_FAILED_REFUNDED = 17
XMR_SWAP_FAILED_SWIPED = 18
XMR_SWAP_FAILED = 19
SWAP_DELAYING = 20
SWAP_TIMEDOUT = 21
BID_ABANDONED = 22 # Bid will no longer be processed
BID_ERROR = 23 # An error occurred
BID_STALLED_FOR_TEST = 24
BID_REJECTED = 25
BID_STATE_UNKNOWN = 26
XMR_SWAP_MSG_SCRIPT_LOCK_TX_SIGS = 27 # XmrBidLockTxSigsMessage
XMR_SWAP_MSG_SCRIPT_LOCK_SPEND_TX = 28 # XmrBidLockSpendTxMessage
class TxStates(IntEnum):
@@ -122,7 +124,7 @@ class TxTypes(IntEnum):
XMR_SWAP_B_LOCK = auto()
class EventTypes(IntEnum):
class ActionTypes(IntEnum):
ACCEPT_BID = auto()
ACCEPT_XMR_BID = auto()
SIGN_XMR_SWAP_LOCK_TX_A = auto()
@@ -132,6 +134,8 @@ class EventTypes(IntEnum):
REDEEM_XMR_SWAP_LOCK_TX_A = auto() # Follower
REDEEM_XMR_SWAP_LOCK_TX_B = auto() # Leader
RECOVER_XMR_SWAP_LOCK_TX_B = auto()
SEND_XMR_SWAP_LOCK_SPEND_MSG = auto()
REDEEM_ITX = auto()
class EventLogTypes(IntEnum):
@@ -155,6 +159,15 @@ class EventLogTypes(IntEnum):
LOCK_TX_B_SPEND_TX_PUBLISHED = auto()
LOCK_TX_A_REFUND_TX_SEEN = auto()
LOCK_TX_A_REFUND_SPEND_TX_SEEN = auto()
ERROR = auto()
AUTOMATION_CONSTRAINT = auto()
AUTOMATION_ACCEPTING_BID = auto()
ITX_PUBLISHED = auto()
ITX_REDEEM_PUBLISHED = auto()
ITX_REFUND_PUBLISHED = auto()
PTX_PUBLISHED = auto()
PTX_REDEEM_PUBLISHED = auto()
PTX_REFUND_PUBLISHED = auto()
class XmrSplitMsgTypes(IntEnum):
@@ -163,12 +176,14 @@ class XmrSplitMsgTypes(IntEnum):
class DebugTypes(IntEnum):
NONE = 0
BID_STOP_AFTER_COIN_A_LOCK = auto()
BID_DONT_SPEND_COIN_A_LOCK_REFUND = auto()
CREATE_INVALID_COIN_B_LOCK = auto()
BUYER_STOP_AFTER_ITX = auto()
MAKE_INVALID_PTX = auto()
DONT_SPEND_ITX = auto()
SKIP_LOCK_TX_REFUND = auto()
def strOfferState(state):
@@ -181,6 +196,13 @@ def strOfferState(state):
return 'Unknown'
class NotificationTypes(IntEnum):
NONE = 0
OFFER_RECEIVED = auto()
BID_RECEIVED = auto()
BID_ACCEPTED = auto()
def strBidState(state):
if state == BidStates.BID_SENT:
return 'Sent'
@@ -232,6 +254,10 @@ def strBidState(state):
return 'Failed'
if state == BidStates.SWAP_DELAYING:
return 'Delaying'
if state == BidStates.XMR_SWAP_MSG_SCRIPT_LOCK_TX_SIGS:
return 'Exchanged script lock tx sigs msg'
if state == BidStates.XMR_SWAP_MSG_SCRIPT_LOCK_SPEND_TX:
return 'Exchanged script lock spend tx msg'
return 'Unknown' + ' ' + str(state)
@@ -331,6 +357,24 @@ def describeEventEntry(event_type, event_msg):
return 'Lock tx A refund spend tx seen in chain'
if event_type == EventLogTypes.SYSTEM_WARNING:
return 'Warning: ' + event_msg
if event_type == EventLogTypes.ERROR:
return 'Error: ' + event_msg
if event_type == EventLogTypes.AUTOMATION_CONSTRAINT:
return 'Failed auto accepting'
if event_type == EventLogTypes.AUTOMATION_ACCEPTING_BID:
return 'Auto accepting'
if event_type == EventLogTypes.ITX_PUBLISHED:
return 'Initiate tx published'
if event_type == EventLogTypes.ITX_REDEEM_PUBLISHED:
return 'Initiate tx redeem tx published'
if event_type == EventLogTypes.ITX_REFUND_PUBLISHED:
return 'Initiate tx refund tx published'
if event_type == EventLogTypes.PTX_PUBLISHED:
return 'Participate tx published'
if event_type == EventLogTypes.PTX_REDEEM_PUBLISHED:
return 'Participate tx redeem tx published'
if event_type == EventLogTypes.PTX_REFUND_PUBLISHED:
return 'Participate tx refund tx published'
def getVoutByAddress(txjs, p2sh):
@@ -381,6 +425,10 @@ def getLastBidState(packed_states):
def isActiveBidState(state):
if state >= BidStates.BID_ACCEPTED and state < BidStates.SWAP_COMPLETED:
return True
if state == BidStates.SWAP_DELAYING:
return True
if state == BidStates.XMR_SWAP_HAVE_SCRIPT_COIN_SPEND_TX:
return True
if state == BidStates.XMR_SWAP_SCRIPT_COIN_LOCKED:
@@ -395,4 +443,8 @@ def isActiveBidState(state):
return True
if state == BidStates.XMR_SWAP_SCRIPT_TX_PREREFUND:
return True
if state == BidStates.XMR_SWAP_MSG_SCRIPT_LOCK_TX_SIGS:
return True
if state == BidStates.XMR_SWAP_MSG_SCRIPT_LOCK_SPEND_TX:
return True
return False

View File

@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2019-2021 tecnovert
# Copyright (c) 2019-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
@@ -26,6 +26,11 @@ class Coins(IntEnum):
XMR = 6
PART_BLIND = 7
PART_ANON = 8
# ZANO = 9
# NDAU = 10
PIVX = 11
DASH = 12
FIRO = 13
chainparams = {
@@ -116,7 +121,8 @@ chainparams = {
'mainnet': {
'rpcport': 9332,
'pubkey_address': 48,
'script_address': 50,
'script_address': 5,
'script_address2': 50,
'key_prefix': 176,
'hrp': 'ltc',
'bip44': 2,
@@ -126,7 +132,8 @@ chainparams = {
'testnet': {
'rpcport': 19332,
'pubkey_address': 111,
'script_address': 58,
'script_address': 196,
'script_address2': 58,
'key_prefix': 239,
'hrp': 'tltc',
'bip44': 1,
@@ -137,7 +144,8 @@ chainparams = {
'regtest': {
'rpcport': 19443,
'pubkey_address': 111,
'script_address': 58,
'script_address': 196,
'script_address2': 58,
'key_prefix': 239,
'hrp': 'rltc',
'bip44': 1,
@@ -203,8 +211,136 @@ chainparams = {
'min_amount': 100000,
'max_amount': 10000 * XMR_COIN,
}
},
Coins.PIVX: {
'name': 'pivx',
'ticker': 'PIVX',
'message_magic': 'DarkNet Signed Message:\n',
'blocks_target': 60 * 1,
'decimal_places': 8,
'has_csv': False,
'has_segwit': False,
'use_ticker_as_name': True,
'mainnet': {
'rpcport': 51473,
'pubkey_address': 30,
'script_address': 13,
'key_prefix': 212,
'bip44': 119,
'min_amount': 1000,
'max_amount': 100000 * COIN,
},
'testnet': {
'rpcport': 51475,
'pubkey_address': 139,
'script_address': 19,
'key_prefix': 239,
'bip44': 1,
'min_amount': 1000,
'max_amount': 100000 * COIN,
'name': 'testnet4',
},
'regtest': {
'rpcport': 51477,
'pubkey_address': 139,
'script_address': 19,
'key_prefix': 239,
'bip44': 1,
'min_amount': 1000,
'max_amount': 100000 * COIN,
}
},
Coins.DASH: {
'name': 'dash',
'ticker': 'DASH',
'message_magic': 'DarkCoin Signed Message:\n',
'blocks_target': 60 * 2.5,
'decimal_places': 8,
'has_csv': True,
'has_segwit': False,
'mainnet': {
'rpcport': 9998,
'pubkey_address': 76,
'script_address': 16,
'key_prefix': 204,
'hrp': '',
'bip44': 5,
'min_amount': 1000,
'max_amount': 100000 * COIN,
},
'testnet': {
'rpcport': 19998,
'pubkey_address': 140,
'script_address': 19,
'key_prefix': 239,
'hrp': '',
'bip44': 1,
'min_amount': 1000,
'max_amount': 100000 * COIN,
},
'regtest': {
'rpcport': 18332,
'pubkey_address': 140,
'script_address': 19,
'key_prefix': 239,
'hrp': '',
'bip44': 1,
'min_amount': 1000,
'max_amount': 100000 * COIN,
}
},
Coins.FIRO: {
'name': 'firo',
'ticker': 'FIRO',
'message_magic': 'Zcoin Signed Message:\n',
'blocks_target': 60 * 10,
'decimal_places': 8,
'has_csv': True,
'has_segwit': True,
'mainnet': {
'rpcport': 8888,
'pubkey_address': 82,
'script_address': 7,
'key_prefix': 210,
'hrp': '',
'bip44': 136,
'min_amount': 1000,
'max_amount': 100000 * COIN,
},
'testnet': {
'rpcport': 18888,
'pubkey_address': 65,
'script_address': 178,
'key_prefix': 185,
'hrp': '',
'bip44': 1,
'min_amount': 1000,
'max_amount': 100000 * COIN,
},
'regtest': {
'rpcport': 28888,
'pubkey_address': 65,
'script_address': 178,
'key_prefix': 185,
'hrp': '',
'bip44': 1,
'min_amount': 1000,
'max_amount': 100000 * COIN,
}
}
}
ticker_map = {}
for c, params in chainparams.items():
ticker_map[params['ticker'].lower()] = c
def getCoinIdFromTicker(ticker):
try:
return ticker_map[ticker.lower()]
except Exception:
raise ValueError('Unknown coin')
class CoinInterface:
@@ -225,7 +361,10 @@ class CoinInterface:
return format_amount(amount_int, self.exp())
def coin_name(self):
return chainparams[self.coin_type()]['name'].capitalize()
coin_chainparams = chainparams[self.coin_type()]
if coin_chainparams.get('use_ticker_as_name', False):
return coin_chainparams['ticker']
return coin_chainparams['name'].capitalize()
def ticker(self):
ticker = chainparams[self.coin_type()]['ticker']
@@ -235,6 +374,10 @@ class CoinInterface:
ticker = 'rt' + ticker
return ticker
def ticker_mainnet(self):
ticker = chainparams[self.coin_type()]['ticker']
return ticker
def min_amount(self):
return chainparams[self.coin_type()][self._network]['min_amount']

View File

@@ -1,13 +1,13 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2019 tecnovert
# Copyright (c) 2019-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import os
CONFIG_FILENAME = 'basicswap.json'
DEFAULT_DATADIR = '~/.basicswap'
BASICSWAP_DATADIR = os.getenv('BASICSWAP_DATADIR', '~/.basicswap')
DEFAULT_ALLOW_CORS = False
TEST_DATADIRS = os.path.expanduser(os.getenv('DATADIRS', '/tmp/basicswap'))
DEFAULT_TEST_BINDIR = os.path.expanduser(os.getenv('DEFAULT_TEST_BINDIR', '~/tmp/bin'))
@@ -36,3 +36,18 @@ NAMECOIN_TX = os.getenv('NAMECOIN_TX', 'namecoin-tx' + bin_suffix)
XMR_BINDIR = os.path.expanduser(os.getenv('XMR_BINDIR', os.path.join(DEFAULT_TEST_BINDIR, 'monero')))
XMRD = os.getenv('XMRD', 'monerod' + bin_suffix)
XMR_WALLET_RPC = os.getenv('XMR_WALLET_RPC', 'monero-wallet-rpc' + bin_suffix)
PIVX_BINDIR = os.path.expanduser(os.getenv('PIVX_BINDIR', os.path.join(DEFAULT_TEST_BINDIR, 'pivx')))
PIVXD = os.getenv('PIVXD', 'pivxd' + bin_suffix)
PIVX_CLI = os.getenv('PIVX_CLI', 'pivx-cli' + bin_suffix)
PIVX_TX = os.getenv('PIVX_TX', 'pivx-tx' + bin_suffix)
DASH_BINDIR = os.path.expanduser(os.getenv('DASH_BINDIR', os.path.join(DEFAULT_TEST_BINDIR, 'dash')))
DASHD = os.getenv('DASHD', 'dashd' + bin_suffix)
DASH_CLI = os.getenv('DASH_CLI', 'dash-cli' + bin_suffix)
DASH_TX = os.getenv('DASH_TX', 'dash-tx' + bin_suffix)
FIRO_BINDIR = os.path.expanduser(os.getenv('FIRO_BINDIR', os.path.join(DEFAULT_TEST_BINDIR, 'firo')))
FIROD = os.getenv('FIROD', 'firod' + bin_suffix)
FIRO_CLI = os.getenv('FIRO_CLI', 'firo-cli' + bin_suffix)
FIRO_TX = os.getenv('FIRO_TX', 'firo-tx' + bin_suffix)

View File

@@ -10,6 +10,7 @@ import hashlib
import struct
import unittest
from typing import List, Dict
from basicswap.util.crypto import ripemd160
from .messages import (
CTransaction,
@@ -25,7 +26,7 @@ MAX_SCRIPT_ELEMENT_SIZE = 520
OPCODE_NAMES = {} # type: Dict[CScriptOp, str]
def hash160(s):
return hashlib.new('ripemd160', sha256(s)).digest()
return ripemd160(sha256(s))
def bn2vch(v):
"""Convert number to bitcoin-specific little endian format."""

View File

@@ -614,6 +614,11 @@ def find_vout_for_address(node, txid, addr):
"""
tx = node.getrawtransaction(txid, True)
for i in range(len(tx["vout"])):
if any([addr == a for a in tx["vout"][i]["scriptPubKey"]["addresses"]]):
return i
scriptPubKey = tx["vout"][i]["scriptPubKey"]
if "addresses" in scriptPubKey:
if any([addr == a for a in scriptPubKey["addresses"]]):
return i
elif "address" in scriptPubKey:
if addr == scriptPubKey["address"]:
return i
raise RuntimeError("Vout not found for address: txid=%s, addr=%s" % (txid, addr))

View File

@@ -0,0 +1 @@
from .websocket_server import *

View File

@@ -0,0 +1,38 @@
import threading
class ThreadWithLoggedException(threading.Thread):
"""
Similar to Thread but will log exceptions to passed logger.
Args:
logger: Logger instance used to log any exception in child thread
Exception is also reachable via <thread>.exception from the main thread.
"""
DIVIDER = "*"*80
def __init__(self, *args, **kwargs):
try:
self.logger = kwargs.pop("logger")
except KeyError:
raise Exception("Missing 'logger' in kwargs")
super().__init__(*args, **kwargs)
self.exception = None
def run(self):
try:
if self._target is not None:
self._target(*self._args, **self._kwargs)
except Exception as exception:
thread = threading.current_thread()
self.exception = exception
self.logger.exception(f"{self.DIVIDER}\nException in child thread {thread}: {exception}\n{self.DIVIDER}")
finally:
del self._target, self._args, self._kwargs
class WebsocketServerThread(ThreadWithLoggedException):
"""Dummy wrapper to make debug messages a bit more readable"""
pass

View File

@@ -0,0 +1,495 @@
# Author: Johan Hanssen Seferidis
# License: MIT
import sys
import struct
import ssl
from base64 import b64encode
from hashlib import sha1
import logging
from socket import error as SocketError
import errno
import threading
from socketserver import ThreadingMixIn, TCPServer, StreamRequestHandler
from .thread import WebsocketServerThread
logger = logging.getLogger(__name__)
logging.basicConfig()
'''
+-+-+-+-+-------+-+-------------+-------------------------------+
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-------+-+-------------+-------------------------------+
|F|R|R|R| opcode|M| Payload len | Extended payload length |
|I|S|S|S| (4) |A| (7) | (16/64) |
|N|V|V|V| |S| | (if payload len==126/127) |
| |1|2|3| |K| | |
+-+-+-+-+-------+-+-------------+ - - - - - - - - - - - - - - - +
| Extended payload length continued, if payload len == 127 |
+ - - - - - - - - - - - - - - - +-------------------------------+
| Payload Data continued ... |
+---------------------------------------------------------------+
'''
FIN = 0x80
OPCODE = 0x0f
MASKED = 0x80
PAYLOAD_LEN = 0x7f
PAYLOAD_LEN_EXT16 = 0x7e
PAYLOAD_LEN_EXT64 = 0x7f
OPCODE_CONTINUATION = 0x0
OPCODE_TEXT = 0x1
OPCODE_BINARY = 0x2
OPCODE_CLOSE_CONN = 0x8
OPCODE_PING = 0x9
OPCODE_PONG = 0xA
CLOSE_STATUS_NORMAL = 1000
DEFAULT_CLOSE_REASON = bytes('', encoding='utf-8')
class API():
def run_forever(self, threaded=False):
return self._run_forever(threaded)
def new_client(self, client, server):
pass
def client_left(self, client, server):
pass
def message_received(self, client, server, message):
pass
def set_fn_new_client(self, fn):
self.new_client = fn
def set_fn_client_left(self, fn):
self.client_left = fn
def set_fn_message_received(self, fn):
self.message_received = fn
def send_message(self, client, msg):
self._unicast(client, msg)
def send_message_to_all(self, msg):
self._multicast(msg)
def deny_new_connections(self, status=CLOSE_STATUS_NORMAL, reason=DEFAULT_CLOSE_REASON):
self._deny_new_connections(status, reason)
def allow_new_connections(self):
self._allow_new_connections()
def shutdown_gracefully(self, status=CLOSE_STATUS_NORMAL, reason=DEFAULT_CLOSE_REASON):
self._shutdown_gracefully(status, reason)
def shutdown_abruptly(self):
self._shutdown_abruptly()
def disconnect_clients_gracefully(self, status=CLOSE_STATUS_NORMAL, reason=DEFAULT_CLOSE_REASON):
self._disconnect_clients_gracefully(status, reason)
def disconnect_clients_abruptly(self):
self._disconnect_clients_abruptly()
class WebsocketServer(ThreadingMixIn, TCPServer, API):
"""
A websocket server waiting for clients to connect.
Args:
port(int): Port to bind to
host(str): Hostname or IP to listen for connections. By default 127.0.0.1
is being used. To accept connections from any client, you should use
0.0.0.0.
loglevel: Logging level from logging module to use for logging. By default
warnings and errors are being logged.
Properties:
clients(list): A list of connected clients. A client is a dictionary
like below.
{
'id' : id,
'handler' : handler,
'address' : (addr, port)
}
"""
allow_reuse_address = True
daemon_threads = True # comment to keep threads alive until finished
def __init__(self, host='127.0.0.1', port=0, loglevel=logging.WARNING, key=None, cert=None):
logger.setLevel(loglevel)
TCPServer.__init__(self, (host, port), WebSocketHandler)
self.host = host
self.port = self.socket.getsockname()[1]
self.url = f'ws://{self.host}:{self.port}/'
self.key = key
self.cert = cert
self.clients = []
self.id_counter = 0
self.thread = None
self._deny_clients = False
def _run_forever(self, threaded):
cls_name = self.__class__.__name__
try:
logger.info("Listening on port %d for clients.." % self.port)
if threaded:
self.daemon = True
self.thread = WebsocketServerThread(target=super().serve_forever, daemon=True, logger=logger)
if sys.version_info[0] > 3 or (sys.version_info[0] == 3 and sys.version_info[1] >= 10):
logger.info(f"Starting {cls_name} on thread {self.thread.name}.")
else:
logger.info(f"Starting {cls_name} on thread {self.thread.getName()}.")
self.thread.start()
else:
self.thread = threading.current_thread()
logger.info(f"Starting {cls_name} on main thread.")
super().serve_forever()
except KeyboardInterrupt:
self.server_close()
logger.info("Server terminated.")
except Exception as e:
logger.error(str(e), exc_info=True)
sys.exit(1)
def _message_received_(self, handler, msg):
self.message_received(self.handler_to_client(handler), self, msg)
def _ping_received_(self, handler, msg):
handler.send_pong(msg)
def _pong_received_(self, handler, msg):
pass
def _new_client_(self, handler):
if self._deny_clients:
status = self._deny_clients["status"]
reason = self._deny_clients["reason"]
handler.send_close(status, reason)
self._terminate_client_handler(handler)
return
self.id_counter += 1
client = {
'id': self.id_counter,
'handler': handler,
'address': handler.client_address
}
self.clients.append(client)
self.new_client(client, self)
def _client_left_(self, handler):
client = self.handler_to_client(handler)
self.client_left(client, self)
if client in self.clients:
self.clients.remove(client)
def _unicast(self, receiver_client, msg):
receiver_client['handler'].send_message(msg)
def _multicast(self, msg):
for client in self.clients:
self._unicast(client, msg)
def handler_to_client(self, handler):
for client in self.clients:
if client['handler'] == handler:
return client
def _terminate_client_handler(self, handler):
handler.keep_alive = False
handler.finish()
handler.connection.close()
def _terminate_client_handlers(self):
"""
Ensures request handler for each client is terminated correctly
"""
for client in self.clients:
self._terminate_client_handler(client["handler"])
def _shutdown_gracefully(self, status=CLOSE_STATUS_NORMAL, reason=DEFAULT_CLOSE_REASON):
"""
Send a CLOSE handshake to all connected clients before terminating server
"""
self.keep_alive = False
self._disconnect_clients_gracefully(status, reason)
self.server_close()
self.shutdown()
def _shutdown_abruptly(self):
"""
Terminate server without sending a CLOSE handshake
"""
self.keep_alive = False
self._disconnect_clients_abruptly()
self.server_close()
self.shutdown()
def _disconnect_clients_gracefully(self, status=CLOSE_STATUS_NORMAL, reason=DEFAULT_CLOSE_REASON):
"""
Terminate clients gracefully without shutting down the server
"""
for client in self.clients:
client["handler"].send_close(status, reason)
self._terminate_client_handlers()
def _disconnect_clients_abruptly(self):
"""
Terminate clients abruptly (no CLOSE handshake) without shutting down the server
"""
self._terminate_client_handlers()
def _deny_new_connections(self, status, reason):
self._deny_clients = {
"status": status,
"reason": reason,
}
def _allow_new_connections(self):
self._deny_clients = False
class WebSocketHandler(StreamRequestHandler):
def __init__(self, socket, addr, server):
self.server = server
self.timeout = 1000 # Must set a timeout or rfile.read timesout in the tests
assert not hasattr(self, "_send_lock"), "_send_lock already exists"
self._send_lock = threading.Lock()
if server.key and server.cert:
try:
socket = ssl.wrap_socket(socket, server_side=True, certfile=server.cert, keyfile=server.key)
except: # Not sure which exception it throws if the key/cert isn't found
logger.warning("SSL not available (are the paths {} and {} correct for the key and cert?)".format(server.key, server.cert))
StreamRequestHandler.__init__(self, socket, addr, server)
def setup(self):
StreamRequestHandler.setup(self)
self.keep_alive = True
self.handshake_done = False
self.valid_client = False
def handle(self):
while self.keep_alive:
if not self.handshake_done:
self.handshake()
elif self.valid_client:
self.read_next_message()
def read_bytes(self, num):
return self.rfile.read(num)
def read_next_message(self):
try:
b1, b2 = self.read_bytes(2)
except TimeoutError:
return
except SocketError as e: # to be replaced with ConnectionResetError for py3
if e.errno == errno.ECONNRESET:
logger.info("Client closed connection.")
self.keep_alive = 0
return
b1, b2 = 0, 0
except ValueError as e:
b1, b2 = 0, 0
fin = b1 & FIN
opcode = b1 & OPCODE
masked = b2 & MASKED
payload_length = b2 & PAYLOAD_LEN
if opcode == OPCODE_CLOSE_CONN:
logger.info("Client asked to close connection.")
self.keep_alive = 0
return
if not masked:
logger.warning("Client must always be masked.")
self.keep_alive = 0
return
if opcode == OPCODE_CONTINUATION:
logger.warning("Continuation frames are not supported.")
return
elif opcode == OPCODE_BINARY:
logger.warning("Binary frames are not supported.")
return
elif opcode == OPCODE_TEXT:
opcode_handler = self.server._message_received_
elif opcode == OPCODE_PING:
opcode_handler = self.server._ping_received_
elif opcode == OPCODE_PONG:
opcode_handler = self.server._pong_received_
else:
logger.warning("Unknown opcode %#x." % opcode)
self.keep_alive = 0
return
if payload_length == 126:
payload_length = struct.unpack(">H", self.rfile.read(2))[0]
elif payload_length == 127:
payload_length = struct.unpack(">Q", self.rfile.read(8))[0]
masks = self.read_bytes(4)
message_bytes = bytearray()
for message_byte in self.read_bytes(payload_length):
message_byte ^= masks[len(message_bytes) % 4]
message_bytes.append(message_byte)
opcode_handler(self, message_bytes.decode('utf8'))
def send_message(self, message):
self.send_text(message)
def send_pong(self, message):
self.send_text(message, OPCODE_PONG)
def send_close(self, status=CLOSE_STATUS_NORMAL, reason=DEFAULT_CLOSE_REASON):
"""
Send CLOSE to client
Args:
status: Status as defined in https://datatracker.ietf.org/doc/html/rfc6455#section-7.4.1
reason: Text with reason of closing the connection
"""
if status < CLOSE_STATUS_NORMAL or status > 1015:
raise Exception(f"CLOSE status must be between 1000 and 1015, got {status}")
header = bytearray()
payload = struct.pack('!H', status) + reason
payload_length = len(payload)
assert payload_length <= 125, "We only support short closing reasons at the moment"
# Send CLOSE with status & reason
header.append(FIN | OPCODE_CLOSE_CONN)
header.append(payload_length)
with self._send_lock:
self.request.send(header + payload)
def send_text(self, message, opcode=OPCODE_TEXT):
"""
Important: Fragmented(=continuation) messages are not supported since
their usage cases are limited - when we don't know the payload length.
"""
# Validate message
if isinstance(message, bytes):
message = try_decode_UTF8(message) # this is slower but ensures we have UTF-8
if not message:
logger.warning("Can\'t send message, message is not valid UTF-8")
return False
elif not isinstance(message, str):
logger.warning('Can\'t send message, message has to be a string or bytes. Got %s' % type(message))
return False
header = bytearray()
payload = encode_to_UTF8(message)
payload_length = len(payload)
# Normal payload
if payload_length <= 125:
header.append(FIN | opcode)
header.append(payload_length)
# Extended payload
elif payload_length >= 126 and payload_length <= 65535:
header.append(FIN | opcode)
header.append(PAYLOAD_LEN_EXT16)
header.extend(struct.pack(">H", payload_length))
# Huge extended payload
elif payload_length < 18446744073709551616:
header.append(FIN | opcode)
header.append(PAYLOAD_LEN_EXT64)
header.extend(struct.pack(">Q", payload_length))
else:
raise Exception("Message is too big. Consider breaking it into chunks.")
return
with self._send_lock:
self.request.send(header + payload)
def read_http_headers(self):
headers = {}
# first line should be HTTP GET
http_get = self.rfile.readline().decode().strip()
assert http_get.upper().startswith('GET')
# remaining should be headers
while True:
header = self.rfile.readline().decode().strip()
if not header:
break
head, value = header.split(':', 1)
headers[head.lower().strip()] = value.strip()
return headers
def handshake(self):
headers = self.read_http_headers()
try:
assert headers['upgrade'].lower() == 'websocket'
except AssertionError:
self.keep_alive = False
return
try:
key = headers['sec-websocket-key']
except KeyError:
logger.warning("Client tried to connect but was missing a key")
self.keep_alive = False
return
response = self.make_handshake_response(key)
with self._send_lock:
self.handshake_done = self.request.send(response.encode())
self.valid_client = True
self.server._new_client_(self)
@classmethod
def make_handshake_response(cls, key):
return \
'HTTP/1.1 101 Switching Protocols\r\n'\
'Upgrade: websocket\r\n' \
'Connection: Upgrade\r\n' \
'Sec-WebSocket-Accept: %s\r\n' \
'\r\n' % cls.calculate_response_key(key)
@classmethod
def calculate_response_key(cls, key):
GUID = '258EAFA5-E914-47DA-95CA-C5AB0DC85B11'
hash = sha1(key.encode() + GUID.encode())
response_key = b64encode(hash.digest()).strip()
return response_key.decode('ASCII')
def finish(self):
self.server._client_left_(self)
def encode_to_UTF8(data):
try:
return data.encode('UTF-8')
except UnicodeEncodeError as e:
logger.error("Could not encode data to UTF-8 -- %s" % e)
return False
except Exception as e:
raise(e)
return False
def try_decode_UTF8(data):
try:
return data.decode('utf-8')
except UnicodeDecodeError:
return False
except Exception as e:
raise(e)

View File

@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2019-2021 tecnovert
# Copyright (c) 2019-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
@@ -12,13 +12,26 @@ from enum import IntEnum, auto
from sqlalchemy.ext.declarative import declarative_base
CURRENT_DB_VERSION = 13
CURRENT_DB_VERSION = 16
CURRENT_DB_DATA_VERSION = 2
Base = declarative_base()
class TableTypes(IntEnum):
class Concepts(IntEnum):
OFFER = auto()
BID = auto()
NETWORK_MESSAGE = auto()
AUTOMATION = auto()
def strConcepts(state):
if state == Concepts.OFFER:
return 'Offer'
if state == Concepts.BID:
return 'Bid'
if state == Concepts.NETWORK_MESSAGE:
return 'Network Message'
return 'Unknown'
class DBKVInt(Base):
@@ -236,16 +249,16 @@ class SmsgAddress(Base):
note = sa.Column(sa.String)
class EventQueue(Base):
__tablename__ = 'eventqueue'
class Action(Base):
__tablename__ = 'actions'
event_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
action_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
active_ind = sa.Column(sa.Integer)
created_at = sa.Column(sa.BigInteger)
trigger_at = sa.Column(sa.BigInteger)
linked_id = sa.Column(sa.LargeBinary)
event_type = sa.Column(sa.Integer)
event_data = sa.Column(sa.LargeBinary)
action_type = sa.Column(sa.Integer)
action_data = sa.Column(sa.LargeBinary)
class EventLog(Base):
@@ -288,7 +301,8 @@ class XmrSwap(Base):
bid_accept_msg_id3 = sa.Column(sa.LargeBinary)
coin_a_lock_tx_sigs_l_msg_id = sa.Column(sa.LargeBinary) # MSG3L F -> L
coin_a_lock_refund_spend_tx_msg_id = sa.Column(sa.LargeBinary) # MSG4F L -> F
coin_a_lock_spend_tx_msg_id = sa.Column(sa.LargeBinary) # MSG4F L -> F
coin_a_lock_release_msg_id = sa.Column(sa.LargeBinary) # MSG5F L -> F
contract_count = sa.Column(sa.Integer)
@@ -372,12 +386,11 @@ class Wallets(Base):
__tablename__ = 'wallets'
record_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
active_ind = sa.Column(sa.Integer)
coin_id = sa.Column(sa.Integer)
wallet_name = sa.Column(sa.String)
wallet_data = sa.Column(sa.String)
balance_type = sa.Column(sa.Integer)
amount = sa.Column(sa.BigInteger)
updated_at = sa.Column(sa.BigInteger)
created_at = sa.Column(sa.BigInteger)
@@ -385,6 +398,7 @@ class KnownIdentity(Base):
__tablename__ = 'knownidentities'
record_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
active_ind = sa.Column(sa.Integer)
address = sa.Column(sa.String)
label = sa.Column(sa.String)
publickey = sa.Column(sa.LargeBinary)
@@ -397,3 +411,74 @@ class KnownIdentity(Base):
note = sa.Column(sa.String)
updated_at = sa.Column(sa.BigInteger)
created_at = sa.Column(sa.BigInteger)
class AutomationStrategy(Base):
__tablename__ = 'automationstrategies'
record_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
active_ind = sa.Column(sa.Integer)
label = sa.Column(sa.String)
type_ind = sa.Column(sa.Integer)
only_known_identities = sa.Column(sa.Integer)
num_concurrent = sa.Column(sa.Integer)
data = sa.Column(sa.LargeBinary)
note = sa.Column(sa.String)
created_at = sa.Column(sa.BigInteger)
class AutomationLink(Base):
__tablename__ = 'automationlinks'
# Contains per order/bid options
record_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
active_ind = sa.Column(sa.Integer)
linked_type = sa.Column(sa.Integer)
linked_id = sa.Column(sa.LargeBinary)
strategy_id = sa.Column(sa.Integer)
data = sa.Column(sa.LargeBinary)
repeat_limit = sa.Column(sa.Integer)
repeat_count = sa.Column(sa.Integer)
note = sa.Column(sa.String)
created_at = sa.Column(sa.BigInteger)
__table_args__ = (sa.Index('linked_index', 'linked_type', 'linked_id'), )
class History(Base):
__tablename__ = 'history'
record_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
concept_type = sa.Column(sa.Integer)
concept_id = sa.Column(sa.Integer)
changed_data = sa.Column(sa.LargeBinary)
created_at = sa.Column(sa.BigInteger)
class BidState(Base):
__tablename__ = 'bidstates'
record_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
active_ind = sa.Column(sa.Integer)
state_id = sa.Column(sa.Integer)
label = sa.Column(sa.String)
in_progress = sa.Column(sa.Integer)
note = sa.Column(sa.String)
created_at = sa.Column(sa.BigInteger)
class Notification(Base):
__tablename__ = 'notifications'
record_id = sa.Column(sa.Integer, primary_key=True, autoincrement=True)
active_ind = sa.Column(sa.Integer)
created_at = sa.Column(sa.BigInteger)
event_type = sa.Column(sa.Integer)
event_data = sa.Column(sa.LargeBinary)

240
basicswap/db_upgrades.py Normal file
View File

@@ -0,0 +1,240 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import json
import time
from sqlalchemy.orm import scoped_session
from .db import (
BidState,
Concepts,
AutomationStrategy,
CURRENT_DB_VERSION,
CURRENT_DB_DATA_VERSION)
from .basicswap_util import (
BidStates,
strBidState,
isActiveBidState)
def upgradeDatabaseData(self, data_version):
if data_version >= CURRENT_DB_DATA_VERSION:
return
self.log.info('Upgrading database records from version %d to %d.', data_version, CURRENT_DB_DATA_VERSION)
with self.mxDB:
try:
session = scoped_session(self.session_factory)
now = int(time.time())
if data_version < 1:
session.add(AutomationStrategy(
active_ind=1,
label='Accept All',
type_ind=Concepts.OFFER,
data=json.dumps({'exact_rate_only': True,
'max_concurrent_bids': 5}).encode('utf-8'),
only_known_identities=False,
created_at=now))
session.add(AutomationStrategy(
active_ind=1,
label='Accept Known',
type_ind=Concepts.OFFER,
data=json.dumps({'exact_rate_only': True,
'max_concurrent_bids': 5}).encode('utf-8'),
only_known_identities=True,
note='Accept bids from identities with previously successful swaps only',
created_at=now))
for state in BidStates:
session.add(BidState(
active_ind=1,
state_id=int(state),
in_progress=isActiveBidState(state),
label=strBidState(state),
created_at=now))
if data_version < 2:
for state in (BidStates.XMR_SWAP_MSG_SCRIPT_LOCK_TX_SIGS, BidStates.XMR_SWAP_MSG_SCRIPT_LOCK_SPEND_TX):
session.add(BidState(
active_ind=1,
state_id=int(state),
in_progress=isActiveBidState(state),
label=strBidState(state),
created_at=now))
self.db_data_version = CURRENT_DB_DATA_VERSION
self.setIntKVInSession('db_data_version', self.db_data_version, session)
session.commit()
self.log.info('Upgraded database records to version {}'.format(self.db_data_version))
finally:
session.close()
session.remove()
def upgradeDatabase(self, db_version):
if db_version >= CURRENT_DB_VERSION:
return
self.log.info('Upgrading database from version %d to %d.', db_version, CURRENT_DB_VERSION)
while True:
session = scoped_session(self.session_factory)
current_version = db_version
if current_version == 6:
session.execute('ALTER TABLE bids ADD COLUMN security_token BLOB')
session.execute('ALTER TABLE offers ADD COLUMN security_token BLOB')
db_version += 1
elif current_version == 7:
session.execute('ALTER TABLE transactions ADD COLUMN block_hash BLOB')
session.execute('ALTER TABLE transactions ADD COLUMN block_height INTEGER')
session.execute('ALTER TABLE transactions ADD COLUMN block_time INTEGER')
db_version += 1
elif current_version == 8:
session.execute('''
CREATE TABLE wallets (
record_id INTEGER NOT NULL,
coin_id INTEGER,
wallet_name VARCHAR,
wallet_data VARCHAR,
balance_type INTEGER,
created_at BIGINT,
PRIMARY KEY (record_id))''')
db_version += 1
elif current_version == 9:
session.execute('ALTER TABLE wallets ADD COLUMN wallet_data VARCHAR')
db_version += 1
elif current_version == 10:
session.execute('ALTER TABLE smsgaddresses ADD COLUMN active_ind INTEGER')
session.execute('ALTER TABLE smsgaddresses ADD COLUMN created_at INTEGER')
session.execute('ALTER TABLE smsgaddresses ADD COLUMN note VARCHAR')
session.execute('ALTER TABLE smsgaddresses ADD COLUMN pubkey VARCHAR')
session.execute('UPDATE smsgaddresses SET active_ind = 1, created_at = 1')
session.execute('ALTER TABLE offers ADD COLUMN addr_to VARCHAR')
session.execute(f'UPDATE offers SET addr_to = "{self.network_addr}"')
db_version += 1
elif current_version == 11:
session.execute('ALTER TABLE bids ADD COLUMN chain_a_height_start INTEGER')
session.execute('ALTER TABLE bids ADD COLUMN chain_b_height_start INTEGER')
session.execute('ALTER TABLE bids ADD COLUMN protocol_version INTEGER')
session.execute('ALTER TABLE offers ADD COLUMN protocol_version INTEGER')
session.execute('ALTER TABLE transactions ADD COLUMN tx_data BLOB')
db_version += 1
elif current_version == 12:
session.execute('''
CREATE TABLE knownidentities (
record_id INTEGER NOT NULL,
address VARCHAR,
label VARCHAR,
publickey BLOB,
num_sent_bids_successful INTEGER,
num_recv_bids_successful INTEGER,
num_sent_bids_rejected INTEGER,
num_recv_bids_rejected INTEGER,
num_sent_bids_failed INTEGER,
num_recv_bids_failed INTEGER,
note VARCHAR,
updated_at BIGINT,
created_at BIGINT,
PRIMARY KEY (record_id))''')
session.execute('ALTER TABLE bids ADD COLUMN reject_code INTEGER')
session.execute('ALTER TABLE bids ADD COLUMN rate INTEGER')
session.execute('ALTER TABLE offers ADD COLUMN amount_negotiable INTEGER')
session.execute('ALTER TABLE offers ADD COLUMN rate_negotiable INTEGER')
db_version += 1
elif current_version == 13:
db_version += 1
session.execute('''
CREATE TABLE automationstrategies (
record_id INTEGER NOT NULL,
active_ind INTEGER,
label VARCHAR,
type_ind INTEGER,
only_known_identities INTEGER,
num_concurrent INTEGER,
data BLOB,
note VARCHAR,
created_at BIGINT,
PRIMARY KEY (record_id))''')
session.execute('''
CREATE TABLE automationlinks (
record_id INTEGER NOT NULL,
active_ind INTEGER,
linked_type INTEGER,
linked_id BLOB,
strategy_id INTEGER,
data BLOB,
repeat_limit INTEGER,
repeat_count INTEGER,
note VARCHAR,
created_at BIGINT,
PRIMARY KEY (record_id))''')
session.execute('''
CREATE TABLE history (
record_id INTEGER NOT NULL,
concept_type INTEGER,
concept_id INTEGER,
changed_data BLOB,
note VARCHAR,
created_at BIGINT,
PRIMARY KEY (record_id))''')
session.execute('''
CREATE TABLE bidstates (
record_id INTEGER NOT NULL,
active_ind INTEGER,
state_id INTEGER,
label VARCHAR,
in_progress INTEGER,
note VARCHAR,
created_at BIGINT,
PRIMARY KEY (record_id))''')
session.execute('ALTER TABLE wallets ADD COLUMN active_ind INTEGER')
session.execute('ALTER TABLE knownidentities ADD COLUMN active_ind INTEGER')
session.execute('ALTER TABLE eventqueue RENAME TO actions')
session.execute('ALTER TABLE actions RENAME COLUMN event_id TO action_id')
session.execute('ALTER TABLE actions RENAME COLUMN event_type TO action_type')
session.execute('ALTER TABLE actions RENAME COLUMN event_data TO action_data')
elif current_version == 14:
db_version += 1
session.execute('ALTER TABLE xmr_swaps ADD COLUMN coin_a_lock_release_msg_id BLOB')
session.execute('ALTER TABLE xmr_swaps RENAME COLUMN coin_a_lock_refund_spend_tx_msg_id TO coin_a_lock_spend_tx_msg_id')
elif current_version == 15:
db_version += 1
session.execute('''
CREATE TABLE notifications (
record_id INTEGER NOT NULL,
active_ind INTEGER,
event_type INTEGER,
event_data BLOB,
created_at BIGINT,
PRIMARY KEY (record_id))''')
if current_version != db_version:
self.db_version = db_version
self.setIntKVInSession('db_version', db_version, session)
session.commit()
session.close()
session.remove()
self.log.info('Upgraded database to version {}'.format(self.db_version))
continue
break
if db_version != CURRENT_DB_VERSION:
raise ValueError('Unable to upgrade database.')

View File

@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2019-2021 tecnovert
# Copyright (c) 2019-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
@@ -17,9 +17,12 @@ class Explorer():
def readURL(self, url):
self.log.debug('Explorer url: {}'.format(url))
headers = {'User-Agent': 'Mozilla/5.0'}
req = urllib.request.Request(url, headers=headers)
return urllib.request.urlopen(req).read()
try:
self.swapclient.setConnectionParameters()
req = urllib.request.Request(url)
return urllib.request.urlopen(req).read()
finally:
self.swapclient.popConnectionParameters()
class ExplorerInsight(Explorer):
@@ -72,7 +75,7 @@ class ExplorerBitAps(Explorer):
# Can't get unspents return only if exactly one transaction exists
data = json.loads(self.readURL(self.base_url + '/address/transactions/' + address))
try:
assert(data['data']['list'] == 1)
assert data['data']['list'] == 1
except Exception as ex:
self.log.debug('Explorer error: {}'.format(str(ex)))
return None

File diff suppressed because it is too large Load Diff

View File

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2020-2021 tecnovert
# Copyright (c) 2020-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
@@ -14,19 +14,28 @@ import traceback
from io import BytesIO
from basicswap.contrib.test_framework import segwit_addr
from .util import (
from basicswap.util import (
dumpj,
toWIF,
ensure,
make_int,
b2h, i2b, b2i, i2h)
from basicswap.util.ecc import (
ep,
pointToCPK, CPKToPoint,
getSecretInt)
from basicswap.util.script import (
decodeScriptNum,
getCompactSizeLen,
SerialiseNumCompact,
getWitnessElementLen,
)
from basicswap.util.address import (
toWIF,
b58encode,
decodeWif,
decodeAddress,
decodeScriptNum,
pubkeyToAddress,
getCompactSizeLen,
SerialiseNumCompact,
getWitnessElementLen)
)
from coincurve.keys import (
PrivateKey,
PublicKey)
@@ -38,13 +47,7 @@ from coincurve.ecdsaotves import (
ecdsaotves_dec_sig,
ecdsaotves_rec_enc_key)
from .ecc_util import (
ep,
pointToCPK, CPKToPoint,
getSecretInt,
b2h, i2b, b2i, i2h)
from .contrib.test_framework.messages import (
from basicswap.contrib.test_framework.messages import (
COIN,
COutPoint,
CTransaction,
@@ -53,7 +56,7 @@ from .contrib.test_framework.messages import (
CTxOut,
FromHex)
from .contrib.test_framework.script import (
from basicswap.contrib.test_framework.script import (
CScript, CScriptOp,
OP_IF, OP_ELSE, OP_ENDIF,
OP_0, OP_2,
@@ -65,11 +68,11 @@ from .contrib.test_framework.script import (
SegwitV0SignatureHash,
hash160)
from .basicswap_util import (
from basicswap.basicswap_util import (
TxLockTypes)
from .chainparams import CoinInterface, Coins
from .rpc import make_rpc_func, openrpc
from basicswap.chainparams import CoinInterface, Coins
from basicswap.rpc import make_rpc_func, openrpc
SEQUENCE_LOCKTIME_GRANULARITY = 9 # 512 seconds
@@ -94,8 +97,13 @@ def find_vout_for_address_from_txobj(tx_obj, addr):
given address. Raises runtime error exception if not found.
"""
for i in range(len(tx_obj["vout"])):
if any([addr == a for a in tx_obj["vout"][i]["scriptPubKey"]["addresses"]]):
return i
scriptPubKey = tx_obj["vout"][i]["scriptPubKey"]
if "addresses" in scriptPubKey:
if any([addr == a for a in scriptPubKey["addresses"]]):
return i
elif "address" in scriptPubKey:
if addr == scriptPubKey["address"]:
return i
raise RuntimeError("Vout not found for address: txid={}, addr={}".format(tx_obj['txid'], addr))
@@ -149,7 +157,7 @@ class BTCInterface(CoinInterface):
@staticmethod
def getExpectedSequence(lockType, lockVal):
assert(lockVal >= 1), 'Bad lockVal'
assert (lockVal >= 1), 'Bad lockVal'
if lockType == TxLockTypes.SEQUENCE_LOCK_BLOCKS:
return lockVal
if lockType == TxLockTypes.SEQUENCE_LOCK_TIME:
@@ -176,9 +184,17 @@ class BTCInterface(CoinInterface):
self.rpc_callback = make_rpc_func(self._rpcport, self._rpcauth, host=self._rpc_host)
self.blocks_confirmed = coin_settings['blocks_confirmed']
self.setConfTarget(coin_settings['conf_target'])
self._use_segwit = coin_settings['use_segwit']
self._connection_type = coin_settings['connection_type']
self._sc = swap_client
self._log = self._sc.log if self._sc and self._sc.log else logging
def using_segwit(self):
return self._use_segwit
def get_connection_type(self):
return self._connection_type
def open_rpc(self, wallet=None):
return openrpc(self._rpcport, self._rpcauth, wallet=wallet, host=self._rpc_host)
@@ -199,11 +215,14 @@ class BTCInterface(CoinInterface):
rpc_conn.close()
def setConfTarget(self, new_conf_target):
assert(new_conf_target >= 1 and new_conf_target < 33), 'Invalid conf_target value'
ensure(new_conf_target >= 1 and new_conf_target < 33, 'Invalid conf_target value')
self._conf_target = new_conf_target
def testDaemonRPC(self):
self.rpc_callback('getwalletinfo', [])
def testDaemonRPC(self, with_wallet=True):
if with_wallet:
self.rpc_callback('getwalletinfo', [])
else:
self.rpc_callback('getblockchaininfo', [])
def getDaemonVersion(self):
return self.rpc_callback('getnetworkinfo')['version']
@@ -224,14 +243,23 @@ class BTCInterface(CoinInterface):
def getBlockHeader(self, block_hash):
return self.rpc_callback('getblockheader', [block_hash])
def getBlockHeaderAt(self, time, block_after=False):
blockchaininfo = self.rpc_callback('getblockchaininfo')
last_block_header = self.rpc_callback('getblockheader', [blockchaininfo['bestblockhash']])
max_tries = 5000
for i in range(max_tries):
prev_block_header = self.rpc_callback('getblock', [last_block_header['previousblockhash']])
if prev_block_header['time'] <= time:
return last_block_header if block_after else prev_block_header
last_block_header = prev_block_header
raise ValueError(f'Block header not found at time: {time}')
def initialiseWallet(self, key_bytes):
key_wif = self.encodeKey(key_bytes)
try:
self.rpc_callback('sethdseed', [True, key_wif])
except Exception as e:
# < 0.21: Cannot set a new HD seed while still in Initial Block Download.
self._log.error('sethdseed failed: {}'.format(str(e)))
self.rpc_callback('sethdseed', [True, key_wif])
def getWalletInfo(self):
return self.rpc_callback('getwalletinfo')
@@ -265,20 +293,25 @@ class BTCInterface(CoinInterface):
def getWalletSeedID(self):
return self.rpc_callback('getwalletinfo')['hdseedid']
def getNewAddress(self, use_segwit):
args = ['swap_receive']
def checkExpectedSeed(self, expect_seedid):
return expect_seedid == self.getWalletSeedID()
def getNewAddress(self, use_segwit, label='swap_receive'):
args = [label]
if use_segwit:
args.append('bech32')
return self.rpc_callback('getnewaddress', args)
def get_fee_rate(self, conf_target=2):
try:
return self.rpc_callback('estimatesmartfee', [conf_target])['feerate'], 'estimatesmartfee'
fee_rate = self.rpc_callback('estimatesmartfee', [conf_target])['feerate']
assert (fee_rate > 0.0), 'Non positive feerate'
return fee_rate, 'estimatesmartfee'
except Exception:
try:
fee_rate = self.rpc_callback('getwalletinfo')['paytxfee'], 'paytxfee'
assert(fee_rate > 0.0), '0 feerate'
return fee_rate
fee_rate = self.rpc_callback('getwalletinfo')['paytxfee']
assert (fee_rate > 0.0), 'Non positive feerate'
return fee_rate, 'paytxfee'
except Exception:
return self.rpc_callback('getnetworkinfo')['relayfee'], 'relayfee'
@@ -287,7 +320,7 @@ class BTCInterface(CoinInterface):
def decodeAddress(self, address):
bech32_prefix = self.chainparams_network()['hrp']
if address.startswith(bech32_prefix + '1'):
if len(bech32_prefix) > 0 and address.startswith(bech32_prefix + '1'):
return bytes(segwit_addr.decode(bech32_prefix, address)[1])
return decodeAddress(address)[1:]
@@ -299,23 +332,33 @@ class BTCInterface(CoinInterface):
def pkh_to_address(self, pkh):
# pkh is hash160(pk)
assert(len(pkh) == 20)
assert (len(pkh) == 20)
prefix = self.chainparams_network()['pubkey_address']
data = bytes((prefix,)) + pkh
checksum = hashlib.sha256(hashlib.sha256(data).digest()).digest()
return b58encode(data + checksum[0:4])
def sh_to_address(self, sh):
assert (len(sh) == 20)
prefix = self.chainparams_network()['script_address']
data = bytes((prefix,)) + sh
checksum = hashlib.sha256(hashlib.sha256(data).digest()).digest()
return b58encode(data + checksum[0:4])
def encode_p2wsh(self, script):
bech32_prefix = self.chainparams_network()['hrp']
version = 0
program = script[2:] # strip version and length
return segwit_addr.encode(bech32_prefix, version, program)
def encodeScriptDest(self, script):
return self.encode_p2wsh(script)
def encode_p2sh(self, script):
return pubkeyToAddress(self.chainparams_network()['script_address'], script)
def pubkey_to_address(self, pk):
assert(len(pk) == 33)
assert (len(pk) == 33)
return self.pkh_to_address(hash160(pk))
def getNewSecretKey(self):
@@ -328,9 +371,12 @@ class BTCInterface(CoinInterface):
pk = self.getPubkey(key)
return hash160(pk)
def getSeedHash(self, seed):
return self.getAddressHashFromKey(seed)[::-1]
def verifyKey(self, k):
i = b2i(k)
return(i < ep.o and i > 0)
return (i < ep.o and i > 0)
def verifyPubkey(self, pubkey_bytes):
return verify_secp256k1_point(pubkey_bytes)
@@ -342,6 +388,12 @@ class BTCInterface(CoinInterface):
def encodePubkey(self, pk):
return pointToCPK(pk)
def encodeSegwitAddress(self, key_hash):
return segwit_addr.encode(self.chainparams_network()['hrp'], 0, key_hash)
def decodeSegwitAddress(self, addr):
return bytes(segwit_addr.decode(self.chainparams_network()['hrp'], addr)[1])
def decodePubkey(self, pke):
return CPKToPoint(pke)
@@ -382,7 +434,7 @@ class BTCInterface(CoinInterface):
return CScript([2, Kal_enc, Kaf_enc, 2, CScriptOp(OP_CHECKMULTISIG)])
def createScriptLockTx(self, value, Kal, Kaf, vkbv=None):
def createSCLockTx(self, value, Kal, Kaf, vkbv=None):
script = self.genScriptLockTxScript(Kal, Kaf)
tx = CTransaction()
tx.nVersion = self.txVersion()
@@ -390,7 +442,7 @@ class BTCInterface(CoinInterface):
return tx.serialize(), script
def fundScriptLockTx(self, tx_bytes, feerate, vkbv=None):
def fundSCLockTx(self, tx_bytes, feerate, vkbv=None):
return self.fundTx(tx_bytes, feerate)
def extractScriptLockRefundScriptValues(self, script_bytes):
@@ -437,11 +489,11 @@ class BTCInterface(CoinInterface):
Kaf_enc, CScriptOp(OP_CHECKSIG),
CScriptOp(OP_ENDIF)])
def createScriptLockRefundTx(self, tx_lock_bytes, script_lock, Kal, Kaf, lock1_value, csv_val, tx_fee_rate, vkbv=None):
def createSCLockRefundTx(self, tx_lock_bytes, script_lock, Kal, Kaf, lock1_value, csv_val, tx_fee_rate, vkbv=None):
tx_lock = CTransaction()
tx_lock = FromHex(tx_lock, tx_lock_bytes.hex())
output_script = CScript([OP_0, hashlib.sha256(script_lock).digest()])
output_script = self.getScriptDest(script_lock)
locked_n = findOutput(tx_lock, output_script)
ensure(locked_n is not None, 'Output not found in tx')
locked_coin = tx_lock.vout[locked_n].nValue
@@ -452,8 +504,10 @@ class BTCInterface(CoinInterface):
refund_script = self.genScriptLockRefundTxScript(Kal, Kaf, csv_val)
tx = CTransaction()
tx.nVersion = self.txVersion()
tx.vin.append(CTxIn(COutPoint(tx_lock_id_int, locked_n), nSequence=lock1_value))
tx.vout.append(self.txoType()(locked_coin, CScript([OP_0, hashlib.sha256(refund_script).digest()])))
tx.vin.append(CTxIn(COutPoint(tx_lock_id_int, locked_n),
nSequence=lock1_value,
scriptSig=self.getScriptScriptSig(script_lock)))
tx.vout.append(self.txoType()(locked_coin, self.getScriptDest(refund_script)))
dummy_witness_stack = self.getScriptLockTxDummyWitness(script_lock)
witness_bytes = self.getWitnessStackSerialisedLength(dummy_witness_stack)
@@ -462,19 +516,19 @@ class BTCInterface(CoinInterface):
tx.vout[0].nValue = locked_coin - pay_fee
tx.rehash()
self._log.info('createScriptLockRefundTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
self._log.info('createSCLockRefundTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
i2h(tx.sha256), tx_fee_rate, vsize, pay_fee)
return tx.serialize(), refund_script, tx.vout[0].nValue
def createScriptLockRefundSpendTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_refund_to, tx_fee_rate, vkbv=None):
def createSCLockRefundSpendTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_refund_to, tx_fee_rate, vkbv=None):
# Returns the coinA locked coin to the leader
# The follower will sign the multisig path with a signature encumbered by the leader's coinB spend pubkey
# If the leader publishes the decrypted signature the leader's coinB spend privatekey will be revealed to the follower
tx_lock_refund = self.loadTx(tx_lock_refund_bytes)
output_script = CScript([OP_0, hashlib.sha256(script_lock_refund).digest()])
output_script = self.getScriptDest(script_lock_refund)
locked_n = findOutput(tx_lock_refund, output_script)
ensure(locked_n is not None, 'Output not found in tx')
locked_coin = tx_lock_refund.vout[locked_n].nValue
@@ -484,7 +538,9 @@ class BTCInterface(CoinInterface):
tx = CTransaction()
tx.nVersion = self.txVersion()
tx.vin.append(CTxIn(COutPoint(tx_lock_refund_hash_int, locked_n), nSequence=0))
tx.vin.append(CTxIn(COutPoint(tx_lock_refund_hash_int, locked_n),
nSequence=0,
scriptSig=self.getScriptScriptSig(script_lock_refund)))
tx.vout.append(self.txoType()(locked_coin, self.getScriptForPubkeyHash(pkh_refund_to)))
@@ -495,18 +551,18 @@ class BTCInterface(CoinInterface):
tx.vout[0].nValue = locked_coin - pay_fee
tx.rehash()
self._log.info('createScriptLockRefundSpendTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
self._log.info('createSCLockRefundSpendTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
i2h(tx.sha256), tx_fee_rate, vsize, pay_fee)
return tx.serialize()
def createScriptLockRefundSpendToFTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_dest, tx_fee_rate, vkbv=None):
def createSCLockRefundSpendToFTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_dest, tx_fee_rate, vkbv=None):
# lock refund swipe tx
# Sends the coinA locked coin to the follower
tx_lock_refund = self.loadTx(tx_lock_refund_bytes)
output_script = CScript([OP_0, hashlib.sha256(script_lock_refund).digest()])
output_script = self.getScriptDest(script_lock_refund)
locked_n = findOutput(tx_lock_refund, output_script)
ensure(locked_n is not None, 'Output not found in tx')
locked_coin = tx_lock_refund.vout[locked_n].nValue
@@ -518,7 +574,9 @@ class BTCInterface(CoinInterface):
tx = CTransaction()
tx.nVersion = self.txVersion()
tx.vin.append(CTxIn(COutPoint(tx_lock_refund_hash_int, locked_n), nSequence=lock2_value))
tx.vin.append(CTxIn(COutPoint(tx_lock_refund_hash_int, locked_n),
nSequence=lock2_value,
scriptSig=self.getScriptScriptSig(script_lock_refund)))
tx.vout.append(self.txoType()(locked_coin, self.getScriptForPubkeyHash(pkh_dest)))
@@ -529,14 +587,14 @@ class BTCInterface(CoinInterface):
tx.vout[0].nValue = locked_coin - pay_fee
tx.rehash()
self._log.info('createScriptLockRefundSpendToFTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
self._log.info('createSCLockRefundSpendToFTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
i2h(tx.sha256), tx_fee_rate, vsize, pay_fee)
return tx.serialize()
def createScriptLockSpendTx(self, tx_lock_bytes, script_lock, pkh_dest, tx_fee_rate, vkbv=None):
def createSCLockSpendTx(self, tx_lock_bytes, script_lock, pkh_dest, tx_fee_rate, vkbv=None):
tx_lock = self.loadTx(tx_lock_bytes)
output_script = CScript([OP_0, hashlib.sha256(script_lock).digest()])
output_script = self.getScriptDest(script_lock)
locked_n = findOutput(tx_lock, output_script)
ensure(locked_n is not None, 'Output not found in tx')
locked_coin = tx_lock.vout[locked_n].nValue
@@ -546,7 +604,8 @@ class BTCInterface(CoinInterface):
tx = CTransaction()
tx.nVersion = self.txVersion()
tx.vin.append(CTxIn(COutPoint(tx_lock_id_int, locked_n)))
tx.vin.append(CTxIn(COutPoint(tx_lock_id_int, locked_n),
scriptSig=self.getScriptScriptSig(script_lock)))
tx.vout.append(self.txoType()(locked_coin, self.getScriptForPubkeyHash(pkh_dest)))
@@ -557,16 +616,16 @@ class BTCInterface(CoinInterface):
tx.vout[0].nValue = locked_coin - pay_fee
tx.rehash()
self._log.info('createScriptLockSpendTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
self._log.info('createSCLockSpendTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
i2h(tx.sha256), tx_fee_rate, vsize, pay_fee)
return tx.serialize()
def verifyLockTx(self, tx_bytes, script_out,
swap_value,
Kal, Kaf,
feerate,
check_lock_tx_inputs, vkbv=None):
def verifySCLockTx(self, tx_bytes, script_out,
swap_value,
Kal, Kaf,
feerate,
check_lock_tx_inputs, vkbv=None):
# Verify:
#
@@ -581,7 +640,7 @@ class BTCInterface(CoinInterface):
ensure(tx.nVersion == self.txVersion(), 'Bad version')
ensure(tx.nLockTime == 0, 'Bad nLockTime') # TODO match txns created by cores
script_pk = CScript([OP_0, hashlib.sha256(script_out).digest()])
script_pk = self.getScriptDest(script_out)
locked_n = findOutput(tx, script_pk)
ensure(locked_n is not None, 'Output not found in tx')
locked_coin = tx.vout[locked_n].nValue
@@ -617,7 +676,7 @@ class BTCInterface(CoinInterface):
for txo in tx.vout:
outputs_value += txo.nValue
fee_paid = inputs_value - outputs_value
assert(fee_paid > 0)
assert (fee_paid > 0)
vsize = self.getTxVSize(tx, add_bytes, add_witness_bytes)
fee_rate_paid = fee_paid * 1000 // vsize
@@ -630,9 +689,9 @@ class BTCInterface(CoinInterface):
return txid, locked_n
def verifyLockRefundTx(self, tx_bytes, lock_tx_bytes, script_out,
prevout_id, prevout_n, prevout_seq, prevout_script,
Kal, Kaf, csv_val_expect, swap_value, feerate, vkbv=None):
def verifySCLockRefundTx(self, tx_bytes, lock_tx_bytes, script_out,
prevout_id, prevout_n, prevout_seq, prevout_script,
Kal, Kaf, csv_val_expect, swap_value, feerate, vkbv=None):
# Verify:
# Must have only one input with correct prevout and sequence
# Must have only one output to the p2wsh of the lock refund script
@@ -647,12 +706,12 @@ class BTCInterface(CoinInterface):
ensure(len(tx.vin) == 1, 'tx doesn\'t have one input')
ensure(tx.vin[0].nSequence == prevout_seq, 'Bad input nSequence')
ensure(len(tx.vin[0].scriptSig) == 0, 'Input scriptsig not empty')
ensure(tx.vin[0].scriptSig == self.getScriptScriptSig(prevout_script), 'Input scriptsig mismatch')
ensure(tx.vin[0].prevout.hash == b2i(prevout_id) and tx.vin[0].prevout.n == prevout_n, 'Input prevout mismatch')
ensure(len(tx.vout) == 1, 'tx doesn\'t have one output')
script_pk = CScript([OP_0, hashlib.sha256(script_out).digest()])
script_pk = self.getScriptDest(script_out)
locked_n = findOutput(tx, script_pk)
ensure(locked_n is not None, 'Output not found in tx')
locked_coin = tx.vout[locked_n].nValue
@@ -665,7 +724,7 @@ class BTCInterface(CoinInterface):
ensure(C == Kaf, 'Bad script pubkey')
fee_paid = swap_value - locked_coin
assert(fee_paid > 0)
assert (fee_paid > 0)
dummy_witness_stack = self.getScriptLockTxDummyWitness(prevout_script)
witness_bytes = self.getWitnessStackSerialisedLength(dummy_witness_stack)
@@ -679,10 +738,10 @@ class BTCInterface(CoinInterface):
return txid, locked_coin, locked_n
def verifyLockRefundSpendTx(self, tx_bytes, lock_refund_tx_bytes,
lock_refund_tx_id, prevout_script,
Kal,
prevout_n, prevout_value, feerate, vkbv=None):
def verifySCLockRefundSpendTx(self, tx_bytes, lock_refund_tx_bytes,
lock_refund_tx_id, prevout_script,
Kal,
prevout_n, prevout_value, feerate, vkbv=None):
# Verify:
# Must have only one input with correct prevout (n is always 0) and sequence
# Must have only one output sending lock refund tx value - fee to leader's address, TODO: follower shouldn't need to verify destination addr
@@ -695,7 +754,7 @@ class BTCInterface(CoinInterface):
ensure(len(tx.vin) == 1, 'tx doesn\'t have one input')
ensure(tx.vin[0].nSequence == 0, 'Bad input nSequence')
ensure(len(tx.vin[0].scriptSig) == 0, 'Input scriptsig not empty')
ensure(tx.vin[0].scriptSig == self.getScriptScriptSig(prevout_script), 'Input scriptsig mismatch')
ensure(tx.vin[0].prevout.hash == b2i(lock_refund_tx_id) and tx.vin[0].prevout.n == 0, 'Input prevout mismatch')
ensure(len(tx.vout) == 1, 'tx doesn\'t have one output')
@@ -709,7 +768,7 @@ class BTCInterface(CoinInterface):
tx_value = tx.vout[0].nValue
fee_paid = prevout_value - tx_value
assert(fee_paid > 0)
assert (fee_paid > 0)
dummy_witness_stack = self.getScriptLockRefundSpendTxDummyWitness(prevout_script)
witness_bytes = self.getWitnessStackSerialisedLength(dummy_witness_stack)
@@ -723,9 +782,9 @@ class BTCInterface(CoinInterface):
return True
def verifyLockSpendTx(self, tx_bytes,
lock_tx_bytes, lock_tx_script,
a_pkhash_f, feerate, vkbv=None):
def verifySCLockSpendTx(self, tx_bytes,
lock_tx_bytes, lock_tx_script,
a_pkhash_f, feerate, vkbv=None):
# Verify:
# Must have only one input with correct prevout (n is always 0) and sequence
# Must have only one output with destination and amount
@@ -741,13 +800,13 @@ class BTCInterface(CoinInterface):
lock_tx = self.loadTx(lock_tx_bytes)
lock_tx_id = self.getTxid(lock_tx)
output_script = CScript([OP_0, hashlib.sha256(lock_tx_script).digest()])
output_script = self.getScriptDest(lock_tx_script)
locked_n = findOutput(lock_tx, output_script)
ensure(locked_n is not None, 'Output not found in tx')
locked_coin = lock_tx.vout[locked_n].nValue
ensure(tx.vin[0].nSequence == 0, 'Bad input nSequence')
ensure(len(tx.vin[0].scriptSig) == 0, 'Input scriptsig not empty')
ensure(tx.vin[0].scriptSig == self.getScriptScriptSig(lock_tx_script), 'Input scriptsig mismatch')
ensure(tx.vin[0].prevout.hash == b2i(lock_tx_id) and tx.vin[0].prevout.n == locked_n, 'Input prevout mismatch')
ensure(len(tx.vout) == 1, 'tx doesn\'t have one output')
@@ -756,7 +815,7 @@ class BTCInterface(CoinInterface):
# The value of the lock tx output should already be verified, if the fee is as expected the difference will be the correct amount
fee_paid = locked_coin - tx.vout[0].nValue
assert(fee_paid > 0)
assert (fee_paid > 0)
dummy_witness_stack = self.getScriptLockTxDummyWitness(lock_tx_script)
witness_bytes = self.getWitnessStackSerialisedLength(dummy_witness_stack)
@@ -858,7 +917,7 @@ class BTCInterface(CoinInterface):
def getTxOutputPos(self, tx, script):
if isinstance(tx, bytes):
tx = self.loadTx(tx)
script_pk = CScript([OP_0, hashlib.sha256(script).digest()])
script_pk = self.getScriptDest(script)
return findOutput(tx, script_pk)
def getPubkeyHash(self, K):
@@ -867,6 +926,9 @@ class BTCInterface(CoinInterface):
def getScriptDest(self, script):
return CScript([OP_0, hashlib.sha256(script).digest()])
def getScriptScriptSig(self, script):
return bytes()
def getPkDest(self, K):
return self.getScriptForPubkeyHash(self.getPubkeyHash(K))
@@ -970,13 +1032,24 @@ class BTCInterface(CoinInterface):
def spendBLockTx(self, chain_b_lock_txid, address_to, kbv, kbs, cb_swap_value, b_fee, restore_height):
raise ValueError('TODO')
def importWatchOnlyAddress(self, address, label):
self.rpc_callback('importaddress', [address, label, False])
def isWatchOnlyAddress(self, address):
addr_info = self.rpc_callback('getaddressinfo', [address])
return addr_info['iswatchonly']
def getSCLockScriptAddress(self, lock_script):
lock_tx_dest = self.getScriptDest(lock_script)
return self.encodeScriptDest(lock_tx_dest)
def getLockTxHeight(self, txid, dest_address, bid_amount, rescan_from, find_index=False):
# Add watchonly address and rescan if required
addr_info = self.rpc_callback('getaddressinfo', [dest_address])
if not addr_info['iswatchonly']:
ro = self.rpc_callback('importaddress', [dest_address, 'bid', False])
if not self.isWatchOnlyAddress(dest_address):
self.importWatchOnlyAddress(dest_address, 'bid')
self._log.info('Imported watch-only addr: {}'.format(dest_address))
self._log.info('Rescanning chain from height: {}'.format(rescan_from))
self._log.info('Rescanning {} chain from height: {}'.format(self.coin_name(), rescan_from))
self.rpc_callback('rescanblockchain', [rescan_from])
return_txid = True if txid is None else False
@@ -1049,15 +1122,15 @@ class BTCInterface(CoinInterface):
privkey = PrivateKey(k)
return privkey.sign_recoverable(message_hash, hasher=None)[:64]
def verifyCompact(self, K, message, sig):
def verifyCompactSig(self, K, message, sig):
message_hash = hashlib.sha256(bytes(message, 'utf-8')).digest()
pubkey = PublicKey(K)
rv = pubkey.verify_compact(sig, message_hash, hasher=None)
assert(rv is True)
assert (rv is True)
def verifyMessage(self, address, message, signature, message_magic=None) -> bool:
if message_magic is None:
message_magic = self.chainparams_network()['message_magic']
message_magic = self.chainparams()['message_magic']
message_bytes = SerialiseNumCompact(len(message_magic)) + bytes(message_magic, 'utf-8') + SerialiseNumCompact(len(message)) + bytes(message, 'utf-8')
message_hash = hashlib.sha256(hashlib.sha256(message_bytes).digest()).digest()
@@ -1128,9 +1201,85 @@ class BTCInterface(CoinInterface):
def getSpendableBalance(self):
return self.make_int(self.rpc_callback('getbalances')['mine']['trusted'])
def createUTXO(self, value_sats):
# Create a new address and send value_sats to it
spendable_balance = self.getSpendableBalance()
if spendable_balance < value_sats:
raise ValueError('Balance too low')
address = self.getNewAddress(self._use_segwit, 'create_utxo')
return self.withdrawCoin(self.format_amount(value_sats), address, False), address
def createRawSignedTransaction(self, addr_to, amount):
txn = self.rpc_callback('createrawtransaction', [[], {addr_to: self.format_amount(amount)}])
options = {
'lockUnspents': True,
'conf_target': self._conf_target,
}
txn_funded = self.rpc_callback('fundrawtransaction', [txn, options])['hex']
txn_signed = self.rpc_callback('signrawtransactionwithwallet', [txn_funded])['hex']
return txn_signed
def getBlockWithTxns(self, block_hash):
return self.rpc_callback('getblock', [block_hash, 2])
def getUnspentsByAddr(self):
unspent_addr = dict()
unspent = self.rpc_callback('listunspent')
for u in unspent:
if u['spendable'] is not True:
continue
unspent_addr[u['address']] = unspent_addr.get(u['address'], 0) + self.make_int(u['amount'], r=1)
return unspent_addr
def getUTXOBalance(self, address):
num_blocks = self.rpc_callback('getblockcount')
sum_unspent = 0
self._log.debug('[rm] scantxoutset start') # scantxoutset is slow
ro = self.rpc_callback('scantxoutset', ['start', ['addr({})'.format(address)]]) # TODO: Use combo(address) where possible
self._log.debug('[rm] scantxoutset end')
for o in ro['unspents']:
sum_unspent += self.make_int(o['amount'])
return sum_unspent
def getProofOfFunds(self, amount_for, extra_commit_bytes):
# TODO: Lock unspent and use same output/s to fund bid
unspent_addr = self.getUnspentsByAddr()
sign_for_addr = None
for addr, value in unspent_addr.items():
if value >= amount_for:
sign_for_addr = addr
break
ensure(sign_for_addr is not None, 'Could not find address with enough funds for proof')
self._log.debug('sign_for_addr %s', sign_for_addr)
if self._use_segwit: # TODO: Use isSegwitAddress when scantxoutset can use combo
# 'Address does not refer to key' for non p2pkh
pkh = self.decodeAddress(sign_for_addr)
sign_for_addr = self.pkh_to_address(pkh)
self._log.debug('sign_for_addr converted %s', sign_for_addr)
signature = self.rpc_callback('signmessage', [sign_for_addr, sign_for_addr + '_swap_proof_' + extra_commit_bytes.hex()])
return (sign_for_addr, signature)
def verifyProofOfFunds(self, address, signature, extra_commit_bytes):
passed = self.verifyMessage(address, address + '_swap_proof_' + extra_commit_bytes.hex(), signature)
ensure(passed is True, 'Proof of funds signature invalid')
if self._use_segwit:
address = self.encodeSegwitAddress(decodeAddress(address)[1:])
return self.getUTXOBalance(address)
def testBTCInterface():
print('testBTCInterface')
print('TODO: testBTCInterface')
if __name__ == "__main__":

View File

View File

@@ -0,0 +1,180 @@
# Copyright (c) 2011 Jeff Garzik
#
# Previous copyright, from python-jsonrpc/jsonrpc/proxy.py:
#
# Copyright (c) 2007 Jan-Klaas Kollhof
#
# This file is part of jsonrpc.
#
# jsonrpc is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# This software is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with this software; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
"""HTTP proxy for opening RPC connection to pivxd.
AuthServiceProxy has the following improvements over python-jsonrpc's
ServiceProxy class:
- HTTP connections persist for the life of the AuthServiceProxy object
(if server supports HTTP/1.1)
- sends protocol 'version', per JSON-RPC 1.1
- sends proper, incrementing 'id'
- sends Basic HTTP authentication headers
- parses all JSON numbers that look like floats as Decimal
- uses standard Python json lib
"""
import base64
import decimal
import http.client
import json
import logging
import socket
import time
import urllib.parse
HTTP_TIMEOUT = 300
USER_AGENT = "AuthServiceProxy/0.1"
log = logging.getLogger("BitcoinRPC")
class JSONRPCException(Exception):
def __init__(self, rpc_error):
try:
errmsg = '%(message)s (%(code)i)' % rpc_error
except (KeyError, TypeError):
errmsg = ''
super().__init__(errmsg)
self.error = rpc_error
def EncodeDecimal(o):
if isinstance(o, decimal.Decimal):
return str(o)
raise TypeError(repr(o) + " is not JSON serializable")
class AuthServiceProxy():
__id_count = 0
# ensure_ascii: escape unicode as \uXXXX, passed to json.dumps
def __init__(self, service_url, service_name=None, timeout=HTTP_TIMEOUT, connection=None, ensure_ascii=True):
self.__service_url = service_url
self._service_name = service_name
self.ensure_ascii = ensure_ascii # can be toggled on the fly by tests
self.__url = urllib.parse.urlparse(service_url)
port = 80 if self.__url.port is None else self.__url.port
user = None if self.__url.username is None else self.__url.username.encode('utf8')
passwd = None if self.__url.password is None else self.__url.password.encode('utf8')
authpair = user + b':' + passwd
self.__auth_header = b'Basic ' + base64.b64encode(authpair)
if connection:
# Callables re-use the connection of the original proxy
self.__conn = connection
elif self.__url.scheme == 'https':
self.__conn = http.client.HTTPSConnection(self.__url.hostname, port, timeout=timeout)
else:
self.__conn = http.client.HTTPConnection(self.__url.hostname, port, timeout=timeout)
def __getattr__(self, name):
if name.startswith('__') and name.endswith('__'):
# Python internal stuff
raise AttributeError
if self._service_name is not None:
name = "%s.%s" % (self._service_name, name)
return AuthServiceProxy(self.__service_url, name, connection=self.__conn)
def _request(self, method, path, postdata):
'''
Do a HTTP request, with retry if we get disconnected (e.g. due to a timeout).
This is a workaround for https://bugs.python.org/issue3566 which is fixed in Python 3.5.
'''
headers = {'Host': self.__url.hostname,
'User-Agent': USER_AGENT,
'Authorization': self.__auth_header,
'Content-type': 'application/json'}
try:
self.__conn.request(method, path, postdata, headers)
return self._get_response()
except http.client.BadStatusLine as e:
if e.line == "''": # if connection was closed, try again
self.__conn.close()
self.__conn.request(method, path, postdata, headers)
return self._get_response()
else:
raise
except (BrokenPipeError, ConnectionResetError):
# Python 3.5+ raises BrokenPipeError instead of BadStatusLine when the connection was reset
# ConnectionResetError happens on FreeBSD with Python 3.4
self.__conn.close()
self.__conn.request(method, path, postdata, headers)
return self._get_response()
def get_request(self, *args, **argsn):
AuthServiceProxy.__id_count += 1
log.debug("-%s-> %s %s" % (AuthServiceProxy.__id_count, self._service_name,
json.dumps(args, default=EncodeDecimal, ensure_ascii=self.ensure_ascii)))
if args and argsn:
raise ValueError('Cannot handle both named and positional arguments')
return {'version': '1.1',
'method': self._service_name,
'params': args or argsn,
'id': AuthServiceProxy.__id_count}
def __call__(self, *args, **argsn):
postdata = json.dumps(self.get_request(*args, **argsn), default=EncodeDecimal, ensure_ascii=self.ensure_ascii)
response = self._request('POST', self.__url.path, postdata.encode('utf-8'))
if response['error'] is not None:
raise JSONRPCException(response['error'])
elif 'result' not in response:
raise JSONRPCException({
'code': -343, 'message': 'missing JSON-RPC result'})
else:
return response['result']
def batch(self, rpc_call_list):
postdata = json.dumps(list(rpc_call_list), default=EncodeDecimal, ensure_ascii=self.ensure_ascii)
log.debug("--> " + postdata)
return self._request('POST', self.__url.path, postdata.encode('utf-8'))
def _get_response(self):
req_start_time = time.time()
try:
http_response = self.__conn.getresponse()
except socket.timeout:
raise JSONRPCException({
'code': -344,
'message': '%r RPC took longer than %f seconds. Consider '
'using larger timeout for calls that take '
'longer to return.' % (self._service_name,
self.__conn.timeout)})
if http_response is None:
raise JSONRPCException({
'code': -342, 'message': 'missing HTTP response from server'})
content_type = http_response.getheader('Content-Type')
if content_type != 'application/json':
raise JSONRPCException({
'code': -342, 'message': 'non-JSON HTTP response with \'%i %s\' from server' % (http_response.status, http_response.reason)})
responsedata = http_response.read().decode('utf8')
response = json.loads(responsedata, parse_float=decimal.Decimal)
elapsed = time.time() - req_start_time
if "error" in response and response["error"] is None:
log.debug("<-%s- [%.6f] %s" % (response["id"], elapsed, json.dumps(response["result"], default=EncodeDecimal, ensure_ascii=self.ensure_ascii)))
else:
log.debug("<-- [%.6f] %s" % (elapsed, responsedata))
return response
def __truediv__(self, relative_uri):
return AuthServiceProxy("{}/{}".format(self.__service_url, relative_uri), self._service_name, connection=self.__conn)

View File

@@ -0,0 +1,109 @@
#!/usr/bin/env python3
# Copyright (c) 2015-2017 The Bitcoin Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Utilities for doing coverage analysis on the RPC interface.
Provides a way to track which RPC commands are exercised during
testing.
"""
import os
REFERENCE_FILENAME = 'rpc_interface.txt'
class AuthServiceProxyWrapper():
"""
An object that wraps AuthServiceProxy to record specific RPC calls.
"""
def __init__(self, auth_service_proxy_instance, coverage_logfile=None):
"""
Kwargs:
auth_service_proxy_instance (AuthServiceProxy): the instance
being wrapped.
coverage_logfile (str): if specified, write each service_name
out to a file when called.
"""
self.auth_service_proxy_instance = auth_service_proxy_instance
self.coverage_logfile = coverage_logfile
def __getattr__(self, name):
return_val = getattr(self.auth_service_proxy_instance, name)
if not isinstance(return_val, type(self.auth_service_proxy_instance)):
# If proxy getattr returned an unwrapped value, do the same here.
return return_val
return AuthServiceProxyWrapper(return_val, self.coverage_logfile)
def __call__(self, *args, **kwargs):
"""
Delegates to AuthServiceProxy, then writes the particular RPC method
called to a file.
"""
return_val = self.auth_service_proxy_instance.__call__(*args, **kwargs)
self._log_call()
return return_val
def _log_call(self):
rpc_method = self.auth_service_proxy_instance._service_name
if self.coverage_logfile:
with open(self.coverage_logfile, 'a+', encoding='utf8') as f:
f.write("%s\n" % rpc_method)
def __truediv__(self, relative_uri):
return AuthServiceProxyWrapper(self.auth_service_proxy_instance / relative_uri,
self.coverage_logfile)
def get_request(self, *args, **kwargs):
self._log_call()
return self.auth_service_proxy_instance.get_request(*args)
def get_filename(dirname, n_node):
"""
Get a filename unique to the test process ID and node.
This file will contain a list of RPC commands covered.
"""
pid = str(os.getpid())
return os.path.join(
dirname, "coverage.pid%s.node%s.txt" % (pid, str(n_node)))
def write_all_rpc_commands(dirname, node):
"""
Write out a list of all RPC functions available in `pivx-cli` for
coverage comparison. This will only happen once per coverage
directory.
Args:
dirname (str): temporary test dir
node (AuthServiceProxy): client
Returns:
bool. if the RPC interface file was written.
"""
filename = os.path.join(dirname, REFERENCE_FILENAME)
if os.path.isfile(filename):
return False
help_output = node.help().split('\n')
commands = set()
for line in help_output:
line = line.strip()
# Ignore blanks and headers
if line and not line.startswith('='):
commands.add("%s\n" % line.split()[0])
with open(filename, 'w', encoding='utf8') as f:
f.writelines(list(commands))
return True

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,63 @@
#!/usr/bin/env python3
# Copyright (c) 2016-2017 The Bitcoin Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Specialized SipHash-2-4 implementations.
This implements SipHash-2-4 for 256-bit integers.
"""
def rotl64(n, b):
return n >> (64 - b) | (n & ((1 << (64 - b)) - 1)) << b
def siphash_round(v0, v1, v2, v3):
v0 = (v0 + v1) & ((1 << 64) - 1)
v1 = rotl64(v1, 13)
v1 ^= v0
v0 = rotl64(v0, 32)
v2 = (v2 + v3) & ((1 << 64) - 1)
v3 = rotl64(v3, 16)
v3 ^= v2
v0 = (v0 + v3) & ((1 << 64) - 1)
v3 = rotl64(v3, 21)
v3 ^= v0
v2 = (v2 + v1) & ((1 << 64) - 1)
v1 = rotl64(v1, 17)
v1 ^= v2
v2 = rotl64(v2, 32)
return (v0, v1, v2, v3)
def siphash256(k0, k1, h):
n0 = h & ((1 << 64) - 1)
n1 = (h >> 64) & ((1 << 64) - 1)
n2 = (h >> 128) & ((1 << 64) - 1)
n3 = (h >> 192) & ((1 << 64) - 1)
v0 = 0x736f6d6570736575 ^ k0
v1 = 0x646f72616e646f6d ^ k1
v2 = 0x6c7967656e657261 ^ k0
v3 = 0x7465646279746573 ^ k1 ^ n0
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0 ^= n0
v3 ^= n1
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0 ^= n1
v3 ^= n2
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0 ^= n2
v3 ^= n3
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0 ^= n3
v3 ^= 0x2000000000000000
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0 ^= 0x2000000000000000
v2 ^= 0xFF
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
v0, v1, v2, v3 = siphash_round(v0, v1, v2, v3)
return v0 ^ v1 ^ v2 ^ v3

View File

@@ -0,0 +1,625 @@
#!/usr/bin/env python3
# Copyright (c) 2014-2017 The Bitcoin Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Helpful routines for regression testing."""
from base64 import b64encode
from binascii import hexlify, unhexlify
from decimal import Decimal, ROUND_DOWN
import hashlib
import json
import logging
import os
import random
import re
from subprocess import CalledProcessError
import time
from . import coverage, messages
from .authproxy import AuthServiceProxy, JSONRPCException
logger = logging.getLogger("TestFramework.utils")
# Assert functions
##################
def assert_fee_amount(fee, tx_size, fee_per_kB):
"""Assert the fee was in range"""
target_fee = round(tx_size * fee_per_kB / 1000, 8)
if fee < target_fee:
raise AssertionError("Fee of %s PIV too low! (Should be %s PIV)" % (str(fee), str(target_fee)))
# allow the wallet's estimation to be at most 2 bytes off
if fee > (tx_size + 20) * fee_per_kB / 1000:
raise AssertionError("Fee of %s PIV too high! (Should be %s PIV)" % (str(fee), str(target_fee)))
def assert_equal(thing1, thing2, *args):
if thing1 != thing2 or any(thing1 != arg for arg in args):
raise AssertionError("not(%s)" % " == ".join(str(arg) for arg in (thing1, thing2) + args))
def assert_true(condition, message = ""):
if not condition:
raise AssertionError(message)
def assert_false(condition, message = ""):
assert_true(not condition, message)
def assert_greater_than(thing1, thing2):
if thing1 <= thing2:
raise AssertionError("%s <= %s" % (str(thing1), str(thing2)))
def assert_greater_than_or_equal(thing1, thing2):
if thing1 < thing2:
raise AssertionError("%s < %s" % (str(thing1), str(thing2)))
def assert_raises(exc, fun, *args, **kwds):
assert_raises_message(exc, None, fun, *args, **kwds)
def assert_raises_message(exc, message, fun, *args, **kwds):
try:
fun(*args, **kwds)
except JSONRPCException:
raise AssertionError("Use assert_raises_rpc_error() to test RPC failures")
except exc as e:
if message is not None and message not in e.error['message']:
raise AssertionError("Expected substring not found:" + e.error['message'])
except Exception as e:
raise AssertionError("Unexpected exception raised: " + type(e).__name__)
else:
raise AssertionError("No exception raised")
def assert_raises_process_error(returncode, output, fun, *args, **kwds):
"""Execute a process and asserts the process return code and output.
Calls function `fun` with arguments `args` and `kwds`. Catches a CalledProcessError
and verifies that the return code and output are as expected. Throws AssertionError if
no CalledProcessError was raised or if the return code and output are not as expected.
Args:
returncode (int): the process return code.
output (string): [a substring of] the process output.
fun (function): the function to call. This should execute a process.
args*: positional arguments for the function.
kwds**: named arguments for the function.
"""
try:
fun(*args, **kwds)
except CalledProcessError as e:
if returncode != e.returncode:
raise AssertionError("Unexpected returncode %i" % e.returncode)
if output not in e.output:
raise AssertionError("Expected substring not found:" + e.output)
else:
raise AssertionError("No exception raised")
def assert_raises_rpc_error(code, message, fun, *args, **kwds):
"""Run an RPC and verify that a specific JSONRPC exception code and message is raised.
Calls function `fun` with arguments `args` and `kwds`. Catches a JSONRPCException
and verifies that the error code and message are as expected. Throws AssertionError if
no JSONRPCException was raised or if the error code/message are not as expected.
Args:
code (int), optional: the error code returned by the RPC call (defined
in src/rpc/protocol.h). Set to None if checking the error code is not required.
message (string), optional: [a substring of] the error string returned by the
RPC call. Set to None if checking the error string is not required.
fun (function): the function to call. This should be the name of an RPC.
args*: positional arguments for the function.
kwds**: named arguments for the function.
"""
assert try_rpc(code, message, fun, *args, **kwds), "No exception raised"
def try_rpc(code, message, fun, *args, **kwds):
"""Tries to run an rpc command.
Test against error code and message if the rpc fails.
Returns whether a JSONRPCException was raised."""
try:
fun(*args, **kwds)
except JSONRPCException as e:
# JSONRPCException was thrown as expected. Check the code and message values are correct.
if (code is not None) and (code != e.error["code"]):
raise AssertionError("Unexpected JSONRPC error code %i" % e.error["code"])
if (message is not None) and (message not in e.error['message']):
raise AssertionError("Expected substring (%s) not found in: %s" % (message, e.error['message']))
return True
except Exception as e:
raise AssertionError("Unexpected exception raised: " + type(e).__name__)
else:
return False
def assert_is_hex_string(string):
try:
int(string, 16)
except Exception as e:
raise AssertionError(
"Couldn't interpret %r as hexadecimal; raised: %s" % (string, e))
def assert_is_hash_string(string, length=64):
if not isinstance(string, str):
raise AssertionError("Expected a string, got type %r" % type(string))
elif length and len(string) != length:
raise AssertionError(
"String of length %d expected; got %d" % (length, len(string)))
elif not re.match('[abcdef0-9]+$', string):
raise AssertionError(
"String %r contains invalid characters for a hash." % string)
def assert_array_result(object_array, to_match, expected, should_not_find=False):
"""
Pass in array of JSON objects, a dictionary with key/value pairs
to match against, and another dictionary with expected key/value
pairs.
If the should_not_find flag is true, to_match should not be found
in object_array
"""
if should_not_find:
assert_equal(expected, {})
num_matched = 0
for item in object_array:
all_match = True
for key, value in to_match.items():
if item[key] != value:
all_match = False
if not all_match:
continue
elif should_not_find:
num_matched = num_matched + 1
for key, value in expected.items():
if item[key] != value:
raise AssertionError("%s : expected %s=%s" % (str(item), str(key), str(value)))
num_matched = num_matched + 1
if num_matched == 0 and not should_not_find:
raise AssertionError("No objects matched %s" % (str(to_match)))
if num_matched > 0 and should_not_find:
raise AssertionError("Objects were found %s" % (str(to_match)))
# Utility functions
###################
def check_json_precision():
"""Make sure json library being used does not lose precision converting BTC values"""
n = Decimal("20000000.00000003")
satoshis = int(json.loads(json.dumps(float(n))) * 1.0e8)
if satoshis != 2000000000000003:
raise RuntimeError("JSON encode/decode loses precision")
def count_bytes(hex_string):
return len(bytearray.fromhex(hex_string))
def bytes_to_hex_str(byte_str):
return hexlify(byte_str).decode('ascii')
def hash256(byte_str):
sha256 = hashlib.sha256()
sha256.update(byte_str)
sha256d = hashlib.sha256()
sha256d.update(sha256.digest())
return sha256d.digest()[::-1]
def hex_str_to_bytes(hex_str):
return unhexlify(hex_str.encode('ascii'))
def str_to_b64str(string):
return b64encode(string.encode('utf-8')).decode('ascii')
def satoshi_round(amount):
return Decimal(amount).quantize(Decimal('0.00000001'), rounding=ROUND_DOWN)
def wait_until(predicate,
*,
attempts=float('inf'),
timeout=float('inf'),
lock=None,
sendpings=None,
mocktime=None):
if attempts == float('inf') and timeout == float('inf'):
timeout = 60
attempt = 0
timeout += time.time()
while attempt < attempts and time.time() < timeout:
if lock:
with lock:
if predicate():
return
else:
if predicate():
return
attempt += 1
time.sleep(0.5)
if sendpings is not None:
sendpings()
if mocktime is not None:
mocktime(1)
# Print the cause of the timeout
assert_greater_than(attempts, attempt)
assert_greater_than(timeout, time.time())
raise RuntimeError('Unreachable')
# RPC/P2P connection constants and functions
############################################
# The maximum number of nodes a single test can spawn
MAX_NODES = 8
# Don't assign rpc or p2p ports lower than this
PORT_MIN = 11000
# The number of ports to "reserve" for p2p and rpc, each
PORT_RANGE = 5000
class PortSeed:
# Must be initialized with a unique integer for each process
n = None
def get_rpc_proxy(url, node_number, timeout=None, coveragedir=None):
"""
Args:
url (str): URL of the RPC server to call
node_number (int): the node number (or id) that this calls to
Kwargs:
timeout (int): HTTP timeout in seconds
Returns:
AuthServiceProxy. convenience object for making RPC calls.
"""
proxy_kwargs = {}
if timeout is not None:
proxy_kwargs['timeout'] = timeout
proxy = AuthServiceProxy(url, **proxy_kwargs)
proxy.url = url # store URL on proxy for info
coverage_logfile = coverage.get_filename(
coveragedir, node_number) if coveragedir else None
return coverage.AuthServiceProxyWrapper(proxy, coverage_logfile)
def p2p_port(n):
assert(n <= MAX_NODES)
return PORT_MIN + n + (MAX_NODES * PortSeed.n) % (PORT_RANGE - 1 - MAX_NODES)
def rpc_port(n):
return PORT_MIN + PORT_RANGE + n + (MAX_NODES * PortSeed.n) % (PORT_RANGE - 1 - MAX_NODES)
def rpc_url(datadir, i, rpchost=None):
rpc_u, rpc_p = get_auth_cookie(datadir)
host = '127.0.0.1'
port = rpc_port(i)
if rpchost:
parts = rpchost.split(':')
if len(parts) == 2:
host, port = parts
else:
host = rpchost
return "http://%s:%s@%s:%d" % (rpc_u, rpc_p, host, int(port))
# Node functions
################
def initialize_datadir(dirname, n):
datadir = get_datadir_path(dirname, n)
if not os.path.isdir(datadir):
os.makedirs(datadir)
with open(os.path.join(datadir, "pivx.conf"), 'w', encoding='utf8') as f:
f.write("regtest=1\n")
f.write("[regtest]\n")
f.write("port=" + str(p2p_port(n)) + "\n")
f.write("rpcport=" + str(rpc_port(n)) + "\n")
f.write("server=1\n")
f.write("keypool=1\n")
f.write("discover=0\n")
f.write("listenonion=0\n")
f.write("spendzeroconfchange=1\n")
f.write("printtoconsole=0\n")
f.write("natpmp=0\n")
return datadir
def get_datadir_path(dirname, n):
return os.path.join(dirname, "node" + str(n))
def append_config(dirname, n, options):
datadir = get_datadir_path(dirname, n)
with open(os.path.join(datadir, "pivx.conf"), 'a', encoding='utf8') as f:
for option in options:
f.write(option + "\n")
def get_auth_cookie(datadir):
user = None
password = None
if os.path.isfile(os.path.join(datadir, "pivx.conf")):
with open(os.path.join(datadir, "pivx.conf"), 'r', encoding='utf8') as f:
for line in f:
if line.startswith("rpcuser="):
assert user is None # Ensure that there is only one rpcuser line
user = line.split("=")[1].strip("\n")
if line.startswith("rpcpassword="):
assert password is None # Ensure that there is only one rpcpassword line
password = line.split("=")[1].strip("\n")
if os.path.isfile(os.path.join(datadir, "regtest", ".cookie")):
with open(os.path.join(datadir, "regtest", ".cookie"), 'r', encoding="utf8") as f:
userpass = f.read()
split_userpass = userpass.split(':')
user = split_userpass[0]
password = split_userpass[1]
if user is None or password is None:
raise ValueError("No RPC credentials")
return user, password
# If a cookie file exists in the given datadir, delete it.
def delete_cookie_file(datadir):
if os.path.isfile(os.path.join(datadir, "regtest", ".cookie")):
logger.debug("Deleting leftover cookie file")
os.remove(os.path.join(datadir, "regtest", ".cookie"))
def get_bip9_status(node, key):
info = node.getblockchaininfo()
return info['bip9_softforks'][key]
def set_node_times(nodes, t):
for node in nodes:
node.setmocktime(t)
def disconnect_nodes(from_connection, node_num):
for addr in [peer['addr'] for peer in from_connection.getpeerinfo() if "testnode%d" % node_num in peer['subver']]:
try:
from_connection.disconnectnode(addr)
except JSONRPCException as e:
# If this node is disconnected between calculating the peer id
# and issuing the disconnect, don't worry about it.
# This avoids a race condition if we're mass-disconnecting peers.
if e.error['code'] != -29: # RPC_CLIENT_NODE_NOT_CONNECTED
raise
# wait to disconnect
wait_until(lambda: [peer['addr'] for peer in from_connection.getpeerinfo() if "testnode%d" % node_num in peer['subver']] == [], timeout=5)
def connect_nodes(from_connection, node_num):
ip_port = "127.0.0.1:" + str(p2p_port(node_num))
from_connection.addnode(ip_port, "onetry")
# poll until version handshake complete to avoid race conditions
# with transaction relaying
wait_until(lambda: all(peer['version'] != 0 for peer in from_connection.getpeerinfo()))
def connect_nodes_clique(nodes):
l = len(nodes)
for a in range(l):
for b in range(a, l):
connect_nodes(nodes[a], b)
connect_nodes(nodes[b], a)
# Transaction/Block functions
#############################
def find_output(node, txid, amount):
"""
Return index to output of txid with value amount
Raises exception if there is none.
"""
txdata = node.getrawtransaction(txid, 1)
for i in range(len(txdata["vout"])):
if txdata["vout"][i]["value"] == amount:
return i
raise RuntimeError("find_output txid %s : %s not found" % (txid, str(amount)))
def gather_inputs(from_node, amount_needed, confirmations_required=1):
"""
Return a random set of unspent txouts that are enough to pay amount_needed
"""
assert(confirmations_required >= 0)
utxo = from_node.listunspent(confirmations_required)
random.shuffle(utxo)
inputs = []
total_in = Decimal("0.00000000")
while total_in < amount_needed and len(utxo) > 0:
t = utxo.pop()
total_in += t["amount"]
inputs.append({"txid": t["txid"], "vout": t["vout"], "address": t["address"]})
if total_in < amount_needed:
raise RuntimeError("Insufficient funds: need %d, have %d" % (amount_needed, total_in))
return (total_in, inputs)
def make_change(from_node, amount_in, amount_out, fee):
"""
Create change output(s), return them
"""
outputs = {}
amount = amount_out + fee
change = amount_in - amount
if change > amount * 2:
# Create an extra change output to break up big inputs
change_address = from_node.getnewaddress()
# Split change in two, being careful of rounding:
outputs[change_address] = Decimal(change / 2).quantize(Decimal('0.00000001'), rounding=ROUND_DOWN)
change = amount_in - amount - outputs[change_address]
if change > 0:
outputs[from_node.getnewaddress()] = change
return outputs
def random_transaction(nodes, amount, min_fee, fee_increment, fee_variants):
"""
Create a random transaction.
Returns (txid, hex-encoded-transaction-data, fee)
"""
from_node = random.choice(nodes)
to_node = random.choice(nodes)
fee = min_fee + fee_increment * random.randint(0, fee_variants)
(total_in, inputs) = gather_inputs(from_node, amount + fee)
outputs = make_change(from_node, total_in, amount, fee)
outputs[to_node.getnewaddress()] = float(amount)
rawtx = from_node.createrawtransaction(inputs, outputs)
signresult = from_node.signrawtransaction(rawtx)
txid = from_node.sendrawtransaction(signresult["hex"], True)
return (txid, signresult["hex"], fee)
# Helper to create at least "count" utxos
# Pass in a fee that is sufficient for relay and mining new transactions.
def create_confirmed_utxos(fee, node, count):
to_generate = int(0.5 * count) + 101
while to_generate > 0:
node.generate(min(25, to_generate))
to_generate -= 25
utxos = node.listunspent()
iterations = count - len(utxos)
addr1 = node.getnewaddress()
addr2 = node.getnewaddress()
if iterations <= 0:
return utxos
for i in range(iterations):
t = utxos.pop()
inputs = []
inputs.append({"txid": t["txid"], "vout": t["vout"]})
outputs = {}
send_value = t['amount'] - fee
outputs[addr1] = float(satoshi_round(send_value / 2))
outputs[addr2] = float(satoshi_round(send_value / 2))
raw_tx = node.createrawtransaction(inputs, outputs)
signed_tx = node.signrawtransaction(raw_tx)["hex"]
node.sendrawtransaction(signed_tx)
while (node.getmempoolinfo()['size'] > 0):
node.generate(1)
utxos = node.listunspent()
assert(len(utxos) >= count)
return utxos
# Create large OP_RETURN txouts that can be appended to a transaction
# to make it large (helper for constructing large transactions).
def gen_return_txouts():
# Some pre-processing to create a bunch of OP_RETURN txouts to insert into transactions we create
# So we have big transactions (and therefore can't fit very many into each block)
# create one script_pubkey
script_pubkey = "6a4d0200" # OP_RETURN OP_PUSH2 512 bytes
for i in range(512):
script_pubkey = script_pubkey + "01"
# concatenate 128 txouts of above script_pubkey which we'll insert before the txout for change
txouts = "81"
for k in range(128):
# add txout value
txouts = txouts + "0000000000000000"
# add length of script_pubkey
txouts = txouts + "fd0402"
# add script_pubkey
txouts = txouts + script_pubkey
return txouts
def create_tx(node, coinbase, to_address, amount):
inputs = [{"txid": coinbase, "vout": 0}]
outputs = {to_address: amount}
rawtx = node.createrawtransaction(inputs, outputs)
signresult = node.signrawtransaction(rawtx)
assert_equal(signresult["complete"], True)
return signresult["hex"]
# Create a spend of each passed-in utxo, splicing in "txouts" to each raw
# transaction to make it large. See gen_return_txouts() above.
def create_lots_of_big_transactions(node, txouts, utxos, num, fee):
addr = node.getnewaddress()
txids = []
for _ in range(num):
t = utxos.pop()
inputs = [{"txid": t["txid"], "vout": t["vout"]}]
outputs = {}
change = t['amount'] - fee
outputs[addr] = float(satoshi_round(change))
rawtx = node.createrawtransaction(inputs, outputs)
newtx = rawtx[0:92]
newtx = newtx + txouts
newtx = newtx + rawtx[94:]
signresult = node.signrawtransaction(newtx, None, None, "NONE")
txid = node.sendrawtransaction(signresult["hex"], True)
txids.append(txid)
return txids
def mine_large_block(node, utxos=None):
# generate a 66k transaction,
# and 14 of them is close to the 1MB block limit
num = 14
txouts = gen_return_txouts()
utxos = utxos if utxos is not None else []
if len(utxos) < num:
utxos.clear()
utxos.extend(node.listunspent())
fee = 100 * node.getnetworkinfo()["relayfee"]
create_lots_of_big_transactions(node, txouts, utxos, num, fee=fee)
node.generate(1)
def find_vout_for_address(node, txid, addr):
"""
Locate the vout index of the given transaction sending to the
given address. Raises runtime error exception if not found.
"""
tx = node.getrawtransaction(txid, True)
for i in range(len(tx["vout"])):
if any([addr == a for a in tx["vout"][i]["scriptPubKey"]["addresses"]]):
return i
raise RuntimeError("Vout not found for address: txid=%s, addr=%s" % (txid, addr))
# PIVX specific utils
DEFAULT_FEE = 0.01
SPORK_ACTIVATION_TIME = 1563253447
SPORK_DEACTIVATION_TIME = 4070908800
def DecimalAmt(x):
"""Return Decimal from float for equality checks against rpc outputs"""
return Decimal("{:0.8f}".format(x))
# Find a coinstake/coinbase address on the node, filtering by the number of UTXOs it has.
# If no filter is provided, returns the coinstake/coinbase address on the node containing
# the greatest number of spendable UTXOs.
# The default cached chain has one address per coinbase output.
def get_coinstake_address(node, expected_utxos=None):
addrs = [utxo['address'] for utxo in node.listunspent() if utxo['generated']]
assert(len(set(addrs)) > 0)
if expected_utxos is None:
addrs = [(addrs.count(a), a) for a in set(addrs)]
return sorted(addrs, reverse=True)[0][1]
addrs = [a for a in set(addrs) if addrs.count(a) == expected_utxos]
assert(len(addrs) > 0)
return addrs[0]
# Deterministic masternodes
def is_coin_locked_by(node, outpoint):
return outpoint.to_json() in node.listlockunspent()
def get_collateral_vout(json_tx):
funding_txidn = -1
for o in json_tx["vout"]:
if o["value"] == Decimal('100'):
funding_txidn = o["n"]
break
assert_greater_than(funding_txidn, -1)
return funding_txidn
# owner and voting keys are created from controller node.
# operator keys are created, if operator_keys is None.
def create_new_dmn(idx, controller, payout_addr, operator_keys):
port = p2p_port(idx) if idx <= MAX_NODES else p2p_port(MAX_NODES) + (idx - MAX_NODES)
ipport = "127.0.0.1:" + str(port)
owner_addr = controller.getnewaddress("mnowner-%d" % idx)
voting_addr = controller.getnewaddress("mnvoting-%d" % idx)
if operator_keys is None:
bls_keypair = controller.generateblskeypair()
operator_pk = bls_keypair["public"]
operator_sk = bls_keypair["secret"]
else:
operator_pk = operator_keys[0]
operator_sk = operator_keys[1]
return messages.Masternode(idx, owner_addr, operator_pk, voting_addr, ipport, payout_addr, operator_sk)
def spend_mn_collateral(spender, dmn):
inputs = [dmn.collateral.to_json()]
outputs = {spender.getnewaddress(): Decimal('99.99')}
sig_res = spender.signrawtransaction(spender.createrawtransaction(inputs, outputs))
assert_equal(sig_res['complete'], True)
return spender.sendrawtransaction(sig_res['hex'])

View File

@@ -0,0 +1,34 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from .btc import BTCInterface
from basicswap.chainparams import Coins
from mnemonic import Mnemonic
class DASHInterface(BTCInterface):
@staticmethod
def coin_type():
return Coins.DASH
def initialiseWallet(self, key):
words = Mnemonic('english').to_mnemonic(key)
self.rpc_callback('upgradetohd', [words, ])
def checkExpectedSeed(self, key_hash):
try:
rv = self.rpc_callback('dumphdinfo')
entropy = Mnemonic('english').to_entropy(rv['mnemonic'].split(' '))
entropy_hash = self.getAddressHashFromKey(entropy)[::-1].hex()
return entropy_hash == key_hash
except Exception as e:
self._log.warning('checkExpectedSeed failed: {}'.format(str(e)))
return False
def withdrawCoin(self, value, addr_to, subfee):
params = [addr_to, value, '', '', subfee]
return self.rpc_callback('sendtoaddress', params)

175
basicswap/interface/firo.py Normal file
View File

@@ -0,0 +1,175 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import hashlib
from .btc import BTCInterface, find_vout_for_address_from_txobj
from basicswap.chainparams import Coins
from basicswap.util.address import (
decodeAddress,
)
from basicswap.contrib.test_framework.script import (
CScript,
OP_0,
OP_DUP,
OP_EQUAL,
OP_HASH160,
OP_CHECKSIG,
OP_EQUALVERIFY,
hash160,
)
from basicswap.contrib.test_framework.messages import (
CTransaction,
)
class FIROInterface(BTCInterface):
@staticmethod
def coin_type():
return Coins.FIRO
def initialiseWallet(self, key):
# load with -hdseed= parameter
pass
def getNewAddress(self, use_segwit, label='swap_receive'):
return self.rpc_callback('getnewaddress', [label])
# addr_plain = self.rpc_callback('getnewaddress', [label])
# return self.rpc_callback('addwitnessaddress', [addr_plain])
def decodeAddress(self, address):
return decodeAddress(address)[1:]
def encodeSegwitAddress(self, script):
raise ValueError('TODO')
def decodeSegwitAddress(self, addr):
raise ValueError('TODO')
def isWatchOnlyAddress(self, address):
addr_info = self.rpc_callback('validateaddress', [address])
return addr_info['iswatchonly']
def getSCLockScriptAddress(self, lock_script):
lock_tx_dest = self.getScriptDest(lock_script)
address = self.encodeScriptDest(lock_tx_dest)
if not self.isWatchOnlyAddress(address):
# Expects P2WSH nested in BIP16_P2SH
ro = self.rpc_callback('importaddress', [lock_tx_dest.hex(), 'bid lock', False, True])
addr_info = self.rpc_callback('validateaddress', [address])
return address
def getLockTxHeightFiro(self, txid, lock_script, bid_amount, rescan_from, find_index=False):
# Add watchonly address and rescan if required
lock_tx_dest = self.getScriptDest(lock_script)
dest_address = self.encodeScriptDest(lock_tx_dest)
if not self.isWatchOnlyAddress(dest_address):
self.rpc_callback('importaddress', [lock_tx_dest.hex(), 'bid lock', False, True])
self._log.info('Imported watch-only addr: {}'.format(dest_address))
self._log.info('Rescanning {} chain from height: {}'.format(self.coin_name(), rescan_from))
self.rpc_callback('rescanblockchain', [rescan_from])
return_txid = True if txid is None else False
if txid is None:
txns = self.rpc_callback('listunspent', [0, 9999999, [dest_address, ]])
for tx in txns:
if self.make_int(tx['amount']) == bid_amount:
txid = bytes.fromhex(tx['txid'])
break
if txid is None:
return None
try:
tx = self.rpc_callback('gettransaction', [txid.hex()])
block_height = 0
if 'blockhash' in tx:
block_header = self.rpc_callback('getblockheader', [tx['blockhash']])
block_height = block_header['height']
rv = {
'depth': 0 if 'confirmations' not in tx else tx['confirmations'],
'height': block_height}
except Exception as e:
self._log.debug('getLockTxHeight gettransaction failed: %s, %s', txid.hex(), str(e))
return None
if find_index:
tx_obj = self.rpc_callback('decoderawtransaction', [tx['hex']])
rv['index'] = find_vout_for_address_from_txobj(tx_obj, dest_address)
if return_txid:
rv['txid'] = txid.hex()
return rv
def createSCLockTx(self, value, Kal, Kaf, vkbv=None):
script = self.genScriptLockTxScript(Kal, Kaf)
tx = CTransaction()
tx.nVersion = self.txVersion()
tx.vout.append(self.txoType()(value, self.getScriptDest(script)))
return tx.serialize(), script
def fundSCLockTx(self, tx_bytes, feerate, vkbv=None):
return self.fundTx(tx_bytes, feerate)
def signTxWithWallet(self, tx):
rv = self.rpc_callback('signrawtransaction', [tx.hex()])
return bytes.fromhex(rv['hex'])
def createRawSignedTransaction(self, addr_to, amount):
txn = self.rpc_callback('createrawtransaction', [[], {addr_to: self.format_amount(amount)}])
fee_rate, fee_src = self.get_fee_rate(self._conf_target)
self._log.debug(f'Fee rate: {fee_rate}, source: {fee_src}, block target: {self._conf_target}')
options = {
'lockUnspents': True,
'feeRate': fee_rate,
}
txn_funded = self.rpc_callback('fundrawtransaction', [txn, options])['hex']
txn_signed = self.rpc_callback('signrawtransaction', [txn_funded])['hex']
return txn_signed
def getScriptForPubkeyHash(self, pkh):
# Return P2WPKH nested in BIP16 P2SH
return CScript([OP_DUP, OP_HASH160, pkh, OP_EQUALVERIFY, OP_CHECKSIG])
def getScriptDest(self, script):
# P2WSH nested in BIP16_P2SH
script_hash = hashlib.sha256(script).digest()
assert len(script_hash) == 32
script_hash_hash = hash160(script_hash)
assert len(script_hash_hash) == 20
return CScript([OP_HASH160, script_hash_hash, OP_EQUAL])
def getSeedHash(self, seed):
return hash160(seed)[::-1]
def encodeScriptDest(self, script):
# Extract hash from script
script_hash = script[2:-1]
return self.sh_to_address(script_hash)
def getScriptScriptSig(self, script):
return CScript([OP_0, hashlib.sha256(script).digest()])
def withdrawCoin(self, value, addr_to, subfee):
params = [addr_to, value, '', '', subfee]
return self.rpc_callback('sendtoaddress', params)
def getWalletSeedID(self):
return self.rpc_callback('getwalletinfo')['hdmasterkeyid']

View File

@@ -5,8 +5,8 @@
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from .interface_btc import BTCInterface
from .chainparams import Coins
from .btc import BTCInterface
from basicswap.chainparams import Coins
class LTCInterface(BTCInterface):

View File

@@ -0,0 +1,42 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2020-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from .btc import BTCInterface
from basicswap.chainparams import Coins
from basicswap.util import (
make_int,
)
class NMCInterface(BTCInterface):
@staticmethod
def coin_type():
return Coins.NMC
def getLockTxHeight(self, txid, dest_address, bid_amount, rescan_from, find_index=False):
self._log.debug('[rm] scantxoutset start') # scantxoutset is slow
ro = self.rpc_callback('scantxoutset', ['start', ['addr({})'.format(dest_address)]]) # TODO: Use combo(address) where possible
self._log.debug('[rm] scantxoutset end')
return_txid = True if txid is None else False
for o in ro['unspents']:
if txid and o['txid'] != txid.hex():
continue
# Verify amount
if make_int(o['amount']) != int(bid_amount):
self._log.warning('Found output to lock tx address of incorrect value: %s, %s', str(o['amount']), o['txid'])
continue
rv = {
'depth': 0,
'height': o['height']}
if o['height'] > 0:
rv['depth'] = ro['height'] - o['height']
if find_index:
rv['index'] = o['vout']
if return_txid:
rv['txid'] = o['txid']
return rv

View File

@@ -1,34 +1,37 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2020-2021 tecnovert
# Copyright (c) 2020-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import hashlib
from enum import IntEnum
from .contrib.test_framework.messages import (
from basicswap.contrib.test_framework.messages import (
CTxOutPart,
)
from .contrib.test_framework.script import (
from basicswap.contrib.test_framework.script import (
CScript,
OP_0,
OP_DUP, OP_HASH160, OP_EQUALVERIFY, OP_CHECKSIG
)
from .ecc_util import i2b
from .util import (
toWIF,
from basicswap.util import (
i2b,
ensure,
make_int,
getP2WSH,
TemporaryError,
)
from basicswap.util.script import (
getP2WSH,
getCompactSizeLen,
encodeStealthAddress,
getWitnessElementLen)
from .chainparams import Coins, chainparams
from .interface_btc import BTCInterface
getWitnessElementLen,
)
from basicswap.util.address import (
toWIF,
encodeStealthAddress)
from basicswap.chainparams import Coins, chainparams
from .btc import BTCInterface
class BalanceTypes(IntEnum):
@@ -62,19 +65,23 @@ class PARTInterface(BTCInterface):
def txoType():
return CTxOutPart
def setDefaults(self) -> None:
super().setDefaults()
self._anon_tx_ring_size = 8 # TODO: Make option
def __init__(self, coin_settings, network, swap_client=None):
super().__init__(coin_settings, network, swap_client)
self.setAnonTxRingSize(int(coin_settings.get('anon_tx_ring_size', 12)))
def setAnonTxRingSize(self, value):
ensure(value >= 3 and value < 33, 'Invalid anon_tx_ring_size value')
self._anon_tx_ring_size = value
def knownWalletSeed(self):
# TODO: Double check
return True
def getNewAddress(self, use_segwit):
return self.rpc_callback('getnewaddress', ['swap_receive'])
def getNewAddress(self, use_segwit, label='swap_receive'):
return self.rpc_callback('getnewaddress', [label])
def getNewStealthAddress(self):
return self.rpc_callback('getnewstealthaddress', ['swap_stealth'])
def getNewStealthAddress(self, label='swap_stealth'):
return self.rpc_callback('getnewstealthaddress', [label])
def haveSpentIndex(self):
version = self.getDaemonVersion()
@@ -159,13 +166,13 @@ class PARTInterfaceBlind(PARTInterface):
ensure(v['result'] is True, 'verifycommitment failed')
return output_n, blinded_info
def createScriptLockTx(self, value, Kal, Kaf, vkbv):
def createSCLockTx(self, value, Kal, Kaf, vkbv):
script = self.genScriptLockTxScript(Kal, Kaf)
# Nonce is derived from vkbv, ephemeral_key isn't used
ephemeral_key = i2b(self.getNewSecretKey())
ephemeral_pubkey = self.getPubkey(ephemeral_key)
assert(len(ephemeral_pubkey) == 33)
assert (len(ephemeral_pubkey) == 33)
nonce = self.getScriptLockTxNonce(vkbv)
p2wsh_addr = self.encode_p2wsh(getP2WSH(script))
inputs = []
@@ -176,7 +183,7 @@ class PARTInterfaceBlind(PARTInterface):
tx_bytes = bytes.fromhex(rv['hex'])
return tx_bytes, script
def fundScriptLockTx(self, tx_bytes, feerate, vkbv):
def fundSCLockTx(self, tx_bytes, feerate, vkbv):
feerate_str = self.format_amount(feerate)
# TODO: unlock unspents if bid cancelled
@@ -185,7 +192,7 @@ class PARTInterfaceBlind(PARTInterface):
tx_obj = self.rpc_callback('decoderawtransaction', [tx_hex])
assert(len(tx_obj['vout']) == 1)
assert (len(tx_obj['vout']) == 1)
txo = tx_obj['vout'][0]
blinded_info = self.rpc_callback('rewindrangeproof', [txo['rangeproof'], txo['valueCommitment'], nonce.hex()])
@@ -198,13 +205,13 @@ class PARTInterfaceBlind(PARTInterface):
rv = self.rpc_callback('fundrawtransactionfrom', ['blind', tx_hex, {}, outputs_info, options])
return bytes.fromhex(rv['hex'])
def createScriptLockRefundTx(self, tx_lock_bytes, script_lock, Kal, Kaf, lock1_value, csv_val, tx_fee_rate, vkbv):
def createSCLockRefundTx(self, tx_lock_bytes, script_lock, Kal, Kaf, lock1_value, csv_val, tx_fee_rate, vkbv):
lock_tx_obj = self.rpc_callback('decoderawtransaction', [tx_lock_bytes.hex()])
assert(self.getTxid(tx_lock_bytes).hex() == lock_tx_obj['txid'])
assert (self.getTxid(tx_lock_bytes).hex() == lock_tx_obj['txid'])
# Nonce is derived from vkbv, ephemeral_key isn't used
ephemeral_key = i2b(self.getNewSecretKey())
ephemeral_pubkey = self.getPubkey(ephemeral_key)
assert(len(ephemeral_pubkey) == 33)
assert (len(ephemeral_pubkey) == 33)
nonce = self.getScriptLockTxNonce(vkbv)
output_nonce = self.getScriptLockRefundTxNonce(vkbv)
@@ -245,7 +252,7 @@ class PARTInterfaceBlind(PARTInterface):
return bytes.fromhex(lock_refund_tx_hex), refund_script, refunded_value
def createScriptLockRefundSpendTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_refund_to, tx_fee_rate, vkbv):
def createSCLockRefundSpendTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_refund_to, tx_fee_rate, vkbv):
# Returns the coinA locked coin to the leader
# The follower will sign the multisig path with a signature encumbered by the leader's coinB spend pubkey
# If the leader publishes the decrypted signature the leader's coinB spend privatekey will be revealed to the follower
@@ -290,11 +297,11 @@ class PARTInterfaceBlind(PARTInterface):
return bytes.fromhex(lock_refund_spend_tx_hex)
def verifyLockTx(self, tx_bytes, script_out,
swap_value,
Kal, Kaf,
feerate,
check_lock_tx_inputs, vkbv):
def verifySCLockTx(self, tx_bytes, script_out,
swap_value,
Kal, Kaf,
feerate,
check_lock_tx_inputs, vkbv):
lock_tx_obj = self.rpc_callback('decoderawtransaction', [tx_bytes.hex()])
lock_txid_hex = lock_tx_obj['txid']
self._log.info('Verifying lock tx: {}.'.format(lock_txid_hex))
@@ -334,9 +341,9 @@ class PARTInterfaceBlind(PARTInterface):
return bytes.fromhex(lock_txid_hex), lock_output_n
def verifyLockRefundTx(self, tx_bytes, lock_tx_bytes, script_out,
prevout_id, prevout_n, prevout_seq, prevout_script,
Kal, Kaf, csv_val_expect, swap_value, feerate, vkbv):
def verifySCLockRefundTx(self, tx_bytes, lock_tx_bytes, script_out,
prevout_id, prevout_n, prevout_seq, prevout_script,
Kal, Kaf, csv_val_expect, swap_value, feerate, vkbv):
lock_refund_tx_obj = self.rpc_callback('decoderawtransaction', [tx_bytes.hex()])
lock_refund_txid_hex = lock_refund_tx_obj['txid']
self._log.info('Verifying lock refund tx: {}.'.format(lock_refund_txid_hex))
@@ -392,10 +399,10 @@ class PARTInterfaceBlind(PARTInterface):
return bytes.fromhex(lock_refund_txid_hex), lock_refund_txo_value, lock_refund_output_n
def verifyLockRefundSpendTx(self, tx_bytes, lock_refund_tx_bytes,
lock_refund_tx_id, prevout_script,
Kal,
prevout_n, prevout_value, feerate, vkbv):
def verifySCLockRefundSpendTx(self, tx_bytes, lock_refund_tx_bytes,
lock_refund_tx_id, prevout_script,
Kal,
prevout_n, prevout_value, feerate, vkbv):
lock_refund_spend_tx_obj = self.rpc_callback('decoderawtransaction', [tx_bytes.hex()])
lock_refund_spend_txid_hex = lock_refund_spend_tx_obj['txid']
self._log.info('Verifying lock refund spend tx: {}.'.format(lock_refund_spend_txid_hex))
@@ -453,7 +460,7 @@ class PARTInterfaceBlind(PARTInterface):
ensure(output_n is not None, 'Output not found in tx')
return output_n
def createScriptLockSpendTx(self, tx_lock_bytes, script_lock, pk_dest, tx_fee_rate, vkbv):
def createSCLockSpendTx(self, tx_lock_bytes, script_lock, pk_dest, tx_fee_rate, vkbv):
lock_tx_obj = self.rpc_callback('decoderawtransaction', [tx_lock_bytes.hex()])
lock_txid_hex = lock_tx_obj['txid']
@@ -494,14 +501,14 @@ class PARTInterfaceBlind(PARTInterface):
vsize = lock_spend_tx_obj['vsize']
pay_fee = make_int(lock_spend_tx_obj['vout'][0]['ct_fee'])
actual_tx_fee_rate = pay_fee * 1000 // vsize
self._log.info('createScriptLockSpendTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
self._log.info('createSCLockSpendTx %s:\n fee_rate, vsize, fee: %ld, %ld, %ld.',
lock_spend_tx_obj['txid'], actual_tx_fee_rate, vsize, pay_fee)
return bytes.fromhex(lock_spend_tx_hex)
def verifyLockSpendTx(self, tx_bytes,
lock_tx_bytes, lock_tx_script,
a_pk_f, feerate, vkbv):
def verifySCLockSpendTx(self, tx_bytes,
lock_tx_bytes, lock_tx_script,
a_pk_f, feerate, vkbv):
lock_spend_tx_obj = self.rpc_callback('decoderawtransaction', [tx_bytes.hex()])
lock_spend_txid_hex = lock_spend_tx_obj['txid']
self._log.info('Verifying lock spend tx: {}.'.format(lock_spend_txid_hex))
@@ -571,7 +578,7 @@ class PARTInterfaceBlind(PARTInterface):
return True
def createScriptLockRefundSpendToFTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_dest, tx_fee_rate, vkbv):
def createSCLockRefundSpendToFTx(self, tx_lock_refund_bytes, script_lock_refund, pkh_dest, tx_fee_rate, vkbv):
# lock refund swipe tx
# Sends the coinA locked coin to the follower
lock_refund_tx_obj = self.rpc_callback('decoderawtransaction', [tx_lock_refund_bytes.hex()])
@@ -660,7 +667,7 @@ class PARTInterfaceAnon(PARTInterface):
wif_scan_key = toWIF(wif_prefix, kbv)
self.rpc_callback('importstealthaddress', [wif_scan_key, Kbs.hex()])
self._log.info('Imported watch-only sx_addr: {}'.format(sx_addr))
self._log.info('Rescanning chain from height: {}'.format(restore_height))
self._log.info('Rescanning {} chain from height: {}'.format(self.coin_name(), restore_height))
self.rpc_callback('rescanblockchain', [restore_height])
params = [{'include_watchonly': True, 'search': sx_addr}]
@@ -668,7 +675,7 @@ class PARTInterfaceAnon(PARTInterface):
if len(txns) == 1:
tx = txns[0]
assert(tx['outputs'][0]['stealth_address'] == sx_addr) # Should not be possible
assert (tx['outputs'][0]['stealth_address'] == sx_addr) # Should not be possible
ensure(tx['outputs'][0]['type'] == 'anon', 'Output is not anon')
if make_int(tx['outputs'][0]['amount']) == cb_swap_value:
@@ -693,7 +700,7 @@ class PARTInterfaceAnon(PARTInterface):
wif_spend_key = toWIF(wif_prefix, kbs)
self.rpc_callback('importstealthaddress', [wif_scan_key, wif_spend_key])
self._log.info('Imported spend key for sx_addr: {}'.format(sx_addr))
self._log.info('Rescanning chain from height: {}'.format(restore_height))
self._log.info('Rescanning {} chain from height: {}'.format(self.coin_name(), restore_height))
self.rpc_callback('rescanblockchain', [restore_height])
autxos = self.rpc_callback('listunspentanon', [1, 9999999, [sx_addr]])
@@ -705,6 +712,7 @@ class PARTInterfaceAnon(PARTInterface):
utxo = autxos[0]
utxo_sats = make_int(utxo['amount'])
if spend_actual_balance and utxo_sats != cb_swap_value:
self._log.warning('Spending actual balance {}, not swap value {}.'.format(utxo_sats, cb_swap_value))
cb_swap_value = utxo_sats

View File

@@ -5,8 +5,8 @@
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from .interface_btc import BTCInterface
from .contrib.test_framework.messages import (
from .btc import BTCInterface
from basicswap.contrib.test_framework.messages import (
CTxOut)

View File

@@ -0,0 +1,60 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2020 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from .btc import BTCInterface
from basicswap.chainparams import Coins
from .contrib.pivx_test_framework.messages import (
CBlock,
ToHex,
FromHex)
class PIVXInterface(BTCInterface):
@staticmethod
def coin_type():
return Coins.PIVX
def createRawSignedTransaction(self, addr_to, amount):
txn = self.rpc_callback('createrawtransaction', [[], {addr_to: self.format_amount(amount)}])
fee_rate, fee_src = self.get_fee_rate(self._conf_target)
self._log.debug(f'Fee rate: {fee_rate}, source: {fee_src}, block target: {self._conf_target}')
options = {
'lockUnspents': True,
'feeRate': fee_rate,
}
txn_funded = self.rpc_callback('fundrawtransaction', [txn, options])['hex']
txn_signed = self.rpc_callback('signrawtransaction', [txn_funded])['hex']
return txn_signed
def getBlockWithTxns(self, block_hash):
# TODO: Bypass decoderawtransaction and getblockheader
block = self.rpc_callback('getblock', [block_hash, False])
block_header = self.rpc_callback('getblockheader', [block_hash])
decoded_block = CBlock()
decoded_block = FromHex(decoded_block, block)
tx_rv = []
for tx in decoded_block.vtx:
tx_dec = self.rpc_callback('decoderawtransaction', [ToHex(tx)])
tx_rv.append(tx_dec)
block_rv = {
'hash': block_hash,
'tx': tx_rv,
'confirmations': block_header['confirmations'],
'height': block_header['height'],
'version': block_header['version'],
'merkleroot': block_header['merkleroot'],
}
return block_rv
def withdrawCoin(self, value, addr_to, subfee):
params = [addr_to, value, '', '', subfee]
return self.rpc_callback('sendtoaddress', params)

View File

@@ -1,41 +1,41 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2020-2021 tecnovert
# Copyright (c) 2020-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import time
import json
import logging
import basicswap.contrib.ed25519_fast as edf
import basicswap.ed25519_fast_util as edu
import basicswap.util_xmr as xmr_util
from coincurve.ed25519 import (
ed25519_add,
ed25519_get_pubkey,
ed25519_scalar_add,
ed25519_add)
)
from coincurve.keys import PrivateKey
from coincurve.dleag import (
verify_ed25519_point,
dleag_proof_len,
dleag_prove,
dleag_verify,
dleag_prove)
dleag_proof_len,
verify_ed25519_point,
)
from .util import (
ensure,
from basicswap.util import (
dumpj,
ensure,
make_int,
TemporaryError)
from .rpc_xmr import (
from basicswap.rpc_xmr import (
make_xmr_rpc_func,
make_xmr_rpc2_func,
make_xmr_wallet_rpc_func)
from .ecc_util import (
from basicswap.util import (
b2i, b2h)
from .chainparams import CoinInterface, Coins
XMR_COIN = 10 ** 12
from basicswap.chainparams import XMR_COIN, CoinInterface, Coins
class XMRInterface(CoinInterface):
@@ -67,7 +67,7 @@ class XMRInterface(CoinInterface):
super().__init__(network)
self.rpc_cb = make_xmr_rpc_func(coin_settings['rpcport'], host=coin_settings.get('rpchost', '127.0.0.1'))
self.rpc_cb2 = make_xmr_rpc2_func(coin_settings['rpcport'], host=coin_settings.get('rpchost', '127.0.0.1')) # non-json endpoint
self.rpc_wallet_cb = make_xmr_wallet_rpc_func(coin_settings['walletrpcport'], coin_settings['walletrpcauth'])
self.rpc_wallet_cb = make_xmr_wallet_rpc_func(coin_settings['walletrpcport'], coin_settings['walletrpcauth'], host=coin_settings.get('walletrpchost', '127.0.0.1'))
self.blocks_confirmed = coin_settings['blocks_confirmed']
self._restore_height = coin_settings.get('restore_height', 0)
@@ -110,29 +110,41 @@ class XMRInterface(CoinInterface):
with self._mx_wallet:
self.rpc_wallet_cb('open_wallet', {'filename': self._wallet_filename})
def testDaemonRPC(self):
def testDaemonRPC(self, with_wallet=True):
self.rpc_wallet_cb('get_languages')
def getDaemonVersion(self):
return self.rpc_wallet_cb('get_version')['version']
def getBlockchainInfo(self):
rv = {}
get_height = self.rpc_cb2('get_height', timeout=30)
rv = {
'blocks': get_height['height'],
'verificationprogress': 0.0,
}
# get_block_count returns "Internal error" if bootstrap-daemon is active
# rv['blocks'] = self.rpc_cb('get_block_count')['count']
rv['blocks'] = self.rpc_cb2('get_height', timeout=30)['height']
try:
# get_block_count.block_count is how many blocks are in the longest chain known to the node.
# get_block_count returns "Internal error" if bootstrap-daemon is active
if get_height['untrusted'] is True:
rv['bootstrapping'] = True
get_info = self.rpc_cb2('get_info', timeout=30)
if 'height_without_bootstrap' in get_info:
rv['blocks'] = get_info['height_without_bootstrap']
# sync_info = self.rpc_cb('sync_info', timeout=30)
# rv['verificationprogress'] = 0.0 if 'spans' in sync_info else 1.0
rv['verificationprogress'] = 0.0
rv['known_block_count'] = get_info['height']
if rv['known_block_count'] > rv['blocks']:
rv['verificationprogress'] = rv['blocks'] / rv['known_block_count']
else:
rv['known_block_count'] = self.rpc_cb('get_block_count', timeout=30)['count']
rv['verificationprogress'] = rv['blocks'] / rv['known_block_count']
except Exception as e:
self._log.warning('XMR get_block_count failed with: %s', str(e))
rv['verificationprogress'] = 0.0
return rv
def getChainHeight(self):
# get_block_count returns "Internal error" if bootstrap-daemon is active
# return self.rpc_cb('get_info')['height']
# return self.rpc_cb('get_block_count')['count']
return self.rpc_cb2('get_height', timeout=30)['height']
def getWalletInfo(self):
@@ -155,7 +167,6 @@ class XMRInterface(CoinInterface):
def getNewAddress(self, placeholder):
with self._mx_wallet:
self._log.warning('TODO - subaddress?')
self.rpc_wallet_cb('open_wallet', {'filename': self._wallet_filename})
return self.rpc_wallet_cb('create_address', {'account_index': 0})['address']
@@ -170,7 +181,10 @@ class XMRInterface(CoinInterface):
return edf.scalarmult_B(key)
def encodeKey(self, vk):
return vk.hex()
return vk[::-1].hex()
def decodeKey(self, k_hex):
return bytes.fromhex(k_hex)[::-1]
def encodePubkey(self, pk):
return edu.encodepoint(pk)
@@ -188,7 +202,7 @@ class XMRInterface(CoinInterface):
def verifyKey(self, k):
i = b2i(k)
return(i < edf.l and i > 8)
return (i < edf.l and i > 8)
def verifyPubkey(self, pubkey_bytes):
# Calls ed25519_decode_check_point() in secp256k1
@@ -205,9 +219,6 @@ class XMRInterface(CoinInterface):
def lengthDLEAG(self):
return dleag_proof_len()
def decodeKey(self, k_hex):
return bytes.fromhex(k_hex)
def sumKeys(self, ka, kb):
return ed25519_scalar_add(ka, kb)
@@ -217,7 +228,7 @@ class XMRInterface(CoinInterface):
def encodeSharedAddress(self, Kbv, Kbs):
return xmr_util.encode_address(Kbv, Kbs)
def publishBLockTx(self, Kbv, Kbs, output_amount, feerate):
def publishBLockTx(self, Kbv, Kbs, output_amount, feerate, delay_for=10):
with self._mx_wallet:
self.rpc_wallet_cb('open_wallet', {'filename': self._wallet_filename})
@@ -230,14 +241,17 @@ class XMRInterface(CoinInterface):
self._log.info('publishBLockTx %s to address_b58 %s', rv['tx_hash'], shared_addr)
tx_hash = bytes.fromhex(rv['tx_hash'])
# Debug
for i in range(10):
params = {'out': True, 'pending': True, 'failed': True, 'pool': True, }
rv = self.rpc_wallet_cb('get_transfers', params)
self._log.info('[rm] get_transfers {}'.format(dumpj(rv)))
if 'pending' not in rv:
break
time.sleep(1)
if self._sc.debug:
i = 0
while not self._sc.delay_event.is_set():
params = {'out': True, 'pending': True, 'failed': True, 'pool': True, }
rv = self.rpc_wallet_cb('get_transfers', params)
self._log.debug('get_transfers {}'.format(dumpj(rv)))
if 'pending' not in rv:
break
if i >= delay_for:
break
self._sc.delay_event.wait(1.0)
return tx_hash
@@ -333,7 +347,6 @@ class XMRInterface(CoinInterface):
return True
# TODO: Is it necessary to check the address?
'''
rv = self.rpc_wallet_cb('get_balance')
print('get_balance', rv)
@@ -346,7 +359,9 @@ class XMRInterface(CoinInterface):
if i >= num_tries:
raise ValueError('Balance not confirming on node')
time.sleep(1)
self._sc.delay_event.wait(1.0)
if self._sc.delay_event.is_set():
raise ValueError('Stopped')
return False
@@ -431,7 +446,7 @@ class XMRInterface(CoinInterface):
params['priority'] = self._fee_priority
rv = self.rpc_wallet_cb('sweep_all', params)
print('sweep_all', rv)
self._log.debug('sweep_all {}'.format(json.dumps(rv)))
return bytes.fromhex(rv['tx_hash_list'][0])

View File

@@ -1,18 +0,0 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2020-2021 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from .interface_btc import BTCInterface
from .chainparams import Coins
class NMCInterface(BTCInterface):
@staticmethod
def coin_type():
return Coins.NMC
def getLockTxHeight(self, txid, dest_address, bid_amount, rescan_from, find_index=False):
raise ValueError('TODO: Use scantxoutset')

View File

@@ -1,10 +1,11 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2020-2021 tecnovert
# Copyright (c) 2020-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import json
import random
import urllib.parse
from .util import (
@@ -13,12 +14,15 @@ from .util import (
from .basicswap_util import (
strBidState,
SwapTypes,
NotificationTypes as NT,
)
from .chainparams import (
Coins,
chainparams,
)
from .ui import (
from .ui.util import (
PAGE_LIMIT,
getCoinName,
getCoinType,
inputAmount,
describeBid,
@@ -27,7 +31,9 @@ from .ui import (
get_data_entry_or,
have_data_entry,
tickerToCoinId,
listOldBidStates,
)
from .ui.page_offers import postNewOffer
from .protocols.xmr_swap_1 import recoverNoScriptTxnWithKey, getChainBSplitKey
@@ -59,7 +65,29 @@ def withdraw_coin(swap_client, coin_type, post_string, is_json):
return {'txid': txid_hex}
def js_coins(self, url_split, post_string, is_json):
swap_client = self.server.swap_client
coins = []
for coin in Coins:
cc = swap_client.coin_clients[coin]
entry = {
'id': int(coin),
'ticker': chainparams[cc['coin']]['ticker'],
'name': getCoinName(coin),
'active': False if cc['connection_type'] == 'none' else True,
}
if coin == Coins.PART_ANON:
entry['variant'] = 'Anon'
elif coin == Coins.PART_BLIND:
entry['variant'] = 'Blind'
coins.append(entry)
return bytes(json.dumps(coins), 'UTF-8')
def js_wallets(self, url_split, post_string, is_json):
swap_client = self.server.swap_client
if len(url_split) > 3:
ticker_str = url_split[3]
coin_type = tickerToCoinId(ticker_str)
@@ -67,13 +95,19 @@ def js_wallets(self, url_split, post_string, is_json):
if len(url_split) > 4:
cmd = url_split[4]
if cmd == 'withdraw':
return bytes(json.dumps(withdraw_coin(self.server.swap_client, coin_type, post_string, is_json)), 'UTF-8')
return bytes(json.dumps(withdraw_coin(swap_client, coin_type, post_string, is_json)), 'UTF-8')
if cmd == 'nextdepositaddr':
return bytes(json.dumps(swap_client.cacheNewAddressForCoin(coin_type)), 'UTF-8')
raise ValueError('Unknown command')
return bytes(json.dumps(self.server.swap_client.getWalletInfo(coin_type)), 'UTF-8')
return bytes(json.dumps(self.server.swap_client.getWalletsInfo()), 'UTF-8')
rv = swap_client.getWalletInfo(coin_type)
rv.update(swap_client.getBlockchainInfo(coin_type))
return bytes(json.dumps(rv), 'UTF-8')
return bytes(json.dumps(self.server.swap_client.getWalletsInfo({'ticker_key': True})), 'UTF-8')
def js_offers(self, url_split, post_string, is_json, sent=False):
swap_client = self.server.swap_client
offer_id = None
if len(url_split) > 3:
if url_split[3] == 'new':
@@ -84,7 +118,7 @@ def js_offers(self, url_split, post_string, is_json, sent=False):
form_data['is_json'] = True
else:
form_data = urllib.parse.parse_qs(post_string)
offer_id = self.postNewOffer(form_data)
offer_id = postNewOffer(swap_client, form_data)
rv = {'offer_id': offer_id.hex()}
return bytes(json.dumps(rv), 'UTF-8')
offer_id = bytes.fromhex(url_split[3])
@@ -112,18 +146,18 @@ def js_offers(self, url_split, post_string, is_json, sent=False):
if have_data_entry(post_data, 'sort_by'):
sort_by = get_data_entry(post_data, 'sort_by')
assert(sort_by in ['created_at', 'rate']), 'Invalid sort by'
assert (sort_by in ['created_at', 'rate']), 'Invalid sort by'
filters['sort_by'] = sort_by
if have_data_entry(post_data, 'sort_dir'):
sort_dir = get_data_entry(post_data, 'sort_dir')
assert(sort_dir in ['asc', 'desc']), 'Invalid sort dir'
assert (sort_dir in ['asc', 'desc']), 'Invalid sort dir'
filters['sort_dir'] = sort_dir
if b'offset' in post_data:
filters['offset'] = int(get_data_entry(post_data, 'offset'))
if b'limit' in post_data:
filters['limit'] = int(get_data_entry(post_data, 'limit'))
assert(filters['limit'] > 0 and filters['limit'] <= PAGE_LIMIT), 'Invalid limit'
assert (filters['limit'] > 0 and filters['limit'] <= PAGE_LIMIT), 'Invalid limit'
offers = self.server.swap_client.listOffers(sent, filters)
rv = []
@@ -163,10 +197,10 @@ def js_bids(self, url_split, post_string, is_json):
post_data = urllib.parse.parse_qs(post_string)
offer_id = bytes.fromhex(get_data_entry(post_data, 'offer_id'))
assert(len(offer_id) == 28)
assert (len(offer_id) == 28)
offer = swap_client.getOffer(offer_id)
assert(offer), 'Offer not found.'
assert (offer), 'Offer not found.'
ci_from = swap_client.ci(offer.coin_from)
ci_to = swap_client.ci(offer.coin_to)
@@ -205,8 +239,9 @@ def js_bids(self, url_split, post_string, is_json):
return bytes(json.dumps(rv), 'UTF-8')
bid_id = bytes.fromhex(url_split[3])
assert(len(bid_id) == 28)
assert (len(bid_id) == 28)
show_txns = False
if post_string != '':
if is_json:
post_data = json.loads(post_string)
@@ -218,8 +253,11 @@ def js_bids(self, url_split, post_string, is_json):
elif have_data_entry(post_data, 'debugind'):
swap_client.setBidDebugInd(bid_id, int(get_data_entry(post_data, 'debugind')))
if have_data_entry(post_data, 'show_extra'):
show_txns = True
bid, xmr_swap, offer, xmr_offer, events = swap_client.getXmrBidAndOffer(bid_id)
assert(bid), 'Unknown bid ID'
assert (bid), 'Unknown bid ID'
if post_string != '':
if have_data_entry(post_data, 'chainbkeysplit'):
@@ -228,8 +266,11 @@ def js_bids(self, url_split, post_string, is_json):
remote_key = get_data_entry(post_data, 'remote_key')
return bytes(json.dumps({'txid': recoverNoScriptTxnWithKey(swap_client, bid_id, remote_key).hex()}), 'UTF-8')
if len(url_split) > 4 and url_split[4] == 'states':
old_states = listOldBidStates(bid)
return bytes(json.dumps(old_states), 'UTF-8')
edit_bid = False
show_txns = False
data = describeBid(swap_client, bid, xmr_swap, offer, xmr_offer, events, edit_bid, show_txns, for_api=True)
return bytes(json.dumps(data), 'UTF-8')
@@ -255,7 +296,7 @@ def js_network(self, url_split, post_string, is_json):
def js_revokeoffer(self, url_split, post_string, is_json):
offer_id = bytes.fromhex(url_split[3])
assert(len(offer_id) == 28)
assert (len(offer_id) == 28)
self.server.swap_client.revokeOffer(offer_id)
return bytes(json.dumps({'revoked_offer': offer_id.hex()}), 'UTF-8')
@@ -304,6 +345,15 @@ def js_rates(self, url_split, post_string, is_json):
return bytes(json.dumps(sc.lookupRates(coin_from, coin_to)), 'UTF-8')
def js_rates_list(self, url_split, query_string, is_json):
get_data = urllib.parse.parse_qs(query_string)
sc = self.server.swap_client
coin_from = getCoinType(get_data['from'][0])
coin_to = getCoinType(get_data['to'][0])
return bytes(json.dumps(sc.lookupRates(coin_from, coin_to, True)), 'UTF-8')
def js_rate(self, url_split, post_string, is_json):
if post_string == '':
raise ValueError('No post data')
@@ -345,3 +395,58 @@ def js_rate(self, url_split, post_string, is_json):
def js_index(self, url_split, post_string, is_json):
return bytes(json.dumps(self.server.swap_client.getSummary()), 'UTF-8')
def js_generatenotification(self, url_split, post_string, is_json):
swap_client = self.server.swap_client
if not swap_client.debug:
raise ValueError('Debug mode not active.')
r = random.randint(0, 3)
if r == 0:
swap_client.notify(NT.OFFER_RECEIVED, {'offer_id': random.randbytes(28).hex()})
elif r == 1:
swap_client.notify(NT.BID_RECEIVED, {'type': 'atomic', 'bid_id': random.randbytes(28).hex(), 'offer_id': random.randbytes(28).hex()})
elif r == 2:
swap_client.notify(NT.BID_ACCEPTED, {'bid_id': random.randbytes(28).hex()})
elif r == 3:
swap_client.notify(NT.BID_RECEIVED, {'type': 'xmr', 'bid_id': random.randbytes(28).hex(), 'offer_id': random.randbytes(28).hex()})
return bytes(json.dumps({'type': r}), 'UTF-8')
def js_notifications(self, url_split, post_string, is_json):
swap_client = self.server.swap_client
swap_client.getNotifications()
return bytes(json.dumps(swap_client.getNotifications()), 'UTF-8')
def js_vacuumdb(self, url_split, post_string, is_json):
swap_client = self.server.swap_client
swap_client.vacuumDB()
return bytes(json.dumps({'completed': True}), 'UTF-8')
def js_url_to_function(url_split):
if len(url_split) > 2:
return {
'coins': js_coins,
'wallets': js_wallets,
'offers': js_offers,
'sentoffers': js_sentoffers,
'bids': js_bids,
'sentbids': js_sentbids,
'network': js_network,
'revokeoffer': js_revokeoffer,
'smsgaddresses': js_smsgaddresses,
'rate': js_rate,
'rates': js_rates,
'rateslist': js_rates_list,
'generatenotification': js_generatenotification,
'notifications': js_notifications,
'vacuumdb': js_vacuumdb,
}.get(url_split[2], js_index)
return js_index

View File

@@ -2,9 +2,9 @@
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: messages.proto
"""Generated protocol buffer code."""
from google.protobuf.internal import builder as _builder
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import reflection as _reflection
from google.protobuf import descriptor_pool as _descriptor_pool
from google.protobuf import symbol_database as _symbol_database
# @@protoc_insertion_point(imports)
@@ -13,872 +13,35 @@ _sym_db = _symbol_database.Default()
DESCRIPTOR = _descriptor.FileDescriptor(
name='messages.proto',
package='basicswap',
syntax='proto3',
serialized_options=None,
create_key=_descriptor._internal_create_key,
serialized_pb=b'\n\x0emessages.proto\x12\tbasicswap\"\xa6\x04\n\x0cOfferMessage\x12\x11\n\tcoin_from\x18\x01 \x01(\r\x12\x0f\n\x07\x63oin_to\x18\x02 \x01(\r\x12\x13\n\x0b\x61mount_from\x18\x03 \x01(\x04\x12\x0c\n\x04rate\x18\x04 \x01(\x04\x12\x16\n\x0emin_bid_amount\x18\x05 \x01(\x04\x12\x12\n\ntime_valid\x18\x06 \x01(\x04\x12\x33\n\tlock_type\x18\x07 \x01(\x0e\x32 .basicswap.OfferMessage.LockType\x12\x12\n\nlock_value\x18\x08 \x01(\r\x12\x11\n\tswap_type\x18\t \x01(\r\x12\x15\n\rproof_address\x18\n \x01(\t\x12\x17\n\x0fproof_signature\x18\x0b \x01(\t\x12\x15\n\rpkhash_seller\x18\x0c \x01(\x0c\x12\x13\n\x0bsecret_hash\x18\r \x01(\x0c\x12\x15\n\rfee_rate_from\x18\x0e \x01(\x04\x12\x13\n\x0b\x66\x65\x65_rate_to\x18\x0f \x01(\x04\x12\x18\n\x10protocol_version\x18\x10 \x01(\r\x12\x19\n\x11\x61mount_negotiable\x18\x11 \x01(\x08\x12\x17\n\x0frate_negotiable\x18\x12 \x01(\x08\"q\n\x08LockType\x12\x0b\n\x07NOT_SET\x10\x00\x12\x18\n\x14SEQUENCE_LOCK_BLOCKS\x10\x01\x12\x16\n\x12SEQUENCE_LOCK_TIME\x10\x02\x12\x13\n\x0f\x41\x42S_LOCK_BLOCKS\x10\x03\x12\x11\n\rABS_LOCK_TIME\x10\x04\"\xb4\x01\n\nBidMessage\x12\x14\n\x0coffer_msg_id\x18\x01 \x01(\x0c\x12\x12\n\ntime_valid\x18\x02 \x01(\x04\x12\x0e\n\x06\x61mount\x18\x03 \x01(\x04\x12\x0c\n\x04rate\x18\x04 \x01(\x04\x12\x14\n\x0cpkhash_buyer\x18\x05 \x01(\x0c\x12\x15\n\rproof_address\x18\x06 \x01(\t\x12\x17\n\x0fproof_signature\x18\x07 \x01(\t\x12\x18\n\x10protocol_version\x18\x08 \x01(\r\"V\n\x10\x42idAcceptMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x15\n\rinitiate_txid\x18\x02 \x01(\x0c\x12\x17\n\x0f\x63ontract_script\x18\x03 \x01(\x0c\"=\n\x12OfferRevokeMessage\x12\x14\n\x0coffer_msg_id\x18\x01 \x01(\x0c\x12\x11\n\tsignature\x18\x02 \x01(\x0c\";\n\x10\x42idRejectMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x13\n\x0breject_code\x18\x02 \x01(\r\"\xb2\x01\n\rXmrBidMessage\x12\x14\n\x0coffer_msg_id\x18\x01 \x01(\x0c\x12\x12\n\ntime_valid\x18\x02 \x01(\x04\x12\x0e\n\x06\x61mount\x18\x03 \x01(\x04\x12\x0c\n\x04rate\x18\x04 \x01(\x04\x12\x0c\n\x04pkaf\x18\x05 \x01(\x0c\x12\x0c\n\x04kbvf\x18\x06 \x01(\x0c\x12\x12\n\nkbsf_dleag\x18\x07 \x01(\x0c\x12\x0f\n\x07\x64\x65st_af\x18\x08 \x01(\x0c\x12\x18\n\x10protocol_version\x18\t \x01(\r\"T\n\x0fXmrSplitMessage\x12\x0e\n\x06msg_id\x18\x01 \x01(\x0c\x12\x10\n\x08msg_type\x18\x02 \x01(\r\x12\x10\n\x08sequence\x18\x03 \x01(\r\x12\r\n\x05\x64leag\x18\x04 \x01(\x0c\"\x80\x02\n\x13XmrBidAcceptMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x0c\n\x04pkal\x18\x03 \x01(\x0c\x12\x0c\n\x04kbvl\x18\x04 \x01(\x0c\x12\x12\n\nkbsl_dleag\x18\x05 \x01(\x0c\x12\x11\n\ta_lock_tx\x18\x06 \x01(\x0c\x12\x18\n\x10\x61_lock_tx_script\x18\x07 \x01(\x0c\x12\x18\n\x10\x61_lock_refund_tx\x18\x08 \x01(\x0c\x12\x1f\n\x17\x61_lock_refund_tx_script\x18\t \x01(\x0c\x12\x1e\n\x16\x61_lock_refund_spend_tx\x18\n \x01(\x0c\x12\x1d\n\x15\x61l_lock_refund_tx_sig\x18\x0b \x01(\x0c\"r\n\x17XmrBidLockTxSigsMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12$\n\x1c\x61\x66_lock_refund_spend_tx_esig\x18\x02 \x01(\x0c\x12\x1d\n\x15\x61\x66_lock_refund_tx_sig\x18\x03 \x01(\x0c\"X\n\x18XmrBidLockSpendTxMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x17\n\x0f\x61_lock_spend_tx\x18\x02 \x01(\x0c\x12\x0f\n\x07kal_sig\x18\x03 \x01(\x0c\"M\n\x18XmrBidLockReleaseMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x1d\n\x15\x61l_lock_spend_tx_esig\x18\x02 \x01(\x0c\x62\x06proto3'
)
_OFFERMESSAGE_LOCKTYPE = _descriptor.EnumDescriptor(
name='LockType',
full_name='basicswap.OfferMessage.LockType',
filename=None,
file=DESCRIPTOR,
create_key=_descriptor._internal_create_key,
values=[
_descriptor.EnumValueDescriptor(
name='NOT_SET', index=0, number=0,
serialized_options=None,
type=None,
create_key=_descriptor._internal_create_key),
_descriptor.EnumValueDescriptor(
name='SEQUENCE_LOCK_BLOCKS', index=1, number=1,
serialized_options=None,
type=None,
create_key=_descriptor._internal_create_key),
_descriptor.EnumValueDescriptor(
name='SEQUENCE_LOCK_TIME', index=2, number=2,
serialized_options=None,
type=None,
create_key=_descriptor._internal_create_key),
_descriptor.EnumValueDescriptor(
name='ABS_LOCK_BLOCKS', index=3, number=3,
serialized_options=None,
type=None,
create_key=_descriptor._internal_create_key),
_descriptor.EnumValueDescriptor(
name='ABS_LOCK_TIME', index=4, number=4,
serialized_options=None,
type=None,
create_key=_descriptor._internal_create_key),
],
containing_type=None,
serialized_options=None,
serialized_start=467,
serialized_end=580,
)
_sym_db.RegisterEnumDescriptor(_OFFERMESSAGE_LOCKTYPE)
_OFFERMESSAGE = _descriptor.Descriptor(
name='OfferMessage',
full_name='basicswap.OfferMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='coin_from', full_name='basicswap.OfferMessage.coin_from', index=0,
number=1, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='coin_to', full_name='basicswap.OfferMessage.coin_to', index=1,
number=2, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='amount_from', full_name='basicswap.OfferMessage.amount_from', index=2,
number=3, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='rate', full_name='basicswap.OfferMessage.rate', index=3,
number=4, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='min_bid_amount', full_name='basicswap.OfferMessage.min_bid_amount', index=4,
number=5, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='time_valid', full_name='basicswap.OfferMessage.time_valid', index=5,
number=6, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='lock_type', full_name='basicswap.OfferMessage.lock_type', index=6,
number=7, type=14, cpp_type=8, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='lock_value', full_name='basicswap.OfferMessage.lock_value', index=7,
number=8, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='swap_type', full_name='basicswap.OfferMessage.swap_type', index=8,
number=9, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='proof_address', full_name='basicswap.OfferMessage.proof_address', index=9,
number=10, type=9, cpp_type=9, label=1,
has_default_value=False, default_value=b"".decode('utf-8'),
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='proof_signature', full_name='basicswap.OfferMessage.proof_signature', index=10,
number=11, type=9, cpp_type=9, label=1,
has_default_value=False, default_value=b"".decode('utf-8'),
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='pkhash_seller', full_name='basicswap.OfferMessage.pkhash_seller', index=11,
number=12, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='secret_hash', full_name='basicswap.OfferMessage.secret_hash', index=12,
number=13, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='fee_rate_from', full_name='basicswap.OfferMessage.fee_rate_from', index=13,
number=14, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='fee_rate_to', full_name='basicswap.OfferMessage.fee_rate_to', index=14,
number=15, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='protocol_version', full_name='basicswap.OfferMessage.protocol_version', index=15,
number=16, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='amount_negotiable', full_name='basicswap.OfferMessage.amount_negotiable', index=16,
number=17, type=8, cpp_type=7, label=1,
has_default_value=False, default_value=False,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='rate_negotiable', full_name='basicswap.OfferMessage.rate_negotiable', index=17,
number=18, type=8, cpp_type=7, label=1,
has_default_value=False, default_value=False,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
_OFFERMESSAGE_LOCKTYPE,
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=30,
serialized_end=580,
)
_BIDMESSAGE = _descriptor.Descriptor(
name='BidMessage',
full_name='basicswap.BidMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='offer_msg_id', full_name='basicswap.BidMessage.offer_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='time_valid', full_name='basicswap.BidMessage.time_valid', index=1,
number=2, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='amount', full_name='basicswap.BidMessage.amount', index=2,
number=3, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='rate', full_name='basicswap.BidMessage.rate', index=3,
number=4, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='pkhash_buyer', full_name='basicswap.BidMessage.pkhash_buyer', index=4,
number=5, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='proof_address', full_name='basicswap.BidMessage.proof_address', index=5,
number=6, type=9, cpp_type=9, label=1,
has_default_value=False, default_value=b"".decode('utf-8'),
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='proof_signature', full_name='basicswap.BidMessage.proof_signature', index=6,
number=7, type=9, cpp_type=9, label=1,
has_default_value=False, default_value=b"".decode('utf-8'),
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='protocol_version', full_name='basicswap.BidMessage.protocol_version', index=7,
number=8, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=583,
serialized_end=763,
)
_BIDACCEPTMESSAGE = _descriptor.Descriptor(
name='BidAcceptMessage',
full_name='basicswap.BidAcceptMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='bid_msg_id', full_name='basicswap.BidAcceptMessage.bid_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='initiate_txid', full_name='basicswap.BidAcceptMessage.initiate_txid', index=1,
number=2, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='contract_script', full_name='basicswap.BidAcceptMessage.contract_script', index=2,
number=3, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=765,
serialized_end=851,
)
_OFFERREVOKEMESSAGE = _descriptor.Descriptor(
name='OfferRevokeMessage',
full_name='basicswap.OfferRevokeMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='offer_msg_id', full_name='basicswap.OfferRevokeMessage.offer_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='signature', full_name='basicswap.OfferRevokeMessage.signature', index=1,
number=2, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=853,
serialized_end=914,
)
_BIDREJECTMESSAGE = _descriptor.Descriptor(
name='BidRejectMessage',
full_name='basicswap.BidRejectMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='bid_msg_id', full_name='basicswap.BidRejectMessage.bid_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='reject_code', full_name='basicswap.BidRejectMessage.reject_code', index=1,
number=2, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=916,
serialized_end=975,
)
_XMRBIDMESSAGE = _descriptor.Descriptor(
name='XmrBidMessage',
full_name='basicswap.XmrBidMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='offer_msg_id', full_name='basicswap.XmrBidMessage.offer_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='time_valid', full_name='basicswap.XmrBidMessage.time_valid', index=1,
number=2, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='amount', full_name='basicswap.XmrBidMessage.amount', index=2,
number=3, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='rate', full_name='basicswap.XmrBidMessage.rate', index=3,
number=4, type=4, cpp_type=4, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='pkaf', full_name='basicswap.XmrBidMessage.pkaf', index=4,
number=5, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='kbvf', full_name='basicswap.XmrBidMessage.kbvf', index=5,
number=6, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='kbsf_dleag', full_name='basicswap.XmrBidMessage.kbsf_dleag', index=6,
number=7, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='dest_af', full_name='basicswap.XmrBidMessage.dest_af', index=7,
number=8, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='protocol_version', full_name='basicswap.XmrBidMessage.protocol_version', index=8,
number=9, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=978,
serialized_end=1156,
)
_XMRSPLITMESSAGE = _descriptor.Descriptor(
name='XmrSplitMessage',
full_name='basicswap.XmrSplitMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='msg_id', full_name='basicswap.XmrSplitMessage.msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='msg_type', full_name='basicswap.XmrSplitMessage.msg_type', index=1,
number=2, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='sequence', full_name='basicswap.XmrSplitMessage.sequence', index=2,
number=3, type=13, cpp_type=3, label=1,
has_default_value=False, default_value=0,
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='dleag', full_name='basicswap.XmrSplitMessage.dleag', index=3,
number=4, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=1158,
serialized_end=1242,
)
_XMRBIDACCEPTMESSAGE = _descriptor.Descriptor(
name='XmrBidAcceptMessage',
full_name='basicswap.XmrBidAcceptMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='bid_msg_id', full_name='basicswap.XmrBidAcceptMessage.bid_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='pkal', full_name='basicswap.XmrBidAcceptMessage.pkal', index=1,
number=3, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='kbvl', full_name='basicswap.XmrBidAcceptMessage.kbvl', index=2,
number=4, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='kbsl_dleag', full_name='basicswap.XmrBidAcceptMessage.kbsl_dleag', index=3,
number=5, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='a_lock_tx', full_name='basicswap.XmrBidAcceptMessage.a_lock_tx', index=4,
number=6, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='a_lock_tx_script', full_name='basicswap.XmrBidAcceptMessage.a_lock_tx_script', index=5,
number=7, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='a_lock_refund_tx', full_name='basicswap.XmrBidAcceptMessage.a_lock_refund_tx', index=6,
number=8, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='a_lock_refund_tx_script', full_name='basicswap.XmrBidAcceptMessage.a_lock_refund_tx_script', index=7,
number=9, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='a_lock_refund_spend_tx', full_name='basicswap.XmrBidAcceptMessage.a_lock_refund_spend_tx', index=8,
number=10, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='al_lock_refund_tx_sig', full_name='basicswap.XmrBidAcceptMessage.al_lock_refund_tx_sig', index=9,
number=11, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=1245,
serialized_end=1501,
)
_XMRBIDLOCKTXSIGSMESSAGE = _descriptor.Descriptor(
name='XmrBidLockTxSigsMessage',
full_name='basicswap.XmrBidLockTxSigsMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='bid_msg_id', full_name='basicswap.XmrBidLockTxSigsMessage.bid_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='af_lock_refund_spend_tx_esig', full_name='basicswap.XmrBidLockTxSigsMessage.af_lock_refund_spend_tx_esig', index=1,
number=2, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='af_lock_refund_tx_sig', full_name='basicswap.XmrBidLockTxSigsMessage.af_lock_refund_tx_sig', index=2,
number=3, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=1503,
serialized_end=1617,
)
_XMRBIDLOCKSPENDTXMESSAGE = _descriptor.Descriptor(
name='XmrBidLockSpendTxMessage',
full_name='basicswap.XmrBidLockSpendTxMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='bid_msg_id', full_name='basicswap.XmrBidLockSpendTxMessage.bid_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='a_lock_spend_tx', full_name='basicswap.XmrBidLockSpendTxMessage.a_lock_spend_tx', index=1,
number=2, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='kal_sig', full_name='basicswap.XmrBidLockSpendTxMessage.kal_sig', index=2,
number=3, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=1619,
serialized_end=1707,
)
_XMRBIDLOCKRELEASEMESSAGE = _descriptor.Descriptor(
name='XmrBidLockReleaseMessage',
full_name='basicswap.XmrBidLockReleaseMessage',
filename=None,
file=DESCRIPTOR,
containing_type=None,
create_key=_descriptor._internal_create_key,
fields=[
_descriptor.FieldDescriptor(
name='bid_msg_id', full_name='basicswap.XmrBidLockReleaseMessage.bid_msg_id', index=0,
number=1, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
_descriptor.FieldDescriptor(
name='al_lock_spend_tx_esig', full_name='basicswap.XmrBidLockReleaseMessage.al_lock_spend_tx_esig', index=1,
number=2, type=12, cpp_type=9, label=1,
has_default_value=False, default_value=b"",
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
],
extensions=[
],
nested_types=[],
enum_types=[
],
serialized_options=None,
is_extendable=False,
syntax='proto3',
extension_ranges=[],
oneofs=[
],
serialized_start=1709,
serialized_end=1786,
)
_OFFERMESSAGE.fields_by_name['lock_type'].enum_type = _OFFERMESSAGE_LOCKTYPE
_OFFERMESSAGE_LOCKTYPE.containing_type = _OFFERMESSAGE
DESCRIPTOR.message_types_by_name['OfferMessage'] = _OFFERMESSAGE
DESCRIPTOR.message_types_by_name['BidMessage'] = _BIDMESSAGE
DESCRIPTOR.message_types_by_name['BidAcceptMessage'] = _BIDACCEPTMESSAGE
DESCRIPTOR.message_types_by_name['OfferRevokeMessage'] = _OFFERREVOKEMESSAGE
DESCRIPTOR.message_types_by_name['BidRejectMessage'] = _BIDREJECTMESSAGE
DESCRIPTOR.message_types_by_name['XmrBidMessage'] = _XMRBIDMESSAGE
DESCRIPTOR.message_types_by_name['XmrSplitMessage'] = _XMRSPLITMESSAGE
DESCRIPTOR.message_types_by_name['XmrBidAcceptMessage'] = _XMRBIDACCEPTMESSAGE
DESCRIPTOR.message_types_by_name['XmrBidLockTxSigsMessage'] = _XMRBIDLOCKTXSIGSMESSAGE
DESCRIPTOR.message_types_by_name['XmrBidLockSpendTxMessage'] = _XMRBIDLOCKSPENDTXMESSAGE
DESCRIPTOR.message_types_by_name['XmrBidLockReleaseMessage'] = _XMRBIDLOCKRELEASEMESSAGE
_sym_db.RegisterFileDescriptor(DESCRIPTOR)
OfferMessage = _reflection.GeneratedProtocolMessageType('OfferMessage', (_message.Message,), {
'DESCRIPTOR' : _OFFERMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.OfferMessage)
})
_sym_db.RegisterMessage(OfferMessage)
BidMessage = _reflection.GeneratedProtocolMessageType('BidMessage', (_message.Message,), {
'DESCRIPTOR' : _BIDMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.BidMessage)
})
_sym_db.RegisterMessage(BidMessage)
BidAcceptMessage = _reflection.GeneratedProtocolMessageType('BidAcceptMessage', (_message.Message,), {
'DESCRIPTOR' : _BIDACCEPTMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.BidAcceptMessage)
})
_sym_db.RegisterMessage(BidAcceptMessage)
OfferRevokeMessage = _reflection.GeneratedProtocolMessageType('OfferRevokeMessage', (_message.Message,), {
'DESCRIPTOR' : _OFFERREVOKEMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.OfferRevokeMessage)
})
_sym_db.RegisterMessage(OfferRevokeMessage)
BidRejectMessage = _reflection.GeneratedProtocolMessageType('BidRejectMessage', (_message.Message,), {
'DESCRIPTOR' : _BIDREJECTMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.BidRejectMessage)
})
_sym_db.RegisterMessage(BidRejectMessage)
XmrBidMessage = _reflection.GeneratedProtocolMessageType('XmrBidMessage', (_message.Message,), {
'DESCRIPTOR' : _XMRBIDMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.XmrBidMessage)
})
_sym_db.RegisterMessage(XmrBidMessage)
XmrSplitMessage = _reflection.GeneratedProtocolMessageType('XmrSplitMessage', (_message.Message,), {
'DESCRIPTOR' : _XMRSPLITMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.XmrSplitMessage)
})
_sym_db.RegisterMessage(XmrSplitMessage)
XmrBidAcceptMessage = _reflection.GeneratedProtocolMessageType('XmrBidAcceptMessage', (_message.Message,), {
'DESCRIPTOR' : _XMRBIDACCEPTMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.XmrBidAcceptMessage)
})
_sym_db.RegisterMessage(XmrBidAcceptMessage)
XmrBidLockTxSigsMessage = _reflection.GeneratedProtocolMessageType('XmrBidLockTxSigsMessage', (_message.Message,), {
'DESCRIPTOR' : _XMRBIDLOCKTXSIGSMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.XmrBidLockTxSigsMessage)
})
_sym_db.RegisterMessage(XmrBidLockTxSigsMessage)
XmrBidLockSpendTxMessage = _reflection.GeneratedProtocolMessageType('XmrBidLockSpendTxMessage', (_message.Message,), {
'DESCRIPTOR' : _XMRBIDLOCKSPENDTXMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.XmrBidLockSpendTxMessage)
})
_sym_db.RegisterMessage(XmrBidLockSpendTxMessage)
XmrBidLockReleaseMessage = _reflection.GeneratedProtocolMessageType('XmrBidLockReleaseMessage', (_message.Message,), {
'DESCRIPTOR' : _XMRBIDLOCKRELEASEMESSAGE,
'__module__' : 'messages_pb2'
# @@protoc_insertion_point(class_scope:basicswap.XmrBidLockReleaseMessage)
})
_sym_db.RegisterMessage(XmrBidLockReleaseMessage)
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x0emessages.proto\x12\tbasicswap\"\xa6\x04\n\x0cOfferMessage\x12\x11\n\tcoin_from\x18\x01 \x01(\r\x12\x0f\n\x07\x63oin_to\x18\x02 \x01(\r\x12\x13\n\x0b\x61mount_from\x18\x03 \x01(\x04\x12\x0c\n\x04rate\x18\x04 \x01(\x04\x12\x16\n\x0emin_bid_amount\x18\x05 \x01(\x04\x12\x12\n\ntime_valid\x18\x06 \x01(\x04\x12\x33\n\tlock_type\x18\x07 \x01(\x0e\x32 .basicswap.OfferMessage.LockType\x12\x12\n\nlock_value\x18\x08 \x01(\r\x12\x11\n\tswap_type\x18\t \x01(\r\x12\x15\n\rproof_address\x18\n \x01(\t\x12\x17\n\x0fproof_signature\x18\x0b \x01(\t\x12\x15\n\rpkhash_seller\x18\x0c \x01(\x0c\x12\x13\n\x0bsecret_hash\x18\r \x01(\x0c\x12\x15\n\rfee_rate_from\x18\x0e \x01(\x04\x12\x13\n\x0b\x66\x65\x65_rate_to\x18\x0f \x01(\x04\x12\x18\n\x10protocol_version\x18\x10 \x01(\r\x12\x19\n\x11\x61mount_negotiable\x18\x11 \x01(\x08\x12\x17\n\x0frate_negotiable\x18\x12 \x01(\x08\"q\n\x08LockType\x12\x0b\n\x07NOT_SET\x10\x00\x12\x18\n\x14SEQUENCE_LOCK_BLOCKS\x10\x01\x12\x16\n\x12SEQUENCE_LOCK_TIME\x10\x02\x12\x13\n\x0f\x41\x42S_LOCK_BLOCKS\x10\x03\x12\x11\n\rABS_LOCK_TIME\x10\x04\"\xb4\x01\n\nBidMessage\x12\x14\n\x0coffer_msg_id\x18\x01 \x01(\x0c\x12\x12\n\ntime_valid\x18\x02 \x01(\x04\x12\x0e\n\x06\x61mount\x18\x03 \x01(\x04\x12\x0c\n\x04rate\x18\x04 \x01(\x04\x12\x14\n\x0cpkhash_buyer\x18\x05 \x01(\x0c\x12\x15\n\rproof_address\x18\x06 \x01(\t\x12\x17\n\x0fproof_signature\x18\x07 \x01(\t\x12\x18\n\x10protocol_version\x18\x08 \x01(\r\"V\n\x10\x42idAcceptMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x15\n\rinitiate_txid\x18\x02 \x01(\x0c\x12\x17\n\x0f\x63ontract_script\x18\x03 \x01(\x0c\"=\n\x12OfferRevokeMessage\x12\x14\n\x0coffer_msg_id\x18\x01 \x01(\x0c\x12\x11\n\tsignature\x18\x02 \x01(\x0c\";\n\x10\x42idRejectMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x13\n\x0breject_code\x18\x02 \x01(\r\"\xb2\x01\n\rXmrBidMessage\x12\x14\n\x0coffer_msg_id\x18\x01 \x01(\x0c\x12\x12\n\ntime_valid\x18\x02 \x01(\x04\x12\x0e\n\x06\x61mount\x18\x03 \x01(\x04\x12\x0c\n\x04rate\x18\x04 \x01(\x04\x12\x0c\n\x04pkaf\x18\x05 \x01(\x0c\x12\x0c\n\x04kbvf\x18\x06 \x01(\x0c\x12\x12\n\nkbsf_dleag\x18\x07 \x01(\x0c\x12\x0f\n\x07\x64\x65st_af\x18\x08 \x01(\x0c\x12\x18\n\x10protocol_version\x18\t \x01(\r\"T\n\x0fXmrSplitMessage\x12\x0e\n\x06msg_id\x18\x01 \x01(\x0c\x12\x10\n\x08msg_type\x18\x02 \x01(\r\x12\x10\n\x08sequence\x18\x03 \x01(\r\x12\r\n\x05\x64leag\x18\x04 \x01(\x0c\"\x80\x02\n\x13XmrBidAcceptMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x0c\n\x04pkal\x18\x03 \x01(\x0c\x12\x0c\n\x04kbvl\x18\x04 \x01(\x0c\x12\x12\n\nkbsl_dleag\x18\x05 \x01(\x0c\x12\x11\n\ta_lock_tx\x18\x06 \x01(\x0c\x12\x18\n\x10\x61_lock_tx_script\x18\x07 \x01(\x0c\x12\x18\n\x10\x61_lock_refund_tx\x18\x08 \x01(\x0c\x12\x1f\n\x17\x61_lock_refund_tx_script\x18\t \x01(\x0c\x12\x1e\n\x16\x61_lock_refund_spend_tx\x18\n \x01(\x0c\x12\x1d\n\x15\x61l_lock_refund_tx_sig\x18\x0b \x01(\x0c\"r\n\x17XmrBidLockTxSigsMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12$\n\x1c\x61\x66_lock_refund_spend_tx_esig\x18\x02 \x01(\x0c\x12\x1d\n\x15\x61\x66_lock_refund_tx_sig\x18\x03 \x01(\x0c\"X\n\x18XmrBidLockSpendTxMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x17\n\x0f\x61_lock_spend_tx\x18\x02 \x01(\x0c\x12\x0f\n\x07kal_sig\x18\x03 \x01(\x0c\"M\n\x18XmrBidLockReleaseMessage\x12\x12\n\nbid_msg_id\x18\x01 \x01(\x0c\x12\x1d\n\x15\x61l_lock_spend_tx_esig\x18\x02 \x01(\x0c\x62\x06proto3')
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, globals())
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'messages_pb2', globals())
if _descriptor._USE_C_DESCRIPTORS == False:
DESCRIPTOR._options = None
_OFFERMESSAGE._serialized_start=30
_OFFERMESSAGE._serialized_end=580
_OFFERMESSAGE_LOCKTYPE._serialized_start=467
_OFFERMESSAGE_LOCKTYPE._serialized_end=580
_BIDMESSAGE._serialized_start=583
_BIDMESSAGE._serialized_end=763
_BIDACCEPTMESSAGE._serialized_start=765
_BIDACCEPTMESSAGE._serialized_end=851
_OFFERREVOKEMESSAGE._serialized_start=853
_OFFERREVOKEMESSAGE._serialized_end=914
_BIDREJECTMESSAGE._serialized_start=916
_BIDREJECTMESSAGE._serialized_end=975
_XMRBIDMESSAGE._serialized_start=978
_XMRBIDMESSAGE._serialized_end=1156
_XMRSPLITMESSAGE._serialized_start=1158
_XMRSPLITMESSAGE._serialized_end=1242
_XMRBIDACCEPTMESSAGE._serialized_start=1245
_XMRBIDACCEPTMESSAGE._serialized_end=1501
_XMRBIDLOCKTXSIGSMESSAGE._serialized_start=1503
_XMRBIDLOCKTXSIGSMESSAGE._serialized_end=1617
_XMRBIDLOCKSPENDTXMESSAGE._serialized_start=1619
_XMRBIDLOCKSPENDTXMESSAGE._serialized_end=1707
_XMRBIDLOCKRELEASEMESSAGE._serialized_start=1709
_XMRBIDLOCKRELEASEMESSAGE._serialized_end=1786
# @@protoc_insertion_point(module_scope)

View File

@@ -1,18 +1,24 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2020 tecnovert
# Copyright (c) 2020-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from basicswap.db import (
Concepts,
)
from basicswap.util import (
SerialiseNum,
)
from basicswap.script import (
OpCodes,
)
from basicswap.basicswap_util import (
EventLogTypes,
)
INITIATE_TX_TIMEOUT = 40 * 60 # TODO: make variable per coin
ABS_LOCK_TIME_LEEWAY = 10 * 60
def buildContractScript(lock_val, secret_hash, pkh_redeem, pkh_refund, op_lock=OpCodes.OP_CHECKSEQUENCEVERIFY):
@@ -48,3 +54,15 @@ def buildContractScript(lock_val, secret_hash, pkh_redeem, pkh_refund, op_lock=O
def extractScriptSecretHash(script):
return script[7:39]
def redeemITx(self, bid_id, session):
bid, offer = self.getBidAndOffer(bid_id, session)
ci_from = self.ci(offer.coin_from)
txn = self.createRedeemTxn(ci_from.coin_type(), bid, for_txn_type='initiate')
txid = ci_from.publishTx(bytes.fromhex(txn))
bid.initiate_tx.spend_txid = bytes.fromhex(txid)
self.log.debug('Submitted initiate redeem txn %s to %s chain for bid %s', txid, ci_from.coin_name(), bid_id.hex())
self.logEvent(Concepts.BID, bid_id, EventLogTypes.ITX_REDEEM_PUBLISHED, '', session)

View File

@@ -46,12 +46,18 @@ def recoverNoScriptTxnWithKey(self, bid_id, encoded_key):
ci_to = self.ci(offer.coin_to)
for_ed25519 = True if Coins(offer.coin_to) == Coins.XMR else False
try:
decoded_key_half = ci_to.decodeKey(encoded_key)
except Exception as e:
raise ValueError('Failed to decode provided key-half: ', str(e))
if bid.was_sent:
kbsl = ci_to.decodeKey(encoded_key)
kbsl = decoded_key_half
kbsf = self.getPathKey(offer.coin_from, offer.coin_to, bid.created_at, xmr_swap.contract_count, KeyTypes.KBSF, for_ed25519)
else:
kbsl = self.getPathKey(offer.coin_from, offer.coin_to, bid.created_at, xmr_swap.contract_count, KeyTypes.KBSL, for_ed25519)
kbsf = ci_to.decodeKey(encoded_key)
kbsf = decoded_key_half
ensure(ci_to.verifyKey(kbsl), 'Invalid kbsl')
ensure(ci_to.verifyKey(kbsf), 'Invalid kbsf')
vkbs = ci_to.sumKeys(kbsl, kbsf)

View File

@@ -1,12 +1,13 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2020 tecnovert
# Copyright (c) 2020-2022 tecnovert
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
import os
import time
import json
import shlex
import urllib
import logging
import traceback
@@ -19,10 +20,13 @@ from xmlrpc.client import (
from .util import jsonDecimal
def waitForRPC(rpc_func, wallet=None, max_tries=7):
def waitForRPC(rpc_func, expect_wallet=True, max_tries=7):
for i in range(max_tries + 1):
try:
rpc_func('getwalletinfo')
if expect_wallet:
rpc_func('getwalletinfo')
else:
rpc_func('getblockchaininfo')
return
except Exception as ex:
if i < max_tries:
@@ -129,8 +133,13 @@ def openrpc(rpc_port, auth, wallet=None, host='127.0.0.1'):
def callrpc_cli(bindir, datadir, chain, cmd, cli_bin='particl-cli'):
cli_bin = os.path.join(bindir, cli_bin)
args = cli_bin + ('' if chain == 'mainnet' else (' -' + chain)) + ' -datadir=' + datadir + ' ' + cmd
p = subprocess.Popen(args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)
args = [cli_bin, ]
if chain != 'mainnet':
args.append('-' + chain)
args.append('-datadir=' + datadir)
args += shlex.split(cmd)
p = subprocess.Popen(args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
out = p.communicate()
if len(out[1]) > 0:

179
basicswap/static/css/libs/dd.min.css vendored Normal file
View File

@@ -0,0 +1,179 @@
/*! *
/** * * MSDropdown - dd.js * * @author: Marghoob Suleman * * @website: https://www.marghoobsuleman.com/ * * @version: 4.0.2 * * @date: Wed Oct 13 2021 15:19:38 GMT+0530 (India Standard Time) * * msDropdown is free web component: you can redistribute it and/or modify * * it under the terms of the either the MIT License or the Gnu General Public License (GPL) Version 2 * * / */
/*! */
.ms-pr {
position: relative;
border-width: 1px;
border-color: #fff
}
.blaat:active {
border-radius: 0.5rem;
border-width: 1px;
border-color: #3b82f6;
outline: none !important
}
.blaat:focus {
border-radius: 0.5rem;
border-width: 1px;
border-color: #3b82f6;
outline: none !important
}
.ms-dd {
border-radius: 0.5rem;
border-width: 1px;
border-color: #d1d5db;
background: none
}
.ms-list-option:active {
border-radius: 0.5rem;
border-width: 1px;
border-color: #3b82f6;
outline: none !important
}
.ms-dd .ms-value-input {
left: 20px;
position: absolute;
top: 10px;
width: 50%
}
.ms-dd .ms-dd-header {
c cursor: pointer;
min-height: 35px;
position: relative;
width: 100%;
}
.ms-dd .ms-dd-header .option-selected {
color: #333f51;
display: block;
overflow: hidden;
padding: 9px 19px 9px 9px;
pointer-events: none;
border-radius: 0.5rem;
border-width: 1px;
border-color: #f9fafb;
background: none
}
.ms-dd .ms-dd-header .ms-list-counter, .ms-dd .ms-dd-header input[type=checkbox] {
display: none
}
.ms-dd .ms-dd-header .ms-header-counter {
color: #0e76a8
}
.ms-dd .ms-dd-header .ms-filter-box {
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
padding: 6px 10px;
min-height: 44px
}
.ms-dd .ms-dd-option-image, .ms-dd .ms-dd-selected-img {
margin-right: 5px;
max-width: 40px;
vertical-align: middle
}
.ms-dd .ms-dd-arrow {
height: 0;
margin-top: -3px;
position: absolute;
right: 10px;
top: 50%;
width: 0
}
.ms-dd .ms-dd-arrow.ms-dd-pointer-down {
display: none
}
.ms-dd .ms-dd-arrow.ms-dd-pointer-up {
display: none
}
.ms-dd .ms-options {
background: #fff;
border: 1px solid #767676;
box-shadow: 0 1px 5px #ddd;
display: none;
list-style: none;
margin: 0;
overflow: auto;
padding: 0;
position: absolute;
width: 100%;
z-index: 9999
}
.ms-dd .ms-list-option, .ms-dd .ms-optgroup ul .ms-list-option {
align-items: center;
color: #333;
cursor: pointer;
display: flex;
justify-content: flex-start;
overflow: hidden;
padding: 10px;
position: relative;
text-decoration: none
}
.ms-dd .ms-list-option input[type=checkbox], .ms-dd .ms-optgroup ul .ms-list-option input[type=checkbox] {
margin-right: 5px;
vertical-align: middle
}
.ms-dd .ms-list-option:last-child, .ms-dd .ms-optgroup ul .ms-list-option:last-child {
border-bottom: none
}
.ms-dd .ms-list-option:hover, .ms-dd .ms-optgroup ul .ms-list-option:hover {
background: #e0e0e6;
color: #000
}
.ms-dd .ms-list-option.option-selected, .ms-dd .ms-optgroup ul .ms-list-option.option-selected {
background: #f9fafb
}
.ms-dd .ms-list-option.ico-align-right .ms-dd-option-image, .ms-dd .ms-list-option.ico-align-right .ms-dd-selected-img, .ms-dd .ms-optgroup ul .ms-list-option.ico-align-right .ms-dd-option-image, .ms-dd .ms-optgroup ul .ms-list-option.ico-align-right .ms-dd-selected-img {
order: 2
}
.ms-dd .ms-list-option.disabled, .ms-dd .ms-list-option:disabled, .ms-dd .ms-optgroup ul .ms-list-option.disabled, .ms-dd .ms-optgroup ul .ms-list-option:disabled {
cursor: default;
opacity: .4
}
.ms-dd .ms-list-option .ms-dd-desc, .ms-dd .ms-optgroup ul .ms-list-option .ms-dd-desc {
color: #aaa;
display: block;
line-height: 1.5em;
overflow: hidden;
text-shadow: 0 1px .5px #fff
}
.ms-dd .ms-header-middle-content, .ms-dd .ms-middle {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
font-size: 0.875rem;
min-width: 100px
}
.ms-dd.disabled, .ms-dd:disabled {
cursor: default;
opacity: .4;
pointer-events: none
}
.ms-dd .ms-optgroup-padding {
padding: 10px 10px 0
}
.ms-dd .ms-optgroup {
display: block
}
.ms-dd .ms-optgroup:hover {
background: #fff;
color: #000
}
.ms-dd .ms-optgroup ul {
margin: 0;
padding: 0
}
.ms-dd .ms-optgroup ul .ms-list-option {
padding-left: 20px
}
.ms-dd .ms-optgroup ul:last-child {
}
.ms-dd .ms-dd-option-content {
width: 100%
}
.ms-value-input {
display:none;
}

416019
basicswap/static/css/libs/tailwind.min.css vendored Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,34 @@
.padded_row td
{
padding-top:1.5em;
}
.bold
{
font-weight:bold;
}
.monospace
{
font-family:monospace;
}
.floatright
{
position: fixed;
top: 2em;
right: 2em;
margin: 0;
z-index: 50;
}
.error
{
border: 1px solid red;
}
.error_msg
{
color:red;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

View File

@@ -0,0 +1,25 @@
<svg width="289" height="289" viewBox="0 0 289 289" fill="none" xmlns="http://www.w3.org/2000/svg">
<mask id="mask0_1384_22144" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="289" height="289">
<circle cx="144.5" cy="144.5" r="142.507" fill="#C4C4C4" stroke="#F8BB54" stroke-width="3.98621"/>
</mask>
<g mask="url(#mask0_1384_22144)">
<path d="M-83.9766 60.6005C-83.9766 60.6005 -16.689 48.136 0.672082 4.51091C17.2756 -37.3086 85.6704 -48.5495 85.6704 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 81.5681C-83.9766 81.5681 -1.42521 67.182 19.8389 14.529C40.1127 -35.736 123.946 -48.5495 123.946 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 102.595C-83.9766 102.595 13.7801 86.2279 38.9475 24.6636C62.9497 -34.2214 162.221 -48.5495 162.221 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 123.563C-83.9766 123.563 29.0437 105.274 58.1143 34.6817C85.7869 -32.6488 200.497 -48.5495 200.497 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 144.531C-83.9766 144.531 44.3072 124.32 77.2812 44.7578C108.624 -31.0762 238.714 -48.5495 238.714 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 165.557C-83.9766 165.557 59.5125 143.424 96.3898 54.8339C131.519 -29.562 276.989 -48.5495 276.989 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 186.525C-83.9766 186.525 74.7761 162.411 115.557 64.9105C154.356 -27.9894 315.265 -48.5495 315.265 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 207.493C-83.9766 207.493 90.0398 181.457 134.665 74.9286C177.193 -26.4168 353.54 -48.5495 353.54 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 228.519C-83.9766 228.519 105.245 200.562 153.832 85.0628C200.031 -24.9026 391.758 -48.5495 391.758 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 249.485C-83.9766 249.485 120.509 219.608 172.941 95.1393C222.868 -23.33 430.033 -48.5495 430.033 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 270.512C-83.9766 270.512 135.772 238.653 192.108 105.215C245.705 -21.7574 468.308 -48.5495 468.308 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 291.482C-83.9766 291.482 150.977 257.7 211.216 115.292C268.542 -20.2428 506.583 -48.5495 506.583 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 312.447C-83.9766 312.447 166.241 276.746 230.383 125.31C291.379 -18.6701 544.858 -48.5495 544.858 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 333.473C-83.9766 333.473 181.505 295.792 249.55 135.444C314.216 -17.0975 583.076 -48.5495 583.076 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 354.443C-83.9766 354.443 196.71 314.837 268.658 145.462C337.053 -15.5833 621.352 -48.5495 621.352 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 375.413C-83.9766 375.413 211.974 333.883 287.825 155.538C359.89 -14.0107 659.627 -48.5495 659.627 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 396.439C-83.9766 396.439 227.237 352.986 306.934 165.615C382.727 -12.4381 697.902 -48.5495 697.902 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
<path d="M-83.9766 417.405C-83.9766 417.405 242.442 371.975 326.101 175.691C405.565 -10.9239 736.121 -48.5495 736.121 -48.5495" stroke="#A855F7" stroke-width="4.48062" stroke-miterlimit="10"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@@ -0,0 +1,84 @@
<svg width="149" height="199" viewBox="0 0 149 199" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_1384_22237)">
<path d="M146.249 198.91C147.707 198.91 148.889 197.728 148.889 196.27C148.889 194.812 147.707 193.63 146.249 193.63C144.791 193.63 143.609 194.812 143.609 196.27C143.609 197.728 144.791 198.91 146.249 198.91Z" fill="#3B82F6"/>
<path d="M122.31 198.91C123.768 198.91 124.95 197.728 124.95 196.27C124.95 194.812 123.768 193.63 122.31 193.63C120.852 193.63 119.67 194.812 119.67 196.27C119.67 197.728 120.852 198.91 122.31 198.91Z" fill="#3B82F6"/>
<path d="M98.3802 198.91C98.9048 198.912 99.4181 198.759 99.8552 198.469C100.292 198.179 100.634 197.765 100.836 197.281C101.038 196.797 101.092 196.264 100.991 195.75C100.889 195.235 100.638 194.762 100.268 194.39C99.8975 194.018 99.4253 193.765 98.911 193.662C98.3967 193.559 97.8633 193.611 97.3785 193.811C96.8937 194.011 96.4793 194.351 96.1876 194.787C95.896 195.223 95.7402 195.736 95.7402 196.26C95.7402 196.961 96.0181 197.634 96.5129 198.131C97.0078 198.627 97.6792 198.908 98.3802 198.91V198.91Z" fill="#3B82F6"/>
<path d="M74.4498 198.91C74.9739 198.91 75.4863 198.755 75.9221 198.464C76.3579 198.173 76.6975 197.759 76.8981 197.274C77.0986 196.79 77.1511 196.257 77.0488 195.743C76.9466 195.229 76.6942 194.757 76.3236 194.387C75.953 194.016 75.4808 193.764 74.9668 193.661C74.4527 193.559 73.9199 193.612 73.4357 193.812C72.9514 194.013 72.5376 194.352 72.2465 194.788C71.9553 195.224 71.7998 195.736 71.7998 196.26C71.7998 196.608 71.8683 196.953 72.0015 197.274C72.1346 197.596 72.3299 197.888 72.5759 198.134C72.822 198.38 73.1142 198.576 73.4357 198.709C73.7572 198.842 74.1018 198.91 74.4498 198.91V198.91Z" fill="#3B82F6"/>
<path d="M50.5101 198.91C51.9681 198.91 53.1501 197.728 53.1501 196.27C53.1501 194.812 51.9681 193.63 50.5101 193.63C49.0521 193.63 47.8701 194.812 47.8701 196.27C47.8701 197.728 49.0521 198.91 50.5101 198.91Z" fill="#3B82F6"/>
<path d="M27.5901 198.595C28.9386 198.041 29.5823 196.498 29.0279 195.15C28.4735 193.801 26.9308 193.157 25.5823 193.712C24.2338 194.266 23.5901 195.809 24.1445 197.157C24.6989 198.506 26.2416 199.15 27.5901 198.595Z" fill="#3B82F6"/>
<path d="M2.65017 193.66C2.1252 193.658 1.61153 193.812 1.17421 194.103C0.736895 194.393 0.395678 194.807 0.193868 195.291C-0.00794293 195.776 -0.0612624 196.31 0.0406694 196.825C0.142601 197.34 0.395167 197.813 0.766377 198.184C1.13759 198.555 1.61065 198.808 2.12563 198.91C2.64061 199.012 3.17433 198.958 3.65896 198.756C4.14359 198.555 4.55737 198.214 4.8478 197.776C5.13822 197.339 5.29216 196.825 5.29018 196.3C5.28755 195.601 5.00858 194.931 4.51406 194.436C4.01953 193.942 3.34953 193.663 2.65017 193.66V193.66Z" fill="#3B82F6"/>
<path d="M146.249 177.5C147.707 177.5 148.889 176.318 148.889 174.86C148.889 173.402 147.707 172.22 146.249 172.22C144.791 172.22 143.609 173.402 143.609 174.86C143.609 176.318 144.791 177.5 146.249 177.5Z" fill="#3B82F6"/>
<path d="M122.31 177.5C123.768 177.5 124.95 176.318 124.95 174.86C124.95 173.402 123.768 172.22 122.31 172.22C120.852 172.22 119.67 173.402 119.67 174.86C119.67 176.318 120.852 177.5 122.31 177.5Z" fill="#3B82F6"/>
<path d="M98.3803 177.5C98.9052 177.502 99.419 177.348 99.8563 177.058C100.294 176.767 100.635 176.354 100.837 175.869C101.038 175.384 101.092 174.851 100.99 174.336C100.888 173.821 100.635 173.348 100.264 172.976C99.893 172.605 99.4198 172.353 98.9048 172.251C98.3898 172.149 97.8562 172.202 97.3716 172.404C96.887 172.606 96.4732 172.947 96.1828 173.384C95.8923 173.821 95.7383 174.335 95.7403 174.86C95.7429 175.56 96.022 176.229 96.5165 176.724C97.011 177.219 97.6809 177.498 98.3803 177.5V177.5Z" fill="#3B82F6"/>
<path d="M74.4498 177.5C74.9744 177.5 75.4871 177.345 75.9231 177.053C76.3591 176.761 76.6988 176.347 76.8991 175.862C77.0993 175.377 77.1512 174.844 77.0481 174.329C76.9451 173.815 76.6917 173.343 76.3201 172.973C75.9485 172.603 75.4753 172.351 74.9606 172.25C74.4459 172.149 73.9128 172.203 73.4287 172.405C72.9447 172.607 72.5316 172.948 72.2416 173.385C71.9516 173.822 71.7978 174.336 71.7998 174.86C71.7998 175.208 71.8684 175.552 72.0017 175.873C72.135 176.194 72.3304 176.485 72.5766 176.73C72.8228 176.976 73.115 177.17 73.4364 177.302C73.7579 177.434 74.1023 177.502 74.4498 177.5V177.5Z" fill="#3B82F6"/>
<path d="M50.5101 177.5C51.9681 177.5 53.1501 176.318 53.1501 174.86C53.1501 173.402 51.9681 172.22 50.5101 172.22C49.0521 172.22 47.8701 173.402 47.8701 174.86C47.8701 176.318 49.0521 177.5 50.5101 177.5Z" fill="#3B82F6"/>
<path d="M27.5921 177.193C28.9406 176.639 29.5843 175.096 29.0299 173.747C28.4754 172.399 26.9328 171.755 25.5843 172.31C24.2358 172.864 23.592 174.407 24.1465 175.755C24.7009 177.104 26.2436 177.747 27.5921 177.193Z" fill="#3B82F6"/>
<path d="M2.65004 177.5C3.17459 177.5 3.68731 177.345 4.12331 177.053C4.55931 176.761 4.89899 176.347 5.09926 175.862C5.29954 175.377 5.3515 174.844 5.24843 174.329C5.14537 173.815 4.89189 173.343 4.52028 172.973C4.14867 172.603 3.67561 172.351 3.16091 172.25C2.6462 172.149 2.11309 172.203 1.62905 172.405C1.145 172.607 0.731771 172.948 0.441791 173.385C0.151812 173.822 -0.00196055 174.336 1.88721e-05 174.86C1.63788e-05 175.208 0.0686259 175.552 0.201923 175.873C0.33522 176.194 0.530667 176.485 0.776874 176.73C1.02308 176.976 1.31528 177.17 1.63674 177.302C1.95819 177.434 2.30251 177.502 2.65004 177.5Z" fill="#3B82F6"/>
<path d="M146.249 156.09C147.707 156.09 148.889 154.908 148.889 153.45C148.889 151.992 147.707 150.81 146.249 150.81C144.791 150.81 143.609 151.992 143.609 153.45C143.609 154.908 144.791 156.09 146.249 156.09Z" fill="#3B82F6"/>
<path d="M122.31 156.09C123.768 156.09 124.95 154.908 124.95 153.45C124.95 151.992 123.768 150.81 122.31 150.81C120.852 150.81 119.67 151.992 119.67 153.45C119.67 154.908 120.852 156.09 122.31 156.09Z" fill="#3B82F6"/>
<path d="M98.3802 156.1C98.9048 156.102 99.4181 155.948 99.8552 155.658C100.292 155.368 100.634 154.955 100.836 154.471C101.038 153.987 101.092 153.454 100.991 152.939C100.889 152.424 100.638 151.951 100.268 151.58C99.8975 151.208 99.4253 150.955 98.911 150.851C98.3967 150.748 97.8633 150.8 97.3785 151.001C96.8937 151.201 96.4793 151.541 96.1876 151.977C95.896 152.413 95.7402 152.925 95.7402 153.45C95.7402 154.151 96.0181 154.823 96.5129 155.32C97.0078 155.817 97.6792 156.097 98.3802 156.1V156.1Z" fill="#3B82F6"/>
<path d="M74.4498 156.1C74.9739 156.1 75.4863 155.944 75.9221 155.653C76.3579 155.362 76.6975 154.948 76.8981 154.464C77.0986 153.98 77.1511 153.447 77.0488 152.933C76.9466 152.419 76.6942 151.947 76.3236 151.576C75.953 151.205 75.4808 150.953 74.9668 150.851C74.4527 150.748 73.9199 150.801 73.4357 151.002C72.9514 151.202 72.5376 151.542 72.2465 151.978C71.9553 152.413 71.7998 152.926 71.7998 153.45C71.7998 153.798 71.8683 154.142 72.0015 154.464C72.1346 154.785 72.3299 155.078 72.5759 155.324C72.822 155.57 73.1142 155.765 73.4357 155.898C73.7572 156.031 74.1018 156.1 74.4498 156.1V156.1Z" fill="#3B82F6"/>
<path d="M50.5101 156.09C51.9681 156.09 53.1501 154.908 53.1501 153.45C53.1501 151.992 51.9681 150.81 50.5101 150.81C49.0521 150.81 47.8701 151.992 47.8701 153.45C47.8701 154.908 49.0521 156.09 50.5101 156.09Z" fill="#3B82F6"/>
<path d="M27.5911 155.791C28.9396 155.237 29.5833 153.694 29.0289 152.346C28.4744 150.997 26.9318 150.354 25.5833 150.908C24.2348 151.463 23.591 153.005 24.1455 154.354C24.6999 155.702 26.2426 156.346 27.5911 155.791Z" fill="#3B82F6"/>
<path d="M2.65002 156.1C3.17414 156.1 3.68652 155.944 4.12231 155.653C4.5581 155.362 4.89769 154.948 5.09827 154.464C5.29884 153.98 5.3514 153.447 5.24915 152.933C5.14689 152.419 4.89453 151.947 4.52393 151.576C4.15332 151.205 3.68104 150.953 3.16699 150.851C2.65294 150.748 2.12021 150.801 1.63599 151.002C1.15176 151.202 0.737841 151.542 0.446655 151.978C0.15547 152.413 0 152.926 0 153.45C0 154.153 0.279274 154.827 0.776245 155.324C1.27322 155.821 1.9472 156.1 2.65002 156.1V156.1Z" fill="#3B82F6"/>
<path d="M146.249 134.69C147.707 134.69 148.889 133.508 148.889 132.05C148.889 130.592 147.707 129.41 146.249 129.41C144.791 129.41 143.609 130.592 143.609 132.05C143.609 133.508 144.791 134.69 146.249 134.69Z" fill="#3B82F6"/>
<path d="M122.31 134.69C123.768 134.69 124.95 133.508 124.95 132.05C124.95 130.592 123.768 129.41 122.31 129.41C120.852 129.41 119.67 130.592 119.67 132.05C119.67 133.508 120.852 134.69 122.31 134.69Z" fill="#3B82F6"/>
<path d="M98.3803 134.66C98.9052 134.662 99.419 134.508 99.8563 134.218C100.294 133.927 100.635 133.514 100.837 133.029C101.038 132.544 101.092 132.011 100.99 131.496C100.888 130.981 100.635 130.508 100.264 130.137C99.893 129.765 99.4198 129.513 98.9048 129.411C98.3898 129.309 97.8562 129.362 97.3716 129.564C96.887 129.766 96.4732 130.107 96.1828 130.544C95.8923 130.982 95.7383 131.495 95.7403 132.02C95.7429 132.72 96.022 133.39 96.5165 133.884C97.011 134.379 97.6809 134.658 98.3803 134.66V134.66Z" fill="#3B82F6"/>
<path d="M74.4498 134.66C74.9744 134.66 75.4871 134.505 75.9231 134.213C76.3591 133.921 76.6988 133.507 76.8991 133.022C77.0993 132.537 77.1512 132.004 77.0481 131.49C76.9451 130.975 76.6917 130.503 76.3201 130.133C75.9485 129.763 75.4753 129.511 74.9606 129.41C74.4459 129.309 73.9128 129.363 73.4287 129.565C72.9447 129.767 72.5316 130.108 72.2416 130.545C71.9516 130.982 71.7978 131.496 71.7998 132.02C71.7998 132.368 71.8684 132.712 72.0017 133.033C72.135 133.354 72.3304 133.645 72.5766 133.891C72.8228 134.136 73.115 134.33 73.4364 134.462C73.7579 134.594 74.1023 134.662 74.4498 134.66V134.66Z" fill="#3B82F6"/>
<path d="M50.5101 134.69C51.9681 134.69 53.1501 133.508 53.1501 132.05C53.1501 130.592 51.9681 129.41 50.5101 129.41C49.0521 129.41 47.8701 130.592 47.8701 132.05C47.8701 133.508 49.0521 134.69 50.5101 134.69Z" fill="#3B82F6"/>
<path d="M27.594 134.389C28.9425 133.835 29.5863 132.292 29.0318 130.944C28.4774 129.595 26.9347 128.951 25.5862 129.506C24.2377 130.06 23.594 131.603 24.1484 132.951C24.7029 134.3 26.2455 134.944 27.594 134.389Z" fill="#3B82F6"/>
<path d="M2.65004 134.66C3.17459 134.66 3.68731 134.505 4.12331 134.213C4.55931 133.921 4.89899 133.507 5.09926 133.022C5.29954 132.537 5.3515 132.004 5.24843 131.49C5.14537 130.975 4.89189 130.503 4.52028 130.133C4.14867 129.763 3.67561 129.511 3.16091 129.41C2.6462 129.309 2.11309 129.363 1.62905 129.565C1.145 129.767 0.731771 130.108 0.441791 130.545C0.151812 130.982 -0.00196055 131.496 1.88721e-05 132.02C1.63788e-05 132.368 0.0686259 132.712 0.201923 133.033C0.33522 133.354 0.530667 133.645 0.776874 133.891C1.02308 134.136 1.31528 134.33 1.63674 134.462C1.95819 134.594 2.30251 134.662 2.65004 134.66V134.66Z" fill="#3B82F6"/>
<path d="M146.249 113.28C147.707 113.28 148.889 112.098 148.889 110.64C148.889 109.182 147.707 108 146.249 108C144.791 108 143.609 109.182 143.609 110.64C143.609 112.098 144.791 113.28 146.249 113.28Z" fill="#3B82F6"/>
<path d="M122.31 113.28C123.768 113.28 124.95 112.098 124.95 110.64C124.95 109.182 123.768 108 122.31 108C120.852 108 119.67 109.182 119.67 110.64C119.67 112.098 120.852 113.28 122.31 113.28Z" fill="#3B82F6"/>
<path d="M98.3802 113.29C98.9048 113.292 99.4181 113.139 99.8552 112.849C100.292 112.559 100.634 112.145 100.836 111.661C101.038 111.177 101.092 110.644 100.991 110.129C100.889 109.615 100.638 109.142 100.268 108.77C99.8975 108.398 99.4253 108.145 98.911 108.042C98.3967 107.939 97.8633 107.991 97.3785 108.191C96.8937 108.391 96.4793 108.731 96.1876 109.167C95.896 109.603 95.7402 110.116 95.7402 110.64C95.7402 111.341 96.0181 112.014 96.5129 112.511C97.0078 113.007 97.6792 113.288 98.3802 113.29V113.29Z" fill="#3B82F6"/>
<path d="M74.4498 113.29C74.9739 113.29 75.4863 113.135 75.9221 112.844C76.3579 112.552 76.6975 112.139 76.8981 111.654C77.0986 111.17 77.1511 110.637 77.0488 110.123C76.9466 109.609 76.6942 109.137 76.3236 108.766C75.953 108.396 75.4808 108.143 74.9668 108.041C74.4527 107.939 73.9199 107.991 73.4357 108.192C72.9514 108.393 72.5376 108.732 72.2465 109.168C71.9553 109.604 71.7998 110.116 71.7998 110.64C71.7998 110.988 71.8683 111.333 72.0015 111.654C72.1346 111.976 72.3299 112.268 72.5759 112.514C72.822 112.76 73.1142 112.955 73.4357 113.089C73.7572 113.222 74.1018 113.29 74.4498 113.29V113.29Z" fill="#3B82F6"/>
<path d="M50.5101 113.28C51.9681 113.28 53.1501 112.098 53.1501 110.64C53.1501 109.182 51.9681 108 50.5101 108C49.0521 108 47.8701 109.182 47.8701 110.64C47.8701 112.098 49.0521 113.28 50.5101 113.28Z" fill="#3B82F6"/>
<path d="M27.592 112.977C28.9406 112.423 29.5843 110.88 29.0298 109.531C28.4754 108.183 26.9328 107.539 25.5843 108.094C24.2358 108.648 23.592 110.191 24.1465 111.539C24.7009 112.888 26.2435 113.532 27.592 112.977Z" fill="#3B82F6"/>
<path d="M2.65002 113.29C3.17414 113.29 3.68652 113.135 4.12231 112.844C4.5581 112.552 4.89769 112.139 5.09827 111.654C5.29884 111.17 5.3514 110.637 5.24915 110.123C5.14689 109.609 4.89453 109.137 4.52393 108.766C4.15332 108.396 3.68104 108.143 3.16699 108.041C2.65294 107.939 2.12021 107.991 1.63599 108.192C1.15176 108.393 0.737841 108.732 0.446655 109.168C0.15547 109.604 0 110.116 0 110.64C0 111.343 0.279274 112.017 0.776245 112.514C1.27322 113.011 1.9472 113.29 2.65002 113.29V113.29Z" fill="#3B82F6"/>
</g>
<g clip-path="url(#clip1_1384_22237)">
<path d="M146.249 90.9099C147.707 90.9099 148.889 89.7279 148.889 88.2699C148.889 86.8119 147.707 85.6299 146.249 85.6299C144.791 85.6299 143.609 86.8119 143.609 88.2699C143.609 89.7279 144.791 90.9099 146.249 90.9099Z" fill="#3B82F6"/>
<path d="M122.31 90.9099C123.768 90.9099 124.95 89.7279 124.95 88.2699C124.95 86.8119 123.768 85.6299 122.31 85.6299C120.852 85.6299 119.67 86.8119 119.67 88.2699C119.67 89.7279 120.852 90.9099 122.31 90.9099Z" fill="#3B82F6"/>
<path d="M98.3802 90.9104C98.9048 90.9123 99.4181 90.7586 99.8552 90.4686C100.292 90.1787 100.634 89.7654 100.836 89.2814C101.038 88.7973 101.092 88.2642 100.991 87.7495C100.889 87.2348 100.638 86.7617 100.268 86.3901C99.8975 86.0185 99.4253 85.7651 98.911 85.662C98.3967 85.5589 97.8633 85.6108 97.3785 85.8111C96.8937 86.0114 96.4793 86.3511 96.1876 86.7871C95.896 87.2231 95.7402 87.7358 95.7402 88.2603C95.7402 88.9614 96.0181 89.6339 96.5129 90.1306C97.0078 90.6273 97.6792 90.9077 98.3802 90.9104V90.9104Z" fill="#3B82F6"/>
<path d="M74.4498 90.9104C74.9739 90.9104 75.4863 90.7549 75.9221 90.4638C76.3579 90.1726 76.6975 89.7587 76.8981 89.2745C77.0986 88.7903 77.1511 88.2574 77.0488 87.7434C76.9466 87.2293 76.6942 86.7572 76.3236 86.3865C75.953 86.0159 75.4808 85.7635 74.9668 85.6613C74.4527 85.559 73.9199 85.6115 73.4357 85.8121C72.9514 86.0127 72.5376 86.3523 72.2465 86.7881C71.9553 87.2239 71.7998 87.7362 71.7998 88.2603C71.7998 88.6083 71.8683 88.953 72.0015 89.2745C72.1346 89.596 72.3299 89.8881 72.5759 90.1342C72.822 90.3802 73.1142 90.5755 73.4357 90.7087C73.7572 90.8419 74.1018 90.9104 74.4498 90.9104V90.9104Z" fill="#3B82F6"/>
<path d="M50.5101 90.9099C51.9681 90.9099 53.1501 89.7279 53.1501 88.2699C53.1501 86.8119 51.9681 85.6299 50.5101 85.6299C49.0521 85.6299 47.8701 86.8119 47.8701 88.2699C47.8701 89.7279 49.0521 90.9099 50.5101 90.9099Z" fill="#3B82F6"/>
<path d="M27.5901 90.5952C28.9386 90.0408 29.5823 88.4982 29.0279 87.1497C28.4735 85.8012 26.9308 85.1575 25.5823 85.7119C24.2338 86.2664 23.5901 87.809 24.1445 89.1575C24.6989 90.506 26.2416 91.1497 27.5901 90.5952Z" fill="#3B82F6"/>
<path d="M2.65017 85.6602C2.1252 85.6582 1.61153 85.8122 1.17421 86.1026C0.736895 86.393 0.395678 86.8068 0.193868 87.2915C-0.00794293 87.7761 -0.0612624 88.3097 0.0406694 88.8247C0.142601 89.3397 0.395167 89.8128 0.766377 90.184C1.13759 90.5552 1.61065 90.8078 2.12563 90.9097C2.64061 91.0116 3.17433 90.9583 3.65896 90.7565C4.14359 90.5547 4.55737 90.2135 4.8478 89.7762C5.13822 89.3389 5.29216 88.8252 5.29018 88.3002C5.28755 87.6008 5.00858 86.9308 4.51406 86.4363C4.01953 85.9418 3.34953 85.6628 2.65017 85.6602V85.6602Z" fill="#3B82F6"/>
<path d="M146.249 69.4997C147.707 69.4997 148.889 68.3178 148.889 66.8597C148.889 65.4017 147.707 64.2197 146.249 64.2197C144.791 64.2197 143.609 65.4017 143.609 66.8597C143.609 68.3178 144.791 69.4997 146.249 69.4997Z" fill="#3B82F6"/>
<path d="M122.31 69.4997C123.768 69.4997 124.95 68.3178 124.95 66.8597C124.95 65.4017 123.768 64.2197 122.31 64.2197C120.852 64.2197 119.67 65.4017 119.67 66.8597C119.67 68.3178 120.852 69.4997 122.31 69.4997Z" fill="#3B82F6"/>
<path d="M98.3803 69.5002C98.9052 69.5022 99.419 69.3482 99.8563 69.0578C100.294 68.7673 100.635 68.3535 100.837 67.8689C101.038 67.3843 101.092 66.8506 100.99 66.3357C100.888 65.8207 100.635 65.3475 100.264 64.9763C99.893 64.6051 99.4198 64.3526 98.9048 64.2506C98.3898 64.1487 97.8562 64.202 97.3716 64.4038C96.887 64.6056 96.4732 64.9469 96.1828 65.3842C95.8923 65.8215 95.7383 66.3352 95.7403 66.8602C95.7429 67.5595 96.022 68.2295 96.5165 68.724C97.011 69.2185 97.6809 69.4976 98.3803 69.5002V69.5002Z" fill="#3B82F6"/>
<path d="M74.4498 69.5002C74.9744 69.5002 75.4871 69.3445 75.9231 69.0529C76.3591 68.7612 76.6988 68.3468 76.8991 67.862C77.0993 67.3772 77.1512 66.8438 77.0481 66.3295C76.9451 65.8152 76.6917 65.343 76.3201 64.9728C75.9485 64.6026 75.4753 64.351 74.9606 64.2499C74.4459 64.1488 73.9128 64.2027 73.4287 64.4048C72.9447 64.6069 72.5316 64.9481 72.2416 65.3852C71.9516 65.8223 71.7978 66.3356 71.7998 66.8602C71.7998 67.2077 71.8684 67.5518 72.0017 67.8728C72.135 68.1937 72.3304 68.4852 72.5766 68.7305C72.8228 68.9758 73.115 69.17 73.4364 69.3021C73.7579 69.4342 74.1023 69.5015 74.4498 69.5002V69.5002Z" fill="#3B82F6"/>
<path d="M50.5101 69.4997C51.9681 69.4997 53.1501 68.3178 53.1501 66.8597C53.1501 65.4017 51.9681 64.2197 50.5101 64.2197C49.0521 64.2197 47.8701 65.4017 47.8701 66.8597C47.8701 68.3178 49.0521 69.4997 50.5101 69.4997Z" fill="#3B82F6"/>
<path d="M27.5921 69.193C28.9406 68.6385 29.5843 67.0959 29.0299 65.7474C28.4754 64.3989 26.9328 63.7551 25.5843 64.3096C24.2358 64.864 23.592 66.4067 24.1465 67.7552C24.7009 69.1037 26.2436 69.7474 27.5921 69.193Z" fill="#3B82F6"/>
<path d="M2.65004 69.5002C3.17459 69.5002 3.68731 69.3445 4.12331 69.0529C4.55931 68.7612 4.89899 68.3468 5.09926 67.862C5.29954 67.3772 5.3515 66.8438 5.24843 66.3295C5.14537 65.8152 4.89189 65.343 4.52028 64.9728C4.14867 64.6026 3.67561 64.351 3.16091 64.2499C2.6462 64.1488 2.11309 64.2027 1.62905 64.4048C1.145 64.6069 0.731771 64.9481 0.441791 65.3852C0.151812 65.8223 -0.00196055 66.3356 1.88721e-05 66.8602C1.63788e-05 67.2077 0.0686259 67.5518 0.201923 67.8728C0.33522 68.1937 0.530667 68.4852 0.776874 68.7305C1.02308 68.9758 1.31528 69.17 1.63674 69.3021C1.95819 69.4342 2.30251 69.5015 2.65004 69.5002Z" fill="#3B82F6"/>
<path d="M146.249 48.0896C147.707 48.0896 148.889 46.9076 148.889 45.4496C148.889 43.9915 147.707 42.8096 146.249 42.8096C144.791 42.8096 143.609 43.9915 143.609 45.4496C143.609 46.9076 144.791 48.0896 146.249 48.0896Z" fill="#3B82F6"/>
<path d="M122.31 48.0896C123.768 48.0896 124.95 46.9076 124.95 45.4496C124.95 43.9915 123.768 42.8096 122.31 42.8096C120.852 42.8096 119.67 43.9915 119.67 45.4496C119.67 46.9076 120.852 48.0896 122.31 48.0896Z" fill="#3B82F6"/>
<path d="M98.3802 48.0998C98.9048 48.1018 99.4181 47.9481 99.8552 47.6581C100.292 47.3681 100.634 46.9549 100.836 46.4708C101.038 45.9868 101.092 45.4537 100.991 44.939C100.889 44.4243 100.638 43.9512 100.268 43.5795C99.8975 43.2079 99.4253 42.9545 98.911 42.8515C98.3967 42.7484 97.8633 42.8003 97.3785 43.0006C96.8937 43.2008 96.4793 43.5405 96.1876 43.9765C95.896 44.4125 95.7402 44.9252 95.7402 45.4498C95.7402 46.1509 96.0181 46.8234 96.5129 47.3201C97.0078 47.8168 97.6792 48.0972 98.3802 48.0998V48.0998Z" fill="#3B82F6"/>
<path d="M74.4498 48.0998C74.9739 48.0998 75.4863 47.9444 75.9221 47.6532C76.3579 47.362 76.6975 46.9482 76.8981 46.4639C77.0986 45.9797 77.1511 45.4469 77.0488 44.9328C76.9466 44.4188 76.6942 43.9465 76.3236 43.5759C75.953 43.2053 75.4808 42.953 74.9668 42.8507C74.4527 42.7485 73.9199 42.801 73.4357 43.0015C72.9514 43.2021 72.5376 43.5418 72.2465 43.9776C71.9553 44.4133 71.7998 44.9257 71.7998 45.4498C71.7998 45.7978 71.8683 46.1424 72.0015 46.4639C72.1346 46.7855 72.3299 47.0775 72.5759 47.3236C72.822 47.5697 73.1142 47.7649 73.4357 47.8981C73.7572 48.0313 74.1018 48.0998 74.4498 48.0998V48.0998Z" fill="#3B82F6"/>
<path d="M50.5101 48.0896C51.9681 48.0896 53.1501 46.9076 53.1501 45.4496C53.1501 43.9915 51.9681 42.8096 50.5101 42.8096C49.0521 42.8096 47.8701 43.9915 47.8701 45.4496C47.8701 46.9076 49.0521 48.0896 50.5101 48.0896Z" fill="#3B82F6"/>
<path d="M27.5911 47.7915C28.9396 47.237 29.5833 45.6944 29.0289 44.3459C28.4744 42.9974 26.9318 42.3537 25.5833 42.9081C24.2348 43.4626 23.591 45.0052 24.1455 46.3537C24.6999 47.7022 26.2426 48.3459 27.5911 47.7915Z" fill="#3B82F6"/>
<path d="M2.65002 48.0998C3.17414 48.0998 3.68652 47.9444 4.12231 47.6532C4.5581 47.362 4.89769 46.9482 5.09827 46.4639C5.29884 45.9797 5.3514 45.4469 5.24915 44.9328C5.14689 44.4188 4.89453 43.9465 4.52393 43.5759C4.15332 43.2053 3.68104 42.953 3.16699 42.8507C2.65294 42.7485 2.12021 42.801 1.63599 43.0015C1.15176 43.2021 0.737841 43.5418 0.446655 43.9776C0.15547 44.4133 0 44.9257 0 45.4498C0 46.1526 0.279274 46.8266 0.776245 47.3236C1.27322 47.8206 1.9472 48.0998 2.65002 48.0998V48.0998Z" fill="#3B82F6"/>
<path d="M146.249 26.6902C147.707 26.6902 148.889 25.5082 148.889 24.0502C148.889 22.5921 147.707 21.4102 146.249 21.4102C144.791 21.4102 143.609 22.5921 143.609 24.0502C143.609 25.5082 144.791 26.6902 146.249 26.6902Z" fill="#3B82F6"/>
<path d="M122.31 26.6902C123.768 26.6902 124.95 25.5082 124.95 24.0502C124.95 22.5921 123.768 21.4102 122.31 21.4102C120.852 21.4102 119.67 22.5921 119.67 24.0502C119.67 25.5082 120.852 26.6902 122.31 26.6902Z" fill="#3B82F6"/>
<path d="M98.3803 26.6604C98.9052 26.6623 99.419 26.5083 99.8563 26.2179C100.294 25.9275 100.635 25.5137 100.837 25.0291C101.038 24.5444 101.092 24.0108 100.99 23.4958C100.888 22.9808 100.635 22.5078 100.264 22.1366C99.893 21.7653 99.4198 21.5127 98.9048 21.4108C98.3898 21.3089 97.8562 21.3622 97.3716 21.564C96.887 21.7658 96.4732 22.107 96.1828 22.5443C95.8923 22.9817 95.7383 23.4954 95.7403 24.0203C95.7429 24.7197 96.022 25.3897 96.5165 25.8842C97.011 26.3788 97.6809 26.6577 98.3803 26.6604V26.6604Z" fill="#3B82F6"/>
<path d="M74.4498 26.6604C74.9744 26.6604 75.4871 26.5047 75.9231 26.213C76.3591 25.9214 76.6988 25.507 76.8991 25.0222C77.0993 24.5374 77.1512 24.004 77.0481 23.4897C76.9451 22.9754 76.6917 22.5032 76.3201 22.133C75.9485 21.7628 75.4753 21.5112 74.9606 21.4101C74.4459 21.3089 73.9128 21.3629 73.4287 21.565C72.9447 21.7671 72.5316 22.1083 72.2416 22.5454C71.9516 22.9825 71.7978 23.4958 71.7998 24.0203C71.7998 24.3679 71.8684 24.712 72.0017 25.033C72.135 25.3539 72.3304 25.6454 72.5766 25.8906C72.8228 26.1359 73.115 26.3302 73.4364 26.4623C73.7579 26.5944 74.1023 26.6617 74.4498 26.6604V26.6604Z" fill="#3B82F6"/>
<path d="M50.5101 26.6902C51.9681 26.6902 53.1501 25.5082 53.1501 24.0502C53.1501 22.5921 51.9681 21.4102 50.5101 21.4102C49.0521 21.4102 47.8701 22.5921 47.8701 24.0502C47.8701 25.5082 49.0521 26.6902 50.5101 26.6902Z" fill="#3B82F6"/>
<path d="M27.594 26.3892C28.9425 25.8348 29.5863 24.2922 29.0318 22.9437C28.4774 21.5952 26.9347 20.9514 25.5862 21.5059C24.2377 22.0603 23.594 23.603 24.1484 24.9515C24.7029 26.3 26.2455 26.9437 27.594 26.3892Z" fill="#3B82F6"/>
<path d="M2.65004 26.6604C3.17459 26.6604 3.68731 26.5047 4.12331 26.213C4.55931 25.9214 4.89899 25.507 5.09926 25.0222C5.29954 24.5374 5.3515 24.004 5.24843 23.4897C5.14537 22.9754 4.89189 22.5032 4.52028 22.133C4.14867 21.7628 3.67561 21.5112 3.16091 21.4101C2.6462 21.3089 2.11309 21.3629 1.62905 21.565C1.145 21.7671 0.731771 22.1083 0.441791 22.5454C0.151812 22.9825 -0.00196055 23.4958 1.88721e-05 24.0203C1.63788e-05 24.3679 0.0686259 24.712 0.201923 25.033C0.33522 25.3539 0.530667 25.6454 0.776874 25.8906C1.02308 26.1359 1.31528 26.3302 1.63674 26.4623C1.95819 26.5944 2.30251 26.6617 2.65004 26.6604V26.6604Z" fill="#3B82F6"/>
<path d="M146.249 5.28C147.707 5.28 148.889 4.09803 148.889 2.64C148.889 1.18197 147.707 0 146.249 0C144.791 0 143.609 1.18197 143.609 2.64C143.609 4.09803 144.791 5.28 146.249 5.28Z" fill="#3B82F6"/>
<path d="M122.31 5.28C123.768 5.28 124.95 4.09803 124.95 2.64C124.95 1.18197 123.768 0 122.31 0C120.852 0 119.67 1.18197 119.67 2.64C119.67 4.09803 120.852 5.28 122.31 5.28Z" fill="#3B82F6"/>
<path d="M98.3802 5.29024C98.9048 5.29222 99.4181 5.13851 99.8552 4.84853C100.292 4.55855 100.634 4.14532 100.836 3.66127C101.038 3.17723 101.092 2.64412 100.991 2.12941C100.889 1.61471 100.638 1.14159 100.268 0.769978C99.8975 0.398368 99.4253 0.144953 98.911 0.0418894C98.3967 -0.0611745 97.8633 -0.00927669 97.3785 0.190998C96.8937 0.391273 96.4793 0.730946 96.1876 1.16695C95.896 1.60295 95.7402 2.11567 95.7402 2.64022C95.7402 3.34131 96.0181 4.01383 96.5129 4.51052C97.0078 5.0072 97.6792 5.2876 98.3802 5.29024V5.29024Z" fill="#3B82F6"/>
<path d="M74.4498 5.29023C74.9739 5.29023 75.4863 5.13483 75.9221 4.84364C76.3579 4.55245 76.6975 4.13859 76.8981 3.65437C77.0986 3.17015 77.1511 2.63729 77.0488 2.12324C76.9466 1.60919 76.6942 1.13698 76.3236 0.76637C75.953 0.395761 75.4808 0.143401 74.9668 0.04115C74.4527 -0.0611008 73.9199 -0.00860433 73.4357 0.191968C72.9514 0.39254 72.5376 0.732191 72.2465 1.16798C71.9553 1.60377 71.7998 2.11609 71.7998 2.64021C71.7998 2.98821 71.8683 3.33286 72.0015 3.65437C72.1346 3.97588 72.3299 4.26798 72.5759 4.51405C72.822 4.76013 73.1142 4.95534 73.4357 5.08851C73.7572 5.22169 74.1018 5.29023 74.4498 5.29023V5.29023Z" fill="#3B82F6"/>
<path d="M50.5101 5.28C51.9681 5.28 53.1501 4.09803 53.1501 2.64C53.1501 1.18197 51.9681 0 50.5101 0C49.0521 0 47.8701 1.18197 47.8701 2.64C47.8701 4.09803 49.0521 5.28 50.5101 5.28Z" fill="#3B82F6"/>
<path d="M27.592 4.97708C28.9406 4.42265 29.5843 2.87999 29.0298 1.53149C28.4754 0.182988 26.9328 -0.460681 25.5843 0.0937553C24.2358 0.648191 23.592 2.19079 24.1465 3.53929C24.7009 4.88779 26.2435 5.53152 27.592 4.97708Z" fill="#3B82F6"/>
<path d="M2.65002 5.29023C3.17414 5.29023 3.68652 5.13483 4.12231 4.84364C4.5581 4.55245 4.89769 4.13859 5.09827 3.65437C5.29884 3.17015 5.3514 2.63729 5.24915 2.12324C5.14689 1.60919 4.89453 1.13698 4.52393 0.76637C4.15332 0.395761 3.68104 0.143401 3.16699 0.04115C2.65294 -0.0611008 2.12021 -0.00860433 1.63599 0.191968C1.15176 0.39254 0.737841 0.732191 0.446655 1.16798C0.15547 1.60377 0 2.11609 0 2.64021C0 3.34303 0.279274 4.01708 0.776245 4.51405C1.27322 5.01102 1.9472 5.29023 2.65002 5.29023V5.29023Z" fill="#3B82F6"/>
</g>
<defs>
<clipPath id="clip0_1384_22237">
<rect width="148.89" height="90.91" fill="white" transform="translate(0 108)"/>
</clipPath>
<clipPath id="clip1_1384_22237">
<rect width="148.89" height="90.91" fill="white"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 26 KiB

View File

@@ -0,0 +1,44 @@
<svg width="149" height="91" viewBox="0 0 149 91" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_623_24537)">
<path d="M146.25 90.91C147.708 90.91 148.89 89.728 148.89 88.27C148.89 86.812 147.708 85.63 146.25 85.63C144.792 85.63 143.61 86.812 143.61 88.27C143.61 89.728 144.792 90.91 146.25 90.91Z" fill="#2AD168"/>
<path d="M122.31 90.91C123.768 90.91 124.95 89.728 124.95 88.27C124.95 86.812 123.768 85.63 122.31 85.63C120.852 85.63 119.67 86.812 119.67 88.27C119.67 89.728 120.852 90.91 122.31 90.91Z" fill="#2AD168"/>
<path d="M98.3798 90.91C98.9043 90.912 99.4176 90.7583 99.8547 90.4683C100.292 90.1783 100.633 89.7651 100.835 89.2811C101.037 88.797 101.091 88.2639 100.99 87.7492C100.889 87.2345 100.637 86.7614 100.267 86.3898C99.897 86.0181 99.4248 85.7647 98.9105 85.6617C98.3962 85.5586 97.8629 85.6105 97.3781 85.8108C96.8932 86.0111 96.4788 86.3507 96.1871 86.7867C95.8955 87.2227 95.7397 87.7355 95.7397 88.26C95.7397 88.9611 96.0176 89.6336 96.5125 90.1303C97.0073 90.627 97.6787 90.9074 98.3798 90.91V90.91Z" fill="#2AD168"/>
<path d="M74.4498 90.91C74.9739 90.91 75.4863 90.7546 75.9221 90.4634C76.3579 90.1722 76.6975 89.7584 76.8981 89.2742C77.0986 88.7899 77.1511 88.2571 77.0488 87.743C76.9466 87.229 76.6942 86.7568 76.3236 86.3862C75.953 86.0156 75.4808 85.7632 74.9668 85.6609C74.4527 85.5587 73.9199 85.6112 73.4357 85.8117C72.9514 86.0123 72.5376 86.352 72.2465 86.7878C71.9553 87.2236 71.7998 87.7359 71.7998 88.26C71.7998 88.608 71.8683 88.9526 72.0015 89.2742C72.1346 89.5957 72.3299 89.8878 72.5759 90.1338C72.822 90.3799 73.1142 90.5752 73.4357 90.7084C73.7572 90.8415 74.1018 90.91 74.4498 90.91V90.91Z" fill="#2AD168"/>
<path d="M50.5101 90.91C51.9681 90.91 53.1501 89.728 53.1501 88.27C53.1501 86.812 51.9681 85.63 50.5101 85.63C49.0521 85.63 47.8701 86.812 47.8701 88.27C47.8701 89.728 49.0521 90.91 50.5101 90.91Z" fill="#2AD168"/>
<path d="M27.5901 90.5955C28.9386 90.0411 29.5823 88.4984 29.0279 87.1499C28.4735 85.8014 26.9308 85.1578 25.5823 85.7122C24.2338 86.2666 23.5901 87.8092 24.1445 89.1577C24.6989 90.5062 26.2416 91.15 27.5901 90.5955Z" fill="#2AD168"/>
<path d="M2.65017 85.66C2.1252 85.658 1.61153 85.812 1.17421 86.1025C0.736895 86.3929 0.395678 86.8067 0.193868 87.2913C-0.00794293 87.7759 -0.0612624 88.3096 0.0406694 88.8246C0.142601 89.3396 0.395167 89.8126 0.766377 90.1838C1.13759 90.555 1.61065 90.8076 2.12563 90.9095C2.64061 91.0115 3.17433 90.9581 3.65896 90.7563C4.14359 90.5545 4.55737 90.2134 4.8478 89.7761C5.13822 89.3387 5.29216 88.825 5.29018 88.3C5.28755 87.6007 5.00858 86.9307 4.51406 86.4361C4.01953 85.9416 3.34953 85.6627 2.65017 85.66V85.66Z" fill="#2AD168"/>
<path d="M146.25 69.5C147.708 69.5 148.89 68.318 148.89 66.86C148.89 65.402 147.708 64.22 146.25 64.22C144.792 64.22 143.61 65.402 143.61 66.86C143.61 68.318 144.792 69.5 146.25 69.5Z" fill="#2AD168"/>
<path d="M122.31 69.5C123.768 69.5 124.95 68.318 124.95 66.86C124.95 65.402 123.768 64.22 122.31 64.22C120.852 64.22 119.67 65.402 119.67 66.86C119.67 68.318 120.852 69.5 122.31 69.5Z" fill="#2AD168"/>
<path d="M98.3798 69.5001C98.9047 69.502 99.4185 69.348 99.8559 69.0576C100.293 68.7672 100.634 68.3534 100.836 67.8688C101.038 67.3841 101.091 66.8505 100.989 66.3355C100.887 65.8205 100.635 65.3474 100.264 64.9762C99.8925 64.605 99.4193 64.3524 98.9043 64.2505C98.3893 64.1485 97.8557 64.2019 97.3711 64.4037C96.8865 64.6055 96.4727 64.9467 96.1823 65.384C95.8918 65.8213 95.7378 66.3351 95.7398 66.86C95.7424 67.5594 96.0215 68.2293 96.516 68.7239C97.0105 69.2184 97.6804 69.4974 98.3798 69.5001V69.5001Z" fill="#2AD168"/>
<path d="M74.4498 69.5001C74.9744 69.5 75.4871 69.3444 75.9231 69.0527C76.3591 68.7611 76.6988 68.3466 76.8991 67.8618C77.0993 67.377 77.1512 66.8437 77.0481 66.3293C76.9451 65.815 76.6917 65.3429 76.3201 64.9726C75.9485 64.6024 75.4753 64.3509 74.9606 64.2497C74.4459 64.1486 73.9128 64.2025 73.4287 64.4047C72.9447 64.6068 72.5316 64.948 72.2416 65.3851C71.9516 65.8222 71.7978 66.3355 71.7998 66.86C71.7998 67.2076 71.8684 67.5517 72.0017 67.8726C72.135 68.1936 72.3304 68.4851 72.5766 68.7303C72.8228 68.9756 73.115 69.1698 73.4364 69.3019C73.7579 69.434 74.1023 69.5014 74.4498 69.5001V69.5001Z" fill="#2AD168"/>
<path d="M50.5101 69.5C51.9681 69.5 53.1501 68.318 53.1501 66.86C53.1501 65.402 51.9681 64.22 50.5101 64.22C49.0521 64.22 47.8701 65.402 47.8701 66.86C47.8701 68.318 49.0521 69.5 50.5101 69.5Z" fill="#2AD168"/>
<path d="M27.5926 69.1932C28.9411 68.6387 29.5848 67.0961 29.0304 65.7476C28.4759 64.3991 26.9333 63.7554 25.5848 64.3098C24.2363 64.8642 23.5925 66.4069 24.147 67.7554C24.7014 69.1039 26.2441 69.7476 27.5926 69.1932Z" fill="#2AD168"/>
<path d="M2.65004 69.5001C3.17459 69.5 3.68731 69.3444 4.12331 69.0527C4.55931 68.7611 4.89899 68.3466 5.09926 67.8618C5.29954 67.377 5.3515 66.8437 5.24843 66.3293C5.14537 65.815 4.89189 65.3429 4.52028 64.9726C4.14867 64.6024 3.67561 64.3509 3.16091 64.2497C2.6462 64.1486 2.11309 64.2025 1.62905 64.4047C1.145 64.6068 0.731771 64.948 0.441791 65.3851C0.151812 65.8222 -0.00196055 66.3355 1.88721e-05 66.86C1.63788e-05 67.2076 0.0686259 67.5517 0.201923 67.8726C0.33522 68.1936 0.530667 68.4851 0.776874 68.7303C1.02308 68.9756 1.31528 69.1698 1.63674 69.3019C1.95819 69.434 2.30251 69.5014 2.65004 69.5001Z" fill="#2AD168"/>
<path d="M146.25 48.09C147.708 48.09 148.89 46.908 148.89 45.45C148.89 43.992 147.708 42.81 146.25 42.81C144.792 42.81 143.61 43.992 143.61 45.45C143.61 46.908 144.792 48.09 146.25 48.09Z" fill="#2AD168"/>
<path d="M122.31 48.09C123.768 48.09 124.95 46.908 124.95 45.45C124.95 43.992 123.768 42.81 122.31 42.81C120.852 42.81 119.67 43.992 119.67 45.45C119.67 46.908 120.852 48.09 122.31 48.09Z" fill="#2AD168"/>
<path d="M98.3798 48.1C98.9043 48.102 99.4176 47.9483 99.8547 47.6583C100.292 47.3683 100.633 46.9551 100.835 46.4711C101.037 45.987 101.091 45.4539 100.99 44.9392C100.889 44.4245 100.637 43.9514 100.267 43.5798C99.897 43.2082 99.4248 42.9547 98.9105 42.8517C98.3962 42.7486 97.8629 42.8005 97.3781 43.0008C96.8932 43.2011 96.4788 43.5407 96.1871 43.9767C95.8955 44.4127 95.7397 44.9255 95.7397 45.45C95.7397 46.1511 96.0176 46.8236 96.5125 47.3203C97.0073 47.817 97.6787 48.0974 98.3798 48.1V48.1Z" fill="#2AD168"/>
<path d="M74.4498 48.1C74.9739 48.1 75.4863 47.9446 75.9221 47.6534C76.3579 47.3622 76.6975 46.9484 76.8981 46.4642C77.0986 45.9799 77.1511 45.4471 77.0488 44.933C76.9466 44.419 76.6942 43.9468 76.3236 43.5762C75.953 43.2055 75.4808 42.9532 74.9668 42.8509C74.4527 42.7487 73.9199 42.8012 73.4357 43.0018C72.9514 43.2023 72.5376 43.542 72.2465 43.9778C71.9553 44.4136 71.7998 44.9259 71.7998 45.45C71.7998 45.798 71.8683 46.1426 72.0015 46.4642C72.1346 46.7857 72.3299 47.0778 72.5759 47.3238C72.822 47.5699 73.1142 47.7651 73.4357 47.8983C73.7572 48.0315 74.1018 48.1 74.4498 48.1V48.1Z" fill="#2AD168"/>
<path d="M50.5101 48.09C51.9681 48.09 53.1501 46.908 53.1501 45.45C53.1501 43.992 51.9681 42.81 50.5101 42.81C49.0521 42.81 47.8701 43.992 47.8701 45.45C47.8701 46.908 49.0521 48.09 50.5101 48.09Z" fill="#2AD168"/>
<path d="M27.5911 47.7915C28.9396 47.2371 29.5833 45.6944 29.0289 44.3459C28.4744 42.9974 26.9318 42.3537 25.5833 42.9082C24.2348 43.4626 23.591 45.0052 24.1455 46.3537C24.6999 47.7022 26.2426 48.3459 27.5911 47.7915Z" fill="#2AD168"/>
<path d="M2.65002 48.1C3.17414 48.1 3.68652 47.9446 4.12231 47.6534C4.5581 47.3622 4.89769 46.9484 5.09827 46.4642C5.29884 45.9799 5.3514 45.4471 5.24915 44.933C5.14689 44.419 4.89453 43.9468 4.52393 43.5762C4.15332 43.2055 3.68104 42.9532 3.16699 42.8509C2.65294 42.7487 2.12021 42.8012 1.63599 43.0018C1.15176 43.2023 0.737841 43.542 0.446655 43.9778C0.15547 44.4136 0 44.9259 0 45.45C0 46.1528 0.279274 46.8269 0.776245 47.3238C1.27322 47.8208 1.9472 48.1 2.65002 48.1V48.1Z" fill="#2AD168"/>
<path d="M146.25 26.69C147.708 26.69 148.89 25.508 148.89 24.05C148.89 22.592 147.708 21.41 146.25 21.41C144.792 21.41 143.61 22.592 143.61 24.05C143.61 25.508 144.792 26.69 146.25 26.69Z" fill="#2AD168"/>
<path d="M122.31 26.69C123.768 26.69 124.95 25.508 124.95 24.05C124.95 22.592 123.768 21.41 122.31 21.41C120.852 21.41 119.67 22.592 119.67 24.05C119.67 25.508 120.852 26.69 122.31 26.69Z" fill="#2AD168"/>
<path d="M98.3798 26.66C98.9047 26.662 99.4185 26.508 99.8559 26.2176C100.293 25.9272 100.634 25.5134 100.836 25.0287C101.038 24.5441 101.091 24.0105 100.989 23.4955C100.887 22.9805 100.635 22.5074 100.264 22.1362C99.8925 21.765 99.4193 21.5124 98.9043 21.4105C98.3893 21.3085 97.8557 21.3618 97.3711 21.5636C96.8865 21.7655 96.4727 22.1067 96.1823 22.544C95.8918 22.9813 95.7378 23.495 95.7398 24.02C95.7424 24.7194 96.0215 25.3894 96.516 25.8839C97.0105 26.3784 97.6804 26.6574 98.3798 26.66V26.66Z" fill="#2AD168"/>
<path d="M74.4498 26.66C74.9744 26.66 75.4871 26.5043 75.9231 26.2127C76.3591 25.9211 76.6988 25.5066 76.8991 25.0218C77.0993 24.537 77.1512 24.0037 77.0481 23.4894C76.9451 22.975 76.6917 22.5029 76.3201 22.1327C75.9485 21.7625 75.4753 21.5108 74.9606 21.4097C74.4459 21.3086 73.9128 21.3625 73.4287 21.5646C72.9447 21.7667 72.5316 22.1079 72.2416 22.545C71.9516 22.9821 71.7978 23.4955 71.7998 24.02C71.7998 24.3675 71.8684 24.7117 72.0017 25.0326C72.135 25.3536 72.3304 25.645 72.5766 25.8903C72.8228 26.1356 73.115 26.3299 73.4364 26.462C73.7579 26.594 74.1023 26.6613 74.4498 26.66V26.66Z" fill="#2AD168"/>
<path d="M50.5101 26.69C51.9681 26.69 53.1501 25.508 53.1501 24.05C53.1501 22.592 51.9681 21.41 50.5101 21.41C49.0521 21.41 47.8701 22.592 47.8701 24.05C47.8701 25.508 49.0521 26.69 50.5101 26.69Z" fill="#2AD168"/>
<path d="M27.5935 26.3891C28.942 25.8347 29.5858 24.292 29.0313 22.9435C28.4769 21.595 26.9342 20.9513 25.5857 21.5057C24.2372 22.0602 23.5935 23.6028 24.1479 24.9513C24.7024 26.2998 26.245 26.9436 27.5935 26.3891Z" fill="#2AD168"/>
<path d="M2.65004 26.66C3.17459 26.66 3.68731 26.5043 4.12331 26.2127C4.55931 25.9211 4.89899 25.5066 5.09926 25.0218C5.29954 24.537 5.3515 24.0037 5.24843 23.4894C5.14537 22.975 4.89189 22.5029 4.52028 22.1327C4.14867 21.7625 3.67561 21.5108 3.16091 21.4097C2.6462 21.3086 2.11309 21.3625 1.62905 21.5646C1.145 21.7667 0.731771 22.1079 0.441791 22.545C0.151812 22.9821 -0.00196055 23.4955 1.88721e-05 24.02C1.63788e-05 24.3675 0.0686259 24.7117 0.201923 25.0326C0.33522 25.3536 0.530667 25.645 0.776874 25.8903C1.02308 26.1356 1.31528 26.3299 1.63674 26.462C1.95819 26.594 2.30251 26.6613 2.65004 26.66V26.66Z" fill="#2AD168"/>
<path d="M146.25 5.28C147.708 5.28 148.89 4.09803 148.89 2.64C148.89 1.18197 147.708 0 146.25 0C144.792 0 143.61 1.18197 143.61 2.64C143.61 4.09803 144.792 5.28 146.25 5.28Z" fill="#2AD168"/>
<path d="M122.31 5.28C123.768 5.28 124.95 4.09803 124.95 2.64C124.95 1.18197 123.768 0 122.31 0C120.852 0 119.67 1.18197 119.67 2.64C119.67 4.09803 120.852 5.28 122.31 5.28Z" fill="#2AD168"/>
<path d="M98.3798 5.29003C98.9043 5.29201 99.4176 5.1383 99.8547 4.84832C100.292 4.55834 100.633 4.14511 100.835 3.66106C101.037 3.17701 101.091 2.64391 100.99 2.1292C100.889 1.61449 100.637 1.14137 100.267 0.769764C99.897 0.398154 99.4248 0.14474 98.9105 0.0416758C98.3962 -0.0613881 97.8629 -0.00949031 97.3781 0.190785C96.8932 0.39106 96.4788 0.730733 96.1871 1.16674C95.8955 1.60274 95.7397 2.11546 95.7397 2.64C95.7397 3.3411 96.0176 4.01362 96.5125 4.5103C97.0073 5.00699 97.6787 5.28738 98.3798 5.29003V5.29003Z" fill="#2AD168"/>
<path d="M74.4498 5.29002C74.9739 5.29002 75.4863 5.13461 75.9221 4.84343C76.3579 4.55224 76.6975 4.13838 76.8981 3.65416C77.0986 3.16993 77.1511 2.63708 77.0488 2.12303C76.9466 1.60898 76.6942 1.13677 76.3236 0.766156C75.953 0.395547 75.4808 0.143187 74.9668 0.0409364C74.4527 -0.0613144 73.9199 -0.00881796 73.4357 0.191754C72.9514 0.392326 72.5376 0.731977 72.2465 1.16777C71.9553 1.60356 71.7998 2.11588 71.7998 2.64C71.7998 2.988 71.8683 3.33264 72.0015 3.65416C72.1346 3.97567 72.3299 4.26776 72.5759 4.51384C72.822 4.75991 73.1142 4.95512 73.4357 5.0883C73.7572 5.22147 74.1018 5.29002 74.4498 5.29002V5.29002Z" fill="#2AD168"/>
<path d="M50.5101 5.28C51.9681 5.28 53.1501 4.09803 53.1501 2.64C53.1501 1.18197 51.9681 0 50.5101 0C49.0521 0 47.8701 1.18197 47.8701 2.64C47.8701 4.09803 49.0521 5.28 50.5101 5.28Z" fill="#2AD168"/>
<path d="M27.592 4.97745C28.9406 4.42301 29.5843 2.88036 29.0298 1.53186C28.4754 0.183354 26.9328 -0.460315 25.5843 0.0941215C24.2358 0.648558 23.592 2.19116 24.1465 3.53966C24.7009 4.88816 26.2435 5.53189 27.592 4.97745Z" fill="#2AD168"/>
<path d="M2.65002 5.29002C3.17414 5.29002 3.68652 5.13461 4.12231 4.84343C4.5581 4.55224 4.89769 4.13838 5.09827 3.65416C5.29884 3.16993 5.3514 2.63708 5.24915 2.12303C5.14689 1.60898 4.89453 1.13677 4.52393 0.766156C4.15332 0.395547 3.68104 0.143187 3.16699 0.0409364C2.65294 -0.0613144 2.12021 -0.00881796 1.63599 0.191754C1.15176 0.392326 0.737841 0.731977 0.446655 1.16777C0.15547 1.60356 0 2.11588 0 2.64C0 3.34282 0.279274 4.01687 0.776245 4.51384C1.27322 5.01081 1.9472 5.29002 2.65002 5.29002V5.29002Z" fill="#2AD168"/>
</g>
<defs>
<clipPath id="clip0_623_24537">
<rect width="148.89" height="90.91" fill="white"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -0,0 +1,44 @@
<svg width="79" height="48" viewBox="0 0 79 48" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_2892_21290)">
<path d="M77.5993 48C78.3729 48 79 47.3759 79 46.6061C79 45.8362 78.3729 45.2122 77.5993 45.2122C76.8256 45.2122 76.1985 45.8362 76.1985 46.6061C76.1985 47.3759 76.8256 48 77.5993 48Z" fill="#F48B7C"/>
<path d="M64.8969 48C65.6705 48 66.2976 47.3759 66.2976 46.6061C66.2976 45.8362 65.6705 45.2122 64.8969 45.2122C64.1232 45.2122 63.4961 45.8362 63.4961 46.6061C63.4961 47.3759 64.1232 48 64.8969 48Z" fill="#F48B7C"/>
<path d="M52.1997 48C52.478 48.0011 52.7504 47.9199 52.9823 47.7668C53.2143 47.6137 53.3953 47.3955 53.5026 47.1399C53.6098 46.8844 53.6384 46.6029 53.5848 46.3311C53.5311 46.0594 53.3976 45.8096 53.2012 45.6134C53.0048 45.4172 52.7542 45.2834 52.4813 45.2289C52.2084 45.1745 51.9255 45.2019 51.6682 45.3077C51.411 45.4134 51.1911 45.5928 51.0363 45.823C50.8816 46.0532 50.799 46.3239 50.799 46.6008C50.7989 46.971 50.9464 47.3261 51.2089 47.5883C51.4715 47.8506 51.8277 47.9986 52.1997 48Z" fill="#F48B7C"/>
<path d="M39.5026 48C39.7807 48 40.0526 47.918 40.2838 47.7642C40.5151 47.6105 40.6952 47.392 40.8017 47.1363C40.9081 46.8806 40.9359 46.5993 40.8816 46.3279C40.8274 46.0565 40.6935 45.8072 40.4969 45.6115C40.3002 45.4158 40.0497 45.2825 39.7769 45.2285C39.5042 45.1746 39.2215 45.2023 38.9645 45.3082C38.7076 45.4141 38.4881 45.5934 38.3335 45.8235C38.179 46.0536 38.0966 46.3241 38.0966 46.6008C38.0966 46.7846 38.1329 46.9666 38.2036 47.1363C38.2742 47.3061 38.3778 47.4603 38.5084 47.5902C38.6389 47.7201 38.7939 47.8232 38.9645 47.8936C39.1351 47.9639 39.318 48 39.5026 48Z" fill="#F48B7C"/>
<path d="M26.8003 48C27.5739 48 28.2011 47.3759 28.2011 46.6061C28.2011 45.8362 27.5739 45.2122 26.8003 45.2122C26.0267 45.2122 25.3995 45.8362 25.3995 46.6061C25.3995 47.3759 26.0267 48 26.8003 48Z" fill="#F48B7C"/>
<path d="M14.6392 47.834C15.3547 47.5412 15.6962 46.7267 15.4021 46.0147C15.1079 45.3027 14.2894 44.9629 13.5739 45.2556C12.8584 45.5483 12.5168 46.3628 12.811 47.0748C13.1052 47.7868 13.9237 48.1267 14.6392 47.834Z" fill="#F48B7C"/>
<path d="M1.40609 45.228C1.12755 45.227 0.855001 45.3083 0.622963 45.4616C0.390924 45.615 0.209877 45.8335 0.102797 46.0893C-0.00428191 46.3452 -0.0325729 46.627 0.0215115 46.8989C0.0755958 47.1708 0.209606 47.4206 0.406567 47.6166C0.603529 47.8126 0.854533 47.9459 1.12778 47.9998C1.40102 48.0536 1.68421 48.0254 1.94135 47.9189C2.19849 47.8123 2.41804 47.6322 2.57214 47.4013C2.72624 47.1704 2.80792 46.8991 2.80687 46.622C2.80547 46.2527 2.65745 45.8989 2.39506 45.6378C2.13267 45.3767 1.77717 45.2294 1.40609 45.228Z" fill="#F48B7C"/>
<path d="M77.5993 36.6956C78.3729 36.6956 79 36.0716 79 35.3017C79 34.5319 78.3729 33.9078 77.5993 33.9078C76.8256 33.9078 76.1985 34.5319 76.1985 35.3017C76.1985 36.0716 76.8256 36.6956 77.5993 36.6956Z" fill="#F48B7C"/>
<path d="M64.8969 36.6956C65.6705 36.6956 66.2976 36.0716 66.2976 35.3017C66.2976 34.5319 65.6705 33.9078 64.8969 33.9078C64.1232 33.9078 63.4961 34.5319 63.4961 35.3017C63.4961 36.0716 64.1232 36.6956 64.8969 36.6956Z" fill="#F48B7C"/>
<path d="M52.1997 36.6957C52.4783 36.6967 52.7509 36.6154 52.9829 36.462C53.215 36.3087 53.396 36.0902 53.5031 35.8343C53.6102 35.5785 53.6385 35.2967 53.5844 35.0248C53.5303 34.7529 53.3963 34.5031 53.1993 34.3071C53.0024 34.1111 52.7513 33.9777 52.478 33.9239C52.2048 33.8701 51.9217 33.8982 51.6645 34.0048C51.4074 34.1114 51.1878 34.2915 51.0337 34.5224C50.8797 34.7533 50.7979 35.0246 50.799 35.3017C50.8004 35.671 50.9484 36.0247 51.2108 36.2858C51.4732 36.5469 51.8287 36.6943 52.1997 36.6957Z" fill="#F48B7C"/>
<path d="M39.5027 36.6957C39.781 36.6957 40.053 36.6135 40.2844 36.4595C40.5157 36.3055 40.6959 36.0866 40.8022 35.8307C40.9085 35.5747 40.936 35.2931 40.8813 35.0215C40.8266 34.75 40.6922 34.5007 40.495 34.3052C40.2978 34.1097 40.0467 33.9769 39.7736 33.9235C39.5005 33.8701 39.2177 33.8986 38.9609 34.0053C38.704 34.112 38.4848 34.2922 38.331 34.523C38.1771 34.7538 38.0955 35.0248 38.0966 35.3017C38.0966 35.4852 38.133 35.6669 38.2037 35.8364C38.2744 36.0058 38.3781 36.1597 38.5087 36.2893C38.6393 36.4188 38.7944 36.5213 38.9649 36.5911C39.1355 36.6608 39.3183 36.6964 39.5027 36.6957Z" fill="#F48B7C"/>
<path d="M26.8003 36.6956C27.5739 36.6956 28.2011 36.0716 28.2011 35.3017C28.2011 34.5319 27.5739 33.9078 26.8003 33.9078C26.0267 33.9078 25.3995 34.5319 25.3995 35.3017C25.3995 36.0716 26.0267 36.6956 26.8003 36.6956Z" fill="#F48B7C"/>
<path d="M14.6405 36.5336C15.356 36.2409 15.6976 35.4264 15.4034 34.7144C15.1092 34.0024 14.2907 33.6625 13.5752 33.9552C12.8597 34.248 12.5181 35.0625 12.8123 35.7745C13.1065 36.4865 13.925 36.8264 14.6405 36.5336Z" fill="#F48B7C"/>
<path d="M1.40609 36.6957C1.68441 36.6957 1.95646 36.6135 2.1878 36.4595C2.41914 36.3055 2.59937 36.0866 2.70563 35.8307C2.8119 35.5747 2.83947 35.2931 2.78478 35.0215C2.7301 34.75 2.5956 34.5007 2.39843 34.3052C2.20126 34.1097 1.95026 33.9769 1.67716 33.9235C1.40406 33.8701 1.12119 33.8986 0.864361 34.0053C0.607529 34.112 0.388273 34.2922 0.234411 34.523C0.0805501 34.7538 -0.00104025 35.0248 1.00134e-05 35.3017C8.6905e-06 35.4852 0.0364124 35.6669 0.107139 35.8364C0.177866 36.0058 0.281568 36.1597 0.412204 36.2893C0.54284 36.4188 0.69788 36.5213 0.868442 36.5911C1.039 36.6608 1.2217 36.6964 1.40609 36.6957Z" fill="#F48B7C"/>
<path d="M77.5993 25.3913C78.3729 25.3913 79 24.7672 79 23.9974C79 23.2275 78.3729 22.6035 77.5993 22.6035C76.8256 22.6035 76.1985 23.2275 76.1985 23.9974C76.1985 24.7672 76.8256 25.3913 77.5993 25.3913Z" fill="#F48B7C"/>
<path d="M64.8969 25.3913C65.6705 25.3913 66.2976 24.7672 66.2976 23.9974C66.2976 23.2275 65.6705 22.6035 64.8969 22.6035C64.1232 22.6035 63.4961 23.2275 63.4961 23.9974C63.4961 24.7672 64.1232 25.3913 64.8969 25.3913Z" fill="#F48B7C"/>
<path d="M52.1997 25.3966C52.478 25.3976 52.7504 25.3165 52.9823 25.1634C53.2143 25.0103 53.3953 24.7921 53.5026 24.5365C53.6098 24.2809 53.6384 23.9994 53.5848 23.7277C53.5311 23.4559 53.3976 23.2061 53.2012 23.0099C53.0048 22.8137 52.7542 22.6799 52.4813 22.6255C52.2084 22.5711 51.9255 22.5985 51.6682 22.7042C51.411 22.81 51.1911 22.9893 51.0363 23.2195C50.8816 23.4497 50.799 23.7204 50.799 23.9974C50.7989 24.3676 50.9464 24.7226 51.2089 24.9849C51.4715 25.2471 51.8277 25.3952 52.1997 25.3966Z" fill="#F48B7C"/>
<path d="M39.5026 25.3966C39.7807 25.3966 40.0526 25.3145 40.2838 25.1608C40.5151 25.007 40.6952 24.7885 40.8017 24.5328C40.9081 24.2772 40.9359 23.9958 40.8816 23.7244C40.8274 23.453 40.6935 23.2037 40.4969 23.008C40.3002 22.8123 40.0497 22.6791 39.7769 22.6251C39.5042 22.5711 39.2215 22.5988 38.9645 22.7047C38.7076 22.8106 38.4881 22.99 38.3335 23.22C38.179 23.4501 38.0966 23.7206 38.0966 23.9974C38.0966 24.1811 38.1329 24.3631 38.2036 24.5328C38.2742 24.7026 38.3778 24.8568 38.5084 24.9868C38.6389 25.1167 38.7939 25.2198 38.9645 25.2901C39.1351 25.3604 39.318 25.3966 39.5026 25.3966Z" fill="#F48B7C"/>
<path d="M26.8003 25.3913C27.5739 25.3913 28.2011 24.7672 28.2011 23.9974C28.2011 23.2275 27.5739 22.6035 26.8003 22.6035C26.0267 22.6035 25.3995 23.2275 25.3995 23.9974C25.3995 24.7672 26.0267 25.3913 26.8003 25.3913Z" fill="#F48B7C"/>
<path d="M14.6397 25.2337C15.3552 24.9409 15.6967 24.1264 15.4025 23.4144C15.1084 22.7024 14.2899 22.3626 13.5744 22.6553C12.8588 22.948 12.5173 23.7625 12.8115 24.4745C13.1056 25.1865 13.9242 25.5264 14.6397 25.2337Z" fill="#F48B7C"/>
<path d="M1.40608 25.3966C1.68418 25.3966 1.95604 25.3145 2.18727 25.1608C2.4185 25.007 2.59868 24.7885 2.70511 24.5328C2.81153 24.2772 2.83941 23.9958 2.78516 23.7244C2.73091 23.453 2.59701 23.2037 2.40036 23.008C2.20372 22.8123 1.95314 22.6791 1.68038 22.6251C1.40763 22.5711 1.12497 22.5988 0.868043 22.7047C0.611117 22.8106 0.391493 22.99 0.236992 23.22C0.0824911 23.4501 0 23.7206 0 23.9974C0 24.3685 0.148181 24.7244 0.41187 24.9868C0.67556 25.2492 1.03317 25.3966 1.40608 25.3966Z" fill="#F48B7C"/>
<path d="M77.5993 14.0922C78.3729 14.0922 79 13.4681 79 12.6983C79 11.9285 78.3729 11.3044 77.5993 11.3044C76.8256 11.3044 76.1985 11.9285 76.1985 12.6983C76.1985 13.4681 76.8256 14.0922 77.5993 14.0922Z" fill="#F48B7C"/>
<path d="M64.8969 14.0922C65.6705 14.0922 66.2976 13.4681 66.2976 12.6983C66.2976 11.9285 65.6705 11.3044 64.8969 11.3044C64.1232 11.3044 63.4961 11.9285 63.4961 12.6983C63.4961 13.4681 64.1232 14.0922 64.8969 14.0922Z" fill="#F48B7C"/>
<path d="M52.1997 14.0763C52.4783 14.0774 52.7509 13.9961 52.9829 13.8427C53.215 13.6894 53.396 13.4709 53.5031 13.215C53.6102 12.9591 53.6385 12.6774 53.5844 12.4055C53.5303 12.1336 53.3963 11.8838 53.1993 11.6878C53.0024 11.4918 52.7513 11.3584 52.478 11.3046C52.2048 11.2508 51.9217 11.2789 51.6645 11.3855C51.4074 11.492 51.1878 11.6722 51.0337 11.9031C50.8797 12.134 50.7979 12.4052 50.799 12.6824C50.8004 13.0517 50.9484 13.4054 51.2108 13.6665C51.4732 13.9276 51.8287 14.0749 52.1997 14.0763Z" fill="#F48B7C"/>
<path d="M39.5027 14.0763C39.781 14.0763 40.053 13.9941 40.2844 13.8401C40.5157 13.6862 40.6959 13.4674 40.8022 13.2114C40.9085 12.9554 40.936 12.6738 40.8813 12.4022C40.8266 12.1307 40.6922 11.8814 40.495 11.6859C40.2978 11.4904 40.0467 11.3576 39.7736 11.3042C39.5005 11.2508 39.2177 11.2793 38.9609 11.386C38.704 11.4927 38.4848 11.6728 38.331 11.9036C38.1771 12.1344 38.0955 12.4055 38.0966 12.6824C38.0966 12.8659 38.133 13.0476 38.2037 13.2171C38.2744 13.3865 38.3781 13.5404 38.5087 13.6699C38.6393 13.7994 38.7944 13.902 38.9649 13.9718C39.1355 14.0415 39.3183 14.077 39.5027 14.0763Z" fill="#F48B7C"/>
<path d="M26.8003 14.0922C27.5739 14.0922 28.2011 13.4681 28.2011 12.6983C28.2011 11.9285 27.5739 11.3044 26.8003 11.3044C26.0267 11.3044 25.3995 11.9285 25.3995 12.6983C25.3995 13.4681 26.0267 14.0922 26.8003 14.0922Z" fill="#F48B7C"/>
<path d="M14.641 13.9333C15.3565 13.6406 15.6981 12.826 15.4039 12.114C15.1097 11.402 14.2912 11.0622 13.5757 11.3549C12.8602 11.6476 12.5186 12.4621 12.8128 13.1741C13.107 13.8862 13.9255 14.226 14.641 13.9333Z" fill="#F48B7C"/>
<path d="M1.40609 14.0763C1.68441 14.0763 1.95646 13.9941 2.1878 13.8401C2.41914 13.6862 2.59937 13.4674 2.70563 13.2114C2.8119 12.9554 2.83947 12.6738 2.78478 12.4022C2.7301 12.1307 2.5956 11.8814 2.39843 11.6859C2.20126 11.4904 1.95026 11.3576 1.67716 11.3042C1.40406 11.2508 1.12119 11.2793 0.864361 11.386C0.607529 11.4927 0.388273 11.6728 0.234411 11.9036C0.0805501 12.1344 -0.00104025 12.4055 1.00134e-05 12.6824C8.6905e-06 12.8659 0.0364124 13.0476 0.107139 13.2171C0.177866 13.3865 0.281568 13.5404 0.412204 13.6699C0.54284 13.7994 0.69788 13.902 0.868442 13.9718C1.039 14.0415 1.2217 14.077 1.40609 14.0763Z" fill="#F48B7C"/>
<path d="M77.5993 2.78781C78.3729 2.78781 79 2.16374 79 1.39391C79 0.624073 78.3729 0 77.5993 0C76.8256 0 76.1985 0.624073 76.1985 1.39391C76.1985 2.16374 76.8256 2.78781 77.5993 2.78781Z" fill="#F48B7C"/>
<path d="M64.8969 2.78781C65.6705 2.78781 66.2976 2.16374 66.2976 1.39391C66.2976 0.624073 65.6705 0 64.8969 0C64.1232 0 63.4961 0.624073 63.4961 1.39391C63.4961 2.16374 64.1232 2.78781 64.8969 2.78781Z" fill="#F48B7C"/>
<path d="M52.1997 2.79313C52.478 2.79417 52.7504 2.71301 52.9823 2.55991C53.2143 2.4068 53.3953 2.18861 53.5026 1.93304C53.6098 1.67747 53.6384 1.39599 53.5848 1.12423C53.5311 0.852464 53.3976 0.60266 53.2012 0.406451C53.0048 0.210243 52.7542 0.0764418 52.4813 0.0220246C52.2084 -0.0323926 51.9255 -0.00499087 51.6682 0.100753C51.411 0.206497 51.1911 0.385843 51.0363 0.616051C50.8816 0.846259 50.799 1.11697 50.799 1.39393C50.7989 1.7641 50.9464 2.11919 51.2089 2.38144C51.4715 2.64368 51.8277 2.79173 52.1997 2.79313Z" fill="#F48B7C"/>
<path d="M39.5026 2.79312C39.7807 2.79312 40.0526 2.71107 40.2838 2.55732C40.5151 2.40358 40.6952 2.18506 40.8017 1.9294C40.9081 1.67373 40.9359 1.39238 40.8816 1.12097C40.8274 0.849553 40.6935 0.600226 40.4969 0.404546C40.3002 0.208867 40.0497 0.0756221 39.7769 0.0216342C39.5042 -0.0323537 39.2215 -0.00463587 38.9645 0.101265C38.7076 0.207166 38.4881 0.3865 38.3335 0.616595C38.179 0.84669 38.0966 1.11719 38.0966 1.39392C38.0966 1.57767 38.1329 1.75964 38.2036 1.9294C38.2742 2.09915 38.3778 2.25338 38.5084 2.3833C38.6389 2.51323 38.7939 2.6163 38.9645 2.68662C39.1351 2.75693 39.318 2.79312 39.5026 2.79312Z" fill="#F48B7C"/>
<path d="M26.8003 2.78781C27.5739 2.78781 28.2011 2.16374 28.2011 1.39391C28.2011 0.624073 27.5739 0 26.8003 0C26.0267 0 25.3995 0.624073 25.3995 1.39391C25.3995 2.16374 26.0267 2.78781 26.8003 2.78781Z" fill="#F48B7C"/>
<path d="M14.6403 2.62809C15.3558 2.33535 15.6973 1.52084 15.4032 0.808835C15.109 0.096833 14.2905 -0.243021 13.575 0.0497186C12.8595 0.342458 12.5179 1.15694 12.8121 1.86894C13.1062 2.58095 13.9248 2.92083 14.6403 2.62809Z" fill="#F48B7C"/>
<path d="M1.40608 2.79312C1.68418 2.79312 1.95604 2.71107 2.18727 2.55732C2.4185 2.40358 2.59868 2.18506 2.70511 1.9294C2.81153 1.67373 2.83941 1.39238 2.78516 1.12097C2.73091 0.849553 2.59701 0.600226 2.40036 0.404546C2.20372 0.208867 1.95314 0.0756221 1.68038 0.0216342C1.40763 -0.0323537 1.12497 -0.00463587 0.868043 0.101265C0.611117 0.207166 0.391493 0.3865 0.236992 0.616595C0.0824911 0.84669 0 1.11719 0 1.39392C0 1.76501 0.148181 2.1209 0.41187 2.3833C0.67556 2.6457 1.03317 2.79312 1.40608 2.79312Z" fill="#F48B7C"/>
</g>
<defs>
<clipPath id="clip0_2892_21290">
<rect width="79" height="48" fill="white"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -0,0 +1,44 @@
<svg width="149" height="91" viewBox="0 0 149 91" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_627_14183)">
<path d="M146.25 90.91C147.708 90.91 148.89 89.728 148.89 88.27C148.89 86.812 147.708 85.63 146.25 85.63C144.792 85.63 143.61 86.812 143.61 88.27C143.61 89.728 144.792 90.91 146.25 90.91Z" fill="#A855F7"/>
<path d="M122.31 90.91C123.768 90.91 124.95 89.728 124.95 88.27C124.95 86.812 123.768 85.63 122.31 85.63C120.852 85.63 119.67 86.812 119.67 88.27C119.67 89.728 120.852 90.91 122.31 90.91Z" fill="#A855F7"/>
<path d="M98.3799 90.91C98.9045 90.912 99.4178 90.7583 99.8549 90.4683C100.292 90.1783 100.633 89.7651 100.835 89.281C101.037 88.797 101.091 88.2639 100.99 87.7492C100.889 87.2345 100.638 86.7613 100.267 86.3897C99.8972 86.0181 99.425 85.7647 98.9107 85.6616C98.3964 85.5586 97.863 85.6105 97.3782 85.8107C96.8934 86.011 96.4789 86.3507 96.1873 86.7867C95.8957 87.2227 95.7399 87.7354 95.7399 88.26C95.7399 88.9611 96.0178 89.6336 96.5126 90.1303C97.0074 90.627 97.6789 90.9073 98.3799 90.91Z" fill="#A855F7"/>
<path d="M74.45 90.91C74.9741 90.91 75.4865 90.7546 75.9223 90.4634C76.3581 90.1722 76.6977 89.7583 76.8983 89.2741C77.0988 88.7899 77.1513 88.257 77.049 87.743C76.9468 87.2289 76.6944 86.7568 76.3238 86.3862C75.9532 86.0156 75.481 85.7632 74.967 85.6609C74.4529 85.5587 73.9201 85.6111 73.4359 85.8117C72.9516 86.0123 72.5378 86.3519 72.2466 86.7877C71.9555 87.2235 71.8 87.7358 71.8 88.26C71.8 88.608 71.8685 88.9526 72.0016 89.2741C72.1348 89.5956 72.33 89.8877 72.5761 90.1338C72.8222 90.3799 73.1143 90.5752 73.4359 90.7083C73.7574 90.8415 74.102 90.91 74.45 90.91Z" fill="#A855F7"/>
<path d="M50.51 90.91C51.968 90.91 53.15 89.728 53.15 88.27C53.15 86.812 51.968 85.63 50.51 85.63C49.052 85.63 47.87 86.812 47.87 88.27C47.87 89.728 49.052 90.91 50.51 90.91Z" fill="#A855F7"/>
<path d="M27.5903 90.5955C28.9388 90.0411 29.5826 88.4984 29.0281 87.1499C28.4737 85.8014 26.9311 85.1577 25.5826 85.7122C24.2341 86.2666 23.5903 87.8092 24.1447 89.1577C24.6992 90.5062 26.2418 91.1499 27.5903 90.5955Z" fill="#A855F7"/>
<path d="M2.64998 85.6601C2.12502 85.6581 1.61135 85.8121 1.17403 86.1025C0.736712 86.3929 0.395495 86.8067 0.193685 87.2913C-0.00812604 87.776 -0.0614455 88.3096 0.0404863 88.8246C0.142418 89.3396 0.394984 89.8126 0.766194 90.1839C1.1374 90.5551 1.61047 90.8076 2.12545 90.9096C2.64043 91.0115 3.17414 90.9582 3.65877 90.7564C4.1434 90.5546 4.55719 90.2134 4.84762 89.7761C5.13804 89.3388 5.29198 88.825 5.29 88.3001C5.28736 87.6007 5.0084 86.9307 4.51388 86.4362C4.01935 85.9416 3.34934 85.6627 2.64998 85.6601Z" fill="#A855F7"/>
<path d="M146.25 69.5C147.708 69.5 148.89 68.318 148.89 66.86C148.89 65.4019 147.708 64.22 146.25 64.22C144.792 64.22 143.61 65.4019 143.61 66.86C143.61 68.318 144.792 69.5 146.25 69.5Z" fill="#A855F7"/>
<path d="M122.31 69.5C123.768 69.5 124.95 68.318 124.95 66.86C124.95 65.4019 123.768 64.22 122.31 64.22C120.852 64.22 119.67 65.4019 119.67 66.86C119.67 68.318 120.852 69.5 122.31 69.5Z" fill="#A855F7"/>
<path d="M98.38 69.5001C98.9049 69.5021 99.4187 69.3481 99.856 69.0576C100.293 68.7672 100.635 68.3534 100.836 67.8688C101.038 67.3842 101.092 66.8505 100.99 66.3355C100.888 65.8206 100.635 65.3474 100.264 64.9762C99.8927 64.605 99.4195 64.3524 98.9045 64.2505C98.3895 64.1486 97.8559 64.2019 97.3713 64.4037C96.8867 64.6055 96.4729 64.9467 96.1825 65.3841C95.892 65.8214 95.738 66.3351 95.7399 66.8601C95.7426 67.5594 96.0217 68.2294 96.5162 68.7239C97.0107 69.2184 97.6806 69.4974 98.38 69.5001Z" fill="#A855F7"/>
<path d="M74.45 69.5001C74.9746 69.5001 75.4873 69.3444 75.9233 69.0528C76.3593 68.7611 76.699 68.3466 76.8993 67.8618C77.0995 67.377 77.1514 66.8437 77.0483 66.3294C76.9452 65.815 76.6919 65.3429 76.3203 64.9727C75.9487 64.6025 75.4755 64.3509 74.9608 64.2498C74.4461 64.1487 73.913 64.2026 73.4289 64.4047C72.9449 64.6068 72.5318 64.948 72.2418 65.3851C71.9518 65.8222 71.798 66.3355 71.8 66.8601C71.8 67.2076 71.8686 67.5517 72.0019 67.8726C72.1352 68.1936 72.3305 68.4851 72.5767 68.7304C72.8229 68.9756 73.1151 69.1699 73.4366 69.302C73.7581 69.434 74.1025 69.5014 74.45 69.5001Z" fill="#A855F7"/>
<path d="M50.51 69.5C51.968 69.5 53.15 68.318 53.15 66.86C53.15 65.4019 51.968 64.22 50.51 64.22C49.052 64.22 47.87 65.4019 47.87 66.86C47.87 68.318 49.052 69.5 50.51 69.5Z" fill="#A855F7"/>
<path d="M27.5927 69.1932C28.9412 68.6388 29.5849 67.0961 29.0305 65.7476C28.476 64.3991 26.9334 63.7554 25.5849 64.3098C24.2364 64.8643 23.5927 66.4069 24.1471 67.7554C24.7015 69.1039 26.2442 69.7476 27.5927 69.1932Z" fill="#A855F7"/>
<path d="M2.64998 69.5001C3.17453 69.5001 3.68724 69.3444 4.12325 69.0528C4.55925 68.7611 4.89893 68.3466 5.0992 67.8618C5.29948 67.377 5.35144 66.8437 5.24837 66.3294C5.14531 65.815 4.89183 65.3429 4.52022 64.9727C4.14861 64.6025 3.67555 64.3509 3.16085 64.2498C2.64614 64.1487 2.11303 64.2026 1.62899 64.4047C1.14494 64.6068 0.73171 64.948 0.44173 65.3851C0.15175 65.8222 -0.00202158 66.3355 -4.21631e-05 66.8601C-4.46563e-05 67.2076 0.0685648 67.5517 0.201862 67.8726C0.335159 68.1936 0.530606 68.4851 0.776813 68.7304C1.02302 68.9756 1.31522 69.1699 1.63668 69.302C1.95813 69.434 2.30245 69.5014 2.64998 69.5001Z" fill="#A855F7"/>
<path d="M146.25 48.0901C147.708 48.0901 148.89 46.9081 148.89 45.4501C148.89 43.992 147.708 42.8101 146.25 42.8101C144.792 42.8101 143.61 43.992 143.61 45.4501C143.61 46.9081 144.792 48.0901 146.25 48.0901Z" fill="#A855F7"/>
<path d="M122.31 48.0901C123.768 48.0901 124.95 46.9081 124.95 45.4501C124.95 43.992 123.768 42.8101 122.31 42.8101C120.852 42.8101 119.67 43.992 119.67 45.4501C119.67 46.9081 120.852 48.0901 122.31 48.0901Z" fill="#A855F7"/>
<path d="M98.3799 48.1001C98.9045 48.102 99.4178 47.9483 99.8549 47.6583C100.292 47.3684 100.633 46.9551 100.835 46.4711C101.037 45.987 101.091 45.4539 100.99 44.9392C100.889 44.4245 100.638 43.9514 100.267 43.5798C99.8972 43.2082 99.425 42.9548 98.9107 42.8517C98.3964 42.7486 97.863 42.8005 97.3782 43.0008C96.8934 43.2011 96.4789 43.5408 96.1873 43.9768C95.8957 44.4128 95.7399 44.9255 95.7399 45.45C95.7399 46.1511 96.0178 46.8236 96.5126 47.3203C97.0074 47.817 97.6789 48.0974 98.3799 48.1001Z" fill="#A855F7"/>
<path d="M74.45 48.1C74.9741 48.1 75.4865 47.9446 75.9223 47.6535C76.3581 47.3623 76.6977 46.9484 76.8983 46.4642C77.0988 45.98 77.1513 45.4471 77.049 44.9331C76.9468 44.419 76.6944 43.9468 76.3238 43.5762C75.9532 43.2056 75.481 42.9532 74.967 42.851C74.4529 42.7487 73.9201 42.8012 73.4359 43.0018C72.9516 43.2024 72.5378 43.542 72.2466 43.9778C71.9555 44.4136 71.8 44.9259 71.8 45.45C71.8 45.798 71.8685 46.1427 72.0016 46.4642C72.1348 46.7857 72.33 47.0778 72.5761 47.3239C72.8222 47.5699 73.1143 47.7652 73.4359 47.8983C73.7574 48.0315 74.102 48.1 74.45 48.1Z" fill="#A855F7"/>
<path d="M50.51 48.0901C51.968 48.0901 53.15 46.9081 53.15 45.4501C53.15 43.992 51.968 42.8101 50.51 42.8101C49.052 42.8101 47.87 43.992 47.87 45.4501C47.87 46.9081 49.052 48.0901 50.51 48.0901Z" fill="#A855F7"/>
<path d="M27.5913 47.7915C28.9398 47.2371 29.5835 45.6944 29.029 44.3459C28.4746 42.9974 26.932 42.3538 25.5835 42.9082C24.235 43.4626 23.5912 45.0052 24.1457 46.3537C24.7001 47.7022 26.2428 48.346 27.5913 47.7915Z" fill="#A855F7"/>
<path d="M2.64996 48.1C3.17408 48.1 3.68646 47.9446 4.12225 47.6535C4.55804 47.3623 4.89763 46.9484 5.09821 46.4642C5.29878 45.98 5.35134 45.4471 5.24908 44.9331C5.14683 44.419 4.89447 43.9468 4.52386 43.5762C4.15326 43.2056 3.68098 42.9532 3.16693 42.851C2.65288 42.7487 2.12015 42.8012 1.63593 43.0018C1.1517 43.2024 0.73778 43.542 0.446594 43.9778C0.155409 44.4136 -6.10352e-05 44.9259 -6.10352e-05 45.45C-6.10352e-05 46.1528 0.279213 46.8269 0.776184 47.3239C1.27316 47.8208 1.94714 48.1 2.64996 48.1Z" fill="#A855F7"/>
<path d="M146.25 26.69C147.708 26.69 148.89 25.5081 148.89 24.05C148.89 22.592 147.708 21.41 146.25 21.41C144.792 21.41 143.61 22.592 143.61 24.05C143.61 25.5081 144.792 26.69 146.25 26.69Z" fill="#A855F7"/>
<path d="M122.31 26.69C123.768 26.69 124.95 25.5081 124.95 24.05C124.95 22.592 123.768 21.41 122.31 21.41C120.852 21.41 119.67 22.592 119.67 24.05C119.67 25.5081 120.852 26.69 122.31 26.69Z" fill="#A855F7"/>
<path d="M98.38 26.66C98.9049 26.662 99.4187 26.508 99.856 26.2175C100.293 25.9271 100.635 25.5133 100.836 25.0287C101.038 24.5441 101.092 24.0104 100.99 23.4954C100.888 22.9805 100.635 22.5074 100.264 22.1362C99.8927 21.765 99.4195 21.5124 98.9045 21.4104C98.3895 21.3085 97.8559 21.3618 97.3713 21.5636C96.8867 21.7654 96.4729 22.1066 96.1825 22.544C95.892 22.9813 95.738 23.495 95.7399 24.02C95.7426 24.7193 96.0217 25.3893 96.5162 25.8839C97.0107 26.3784 97.6806 26.6574 98.38 26.66Z" fill="#A855F7"/>
<path d="M74.45 26.66C74.9746 26.66 75.4873 26.5043 75.9233 26.2127C76.3593 25.921 76.699 25.5066 76.8993 25.0218C77.0995 24.537 77.1514 24.0037 77.0483 23.4893C76.9452 22.975 76.6919 22.5029 76.3203 22.1327C75.9487 21.7624 75.4755 21.5108 74.9608 21.4097C74.4461 21.3086 73.913 21.3625 73.4289 21.5646C72.9449 21.7667 72.5318 22.1079 72.2418 22.545C71.9518 22.9821 71.798 23.4954 71.8 24.02C71.8 24.3675 71.8686 24.7117 72.0019 25.0326C72.1352 25.3536 72.3305 25.645 72.5767 25.8903C72.8229 26.1356 73.1151 26.3299 73.4366 26.4619C73.7581 26.594 74.1025 26.6613 74.45 26.66Z" fill="#A855F7"/>
<path d="M50.51 26.69C51.968 26.69 53.15 25.5081 53.15 24.05C53.15 22.592 51.968 21.41 50.51 21.41C49.052 21.41 47.87 22.592 47.87 24.05C47.87 25.5081 49.052 26.69 50.51 26.69Z" fill="#A855F7"/>
<path d="M27.5937 26.3891C28.9422 25.8347 29.5859 24.292 29.0315 22.9435C28.477 21.595 26.9344 20.9513 25.5859 21.5057C24.2374 22.0602 23.5936 23.6028 24.1481 24.9513C24.7025 26.2998 26.2452 26.9436 27.5937 26.3891Z" fill="#A855F7"/>
<path d="M2.64998 26.66C3.17453 26.66 3.68724 26.5043 4.12325 26.2127C4.55925 25.921 4.89893 25.5066 5.0992 25.0218C5.29948 24.537 5.35144 24.0037 5.24837 23.4893C5.14531 22.975 4.89183 22.5029 4.52022 22.1327C4.14861 21.7624 3.67555 21.5108 3.16085 21.4097C2.64614 21.3086 2.11303 21.3625 1.62899 21.5646C1.14494 21.7667 0.73171 22.1079 0.44173 22.545C0.15175 22.9821 -0.00202158 23.4954 -4.21631e-05 24.02C-4.46563e-05 24.3675 0.0685648 24.7117 0.201862 25.0326C0.335159 25.3536 0.530606 25.645 0.776813 25.8903C1.02302 26.1356 1.31522 26.3299 1.63668 26.4619C1.95813 26.594 2.30245 26.6613 2.64998 26.66Z" fill="#A855F7"/>
<path d="M146.25 5.28C147.708 5.28 148.89 4.09803 148.89 2.64C148.89 1.18197 147.708 0 146.25 0C144.792 0 143.61 1.18197 143.61 2.64C143.61 4.09803 144.792 5.28 146.25 5.28Z" fill="#A855F7"/>
<path d="M122.31 5.28C123.768 5.28 124.95 4.09803 124.95 2.64C124.95 1.18197 123.768 0 122.31 0C120.852 0 119.67 1.18197 119.67 2.64C119.67 4.09803 120.852 5.28 122.31 5.28Z" fill="#A855F7"/>
<path d="M98.3799 5.29C98.9045 5.29198 99.4178 5.13827 99.8549 4.84829C100.292 4.55831 100.633 4.14508 100.835 3.66103C101.037 3.17698 101.091 2.64388 100.99 2.12917C100.889 1.61446 100.638 1.14134 100.267 0.769734C99.8972 0.398123 99.425 0.144709 98.9107 0.0416453C98.3964 -0.0614187 97.863 -0.00952083 97.3782 0.190754C96.8934 0.391029 96.4789 0.730702 96.1873 1.16671C95.8957 1.60271 95.7399 2.11543 95.7399 2.63997C95.7399 3.34107 96.0178 4.01359 96.5126 4.51027C97.0074 5.00696 97.6789 5.28735 98.3799 5.29Z" fill="#A855F7"/>
<path d="M74.45 5.28999C74.9741 5.28999 75.4865 5.13458 75.9223 4.8434C76.3581 4.55221 76.6977 4.13835 76.8983 3.65413C77.0988 3.1699 77.1513 2.63705 77.049 2.123C76.9468 1.60895 76.6944 1.13673 76.3238 0.766126C75.9532 0.395516 75.481 0.143157 74.967 0.0409059C74.4529 -0.061345 73.9201 -0.00884847 73.4359 0.191724C72.9516 0.392296 72.5378 0.731947 72.2466 1.16774C71.9555 1.60353 71.8 2.11585 71.8 2.63997C71.8 2.98797 71.8685 3.33261 72.0016 3.65413C72.1348 3.97564 72.33 4.26773 72.5761 4.51381C72.8222 4.75988 73.1143 4.95509 73.4359 5.08827C73.7574 5.22144 74.102 5.28999 74.45 5.28999Z" fill="#A855F7"/>
<path d="M50.51 5.28C51.968 5.28 53.15 4.09803 53.15 2.64C53.15 1.18197 51.968 0 50.51 0C49.052 0 47.87 1.18197 47.87 2.64C47.87 4.09803 49.052 5.28 50.51 5.28Z" fill="#A855F7"/>
<path d="M27.5922 4.97745C28.9407 4.42301 29.5844 2.88036 29.03 1.53186C28.4755 0.183354 26.9329 -0.460315 25.5844 0.0941215C24.2359 0.648558 23.5921 2.19116 24.1466 3.53966C24.701 4.88816 26.2437 5.53189 27.5922 4.97745Z" fill="#A855F7"/>
<path d="M2.64996 5.28999C3.17408 5.28999 3.68646 5.13458 4.12225 4.8434C4.55804 4.55221 4.89763 4.13835 5.09821 3.65413C5.29878 3.1699 5.35134 2.63705 5.24908 2.123C5.14683 1.60895 4.89447 1.13673 4.52386 0.766126C4.15326 0.395516 3.68098 0.143157 3.16693 0.0409059C2.65288 -0.061345 2.12015 -0.00884847 1.63593 0.191724C1.1517 0.392296 0.73778 0.731947 0.446594 1.16774C0.155409 1.60353 -6.10352e-05 2.11585 -6.10352e-05 2.63997C-6.10352e-05 3.34279 0.279213 4.01683 0.776184 4.51381C1.27316 5.01078 1.94714 5.28999 2.64996 5.28999Z" fill="#A855F7"/>
</g>
<defs>
<clipPath id="clip0_627_14183">
<rect width="148.89" height="90.91" fill="white"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -0,0 +1,25 @@
<svg width="164" height="160" viewBox="0 0 164 160" fill="none" xmlns="http://www.w3.org/2000/svg">
<mask id="mask0_623_24480" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="4" y="0" width="279" height="279">
<circle cx="143.5" cy="139.5" r="137.576" fill="#C4C4C4" stroke="#F8BB54" stroke-width="3.84828"/>
</mask>
<g mask="url(#mask0_623_24480)">
<path d="M-77.0708 58.5036C-77.0708 58.5036 -12.1115 46.4704 4.64888 4.35483C20.6779 -36.0177 86.7061 -46.8696 86.7061 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 78.7456C-77.0708 78.7456 2.62416 64.8573 23.1525 14.0263C42.7247 -34.4995 123.657 -46.8696 123.657 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 99.0445C-77.0708 99.0445 17.3033 83.2442 41.5999 23.8102C64.7716 -33.0373 160.608 -46.8696 160.608 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 119.287C-77.0708 119.287 32.0387 101.631 60.1035 33.4816C86.8185 -31.5191 197.559 -46.8696 197.559 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 139.53C-77.0708 139.53 46.7742 120.018 78.6072 43.2091C108.865 -30.0009 234.454 -46.8696 234.454 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 159.828C-77.0708 159.828 61.4533 138.461 97.0546 52.9366C130.968 -28.5391 271.405 -46.8696 271.405 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 180.07C-77.0708 180.07 76.1887 156.792 115.558 62.6644C153.015 -27.0209 308.356 -46.8696 308.356 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 200.313C-77.0708 200.313 90.9243 175.178 134.005 72.3359C175.062 -25.5027 345.307 -46.8696 345.307 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 220.612C-77.0708 220.612 105.603 193.622 152.509 82.1194C197.109 -24.0409 382.202 -46.8696 382.202 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 240.853C-77.0708 240.853 120.339 212.009 170.957 91.8473C219.156 -22.5227 419.153 -46.8696 419.153 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 261.152C-77.0708 261.152 135.074 230.395 189.46 101.575C241.203 -21.0045 456.104 -46.8696 456.104 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 281.396C-77.0708 281.396 149.753 248.783 207.908 111.303C263.25 -19.5423 493.054 -46.8696 493.054 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 301.636C-77.0708 301.636 164.489 267.17 226.411 120.974C285.297 -18.0241 530.005 -46.8696 530.005 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 321.935C-77.0708 321.935 179.224 285.557 244.915 130.758C307.343 -16.5059 566.901 -46.8696 566.901 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 342.179C-77.0708 342.179 193.903 303.943 263.362 140.429C329.391 -15.0441 603.852 -46.8696 603.852 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 362.423C-77.0708 362.423 208.639 322.33 281.866 150.157C351.437 -13.5259 640.803 -46.8696 640.803 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 382.722C-77.0708 382.722 223.374 340.772 300.313 159.884C373.484 -12.0077 677.753 -46.8696 677.753 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-77.0708 402.962C-77.0708 402.962 238.053 359.104 318.817 169.612C395.531 -10.546 714.65 -46.8696 714.65 -46.8696" stroke="#EF5944" stroke-width="4.32558" stroke-miterlimit="10"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@@ -0,0 +1,22 @@
<svg width="160" height="160" viewBox="0 0 160 160" fill="none" xmlns="http://www.w3.org/2000/svg">
<mask id="mask0_623_24459" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="-119" y="-119" width="279" height="279">
<circle cx="20.5" cy="20.5" r="137.576" fill="#C4C4C4" stroke="#F8BB54" stroke-width="3.84828"/>
</mask>
<g mask="url(#mask0_623_24459)">
<path d="M-200.071 0.287015C-200.071 0.287015 -90.9613 -17.3688 -62.8965 -85.5184C-36.1815 -150.519 74.5591 -165.87 74.5591 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 20.5295C-200.071 20.5295 -76.2258 1.01813 -44.3928 -75.7909C-14.1348 -149.001 111.454 -165.87 111.454 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 40.828C-200.071 40.828 -61.5467 19.461 -25.9454 -66.0635C7.96833 -147.539 148.405 -165.87 148.405 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 61.0704C-200.071 61.0704 -46.8113 37.7915 -7.44177 -56.3356C30.0154 -146.021 185.356 -165.87 185.356 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 81.3129C-200.071 81.3129 -32.0757 56.1785 11.0054 -46.6641C52.0621 -144.503 222.307 -165.87 222.307 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 101.612C-200.071 101.612 -17.3968 74.6219 29.5091 -36.8806C74.1093 -143.041 259.202 -165.87 259.202 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 121.853C-200.071 121.853 -2.66112 93.0088 47.9568 -27.1527C96.156 -141.523 296.153 -165.87 296.153 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 142.152C-200.071 142.152 12.0741 111.395 66.4604 -17.4253C118.203 -140.005 333.104 -165.87 333.104 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 162.396C-200.071 162.396 26.7534 129.783 84.9076 -7.69737C140.25 -138.542 370.054 -165.87 370.054 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 182.636C-200.071 182.636 41.4887 148.17 103.411 1.97366C162.297 -137.024 407.005 -165.87 407.005 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 202.935C-200.071 202.935 56.2243 166.557 121.915 11.7576C184.343 -135.506 443.901 -165.87 443.901 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 223.179C-200.071 223.179 70.9033 184.943 140.362 21.429C206.391 -134.044 480.852 -165.87 480.852 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 243.423C-200.071 243.423 85.639 203.33 158.866 31.1565C228.437 -132.526 517.803 -165.87 517.803 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 263.722C-200.071 263.722 100.374 221.772 177.313 40.8844C250.484 -131.008 554.753 -165.87 554.753 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
<path d="M-200.071 283.962C-200.071 283.962 115.053 240.104 195.817 50.6119C272.531 -129.546 591.65 -165.87 591.65 -165.87" stroke="#F59E0B" stroke-width="4.32558" stroke-miterlimit="10"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.2 KiB

View File

@@ -0,0 +1,7 @@
<svg width="616" height="220" viewBox="0 0 616 220" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M615.24 218.233V219.948H538.078C538.078 234.694 520.93 246.697 499.668 246.697C478.405 246.697 461.258 234.694 461.258 219.948H384.439C384.439 234.694 367.292 246.697 346.029 246.697C324.767 246.697 307.62 234.694 307.62 219.948H230.801C230.801 234.694 213.653 246.697 192.391 246.697C171.129 246.697 153.981 234.694 153.981 219.948H76.8192C76.8192 234.694 59.6721 246.697 38.4096 246.697C17.1472 246.697 0 234.694 0 219.948H76.8192V218.233C76.8192 203.486 94.3093 191.484 115.572 191.484C136.834 191.484 153.981 203.486 153.981 218.233V219.948H230.801V218.233C230.801 203.486 247.948 191.484 269.21 191.484C290.473 191.484 307.62 203.486 307.62 218.233V219.948H384.439V218.233C384.439 203.486 401.586 191.484 422.849 191.484C444.111 191.484 461.258 203.486 461.258 218.233V219.948H538.078V218.233C538.078 203.486 555.568 191.484 576.83 191.484C598.093 191.484 615.24 203.486 615.24 218.233Z" fill="black" fill-opacity="0.05"/>
<path d="M615.24 163.362V165.077H538.078C538.078 179.823 520.93 191.826 499.668 191.826C478.405 191.826 461.258 179.823 461.258 165.077H384.439C384.439 179.823 367.292 191.826 346.029 191.826C324.767 191.826 307.62 179.823 307.62 165.077H230.801C230.801 179.823 213.653 191.826 192.391 191.826C171.129 191.826 153.981 179.823 153.981 165.077H76.8192C76.8192 179.823 59.6721 191.826 38.4096 191.826C17.1472 191.826 0 179.823 0 165.077H76.8192V163.362C76.8192 148.616 94.3093 136.613 115.572 136.613C136.834 136.613 153.981 148.616 153.981 163.362V165.077H230.801V163.362C230.801 148.616 247.948 136.613 269.21 136.613C290.473 136.613 307.62 148.616 307.62 163.362V165.077H384.439V163.362C384.439 148.616 401.586 136.613 422.849 136.613C444.111 136.613 461.258 148.616 461.258 163.362V165.077H538.078V163.362C538.078 148.616 555.568 136.613 576.83 136.613C598.093 136.613 615.24 148.616 615.24 163.362Z" fill="black" fill-opacity="0.05"/>
<path d="M615.24 108.491V110.206H538.078C538.078 124.953 520.93 136.956 499.668 136.956C478.405 136.956 461.258 124.953 461.258 110.206H384.439C384.439 124.953 367.292 136.956 346.029 136.956C324.767 136.956 307.62 124.953 307.62 110.206H230.801C230.801 124.953 213.653 136.956 192.391 136.956C171.129 136.956 153.981 124.953 153.981 110.206H76.8192C76.8192 124.953 59.6721 136.956 38.4096 136.956C17.1472 136.956 0 124.953 0 110.206H76.8192V108.491C76.8192 93.7447 94.3093 81.7418 115.572 81.7418C136.834 81.7418 153.981 93.7447 153.981 108.491V110.206H230.801V108.491C230.801 93.7447 247.948 81.7418 269.21 81.7418C290.473 81.7418 307.62 93.7447 307.62 108.491V110.206H384.439V108.491C384.439 93.7447 401.586 81.7418 422.849 81.7418C444.111 81.7418 461.258 93.7447 461.258 108.491V110.206H538.078V108.491C538.078 93.7447 555.568 81.7418 576.83 81.7418C598.093 81.7418 615.24 93.7447 615.24 108.491Z" fill="black" fill-opacity="0.05"/>
<path d="M615.24 53.6204V55.3351H538.078C538.078 70.0816 520.93 82.0847 499.668 82.0847C478.405 82.0847 461.258 70.0816 461.258 55.3351H384.439C384.439 70.0816 367.292 82.0847 346.029 82.0847C324.767 82.0847 307.62 70.0816 307.62 55.3351H230.801C230.801 70.0816 213.653 82.0847 192.391 82.0847C171.129 82.0847 153.981 70.0816 153.981 55.3351H76.8192C76.8192 70.0816 59.6721 82.0847 38.4096 82.0847C17.1472 82.0847 0 70.0816 0 55.3351H76.8192V53.6204C76.8192 38.8738 94.3093 26.8708 115.572 26.8708C136.834 26.8708 153.981 38.8738 153.981 53.6204V55.3351H230.801V53.6204C230.801 38.8738 247.948 26.8708 269.21 26.8708C290.473 26.8708 307.62 38.8738 307.62 53.6204V55.3351H384.439V53.6204C384.439 38.8738 401.586 26.8708 422.849 26.8708C444.111 26.8708 461.258 38.8738 461.258 53.6204V55.3351H538.078V53.6204C538.078 38.8738 555.568 26.8708 576.83 26.8708C598.093 26.8708 615.24 38.8738 615.24 53.6204Z" fill="black" fill-opacity="0.05"/>
<path d="M615.24 -1.25049V0.464224H538.078C538.078 15.2108 520.93 27.2138 499.668 27.2138C478.405 27.2138 461.258 15.2108 461.258 0.464224H384.439C384.439 15.2108 367.292 27.2138 346.029 27.2138C324.767 27.2138 307.62 15.2108 307.62 0.464224H230.801C230.801 15.2108 213.653 27.2138 192.391 27.2138C171.129 27.2138 153.981 15.2108 153.981 0.464224H76.8192C76.8192 15.2108 59.6721 27.2138 38.4096 27.2138C17.1472 27.2138 0 15.2108 0 0.464224H76.8192V-1.25049C76.8192 -15.997 94.3093 -28 115.572 -28C136.834 -28 153.981 -15.997 153.981 -1.25049V0.464224H230.801V-1.25049C230.801 -15.997 247.948 -28 269.21 -28C290.473 -28 307.62 -15.997 307.62 -1.25049V0.464224H384.439V-1.25049C384.439 -15.997 401.586 -28 422.849 -28C444.111 -28 461.258 -15.997 461.258 -1.25049V0.464224H538.078V-1.25049C538.078 -15.997 555.568 -28 576.83 -28C598.093 -28 615.24 -15.997 615.24 -1.25049Z" fill="black" fill-opacity="0.05"/>
</svg>

After

Width:  |  Height:  |  Size: 4.6 KiB

View File

Before

Width:  |  Height:  |  Size: 715 B

After

Width:  |  Height:  |  Size: 715 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

View File

@@ -0,0 +1,68 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 26.5.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
width="121px" height="32px" viewBox="0 0 121 32" style="enable-background:new 0 0 121 32;" xml:space="preserve">
<style type="text/css">
.st0{fill:#0073FF;stroke:#0073FF;stroke-miterlimit:10;}
.st1{fill:#212121;}
</style>
<path class="st0" d="M5.4,10.6C5.4,9.1,6.6,8,8,8h11.8l-2,2c-0.3,0.3-0.3,0.9,0,1.2s0.9,0.3,1.2,0l3.4-3.4c0.2-0.1,0.3-0.4,0.3-0.7
c0-0.2-0.1-0.5-0.3-0.6L19,3c-0.3-0.3-0.9-0.3-1.2,0c-0.3,0.3-0.3,0.9,0,1.2l2,2H8c-2.4,0-4.3,2-4.3,4.4v8.1c0,0.5,0.4,0.9,0.9,0.9
s0.9-0.4,0.9-0.9L5.4,10.6L5.4,10.6z"/>
<path class="st0" d="M18.1,24H6.3l2-2c0.3-0.3,0.3-0.9,0-1.2c-0.3-0.3-0.9-0.3-1.2,0l-3.4,3.4c-0.2,0.1-0.3,0.4-0.3,0.7
c0,0.2,0.1,0.5,0.3,0.6L7.1,29c0.3,0.3,0.9,0.3,1.2,0s0.3-0.9,0-1.2l-2-2h11.8c2.4,0,4.3-2,4.3-4.4v-8.1c0-0.5-0.4-0.9-0.9-0.9
s-0.9,0.4-0.9,0.9v8.1C20.7,22.9,19.5,24,18.1,24z"/>
<g>
<path class="st1" d="M29.6,21.6V10h4.7c0.9,0,1.6,0.1,2.1,0.4s1,0.6,1.3,1.1c0.3,0.4,0.4,1,0.4,1.5c0,0.5-0.1,0.9-0.3,1.2
c-0.2,0.3-0.4,0.6-0.7,0.8s-0.7,0.4-1.1,0.5v0.1c0.4,0,0.9,0.1,1.2,0.4c0.4,0.2,0.7,0.6,0.9,1c0.2,0.4,0.4,0.9,0.4,1.5
c0,0.6-0.2,1.2-0.5,1.7c-0.3,0.5-0.8,0.9-1.3,1.1c-0.6,0.3-1.3,0.4-2.2,0.4H29.6z M32.1,14.8h1.8c0.3,0,0.6-0.1,0.9-0.2
c0.3-0.1,0.5-0.3,0.6-0.5c0.2-0.2,0.2-0.5,0.2-0.8c0-0.4-0.1-0.8-0.4-1C34.9,12.1,34.5,12,34,12h-1.9V14.8z M32.1,19.6h2
c0.7,0,1.2-0.1,1.5-0.4s0.5-0.6,0.5-1.1c0-0.3-0.1-0.6-0.2-0.9s-0.4-0.4-0.7-0.6c-0.3-0.1-0.6-0.2-1-0.2h-2.1V19.6z"/>
<path class="st1" d="M42.7,21.8c-0.6,0-1.1-0.1-1.5-0.3s-0.8-0.5-1-0.9s-0.4-0.9-0.4-1.4c0-0.5,0.1-0.9,0.3-1.2
c0.2-0.3,0.4-0.6,0.7-0.8c0.3-0.2,0.7-0.4,1-0.5s0.8-0.2,1.2-0.2c0.5-0.1,0.9-0.1,1.2-0.2c0.3,0,0.5-0.1,0.7-0.2s0.2-0.2,0.2-0.4v0
c0-0.4-0.1-0.6-0.3-0.8c-0.2-0.2-0.5-0.3-1-0.3c-0.4,0-0.8,0.1-1,0.3c-0.3,0.2-0.4,0.4-0.5,0.7l-2.2-0.2c0.1-0.5,0.3-1,0.7-1.4
c0.3-0.4,0.8-0.7,1.3-0.9s1.1-0.3,1.8-0.3c0.5,0,1,0.1,1.4,0.2c0.4,0.1,0.8,0.3,1.2,0.5c0.3,0.2,0.6,0.5,0.8,0.9
c0.2,0.4,0.3,0.8,0.3,1.3v5.9h-2.3v-1.2h-0.1c-0.1,0.3-0.3,0.5-0.6,0.7c-0.2,0.2-0.5,0.4-0.8,0.5C43.5,21.7,43.1,21.8,42.7,21.8z
M43.4,20.1c0.4,0,0.7-0.1,0.9-0.2c0.3-0.1,0.5-0.3,0.6-0.6c0.2-0.2,0.2-0.5,0.2-0.8v-0.9c-0.1,0-0.2,0.1-0.3,0.1s-0.3,0.1-0.4,0.1
c-0.2,0-0.3,0.1-0.5,0.1c-0.2,0-0.3,0-0.4,0.1c-0.3,0-0.5,0.1-0.7,0.2c-0.2,0.1-0.4,0.2-0.5,0.4s-0.2,0.3-0.2,0.6
c0,0.3,0.1,0.6,0.4,0.8C42.7,20,43,20.1,43.4,20.1z"/>
<path class="st1" d="M56.7,15.4l-2.2,0.1c0-0.2-0.1-0.4-0.2-0.5s-0.3-0.3-0.5-0.4s-0.4-0.1-0.7-0.1c-0.4,0-0.7,0.1-0.9,0.2
c-0.3,0.2-0.4,0.4-0.4,0.6c0,0.2,0.1,0.4,0.2,0.5c0.2,0.1,0.5,0.3,0.9,0.3l1.6,0.3c0.8,0.2,1.5,0.5,1.9,0.8
c0.4,0.4,0.6,0.9,0.6,1.5c0,0.6-0.2,1.1-0.5,1.5c-0.3,0.4-0.8,0.8-1.4,1s-1.3,0.4-2,0.4c-1.2,0-2.1-0.2-2.8-0.7
c-0.7-0.5-1.1-1.1-1.2-2l2.4-0.1c0.1,0.4,0.2,0.6,0.5,0.8S52.6,20,53,20c0.4,0,0.8-0.1,1-0.2c0.3-0.2,0.4-0.4,0.4-0.6
c0-0.2-0.1-0.4-0.3-0.5c-0.2-0.1-0.5-0.3-0.8-0.3L51.8,18c-0.9-0.2-1.5-0.5-1.9-0.9c-0.4-0.4-0.6-1-0.6-1.6c0-0.6,0.2-1,0.5-1.4
c0.3-0.4,0.7-0.7,1.3-0.9c0.6-0.2,1.2-0.3,2-0.3c1.1,0,2,0.2,2.6,0.7C56.2,13.9,56.6,14.6,56.7,15.4z"/>
<path class="st1" d="M59.7,11.7c-0.4,0-0.7-0.1-0.9-0.4c-0.3-0.2-0.4-0.5-0.4-0.9c0-0.3,0.1-0.6,0.4-0.9c0.3-0.2,0.6-0.4,0.9-0.4
c0.4,0,0.7,0.1,0.9,0.4c0.3,0.2,0.4,0.5,0.4,0.9c0,0.3-0.1,0.6-0.4,0.9C60.3,11.6,60,11.7,59.7,11.7z M58.4,21.6v-8.7h2.4v8.7H58.4
z"/>
<path class="st1" d="M66.7,21.8c-0.9,0-1.7-0.2-2.3-0.6c-0.6-0.4-1.1-0.9-1.5-1.6c-0.3-0.7-0.5-1.5-0.5-2.3c0-0.9,0.2-1.7,0.5-2.4
s0.8-1.2,1.5-1.6c0.6-0.4,1.4-0.6,2.3-0.6c0.8,0,1.4,0.1,2,0.4c0.6,0.3,1,0.7,1.4,1.2c0.3,0.5,0.5,1.1,0.6,1.8h-2.3
c-0.1-0.4-0.2-0.8-0.5-1.1c-0.3-0.3-0.6-0.4-1.1-0.4c-0.4,0-0.7,0.1-1,0.3c-0.3,0.2-0.5,0.5-0.7,0.9c-0.2,0.4-0.2,0.9-0.2,1.4
c0,0.6,0.1,1,0.2,1.4c0.2,0.4,0.4,0.7,0.7,0.9c0.3,0.2,0.6,0.3,1,0.3c0.3,0,0.5-0.1,0.7-0.2c0.2-0.1,0.4-0.3,0.6-0.5
c0.1-0.2,0.2-0.5,0.3-0.8h2.3c0,0.7-0.2,1.3-0.5,1.8c-0.3,0.5-0.8,0.9-1.3,1.2C68.2,21.6,67.5,21.8,66.7,21.8z"/>
<path class="st1" d="M78.6,13.3c0-0.5-0.2-0.8-0.6-1.1c-0.3-0.3-0.8-0.4-1.4-0.4c-0.4,0-0.7,0.1-1,0.2c-0.3,0.1-0.5,0.3-0.6,0.5
c-0.1,0.2-0.2,0.4-0.2,0.7c0,0.2,0,0.4,0.1,0.5s0.2,0.3,0.4,0.4c0.2,0.1,0.4,0.2,0.6,0.3c0.2,0.1,0.5,0.2,0.7,0.2l1,0.2
c0.5,0.1,1,0.3,1.4,0.5s0.8,0.4,1.1,0.7s0.6,0.6,0.7,1c0.2,0.4,0.3,0.8,0.3,1.3c0,0.7-0.2,1.3-0.5,1.8c-0.4,0.5-0.9,0.9-1.5,1.2
c-0.7,0.3-1.5,0.4-2.4,0.4c-0.9,0-1.8-0.1-2.5-0.4c-0.7-0.3-1.2-0.7-1.6-1.3c-0.4-0.6-0.6-1.3-0.6-2.1h2.4c0,0.4,0.1,0.7,0.3,1
c0.2,0.3,0.5,0.5,0.8,0.6s0.7,0.2,1.1,0.2c0.4,0,0.8-0.1,1.1-0.2c0.3-0.1,0.5-0.3,0.7-0.5c0.2-0.2,0.3-0.5,0.3-0.7
c0-0.3-0.1-0.5-0.2-0.7c-0.2-0.2-0.4-0.3-0.7-0.5c-0.3-0.1-0.7-0.2-1.1-0.3l-1.3-0.3c-1-0.2-1.8-0.6-2.3-1.1s-0.9-1.2-0.8-2.1
c0-0.7,0.2-1.3,0.6-1.8s0.9-0.9,1.6-1.2c0.7-0.3,1.4-0.4,2.3-0.4c0.9,0,1.6,0.1,2.3,0.4c0.6,0.3,1.1,0.7,1.5,1.2
c0.4,0.5,0.5,1.1,0.6,1.8H78.6z"/>
<path class="st1" d="M84.4,21.6L82,12.9h2.4l1.4,5.9h0.1l1.4-5.9h2.4l1.4,5.8h0.1l1.3-5.8H95l-2.4,8.7h-2.6l-1.5-5.5h-0.1L87,21.6
H84.4z"/>
<path class="st1" d="M98.8,21.8c-0.6,0-1.1-0.1-1.5-0.3s-0.8-0.5-1-0.9s-0.4-0.9-0.4-1.4c0-0.5,0.1-0.9,0.3-1.2
c0.2-0.3,0.4-0.6,0.7-0.8c0.3-0.2,0.7-0.4,1-0.5c0.4-0.1,0.8-0.2,1.2-0.2c0.5-0.1,0.9-0.1,1.2-0.2c0.3,0,0.5-0.1,0.7-0.2
c0.1-0.1,0.2-0.2,0.2-0.4v0c0-0.4-0.1-0.6-0.3-0.8c-0.2-0.2-0.5-0.3-1-0.3c-0.4,0-0.8,0.1-1,0.3c-0.3,0.2-0.4,0.4-0.5,0.7l-2.2-0.2
c0.1-0.5,0.3-1,0.7-1.4c0.3-0.4,0.8-0.7,1.3-0.9c0.5-0.2,1.1-0.3,1.8-0.3c0.5,0,0.9,0.1,1.4,0.2c0.4,0.1,0.8,0.3,1.2,0.5
c0.3,0.2,0.6,0.5,0.8,0.9c0.2,0.4,0.3,0.8,0.3,1.3v5.9h-2.3v-1.2h-0.1c-0.1,0.3-0.3,0.5-0.6,0.7c-0.2,0.2-0.5,0.4-0.8,0.5
C99.6,21.7,99.2,21.8,98.8,21.8z M99.5,20.1c0.4,0,0.7-0.1,0.9-0.2s0.5-0.3,0.6-0.6c0.2-0.2,0.2-0.5,0.2-0.8v-0.9
c-0.1,0-0.2,0.1-0.3,0.1s-0.3,0.1-0.4,0.1s-0.3,0.1-0.5,0.1c-0.2,0-0.3,0-0.4,0.1c-0.3,0-0.5,0.1-0.7,0.2c-0.2,0.1-0.4,0.2-0.5,0.4
c-0.1,0.2-0.2,0.3-0.2,0.6c0,0.3,0.1,0.6,0.4,0.8C98.8,20,99.1,20.1,99.5,20.1z"/>
<path class="st1" d="M105.6,24.9v-12h2.4v1.5h0.1c0.1-0.2,0.3-0.5,0.5-0.7c0.2-0.2,0.5-0.4,0.8-0.6c0.3-0.2,0.7-0.2,1.2-0.2
c0.6,0,1.2,0.2,1.8,0.5c0.5,0.3,1,0.8,1.3,1.5s0.5,1.5,0.5,2.5c0,1-0.2,1.8-0.5,2.5c-0.3,0.7-0.7,1.2-1.3,1.5
c-0.5,0.3-1.1,0.5-1.8,0.5c-0.5,0-0.9-0.1-1.2-0.2c-0.3-0.2-0.6-0.4-0.8-0.6c-0.2-0.2-0.4-0.5-0.5-0.7H108v4.7H105.6z M107.9,17.2
c0,0.5,0.1,1,0.2,1.4c0.1,0.4,0.4,0.7,0.6,0.9c0.3,0.2,0.6,0.3,1,0.3c0.4,0,0.7-0.1,1-0.3c0.3-0.2,0.5-0.5,0.6-0.9
c0.1-0.4,0.2-0.8,0.2-1.3c0-0.5-0.1-0.9-0.2-1.3c-0.1-0.4-0.3-0.7-0.6-0.9c-0.3-0.2-0.6-0.3-1-0.3c-0.4,0-0.7,0.1-1,0.3
c-0.3,0.2-0.5,0.5-0.6,0.9C108,16.3,107.9,16.7,107.9,17.2z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 6.6 KiB

View File

@@ -0,0 +1,68 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 26.5.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
width="121px" height="32px" viewBox="0 0 121 32" style="enable-background:new 0 0 121 32;" xml:space="preserve">
<style type="text/css">
.st0{fill:#0073FF;stroke:#0073FF;stroke-miterlimit:10;}
.st1{fill:#FFFFFF;}
</style>
<path class="st0" d="M5.4,10.6C5.4,9.1,6.6,8,8,8h11.8l-2,2c-0.3,0.3-0.3,0.9,0,1.2s0.9,0.3,1.2,0l3.4-3.4c0.2-0.1,0.3-0.4,0.3-0.7
c0-0.2-0.1-0.5-0.3-0.6L19,3c-0.3-0.3-0.9-0.3-1.2,0c-0.3,0.3-0.3,0.9,0,1.2l2,2H8c-2.4,0-4.3,2-4.3,4.4v8.1c0,0.5,0.4,0.9,0.9,0.9
s0.9-0.4,0.9-0.9L5.4,10.6L5.4,10.6z"/>
<path class="st0" d="M18.1,24H6.3l2-2c0.3-0.3,0.3-0.9,0-1.2c-0.3-0.3-0.9-0.3-1.2,0l-3.4,3.4c-0.2,0.1-0.3,0.4-0.3,0.7
c0,0.2,0.1,0.5,0.3,0.6L7.1,29c0.3,0.3,0.9,0.3,1.2,0s0.3-0.9,0-1.2l-2-2h11.8c2.4,0,4.3-2,4.3-4.4v-8.1c0-0.5-0.4-0.9-0.9-0.9
s-0.9,0.4-0.9,0.9v8.1C20.7,22.9,19.5,24,18.1,24z"/>
<g>
<path class="st1" d="M29.6,21.6V10h4.7c0.9,0,1.6,0.1,2.1,0.4s1,0.6,1.3,1.1c0.3,0.4,0.4,1,0.4,1.5c0,0.5-0.1,0.9-0.3,1.2
c-0.2,0.3-0.4,0.6-0.7,0.8s-0.7,0.4-1.1,0.5v0.1c0.4,0,0.9,0.1,1.2,0.4c0.4,0.2,0.7,0.6,0.9,1c0.2,0.4,0.4,0.9,0.4,1.5
c0,0.6-0.2,1.2-0.5,1.7c-0.3,0.5-0.8,0.9-1.3,1.1c-0.6,0.3-1.3,0.4-2.2,0.4H29.6z M32.1,14.8h1.8c0.3,0,0.6-0.1,0.9-0.2
c0.3-0.1,0.5-0.3,0.6-0.5c0.2-0.2,0.2-0.5,0.2-0.8c0-0.4-0.1-0.8-0.4-1C34.9,12.1,34.5,12,34,12h-1.9V14.8z M32.1,19.6h2
c0.7,0,1.2-0.1,1.5-0.4s0.5-0.6,0.5-1.1c0-0.3-0.1-0.6-0.2-0.9s-0.4-0.4-0.7-0.6c-0.3-0.1-0.6-0.2-1-0.2h-2.1V19.6z"/>
<path class="st1" d="M42.7,21.8c-0.6,0-1.1-0.1-1.5-0.3s-0.8-0.5-1-0.9s-0.4-0.9-0.4-1.4c0-0.5,0.1-0.9,0.3-1.2
c0.2-0.3,0.4-0.6,0.7-0.8c0.3-0.2,0.7-0.4,1-0.5s0.8-0.2,1.2-0.2c0.5-0.1,0.9-0.1,1.2-0.2c0.3,0,0.5-0.1,0.7-0.2s0.2-0.2,0.2-0.4v0
c0-0.4-0.1-0.6-0.3-0.8c-0.2-0.2-0.5-0.3-1-0.3c-0.4,0-0.8,0.1-1,0.3c-0.3,0.2-0.4,0.4-0.5,0.7l-2.2-0.2c0.1-0.5,0.3-1,0.7-1.4
c0.3-0.4,0.8-0.7,1.3-0.9s1.1-0.3,1.8-0.3c0.5,0,1,0.1,1.4,0.2c0.4,0.1,0.8,0.3,1.2,0.5c0.3,0.2,0.6,0.5,0.8,0.9
c0.2,0.4,0.3,0.8,0.3,1.3v5.9h-2.3v-1.2h-0.1c-0.1,0.3-0.3,0.5-0.6,0.7c-0.2,0.2-0.5,0.4-0.8,0.5C43.5,21.7,43.1,21.8,42.7,21.8z
M43.4,20.1c0.4,0,0.7-0.1,0.9-0.2c0.3-0.1,0.5-0.3,0.6-0.6c0.2-0.2,0.2-0.5,0.2-0.8v-0.9c-0.1,0-0.2,0.1-0.3,0.1s-0.3,0.1-0.4,0.1
c-0.2,0-0.3,0.1-0.5,0.1c-0.2,0-0.3,0-0.4,0.1c-0.3,0-0.5,0.1-0.7,0.2c-0.2,0.1-0.4,0.2-0.5,0.4s-0.2,0.3-0.2,0.6
c0,0.3,0.1,0.6,0.4,0.8C42.7,20,43,20.1,43.4,20.1z"/>
<path class="st1" d="M56.7,15.4l-2.2,0.1c0-0.2-0.1-0.4-0.2-0.5s-0.3-0.3-0.5-0.4s-0.4-0.1-0.7-0.1c-0.4,0-0.7,0.1-0.9,0.2
c-0.3,0.2-0.4,0.4-0.4,0.6c0,0.2,0.1,0.4,0.2,0.5c0.2,0.1,0.5,0.3,0.9,0.3l1.6,0.3c0.8,0.2,1.5,0.5,1.9,0.8
c0.4,0.4,0.6,0.9,0.6,1.5c0,0.6-0.2,1.1-0.5,1.5c-0.3,0.4-0.8,0.8-1.4,1s-1.3,0.4-2,0.4c-1.2,0-2.1-0.2-2.8-0.7
c-0.7-0.5-1.1-1.1-1.2-2l2.4-0.1c0.1,0.4,0.2,0.6,0.5,0.8S52.6,20,53,20c0.4,0,0.8-0.1,1-0.2c0.3-0.2,0.4-0.4,0.4-0.6
c0-0.2-0.1-0.4-0.3-0.5c-0.2-0.1-0.5-0.3-0.8-0.3L51.8,18c-0.9-0.2-1.5-0.5-1.9-0.9c-0.4-0.4-0.6-1-0.6-1.6c0-0.6,0.2-1,0.5-1.4
c0.3-0.4,0.7-0.7,1.3-0.9c0.6-0.2,1.2-0.3,2-0.3c1.1,0,2,0.2,2.6,0.7C56.2,13.9,56.6,14.6,56.7,15.4z"/>
<path class="st1" d="M59.7,11.7c-0.4,0-0.7-0.1-0.9-0.4c-0.3-0.2-0.4-0.5-0.4-0.9c0-0.3,0.1-0.6,0.4-0.9c0.3-0.2,0.6-0.4,0.9-0.4
c0.4,0,0.7,0.1,0.9,0.4c0.3,0.2,0.4,0.5,0.4,0.9c0,0.3-0.1,0.6-0.4,0.9C60.3,11.6,60,11.7,59.7,11.7z M58.4,21.6v-8.7h2.4v8.7H58.4
z"/>
<path class="st1" d="M66.7,21.8c-0.9,0-1.7-0.2-2.3-0.6c-0.6-0.4-1.1-0.9-1.5-1.6c-0.3-0.7-0.5-1.5-0.5-2.3c0-0.9,0.2-1.7,0.5-2.4
s0.8-1.2,1.5-1.6c0.6-0.4,1.4-0.6,2.3-0.6c0.8,0,1.4,0.1,2,0.4c0.6,0.3,1,0.7,1.4,1.2c0.3,0.5,0.5,1.1,0.6,1.8h-2.3
c-0.1-0.4-0.2-0.8-0.5-1.1c-0.3-0.3-0.6-0.4-1.1-0.4c-0.4,0-0.7,0.1-1,0.3c-0.3,0.2-0.5,0.5-0.7,0.9c-0.2,0.4-0.2,0.9-0.2,1.4
c0,0.6,0.1,1,0.2,1.4c0.2,0.4,0.4,0.7,0.7,0.9c0.3,0.2,0.6,0.3,1,0.3c0.3,0,0.5-0.1,0.7-0.2c0.2-0.1,0.4-0.3,0.6-0.5
c0.1-0.2,0.2-0.5,0.3-0.8h2.3c0,0.7-0.2,1.3-0.5,1.8c-0.3,0.5-0.8,0.9-1.3,1.2C68.2,21.6,67.5,21.8,66.7,21.8z"/>
<path class="st1" d="M78.6,13.3c0-0.5-0.2-0.8-0.6-1.1c-0.3-0.3-0.8-0.4-1.4-0.4c-0.4,0-0.7,0.1-1,0.2c-0.3,0.1-0.5,0.3-0.6,0.5
c-0.1,0.2-0.2,0.4-0.2,0.7c0,0.2,0,0.4,0.1,0.5s0.2,0.3,0.4,0.4c0.2,0.1,0.4,0.2,0.6,0.3c0.2,0.1,0.5,0.2,0.7,0.2l1,0.2
c0.5,0.1,1,0.3,1.4,0.5s0.8,0.4,1.1,0.7s0.6,0.6,0.7,1c0.2,0.4,0.3,0.8,0.3,1.3c0,0.7-0.2,1.3-0.5,1.8c-0.4,0.5-0.9,0.9-1.5,1.2
c-0.7,0.3-1.5,0.4-2.4,0.4c-0.9,0-1.8-0.1-2.5-0.4c-0.7-0.3-1.2-0.7-1.6-1.3c-0.4-0.6-0.6-1.3-0.6-2.1h2.4c0,0.4,0.1,0.7,0.3,1
c0.2,0.3,0.5,0.5,0.8,0.6s0.7,0.2,1.1,0.2c0.4,0,0.8-0.1,1.1-0.2c0.3-0.1,0.5-0.3,0.7-0.5c0.2-0.2,0.3-0.5,0.3-0.7
c0-0.3-0.1-0.5-0.2-0.7c-0.2-0.2-0.4-0.3-0.7-0.5c-0.3-0.1-0.7-0.2-1.1-0.3l-1.3-0.3c-1-0.2-1.8-0.6-2.3-1.1s-0.9-1.2-0.8-2.1
c0-0.7,0.2-1.3,0.6-1.8s0.9-0.9,1.6-1.2c0.7-0.3,1.4-0.4,2.3-0.4c0.9,0,1.6,0.1,2.3,0.4c0.6,0.3,1.1,0.7,1.5,1.2
c0.4,0.5,0.5,1.1,0.6,1.8H78.6z"/>
<path class="st1" d="M84.4,21.6L82,12.9h2.4l1.4,5.9h0.1l1.4-5.9h2.4l1.4,5.8h0.1l1.3-5.8H95l-2.4,8.7h-2.6l-1.5-5.5h-0.1L87,21.6
H84.4z"/>
<path class="st1" d="M98.8,21.8c-0.6,0-1.1-0.1-1.5-0.3s-0.8-0.5-1-0.9s-0.4-0.9-0.4-1.4c0-0.5,0.1-0.9,0.3-1.2
c0.2-0.3,0.4-0.6,0.7-0.8c0.3-0.2,0.7-0.4,1-0.5c0.4-0.1,0.8-0.2,1.2-0.2c0.5-0.1,0.9-0.1,1.2-0.2c0.3,0,0.5-0.1,0.7-0.2
c0.1-0.1,0.2-0.2,0.2-0.4v0c0-0.4-0.1-0.6-0.3-0.8c-0.2-0.2-0.5-0.3-1-0.3c-0.4,0-0.8,0.1-1,0.3c-0.3,0.2-0.4,0.4-0.5,0.7l-2.2-0.2
c0.1-0.5,0.3-1,0.7-1.4c0.3-0.4,0.8-0.7,1.3-0.9c0.5-0.2,1.1-0.3,1.8-0.3c0.5,0,0.9,0.1,1.4,0.2c0.4,0.1,0.8,0.3,1.2,0.5
c0.3,0.2,0.6,0.5,0.8,0.9c0.2,0.4,0.3,0.8,0.3,1.3v5.9h-2.3v-1.2h-0.1c-0.1,0.3-0.3,0.5-0.6,0.7c-0.2,0.2-0.5,0.4-0.8,0.5
C99.6,21.7,99.2,21.8,98.8,21.8z M99.5,20.1c0.4,0,0.7-0.1,0.9-0.2s0.5-0.3,0.6-0.6c0.2-0.2,0.2-0.5,0.2-0.8v-0.9
c-0.1,0-0.2,0.1-0.3,0.1s-0.3,0.1-0.4,0.1s-0.3,0.1-0.5,0.1c-0.2,0-0.3,0-0.4,0.1c-0.3,0-0.5,0.1-0.7,0.2c-0.2,0.1-0.4,0.2-0.5,0.4
c-0.1,0.2-0.2,0.3-0.2,0.6c0,0.3,0.1,0.6,0.4,0.8C98.8,20,99.1,20.1,99.5,20.1z"/>
<path class="st1" d="M105.6,24.9v-12h2.4v1.5h0.1c0.1-0.2,0.3-0.5,0.5-0.7c0.2-0.2,0.5-0.4,0.8-0.6c0.3-0.2,0.7-0.2,1.2-0.2
c0.6,0,1.2,0.2,1.8,0.5c0.5,0.3,1,0.8,1.3,1.5s0.5,1.5,0.5,2.5c0,1-0.2,1.8-0.5,2.5c-0.3,0.7-0.7,1.2-1.3,1.5
c-0.5,0.3-1.1,0.5-1.8,0.5c-0.5,0-0.9-0.1-1.2-0.2c-0.3-0.2-0.6-0.4-0.8-0.6c-0.2-0.2-0.4-0.5-0.5-0.7H108v4.7H105.6z M107.9,17.2
c0,0.5,0.1,1,0.2,1.4c0.1,0.4,0.4,0.7,0.6,0.9c0.3,0.2,0.6,0.3,1,0.3c0.4,0,0.7-0.1,1-0.3c0.3-0.2,0.5-0.5,0.6-0.9
c0.1-0.4,0.2-0.8,0.2-1.3c0-0.5-0.1-0.9-0.2-1.3c-0.1-0.4-0.3-0.7-0.6-0.9c-0.3-0.2-0.6-0.3-1-0.3c-0.4,0-0.7,0.1-1,0.3
c-0.3,0.2-0.5,0.5-0.6,0.9C108,16.3,107.9,16.7,107.9,17.2z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 MiB

1015
basicswap/static/js/libs/dd.min.js vendored Normal file

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,40 @@
// Burger menus
document.addEventListener('DOMContentLoaded', function() {
// open
const burger = document.querySelectorAll('.navbar-burger');
const menu = document.querySelectorAll('.navbar-menu');
if (burger.length && menu.length) {
for (var i = 0; i < burger.length; i++) {
burger[i].addEventListener('click', function() {
for (var j = 0; j < menu.length; j++) {
menu[j].classList.toggle('hidden');
}
});
}
}
// close
const close = document.querySelectorAll('.navbar-close');
const backdrop = document.querySelectorAll('.navbar-backdrop');
if (close.length) {
for (var i = 0; i < close.length; i++) {
close[i].addEventListener('click', function() {
for (var j = 0; j < menu.length; j++) {
menu[j].classList.toggle('hidden');
}
});
}
}
if (backdrop.length) {
for (var i = 0; i < backdrop.length; i++) {
backdrop[i].addEventListener('click', function() {
for (var j = 0; j < menu.length; j++) {
menu[j].classList.toggle('hidden');
}
});
}
}
});

View File

@@ -0,0 +1,27 @@
window.addEventListener('DOMContentLoaded', (event) => {
let err_msgs = document.querySelectorAll('p.error_msg');
for (let i=0; i < err_msgs.length; i++) {
err_msg = err_msgs[i].innerText
if (err_msg.indexOf('coin_to') >= 0 || err_msg.indexOf('Coin To') >= 0) {
e = document.getElementById('coin_to');
e.classList.add('error');
}
if (err_msg.indexOf('Coin From') >= 0) {
e = document.getElementById('coin_from');
e.classList.add('error');
}
if (err_msg.indexOf('Amount From') >= 0) {
e = document.getElementById('amt_from');
e.classList.add('error');
}
if (err_msg.indexOf('Amount To') >= 0) {
e = document.getElementById('amt_to');
e.classList.add('error');
}
if (err_msg.indexOf('Minimum Bid Amount') >= 0) {
e = document.getElementById('amt_bid_min');
e.classList.add('error');
}
}
});

View File

@@ -0,0 +1,343 @@
<svg version="1.1" id="mscgenjsreplaceme" class="mscgenjsreplaceme" xmlns="http://www.w3.org/2000/svg" width="1176" height="1664.36" style="font-family:Helvetica,sans-serif;font-size:12px;font-weight:400;font-style:normal;text-decoration:none;background-color:#fff;stroke:#000;stroke-width:2">
<defs>
<marker orient="auto" id="mscgenjsreplacemecallback-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#00f"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#00f"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-#008800" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#080"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#008800" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#080"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:red"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:red"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="#00F" fill="#00F" d="m1 1 8 2-8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-l-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="#00F" fill="#00F" d="M17 1 9 3l8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="red" fill="red" d="m1 1 8 2-8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-l-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="red" fill="red" d="M17 1 9 3l8 2z"/>
</marker>
<style>
.mscgenjsreplaceme path,.mscgenjsreplaceme rect{fill:none}.mscgenjsreplaceme .label-text-background{fill:#fff;stroke:#fff;stroke-width:0}.mscgenjsreplaceme .return{stroke-dasharray:5,3}.mscgenjsreplaceme text{color:inherit;stroke:none;text-anchor:middle}.mscgenjsreplaceme text.anchor-start{text-anchor:start}.mscgenjsreplaceme .arrow-marker{overflow:visible}.mscgenjsreplaceme .arrow-style{stroke-width:1}.mscgenjsreplaceme .arcrow{stroke-linecap:butt}.mscgenjsreplaceme .box,.mscgenjsreplaceme .entity{fill:#fff;stroke-linejoin:round}
</style>
</defs>
<g id="mscgenjsreplaceme_body" transform="translate(48 3)">
<path class="bglayer" style="fill:#fff;stroke:#fff;stroke-width:0" d="M-48-3h1176v1664.36H-48z" id="mscgenjsreplaceme_background"/>
<g id="mscgenjsreplaceme_arcspans">
<path class="box inline_expression alt" d="M-38 859.12h964v780.24H-38z"/>
<path class="box inline_expression alt" d="M-34 1206.18h956v195.06H-34z"/>
</g>
<g id="mscgenjsreplaceme_lifelines">
<path class="arcrow" style="stroke:transparent" d="M60 38v38"/>
<path class="arcrow" style="stroke:#080" d="M252 38v38"/>
<path class="arcrow" style="stroke:red" d="M444 38v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 38v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 38v38M1020 38v38M60 76v38"/>
<path class="arcrow" style="stroke:#080" d="M252 76v38"/>
<path class="arcrow" style="stroke:red" d="M444 76v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 76v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 76v38M1020 76v38M60 114v38"/>
<path class="arcrow" style="stroke:#080" d="M252 114v38"/>
<path class="arcrow" style="stroke:red" d="M444 114v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 114v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 114v38M1020 114v38M60 152v38"/>
<path class="arcrow" style="stroke:#080" d="M252 152v38"/>
<path class="arcrow" style="stroke:red" d="M444 152v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 152v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 152v38M1020 152v38M60 190v38"/>
<path class="arcrow" style="stroke:#080" d="M252 190v38"/>
<path class="arcrow" style="stroke:red" d="M444 190v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 190v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 190v38M1020 190v38M60 228v38"/>
<path class="arcrow" style="stroke:#080" d="M252 228v38"/>
<path class="arcrow" style="stroke:red" d="M444 228v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 228v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 228v38M1020 228v38M60 266v38"/>
<path class="arcrow" style="stroke:#080" d="M252 266v38"/>
<path class="arcrow" style="stroke:red" d="M444 266v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 266v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 266v38M1020 266v38M60 304v54"/>
<path class="arcrow" style="stroke:#080" d="M252 304v54"/>
<path class="arcrow" style="stroke:red" d="M444 304v54"/>
<path class="arcrow" style="stroke:#00f" d="M636 304v54"/>
<path class="arcrow" style="stroke:transparent" d="M828 304v54M1020 304v54M60 358v38"/>
<path class="arcrow" style="stroke:#080" d="M252 358v38"/>
<path class="arcrow" style="stroke:red" d="M444 358v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 358v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 358v38M1020 358v38M60 396v38"/>
<path class="arcrow" style="stroke:#080" d="M252 396v38"/>
<path class="arcrow" style="stroke:red" d="M444 396v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 396v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 396v38M1020 396v38M60 434v38"/>
<path class="arcrow" style="stroke:#080" d="M252 434v38"/>
<path class="arcrow" style="stroke:red" d="M444 434v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 434v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 434v38M1020 434v38M60 472v43.06"/>
<path class="arcrow" style="stroke:#080" d="M252 472v43.06"/>
<path class="arcrow" style="stroke:red" d="M444 472v43.06"/>
<path class="arcrow" style="stroke:#00f" d="M636 472v43.06"/>
<path class="arcrow" style="stroke:transparent" d="M828 472v43.06M1020 472v43.06M60 515.06v38"/>
<path class="arcrow" style="stroke:#080" d="M252 515.06v38"/>
<path class="arcrow" style="stroke:red" d="M444 515.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 515.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 515.06v38M1020 515.06v38M60 553.06v38"/>
<path class="arcrow" style="stroke:#080" d="M252 553.06v38"/>
<path class="arcrow" style="stroke:red" d="M444 553.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 553.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 553.06v38M1020 553.06v38M60 591.06v54"/>
<path class="arcrow" style="stroke:#080" d="M252 591.06v54"/>
<path class="arcrow" style="stroke:red" d="M444 591.06v54"/>
<path class="arcrow" style="stroke:#00f" d="M636 591.06v54"/>
<path class="arcrow" style="stroke:transparent" d="M828 591.06v54M1020 591.06v54M60 645.06v38"/>
<path class="arcrow" style="stroke:#080" d="M252 645.06v38"/>
<path class="arcrow" style="stroke:red" d="M444 645.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 645.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 645.06v38M1020 645.06v38M60 683.06v38"/>
<path class="arcrow" style="stroke:#080" d="M252 683.06v38"/>
<path class="arcrow" style="stroke:red" d="M444 683.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 683.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 683.06v38M1020 683.06v38M60 721.06v43.06"/>
<path class="arcrow" style="stroke:#080" d="M252 721.06v43.06"/>
<path class="arcrow" style="stroke:red" d="M444 721.06v43.06"/>
<path class="arcrow" style="stroke:#00f" d="M636 721.06v43.06"/>
<path class="arcrow" style="stroke:transparent" d="M828 721.06v43.06M1020 721.06v43.06M60 764.12v38"/>
<path class="arcrow" style="stroke:#080" d="M252 764.12v38"/>
<path class="arcrow" style="stroke:red" d="M444 764.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 764.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 764.12v38M1020 764.12v38M60 802.12v38"/>
<path class="arcrow" style="stroke:#080" d="M252 802.12v38"/>
<path class="arcrow" style="stroke:red" d="M444 802.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 802.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 802.12v38M1020 802.12v38M60 840.12v38"/>
<path class="arcrow" style="stroke:#080" d="M252 840.12v38"/>
<path class="arcrow" style="stroke:red" d="M444 840.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 840.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 840.12v38M1020 840.12v38M60 878.12v38"/>
<path class="arcrow" style="stroke:#080" d="M252 878.12v38"/>
<path class="arcrow" style="stroke:red" d="M444 878.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 878.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 878.12v38M1020 878.12v38M60 916.12v38"/>
<path class="arcrow" style="stroke:#080" d="M252 916.12v38"/>
<path class="arcrow" style="stroke:red" d="M444 916.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 916.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 916.12v38M1020 916.12v38M60 954.12v38"/>
<path class="arcrow" style="stroke:#080" d="M252 954.12v38"/>
<path class="arcrow" style="stroke:red" d="M444 954.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 954.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 954.12v38M1020 954.12v38M60 992.12v38"/>
<path class="arcrow" style="stroke:#080" d="M252 992.12v38"/>
<path class="arcrow" style="stroke:red" d="M444 992.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 992.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 992.12v38M1020 992.12v38M60 1030.12v43.06"/>
<path class="arcrow" style="stroke:#080" d="M252 1030.12v43.06"/>
<path class="arcrow" style="stroke:red" d="M444 1030.12v43.06"/>
<path class="arcrow" style="stroke:#00f" d="M636 1030.12v43.06"/>
<path class="arcrow" style="stroke:transparent" d="M828 1030.12v43.06M1020 1030.12v43.06M60 1073.18v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1073.18v38"/>
<path class="arcrow" style="stroke:red" d="M444 1073.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1073.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1073.18v38M1020 1073.18v38M60 1111.18v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1111.18v38"/>
<path class="arcrow" style="stroke:red" d="M444 1111.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1111.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1111.18v38M1020 1111.18v38M60 1149.18v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1149.18v38"/>
<path class="arcrow" style="stroke:red" d="M444 1149.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1149.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1149.18v38M1020 1149.18v38M60 1187.18v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1187.18v38"/>
<path class="arcrow" style="stroke:red" d="M444 1187.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1187.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1187.18v38M1020 1187.18v38M60 1225.18v43.06"/>
<path class="arcrow" style="stroke:#080" d="M252 1225.18v43.06"/>
<path class="arcrow" style="stroke:red" d="M444 1225.18v43.06"/>
<path class="arcrow" style="stroke:#00f" d="M636 1225.18v43.06"/>
<path class="arcrow" style="stroke:transparent" d="M828 1225.18v43.06M1020 1225.18v43.06M60 1268.24v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1268.24v38"/>
<path class="arcrow" style="stroke:red" d="M444 1268.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1268.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1268.24v38M1020 1268.24v38M60 1306.24v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1306.24v38"/>
<path class="arcrow" style="stroke:red" d="M444 1306.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1306.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1306.24v38M1020 1306.24v38M60 1344.24v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1344.24v38"/>
<path class="arcrow" style="stroke:red" d="M444 1344.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1344.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1344.24v38M1020 1344.24v38M60 1382.24v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1382.24v38"/>
<path class="arcrow" style="stroke:red" d="M444 1382.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1382.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1382.24v38M1020 1382.24v38M60 1420.24v43.06"/>
<path class="arcrow" style="stroke:#080" d="M252 1420.24v43.06"/>
<path class="arcrow" style="stroke:red" d="M444 1420.24v43.06"/>
<path class="arcrow" style="stroke:#00f" d="M636 1420.24v43.06"/>
<path class="arcrow" style="stroke:transparent" d="M828 1420.24v43.06M1020 1420.24v43.06M60 1463.3v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1463.3v38"/>
<path class="arcrow" style="stroke:red" d="M444 1463.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1463.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1463.3v38M1020 1463.3v38M60 1501.3v43.06"/>
<path class="arcrow" style="stroke:#080" d="M252 1501.3v43.06"/>
<path class="arcrow" style="stroke:red" d="M444 1501.3v43.06"/>
<path class="arcrow" style="stroke:#00f" d="M636 1501.3v43.06"/>
<path class="arcrow" style="stroke:transparent" d="M828 1501.3v43.06M1020 1501.3v43.06M60 1544.36v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1544.36v38"/>
<path class="arcrow" style="stroke:red" d="M444 1544.36v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1544.36v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1544.36v38M1020 1544.36v38M60 1582.36v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1582.36v38"/>
<path class="arcrow" style="stroke:red" d="M444 1582.36v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1582.36v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1582.36v38M1020 1582.36v38M60 1620.36v38"/>
<path class="arcrow" style="stroke:#080" d="M252 1620.36v38"/>
<path class="arcrow" style="stroke:red" d="M444 1620.36v38"/>
<path class="arcrow" style="stroke:#00f" d="M636 1620.36v38"/>
<path class="arcrow" style="stroke:transparent" d="M828 1620.36v38M1020 1620.36v38"/>
</g>
<g id="mscgenjsreplaceme_sequence">
<path class="entity" style="stroke:transparent" d="M0 0h120v38H0z"/>
<text x="60" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="entity" style="fill:#cfc;stroke:#080" d="M192 0h120v38H192z"/>
<text x="252" y="22.75" class="entity-text"><tspan>Network</tspan></text>
<path class="entity" style="fill:#fcc;stroke:red" d="M384 0h120v38H384z"/>
<text x="444" y="22.75" class="entity-text"><tspan>Offerer</tspan></text>
<path class="entity" style="fill:#ccf;stroke:#00f" d="M576 0h120v38H576z"/>
<text x="636" y="22.75" class="entity-text"><tspan>Bidder</tspan></text>
<path class="entity" style="stroke:transparent" d="M768 0h120v38H768z"/>
<text x="828" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="entity" style="stroke:transparent" d="M960 0h120v38H960z"/>
<text x="1020" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M444 95H252"/>
<path class="label-text-background" d="M316.08 79.25h63.84v14h-63.84z"/>
<text x="348" y="90.25" class="directional-text callback-text"><tspan>Sends Offer</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M252 133h384"/>
<path class="label-text-background" d="M408.75 117.25h70.5v14h-70.5z"/>
<text x="444" y="128.25" class="directional-text return-text"><tspan>Detects Offer</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M636 171H444"/>
<path class="label-text-background" d="M512.64 155.25h54.72v14h-54.72z"/>
<text x="540" y="166.25" class="directional-text callback-text"><tspan>Sends Bid</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M444 285H252"/>
<path class="label-text-background" d="M303.3 269.25h89.41v14H303.3z"/>
<text x="348" y="280.25" class="directional-text callback-text"><tspan>Sends Initiate Tx</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M444 331h192"/>
<path class="label-text-background" d="M494.3 315.25h92.08v14H494.3z"/>
<text x="540" y="326.25" class="directional-text callback-text"><tspan>Sends BidAccept</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M252 415h384"/>
<path class="label-text-background" d="M395.97 399.25h96.06v14h-96.06z"/>
<text x="444" y="410.25" class="directional-text return-text"><tspan>Detects Initiate Tx</tspan></text>
<path d="M636 485.93c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M639 469.67h118.92v14.02H639z"/>
<text x="639" y="480.68" class="directional-text method-text anchor-start"><tspan>Wait for ITX to confirm</tspan></text>
<path d="M444 485.93c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M447 469.67h118.92v14.02H447z"/>
<text x="447" y="480.68" class="directional-text method-text anchor-start"><tspan>Wait for ITX to confirm</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M636 618.06H252"/>
<path class="label-text-background" d="M388.64 602.3h110.72v14.02H388.64z"/>
<text x="444" y="613.31" class="directional-text callback-text"><tspan>Sends Participate Tx</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M252 702.06h192"/>
<path class="label-text-background" d="M289.31 686.3h117.38v14.02H289.31z"/>
<text x="348" y="697.31" class="directional-text return-text"><tspan>Detects Participate Tx</tspan></text>
<path d="M636 734.99c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M639 718.73h123.59v14.02H639z"/>
<text x="639" y="729.74" class="directional-text method-text anchor-start"><tspan>Wait for PTX to confirm</tspan></text>
<path d="M444 734.99c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M447 718.73h123.59v14.02H447z"/>
<text x="447" y="729.74" class="directional-text method-text anchor-start"><tspan>Wait for PTX to confirm</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M444 897.12H252"/>
<path class="label-text-background" d="M268.28 881.36h159.44v14.02H268.28z"/>
<text x="348" y="892.37" class="directional-text callback-text"><tspan>Sends Participate Redeem Tx</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M252 935.12h384"/>
<path class="label-text-background" d="M360.95 919.36h166.09v14.02H360.95z"/>
<text x="444" y="930.37" class="directional-text return-text"><tspan>Detects Participate Redeem Tx</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M636 1011.12H252"/>
<path class="label-text-background" d="M374.95 995.36h138.09v14.02H374.95z"/>
<text x="444" y="1006.37" class="directional-text callback-text"><tspan>Sends Initiate Redeem Tx</tspan></text>
<path d="M636 1044.05c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M639 1027.8h167.61v14.02H639z"/>
<text x="639" y="1038.8" class="directional-text method-text anchor-start"><tspan>Wait for ITX Redeem to confirm</tspan></text>
<path class="inline_expression_divider" style="stroke-dasharray:10,5" d="M-38 1168.18h964"/>
<path class="label-text-background" d="M422.98 1160.92h42.03v14.02h-42.03z"/>
<text x="444" y="1171.93" class="empty-text comment-row-text"><tspan>fail path</tspan></text>
<path d="M444 1239.11c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M447 1222.86h159.94v14.02H447z"/>
<text x="447" y="1233.86" class="directional-text method-text anchor-start"><tspan>Wait for ITX locktime to expire</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M444 1287.24H252"/>
<path class="label-text-background" d="M309.31 1271.48h77.38v14.02h-77.38z"/>
<text x="348" y="1282.49" class="directional-text callback-text"><tspan>ITX Refund Tx</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M252 1325.24h384"/>
<path class="label-text-background" d="M368.97 1309.48h150.06v14.02H368.97z"/>
<text x="444" y="1320.49" class="directional-text return-text"><tspan>Detects Initiate Tx refund Tx</tspan></text>
<path d="M636 1434.17c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M639 1417.91h164.59v14.02H639z"/>
<text x="639" y="1428.92" class="directional-text method-text anchor-start"><tspan>Wait for PTX locktime to expire</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M636 1482.3H252"/>
<path class="label-text-background" d="M402.98 1466.55h82.03v14.02h-82.03z"/>
<text x="444" y="1477.55" class="directional-text callback-text"><tspan>PTX Refund Tx</tspan></text>
<path d="M636 1515.23c96 .1 96 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M639 1498.97h165.63v14.02H639z"/>
<text x="639" y="1509.98" class="directional-text method-text anchor-start"><tspan>Wait for PTX Refund to confirm</tspan></text>
</g>
<g id="mscgenjsreplaceme_notes">
<path d="m546 209 3-17h174l3 17-3 17H549z" class="box abox" style="stroke:#00f"/>
<text x="636" y="212.75" class="box-text abox-text"><tspan>Bid Sent</tspan></text>
<path class="box" style="stroke:red" d="M354 230h180v34H354z"/>
<text x="444" y="250.75" class="box-text"><tspan>User accepts bid</tspan></text>
<path d="M738 268h363v9h9m-9-9 9 9v25H738v-34z" class="box note" style="fill:#ffc"/>
<text x="924" y="280.75" class="box-text note-text"><tspan>Offerer generates secret_value and sends Hash(secret_value) to</tspan></text>
<text x="924" y="296.75" class="box-text note-text"><tspan>the Bidder</tspan></text>
<path d="M738 306h363v9h9m-9-9 9 9v41H738v-50z" class="box note" style="fill:#ffc"/>
<text x="924" y="318.75" class="box-text note-text"><tspan>ITX can be spent by knowledge of the</tspan></text>
<text x="924" y="334.75" class="box-text note-text"><tspan>secret_value and the bidder_redeem_key or after a timeout</tspan></text>
<text x="924" y="350.75" class="box-text note-text"><tspan>by the offerer_refund_key</tspan></text>
<path d="m546 377 3-17h174l3 17-3 17H549z" class="box abox" style="stroke:#00f"/>
<text x="636" y="380.75" class="box-text abox-text"><tspan>Bid Accepted</tspan></text>
<path d="m546 453 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#4bdbf1;stroke:#00f"/>
<text x="636" y="456.75" class="box-text abox-text"><tspan>ITX Sent</tspan></text>
<path d="m546 534.06 3-17h174l3 17-3 17H549z" class="box abox" style="stroke:#00f"/>
<text x="636" y="537.81" class="box-text abox-text"><tspan>Bid Initiated</tspan></text>
<path d="m546 572.06 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#4bdbf1;stroke:#00f"/>
<text x="636" y="575.81" class="box-text abox-text"><tspan>ITX Confirmed</tspan></text>
<path d="M738 593.05h363v9h9m-9-9 9 9v41.02H738v-50.02z" class="box note" style="fill:#ffc"/>
<text x="924" y="605.81" class="box-text note-text"><tspan>PTX can be spent by knowledge of the</tspan></text>
<text x="924" y="621.81" class="box-text note-text"><tspan>secret_value and the offerer_redeem_key or after a timeout</tspan></text>
<text x="924" y="637.81" class="box-text note-text"><tspan>by the bidder_refund_key</tspan></text>
<path d="m546 664.06 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#f1db4b;stroke:#00f"/>
<text x="636" y="667.81" class="box-text abox-text"><tspan>PTX Sent</tspan></text>
<path d="m546 783.12 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#f1db4b;stroke:#00f"/>
<text x="636" y="786.87" class="box-text abox-text"><tspan>PTX Confirmed</tspan></text>
<path d="m546 821.12 3-17h174l3 17-3 17H549z" class="box abox" style="stroke:#00f"/>
<text x="636" y="824.87" class="box-text abox-text"><tspan>Bid Participating</tspan></text>
<path d="M-37 859.12h98.39v11.02l-7 7H-37" class="box inline_expression_label"/>
<text x="-35" y="872.37" class="inline_expression-text alt-text anchor-start"><tspan>alt: success path</tspan></text>
<path d="M738 880.12h363v9h9m-9-9 9 9v25H738v-34z" class="box note" style="fill:#ffc"/>
<text x="924" y="900.87" class="box-text note-text"><tspan>Reveals secret_value</tspan></text>
<path d="m546 973.12 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#f1db4b;stroke:#00f"/>
<text x="636" y="976.87" class="box-text abox-text"><tspan>PTX Redeemed</tspan></text>
<path d="m546 1092.18 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#4bdbf1;stroke:#00f"/>
<text x="636" y="1095.93" class="box-text abox-text"><tspan>ITX Redeemed</tspan></text>
<path d="m546 1130.18 3-17h174l3 17-3 17H549z" class="box abox" style="stroke:#00f"/>
<text x="636" y="1133.93" class="box-text abox-text"><tspan>Bid Completed</tspan></text>
<path d="M-33 1206.18h152.83v11.02l-7 7H-33" class="box inline_expression_label"/>
<text x="-31" y="1219.43" class="inline_expression-text alt-text anchor-start"><tspan>alt: offerer may reclaim ITX</tspan></text>
<path d="m546 1363.24 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#4bdbf1;stroke:#00f"/>
<text x="636" y="1366.99" class="box-text abox-text"><tspan>ITX Refunded</tspan></text>
<path d="m546 1563.36 3-17h174l3 17-3 17H549z" class="box abox" style="fill:#f1db4b;stroke:#00f"/>
<text x="636" y="1567.11" class="box-text abox-text"><tspan>PTX Refunded</tspan></text>
<path d="m546 1601.36 3-17h174l3 17-3 17H549z" class="box abox" style="stroke:#00f"/>
<text x="636" y="1605.11" class="box-text abox-text"><tspan>Bid Completed</tspan></text>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 32 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 28 KiB

View File

@@ -0,0 +1,414 @@
<svg version="1.1" id="mscgenjsreplaceme" class="mscgenjsreplaceme" xmlns="http://www.w3.org/2000/svg" width="1272" height="2063.3" style="font-family:Helvetica,sans-serif;font-size:12px;font-weight:400;font-style:normal;text-decoration:none;background-color:#fff;stroke:#000;stroke-width:2">
<defs>
<marker orient="auto" id="mscgenjsreplacemecallback-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#00f"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#00f"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-#008800" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#080"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#008800" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#080"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:red"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:red"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="#00F" fill="#00F" d="m1 1 8 2-8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-l-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="#00F" fill="#00F" d="M17 1 9 3l8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="red" fill="red" d="m1 1 8 2-8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-l-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="red" fill="red" d="M17 1 9 3l8 2z"/>
</marker>
<style>
.mscgenjsreplaceme path,.mscgenjsreplaceme rect{fill:none}.mscgenjsreplaceme .label-text-background{fill:#fff;stroke:#fff;stroke-width:0}.mscgenjsreplaceme .return{stroke-dasharray:5,3}.mscgenjsreplaceme .inline_expression_divider{stroke-dasharray:10,5}.mscgenjsreplaceme text{color:inherit;stroke:none;text-anchor:middle}.mscgenjsreplaceme text.anchor-start{text-anchor:start}.mscgenjsreplaceme .arrow-marker{overflow:visible}.mscgenjsreplaceme .arrow-style{stroke-width:1}.mscgenjsreplaceme .arcrow{stroke-linecap:butt}.mscgenjsreplaceme .box,.mscgenjsreplaceme .entity{fill:#fff;stroke-linejoin:round}
</style>
</defs>
<g id="mscgenjsreplaceme_body" transform="translate(51 3)">
<path class="bglayer" style="fill:#fff;stroke:#fff;stroke-width:0" d="M-51-3h1272v2063.3H-51z" id="mscgenjsreplaceme_background"/>
<g id="mscgenjsreplaceme_arcspans">
<path class="box inline_expression alt" d="M-41 869.12h1044V2038.3H-41z"/>
<path class="box inline_expression alt" d="M-37 1410.18H999v590.12H-37z"/>
</g>
<g id="mscgenjsreplaceme_lifelines">
<path class="arcrow" style="stroke:transparent" d="M65 38v38"/>
<path class="arcrow" style="stroke:#080" d="M273 38v38"/>
<path class="arcrow" style="stroke:red" d="M481 38v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 38v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 38v38M1105 38v38M65 76v38"/>
<path class="arcrow" style="stroke:#080" d="M273 76v38"/>
<path class="arcrow" style="stroke:red" d="M481 76v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 76v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 76v38M1105 76v38M65 114v38"/>
<path class="arcrow" style="stroke:#080" d="M273 114v38"/>
<path class="arcrow" style="stroke:red" d="M481 114v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 114v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 114v38M1105 114v38M65 152v38"/>
<path class="arcrow" style="stroke:#080" d="M273 152v38"/>
<path class="arcrow" style="stroke:red" d="M481 152v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 152v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 152v38M1105 152v38M65 190v38"/>
<path class="arcrow" style="stroke:#080" d="M273 190v38"/>
<path class="arcrow" style="stroke:red" d="M481 190v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 190v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 190v38M1105 190v38M65 228v38"/>
<path class="arcrow" style="stroke:#080" d="M273 228v38"/>
<path class="arcrow" style="stroke:red" d="M481 228v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 228v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 228v38M1105 228v38M65 266v54"/>
<path class="arcrow" style="stroke:#080" d="M273 266v54"/>
<path class="arcrow" style="stroke:red" d="M481 266v54"/>
<path class="arcrow" style="stroke:#00f" d="M689 266v54"/>
<path class="arcrow" style="stroke:transparent" d="M897 266v54M1105 266v54M65 320v38"/>
<path class="arcrow" style="stroke:#080" d="M273 320v38"/>
<path class="arcrow" style="stroke:red" d="M481 320v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 320v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 320v38M1105 320v38M65 358v38"/>
<path class="arcrow" style="stroke:#080" d="M273 358v38"/>
<path class="arcrow" style="stroke:red" d="M481 358v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 358v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 358v38M1105 358v38M65 396v38"/>
<path class="arcrow" style="stroke:#080" d="M273 396v38"/>
<path class="arcrow" style="stroke:red" d="M481 396v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 396v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 396v38M1105 396v38M65 434v38"/>
<path class="arcrow" style="stroke:#080" d="M273 434v38"/>
<path class="arcrow" style="stroke:red" d="M481 434v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 434v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 434v38M1105 434v38M65 472v38"/>
<path class="arcrow" style="stroke:#080" d="M273 472v38"/>
<path class="arcrow" style="stroke:red" d="M481 472v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 472v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 472v38M1105 472v38M65 510v38"/>
<path class="arcrow" style="stroke:#080" d="M273 510v38"/>
<path class="arcrow" style="stroke:red" d="M481 510v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 510v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 510v38M1105 510v38M65 548v38"/>
<path class="arcrow" style="stroke:#080" d="M273 548v38"/>
<path class="arcrow" style="stroke:red" d="M481 548v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 548v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 548v38M1105 548v38M65 586v75.06"/>
<path class="arcrow" style="stroke:#080" d="M273 586v75.06"/>
<path class="arcrow" style="stroke:red" d="M481 586v75.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 586v75.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 586v75.06M1105 586v75.06M65 661.06v38"/>
<path class="arcrow" style="stroke:#080" d="M273 661.06v38"/>
<path class="arcrow" style="stroke:red" d="M481 661.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 661.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 661.06v38M1105 661.06v38M65 699.06v38"/>
<path class="arcrow" style="stroke:#080" d="M273 699.06v38"/>
<path class="arcrow" style="stroke:red" d="M481 699.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 699.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 699.06v38M1105 699.06v38M65 737.06v75.06"/>
<path class="arcrow" style="stroke:#080" d="M273 737.06v75.06"/>
<path class="arcrow" style="stroke:red" d="M481 737.06v75.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 737.06v75.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 737.06v75.06M1105 737.06v75.06M65 812.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 812.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 812.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 812.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 812.12v38M1105 812.12v38M65 850.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 850.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 850.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 850.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 850.12v38M1105 850.12v38M65 888.12v86"/>
<path class="arcrow" style="stroke:#080" d="M273 888.12v86"/>
<path class="arcrow" style="stroke:red" d="M481 888.12v86"/>
<path class="arcrow" style="stroke:#00f" d="M689 888.12v86"/>
<path class="arcrow" style="stroke:transparent" d="M897 888.12v86M1105 888.12v86M65 974.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 974.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 974.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 974.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 974.12v38M1105 974.12v38M65 1012.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1012.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1012.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1012.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1012.12v38M1105 1012.12v38M65 1050.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1050.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1050.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1050.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1050.12v38M1105 1050.12v38M65 1088.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1088.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1088.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1088.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1088.12v38M1105 1088.12v38M65 1126.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1126.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1126.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1126.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1126.12v38M1105 1126.12v38M65 1164.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1164.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1164.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1164.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1164.12v38M1105 1164.12v38M65 1202.12v75.06"/>
<path class="arcrow" style="stroke:#080" d="M273 1202.12v75.06"/>
<path class="arcrow" style="stroke:red" d="M481 1202.12v75.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 1202.12v75.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 1202.12v75.06M1105 1202.12v75.06M65 1277.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1277.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1277.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1277.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1277.18v38M1105 1277.18v38M65 1315.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1315.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1315.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1315.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1315.18v38M1105 1315.18v38M65 1353.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1353.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1353.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1353.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1353.18v38M1105 1353.18v38M65 1391.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1391.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1391.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1391.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1391.18v38M1105 1391.18v38M65 1429.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1429.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1429.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1429.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1429.18v38M1105 1429.18v38M65 1467.18v59.06"/>
<path class="arcrow" style="stroke:#080" d="M273 1467.18v59.06"/>
<path class="arcrow" style="stroke:red" d="M481 1467.18v59.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 1467.18v59.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 1467.18v59.06M1105 1467.18v59.06M65 1526.24v54"/>
<path class="arcrow" style="stroke:#080" d="M273 1526.24v54"/>
<path class="arcrow" style="stroke:red" d="M481 1526.24v54"/>
<path class="arcrow" style="stroke:#00f" d="M689 1526.24v54"/>
<path class="arcrow" style="stroke:transparent" d="M897 1526.24v54M1105 1526.24v54M65 1580.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1580.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1580.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1580.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1580.24v38M1105 1580.24v38M65 1618.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1618.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1618.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1618.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1618.24v38M1105 1618.24v38M65 1656.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1656.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1656.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1656.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1656.24v38M1105 1656.24v38M65 1694.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1694.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1694.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1694.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1694.24v38M1105 1694.24v38M65 1732.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1732.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1732.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1732.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1732.24v38M1105 1732.24v38M65 1770.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1770.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1770.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1770.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1770.24v38M1105 1770.24v38M65 1808.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1808.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1808.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1808.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1808.24v38M1105 1808.24v38M65 1846.24v59.06"/>
<path class="arcrow" style="stroke:#080" d="M273 1846.24v59.06"/>
<path class="arcrow" style="stroke:red" d="M481 1846.24v59.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 1846.24v59.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 1846.24v59.06M1105 1846.24v59.06M65 1905.3v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1905.3v38"/>
<path class="arcrow" style="stroke:red" d="M481 1905.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1905.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1905.3v38M1105 1905.3v38M65 1943.3v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1943.3v38"/>
<path class="arcrow" style="stroke:red" d="M481 1943.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1943.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1943.3v38M1105 1943.3v38M65 1981.3v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1981.3v38"/>
<path class="arcrow" style="stroke:red" d="M481 1981.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1981.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1981.3v38M1105 1981.3v38M65 2019.3v38"/>
<path class="arcrow" style="stroke:#080" d="M273 2019.3v38"/>
<path class="arcrow" style="stroke:red" d="M481 2019.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 2019.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 2019.3v38M1105 2019.3v38"/>
</g>
<g id="mscgenjsreplaceme_sequence">
<path class="entity" style="stroke:transparent" d="M0 0h130v38H0z"/>
<text x="65" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="entity" style="fill:#cfc;stroke:#080" d="M208 0h130v38H208z"/>
<text x="273" y="22.75" class="entity-text"><tspan>Network</tspan></text>
<path class="entity" style="fill:#fcc;stroke:red" d="M416 0h130v38H416z"/>
<text x="481" y="22.75" class="entity-text"><tspan>Offerer</tspan></text>
<path class="entity" style="fill:#ccf;stroke:#00f" d="M624 0h130v38H624z"/>
<text x="689" y="22.75" class="entity-text"><tspan>Bidder</tspan></text>
<path class="entity" style="stroke:transparent" d="M832 0h130v38H832z"/>
<text x="897" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="entity" style="stroke:transparent" d="M1040 0h130v38h-130z"/>
<text x="1105" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 95H273"/>
<path class="label-text-background" d="M345.08 79.25h63.84v14h-63.84z"/>
<text x="377" y="90.25" class="directional-text callback-text"><tspan>Sends Offer</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M273 133h416"/>
<path class="label-text-background" d="M445.75 117.25h70.5v14h-70.5z"/>
<text x="481" y="128.25" class="directional-text return-text"><tspan>Detects Offer</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 171H481"/>
<path class="label-text-background" d="M557.64 155.25h54.72v14h-54.72z"/>
<text x="585" y="166.25" class="directional-text callback-text"><tspan>Sends Bid</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 293h208"/>
<path class="label-text-background" d="M513.28 277.25h143.77v14H513.28z"/>
<text x="585" y="288.25" class="directional-text callback-text"><tspan>Sends BidAccept message</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 415H481"/>
<path class="label-text-background" d="M491.28 399.25h187.77v14H491.28z"/>
<text x="585" y="410.25" class="directional-text callback-text"><tspan>Sends XmrBidLockTxSigsMessage</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 491h208"/>
<path class="label-text-background" d="M485.61 475.25h199.11v14H485.61z"/>
<text x="585" y="486.25" class="directional-text callback-text"><tspan>Sends XmrBidLockSpendTxMessage</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 529H273"/>
<path class="label-text-background" d="M311.64 513.25h130.72v14H311.64z"/>
<text x="377" y="524.25" class="directional-text callback-text"><tspan>Sends script-coin-lock-tx</tspan></text>
<path d="M689 615.93c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M692 567.67h40.91v14.02H692z"/>
<text x="692" y="578.68" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M692 583.67h107.02v14.02H692z"/>
<text x="692" y="594.68" class="directional-text method-text anchor-start"><tspan>script-coin-lock-tx to</tspan></text>
<path class="label-text-background" d="M692 599.67h39.34v14.02H692z"/>
<text x="692" y="610.68" class="directional-text method-text anchor-start"><tspan>confirm</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 718.06H273"/>
<path class="label-text-background" d="M408.97 702.3h144.06v14.02H408.97z"/>
<text x="481" y="713.31" class="directional-text callback-text"><tspan>Sends noscript-coin-lock-tx</tspan></text>
<path d="M689 766.99c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M692 718.73h40.91v14.02H692z"/>
<text x="692" y="729.74" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M692 734.73h120.38v14.02H692z"/>
<text x="692" y="745.74" class="directional-text method-text anchor-start"><tspan>noscript-coin-lock-tx to</tspan></text>
<path class="label-text-background" d="M692 750.73h39.34v14.02H692z"/>
<text x="692" y="761.74" class="directional-text method-text anchor-start"><tspan>confirm</tspan></text>
<path d="M481 766.99c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M484 718.73h40.91v14.02H484z"/>
<text x="484" y="729.74" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M484 734.73h120.38v14.02H484z"/>
<text x="484" y="745.74" class="directional-text method-text anchor-start"><tspan>noscript-coin-lock-tx to</tspan></text>
<path class="label-text-background" d="M484 750.73h39.34v14.02H484z"/>
<text x="484" y="761.74" class="directional-text method-text anchor-start"><tspan>confirm</tspan></text>
<path class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)" d="M481 931.12h208"/>
<path class="label-text-background" d="M519.64 915.36h130.72v14.02H519.64z"/>
<text x="585" y="926.37" class="directional-text method-text"><tspan>Sends script-coin-lock-tx</tspan></text>
<path class="label-text-background" d="M539.3 933.36h91.73v14.02H539.3z"/>
<text x="585" y="944.37" class="directional-text method-text"><tspan>release message</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 1031.12H273"/>
<path class="label-text-background" d="M397.3 1015.36h167.41v14.02H397.3z"/>
<text x="481" y="1026.37" class="directional-text callback-text"><tspan>Sends script-coin-lock-spend-tx</tspan></text>
<path class="inline_expression_divider" d="M-41 1145.12h1044"/>
<path class="label-text-background" d="M459.98 1137.86h42.03v14.02h-42.03z"/>
<text x="481" y="1148.87" class="empty-text comment-row-text"><tspan>fail path</tspan></text>
<path d="M689 1232.05c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M692 1183.8h40.91v14.02H692z"/>
<text x="692" y="1194.8" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M692 1199.8h131.69v14.02H692z"/>
<text x="692" y="1210.8" class="directional-text method-text anchor-start"><tspan>script-coin-lock-tx lock to</tspan></text>
<path class="label-text-background" d="M692 1215.8h33.02v14.02H692z"/>
<text x="692" y="1226.8" class="directional-text method-text anchor-start"><tspan>expire</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 1296.18H273"/>
<path class="label-text-background" d="M359.98 1280.42h34.03v14.02h-34.03z"/>
<text x="377" y="1291.43" class="directional-text callback-text"><tspan>Sends</tspan></text>
<path class="label-text-background" d="M300.64 1298.42h152.72v14.02H300.64z"/>
<text x="377" y="1309.43" class="directional-text callback-text"><tspan>script-coin-lock-pre-refund-tx</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M273 1334.18h208"/>
<path class="label-text-background" d="M300.64 1318.42h152.72v14.02H300.64z"/>
<text x="377" y="1329.43" class="directional-text return-text"><tspan>script-coin-lock-pre-refund-tx</tspan></text>
<path d="M481 1489.11c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M484 1456.86h40.91v14.02H484z"/>
<text x="484" y="1467.86" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M484 1472.86h124.06v14.02H484z"/>
<text x="484" y="1483.86" class="directional-text method-text anchor-start"><tspan>pre-refund tx to confirm</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 1553.24H273"/>
<path class="label-text-background" d="M359.98 1537.48h34.03v14.02h-34.03z"/>
<text x="377" y="1548.49" class="directional-text callback-text"><tspan>Sends</tspan></text>
<path class="label-text-background" d="M282.3 1555.48h189.41v14.02H282.3z"/>
<text x="377" y="1566.49" class="directional-text callback-text"><tspan>script-coin-lock-pre-refund-spend-tx</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M273 1637.24h416"/>
<path class="label-text-background" d="M364.28 1621.48h233.44v14.02H364.28z"/>
<text x="481" y="1632.49" class="directional-text return-text"><tspan>Detects script-coin-lock-pre-refund-spend-tx</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 1675.24H273"/>
<path class="label-text-background" d="M382.97 1659.48h196.06v14.02H382.97z"/>
<text x="481" y="1670.49" class="directional-text callback-text"><tspan>Sends scriptless-coin-lock-recover-tx</tspan></text>
<path class="inline_expression_divider" d="M-37 1789.24H999"/>
<path class="label-text-background" d="M396.95 1781.98h168.09V1796H396.95z"/>
<text x="481" y="1792.99" class="empty-text comment-row-text"><tspan>bidder swipes script coin lock tx</tspan></text>
<path d="M689 1868.17c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M692 1835.91h40.91v14.02H692z"/>
<text x="692" y="1846.92" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M692 1851.91h142.41v14.02H692z"/>
<text x="692" y="1862.92" class="directional-text method-text anchor-start"><tspan>pre-refund tx lock to expire</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 1924.3H273"/>
<path class="label-text-background" d="M368.63 1908.55h224.75v14.02H368.63z"/>
<text x="481" y="1919.55" class="directional-text callback-text"><tspan>Sends script-coin-lock-pre-refund-swipe-tx</tspan></text>
</g>
<g id="mscgenjsreplaceme_notes">
<path d="m591 209 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="212.75" class="box-text abox-text"><tspan>Bid Sent</tspan></text>
<path class="box" style="stroke:red" d="M383 230h196v34H383z"/>
<text x="481" y="250.75" class="box-text"><tspan>User accepts bid</tspan></text>
<path d="M799 268h395v9h9m-9-9 9 9v41H799v-50z" class="box note" style="fill:#ffc"/>
<text x="1001" y="280.75" class="box-text note-text"><tspan>The BidAccept message contains the pubkeys the offerer will use and</tspan></text>
<text x="1001" y="296.75" class="box-text note-text"><tspan>a DLEAG proof one key will work across both chains of the swapping</tspan></text>
<text x="1001" y="312.75" class="box-text note-text"><tspan>coins</tspan></text>
<path d="m591 339 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="342.75" class="box-text abox-text"><tspan>Bid Receiving accept</tspan></text>
<path d="m591 377 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="380.75" class="box-text abox-text"><tspan>Bid Accepted</tspan></text>
<path d="M799 398h395v9h9m-9-9 9 9v25H799v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="410.75" class="box-text note-text"><tspan>The XmrBidLockTxSigsMessage contains the bidder&apos;s signatures for the</tspan></text>
<text x="1001" y="426.75" class="box-text note-text"><tspan>script-coin-lock-refund and script-coin-lock-refund-spend txns.</tspan></text>
<path d="m591 453 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="448.75" class="box-text abox-text"><tspan>Exchanged script lock tx sigs</tspan></text>
<text x="689" y="464.75" class="box-text abox-text"><tspan>msg</tspan></text>
<path d="M799 474h395v9h9m-9-9 9 9v25H799v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="486.75" class="box-text note-text"><tspan>The XmrBidLockSpendTxMessage contains the script-coin-lock-tx and</tspan></text>
<text x="1001" y="502.75" class="box-text note-text"><tspan>the offerer&apos;s signature for it.</tspan></text>
<path d="m591 529 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="532.75" class="box-text abox-text"><tspan>Bid Script coin spend tx valid</tspan></text>
<path d="m591 567 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="562.75" class="box-text abox-text"><tspan>Exchanged script lock spend tx</tspan></text>
<text x="689" y="578.75" class="box-text abox-text"><tspan>msg</tspan></text>
<path d="m591 680.06 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="683.81" class="box-text abox-text"><tspan>Bid Script coin locked</tspan></text>
<path d="m591 831.12 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="834.87" class="box-text abox-text"><tspan>Bid Scriptless coin locked</tspan></text>
<path d="M-40 869.12h98.39v11.02l-7 7H-40" class="box inline_expression_label"/>
<text x="-38" y="882.37" class="inline_expression-text alt-text anchor-start"><tspan>alt: success path</tspan></text>
<path d="M799 890.11h395v9h9m-9-9 9 9v73.02H799v-82.02z" class="box note" style="fill:#ffc"/>
<text x="1001" y="902.87" class="box-text note-text"><tspan>The XmrBidLockReleaseMessage contains the offerer&apos;s OTVES for it. </tspan></text>
<text x="1001" y="918.87" class="box-text note-text"><tspan> The bidder decodes the offerer&apos;s signature</tspan></text>
<text x="1001" y="934.87" class="box-text note-text"><tspan>from the OTVES. When the offerer has the</tspan></text>
<text x="1001" y="950.87" class="box-text note-text"><tspan>plaintext signature, they can decode the bidder&apos;s noscript-coin-lock-tx</tspan></text>
<text x="1001" y="966.87" class="box-text note-text"><tspan>signature.</tspan></text>
<path d="m591 993.12 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="996.87" class="box-text abox-text"><tspan>Script coin lock released</tspan></text>
<path d="m591 1069.12 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="1072.87" class="box-text abox-text"><tspan>Script tx redeemed</tspan></text>
<path d="m591 1107.12 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="1110.87" class="box-text abox-text"><tspan>Bid Completed</tspan></text>
<path d="M799 1279.18h395v9h9m-9-9 9 9v25H799v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="1299.93" class="box-text note-text"><tspan>tx can be sent by either party.</tspan></text>
<path d="m591 1372.18 3-17.01h190l3 17.01-3 17.01H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="1367.93" class="box-text abox-text"><tspan>Bid Script pre-refund tx in</tspan></text>
<text x="689" y="1383.93" class="box-text abox-text"><tspan>chain</tspan></text>
<path d="M-36 1410.18h200.86v11.02l-7 7H-36" class="box inline_expression_label"/>
<text x="-34" y="1423.43" class="inline_expression-text alt-text anchor-start"><tspan>alt: offerer refunds script coin lock tx</tspan></text>
<path d="M799 1528.23h395v9h9m-9-9 9 9v41.02H799v-50.02z" class="box note" style="fill:#ffc"/>
<text x="1001" y="1540.99" class="box-text note-text"><tspan>Refunds the script lock tx, with the offerer&apos;s cleartext signature</tspan></text>
<text x="1001" y="1556.99" class="box-text note-text"><tspan>the bidder can refund the noscript lock tx. </tspan></text>
<text x="1001" y="1572.99" class="box-text note-text"><tspan>Once the lock expires the pre-refund tx can be spent by the bidder.</tspan></text>
<path d="m383 1599.24 3-17h190l3 17-3 17H386z" class="box abox" style="stroke:red"/>
<text x="481" y="1602.99" class="box-text abox-text"><tspan>Bid Failed, refunded</tspan></text>
<path d="M799 1620.24h395v9h9m-9-9 9 9v25H799v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="1640.99" class="box-text note-text"><tspan>Bidder recovers the offerer&apos;s scriptless chain key-shard.</tspan></text>
<path d="m591 1713.24 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="1716.99" class="box-text abox-text"><tspan>Bid Scriptless tx recovered</tspan></text>
<path d="m591 1751.24 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="1754.99" class="box-text abox-text"><tspan>Bid Failed, refunded</tspan></text>
<path d="m591 1962.3 3-17h190l3 17-3 17H594z" class="box abox" style="stroke:#00f"/>
<text x="689" y="1966.05" class="box-text abox-text"><tspan>Bid Failed, swiped</tspan></text>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 39 KiB

View File

@@ -0,0 +1,388 @@
<svg version="1.1" id="mscgenjsreplaceme" class="mscgenjsreplaceme" xmlns="http://www.w3.org/2000/svg" width="1264" height="1933.3" style="font-family:Helvetica,sans-serif;font-size:12px;font-weight:400;font-style:normal;text-decoration:none;background-color:#fff;stroke:#000;stroke-width:2">
<defs>
<marker orient="auto" id="mscgenjsreplacemecallback-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#00f"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#00f"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-#008800" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#080"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#008800" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:#080"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="m1 1 8 2-8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:red"/>
</marker>
<marker orient="auto" id="mscgenjsreplacemecallback-l-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path d="M17 1 9 3l8 2" class="arrow-style" style="stroke-dasharray:100,1;stroke:red"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="#00F" fill="#00F" d="m1 1 8 2-8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-l-#0000FF" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="#00F" fill="#00F" d="M17 1 9 3l8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="red" fill="red" d="m1 1 8 2-8 2z"/>
</marker>
<marker orient="auto" id="mscgenjsreplacememethod-l-#FF0000" class="arrow-marker" viewBox="0 0 10 10" refX="9" refY="3" markerUnits="strokeWidth" markerWidth="10" markerHeight="10">
<path class="arrow-style" stroke="red" fill="red" d="M17 1 9 3l8 2z"/>
</marker>
<style>
.mscgenjsreplaceme path,.mscgenjsreplaceme rect{fill:none}.mscgenjsreplaceme .label-text-background{fill:#fff;stroke:#fff;stroke-width:0}.mscgenjsreplaceme .return{stroke-dasharray:5,3}.mscgenjsreplaceme text{color:inherit;stroke:none;text-anchor:middle}.mscgenjsreplaceme text.anchor-start{text-anchor:start}.mscgenjsreplaceme .arrow-marker{overflow:visible}.mscgenjsreplaceme .arrow-style{stroke-width:1}.mscgenjsreplaceme .arcrow{stroke-linecap:butt}.mscgenjsreplaceme .box,.mscgenjsreplaceme .entity{fill:#fff;stroke-linejoin:round}
</style>
</defs>
<g id="mscgenjsreplaceme_body" transform="translate(47 3)">
<path class="bglayer" style="fill:#fff;stroke:#fff;stroke-width:0" d="M-47-3h1264v1933.3H-47z" id="mscgenjsreplaceme_background"/>
<path class="box inline_expression alt" d="M-39 778.06h1040V1908.3H-39z" id="mscgenjsreplaceme_arcspans"/>
<g id="mscgenjsreplaceme_lifelines">
<path class="arcrow" style="stroke:transparent" d="M65 38v38"/>
<path class="arcrow" style="stroke:#080" d="M273 38v38"/>
<path class="arcrow" style="stroke:red" d="M481 38v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 38v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 38v38M1105 38v38M65 76v38"/>
<path class="arcrow" style="stroke:#080" d="M273 76v38"/>
<path class="arcrow" style="stroke:red" d="M481 76v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 76v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 76v38M1105 76v38M65 114v38"/>
<path class="arcrow" style="stroke:#080" d="M273 114v38"/>
<path class="arcrow" style="stroke:red" d="M481 114v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 114v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 114v38M1105 114v38M65 152v38"/>
<path class="arcrow" style="stroke:#080" d="M273 152v38"/>
<path class="arcrow" style="stroke:red" d="M481 152v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 152v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 152v38M1105 152v38M65 190v38"/>
<path class="arcrow" style="stroke:#080" d="M273 190v38"/>
<path class="arcrow" style="stroke:red" d="M481 190v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 190v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 190v38M1105 190v38M65 228v38"/>
<path class="arcrow" style="stroke:#080" d="M273 228v38"/>
<path class="arcrow" style="stroke:red" d="M481 228v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 228v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 228v38M1105 228v38M65 266v38"/>
<path class="arcrow" style="stroke:#080" d="M273 266v38"/>
<path class="arcrow" style="stroke:red" d="M481 266v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 266v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 266v38M1105 266v38M65 304v38"/>
<path class="arcrow" style="stroke:#080" d="M273 304v38"/>
<path class="arcrow" style="stroke:red" d="M481 304v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 304v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 304v38M1105 304v38M65 342v38"/>
<path class="arcrow" style="stroke:#080" d="M273 342v38"/>
<path class="arcrow" style="stroke:red" d="M481 342v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 342v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 342v38M1105 342v38M65 380v38"/>
<path class="arcrow" style="stroke:#080" d="M273 380v38"/>
<path class="arcrow" style="stroke:red" d="M481 380v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 380v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 380v38M1105 380v38M65 418v38"/>
<path class="arcrow" style="stroke:#080" d="M273 418v38"/>
<path class="arcrow" style="stroke:red" d="M481 418v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 418v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 418v38M1105 418v38M65 456v38"/>
<path class="arcrow" style="stroke:#080" d="M273 456v38"/>
<path class="arcrow" style="stroke:red" d="M481 456v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 456v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 456v38M1105 456v38M65 494v38"/>
<path class="arcrow" style="stroke:#080" d="M273 494v38"/>
<path class="arcrow" style="stroke:red" d="M481 494v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 494v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 494v38M1105 494v38M65 532v38"/>
<path class="arcrow" style="stroke:#080" d="M273 532v38"/>
<path class="arcrow" style="stroke:red" d="M481 532v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 532v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 532v38M1105 532v38M65 570v38"/>
<path class="arcrow" style="stroke:#080" d="M273 570v38"/>
<path class="arcrow" style="stroke:red" d="M481 570v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 570v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 570v38M1105 570v38M65 608v38"/>
<path class="arcrow" style="stroke:#080" d="M273 608v38"/>
<path class="arcrow" style="stroke:red" d="M481 608v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 608v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 608v38M1105 608v38M65 646v75.06"/>
<path class="arcrow" style="stroke:#080" d="M273 646v75.06"/>
<path class="arcrow" style="stroke:red" d="M481 646v75.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 646v75.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 646v75.06M1105 646v75.06M65 721.06v38"/>
<path class="arcrow" style="stroke:#080" d="M273 721.06v38"/>
<path class="arcrow" style="stroke:red" d="M481 721.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 721.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 721.06v38M1105 721.06v38M65 759.06v38"/>
<path class="arcrow" style="stroke:#080" d="M273 759.06v38"/>
<path class="arcrow" style="stroke:red" d="M481 759.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 759.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 759.06v38M1105 759.06v38M65 797.06v38"/>
<path class="arcrow" style="stroke:#080" d="M273 797.06v38"/>
<path class="arcrow" style="stroke:red" d="M481 797.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 797.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 797.06v38M1105 797.06v38M65 835.06v38"/>
<path class="arcrow" style="stroke:#080" d="M273 835.06v38"/>
<path class="arcrow" style="stroke:red" d="M481 835.06v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 835.06v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 835.06v38M1105 835.06v38M65 873.06v75.06"/>
<path class="arcrow" style="stroke:#080" d="M273 873.06v75.06"/>
<path class="arcrow" style="stroke:red" d="M481 873.06v75.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 873.06v75.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 873.06v75.06M1105 873.06v75.06M65 948.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 948.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 948.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 948.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 948.12v38M1105 948.12v38M65 986.12v86"/>
<path class="arcrow" style="stroke:#080" d="M273 986.12v86"/>
<path class="arcrow" style="stroke:red" d="M481 986.12v86"/>
<path class="arcrow" style="stroke:#00f" d="M689 986.12v86"/>
<path class="arcrow" style="stroke:transparent" d="M897 986.12v86M1105 986.12v86M65 1072.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1072.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1072.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1072.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1072.12v38M1105 1072.12v38M65 1110.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1110.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1110.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1110.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1110.12v38M1105 1110.12v38M65 1148.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1148.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1148.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1148.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1148.12v38M1105 1148.12v38M65 1186.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1186.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1186.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1186.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1186.12v38M1105 1186.12v38M65 1224.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1224.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1224.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1224.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1224.12v38M1105 1224.12v38M65 1262.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1262.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1262.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1262.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1262.12v38M1105 1262.12v38M65 1300.12v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1300.12v38"/>
<path class="arcrow" style="stroke:red" d="M481 1300.12v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1300.12v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1300.12v38M1105 1300.12v38M65 1338.12v75.06"/>
<path class="arcrow" style="stroke:#080" d="M273 1338.12v75.06"/>
<path class="arcrow" style="stroke:red" d="M481 1338.12v75.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 1338.12v75.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 1338.12v75.06M1105 1338.12v75.06M65 1413.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1413.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1413.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1413.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1413.18v38M1105 1413.18v38M65 1451.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1451.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1451.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1451.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1451.18v38M1105 1451.18v38M65 1489.18v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1489.18v38"/>
<path class="arcrow" style="stroke:red" d="M481 1489.18v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1489.18v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1489.18v38M1105 1489.18v38M65 1527.18v75.06"/>
<path class="arcrow" style="stroke:#080" d="M273 1527.18v75.06"/>
<path class="arcrow" style="stroke:red" d="M481 1527.18v75.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 1527.18v75.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 1527.18v75.06M1105 1527.18v75.06M65 1602.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1602.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1602.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1602.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1602.24v38M1105 1602.24v38M65 1640.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1640.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1640.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1640.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1640.24v38M1105 1640.24v38M65 1678.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1678.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1678.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1678.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1678.24v38M1105 1678.24v38M65 1716.24v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1716.24v38"/>
<path class="arcrow" style="stroke:red" d="M481 1716.24v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1716.24v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1716.24v38M1105 1716.24v38M65 1754.24v59.06"/>
<path class="arcrow" style="stroke:#080" d="M273 1754.24v59.06"/>
<path class="arcrow" style="stroke:red" d="M481 1754.24v59.06"/>
<path class="arcrow" style="stroke:#00f" d="M689 1754.24v59.06"/>
<path class="arcrow" style="stroke:transparent" d="M897 1754.24v59.06M1105 1754.24v59.06M65 1813.3v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1813.3v38"/>
<path class="arcrow" style="stroke:red" d="M481 1813.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1813.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1813.3v38M1105 1813.3v38M65 1851.3v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1851.3v38"/>
<path class="arcrow" style="stroke:red" d="M481 1851.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1851.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1851.3v38M1105 1851.3v38M65 1889.3v38"/>
<path class="arcrow" style="stroke:#080" d="M273 1889.3v38"/>
<path class="arcrow" style="stroke:red" d="M481 1889.3v38"/>
<path class="arcrow" style="stroke:#00f" d="M689 1889.3v38"/>
<path class="arcrow" style="stroke:transparent" d="M897 1889.3v38M1105 1889.3v38"/>
</g>
<g id="mscgenjsreplaceme_sequence">
<path class="entity" style="stroke:transparent" d="M0 0h130v38H0z"/>
<text x="65" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="entity" style="fill:#cfc;stroke:#080" d="M208 0h130v38H208z"/>
<text x="273" y="22.75" class="entity-text"><tspan>Network</tspan></text>
<path class="entity" style="fill:#fcc;stroke:red" d="M416 0h130v38H416z"/>
<text x="481" y="22.75" class="entity-text"><tspan>Offerer</tspan></text>
<path class="entity" style="fill:#ccf;stroke:#00f" d="M624 0h130v38H624z"/>
<text x="689" y="22.75" class="entity-text"><tspan>Bidder</tspan></text>
<path class="entity" style="stroke:transparent" d="M832 0h130v38H832z"/>
<text x="897" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="entity" style="stroke:transparent" d="M1040 0h130v38h-130z"/>
<text x="1105" y="22.75" class="entity-text"><tspan> </tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 95H273"/>
<path class="label-text-background" d="M345.08 79.25h63.84v14h-63.84z"/>
<text x="377" y="90.25" class="directional-text callback-text"><tspan>Sends Offer</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M273 133h416"/>
<path class="label-text-background" d="M445.75 117.25h70.5v14h-70.5z"/>
<text x="481" y="128.25" class="directional-text return-text"><tspan>Detects Offer</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 171H481"/>
<path class="label-text-background" d="M557.64 155.25h54.72v14h-54.72z"/>
<text x="585" y="166.25" class="directional-text callback-text"><tspan>Sends Bid</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 323h208"/>
<path class="label-text-background" d="M513.28 307.25h143.77v14H513.28z"/>
<text x="585" y="318.25" class="directional-text callback-text"><tspan>Sends BidAccept message</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 399H481"/>
<path class="label-text-background" d="M491.28 383.25h187.77v14H491.28z"/>
<text x="585" y="394.25" class="directional-text callback-text"><tspan>Sends XmrBidLockTxSigsMessage</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 475H273"/>
<path class="label-text-background" d="M311.64 459.25h130.72v14H311.64z"/>
<text x="377" y="470.25" class="directional-text callback-text"><tspan>Sends script-coin-lock-tx</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 551h208"/>
<path class="label-text-background" d="M485.61 535.25h199.11v14H485.61z"/>
<text x="585" y="546.25" class="directional-text callback-text"><tspan>Sends XmrBidLockSpendTxMessage</tspan></text>
<path d="M689 675.93c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:#00f" marker-end="url(#mscgenjsreplacememethod-#0000FF)"/>
<path class="label-text-background" d="M692 627.67h40.91v14.02H692z"/>
<text x="692" y="638.68" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M692 643.67h107.02v14.02H692z"/>
<text x="692" y="654.68" class="directional-text method-text anchor-start"><tspan>script-coin-lock-tx to</tspan></text>
<path class="label-text-background" d="M692 659.67h39.34v14.02H692z"/>
<text x="692" y="670.68" class="directional-text method-text anchor-start"><tspan>confirm</tspan></text>
<path d="M481 675.93c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M484 627.67h40.91v14.02H484z"/>
<text x="484" y="638.68" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M484 643.67h107.02v14.02H484z"/>
<text x="484" y="654.68" class="directional-text method-text anchor-start"><tspan>script-coin-lock-tx to</tspan></text>
<path class="label-text-background" d="M484 659.67h39.34v14.02H484z"/>
<text x="484" y="670.68" class="directional-text method-text anchor-start"><tspan>confirm</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 816.06H273"/>
<path class="label-text-background" d="M408.97 800.3h144.06v14.02H408.97z"/>
<text x="481" y="811.31" class="directional-text callback-text"><tspan>Sends noscript-coin-lock-tx</tspan></text>
<path d="M481 902.99c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M484 854.73h40.91v14.02H484z"/>
<text x="484" y="865.74" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M484 870.73h120.38v14.02H484z"/>
<text x="484" y="881.74" class="directional-text method-text anchor-start"><tspan>noscript-coin-lock-tx to</tspan></text>
<path class="label-text-background" d="M484 886.73h39.34v14.02H484z"/>
<text x="484" y="897.74" class="directional-text method-text anchor-start"><tspan>confirm</tspan></text>
<path class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)" d="M481 1029.12h208"/>
<path class="label-text-background" d="M519.64 1013.36h130.72v14.02H519.64z"/>
<text x="585" y="1024.37" class="directional-text method-text"><tspan>Sends script-coin-lock-tx</tspan></text>
<path class="label-text-background" d="M539.3 1031.36h91.73v14.02H539.3z"/>
<text x="585" y="1042.37" class="directional-text method-text"><tspan>release message</tspan></text>
<path class="arc directional callback" style="stroke:#00f" marker-end="url(#mscgenjsreplacemecallback-#0000FF)" d="M689 1129.12H273"/>
<path class="label-text-background" d="M397.3 1113.36h167.41v14.02H397.3z"/>
<text x="481" y="1124.37" class="directional-text callback-text"><tspan>Sends script-coin-lock-spend-tx</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M273 1167.12h208"/>
<path class="label-text-background" d="M289.97 1151.36h174.06v14.02H289.97z"/>
<text x="377" y="1162.37" class="directional-text return-text"><tspan>Detects script-coin-lock-spend-tx</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 1243.12H273"/>
<path class="label-text-background" d="M286.63 1227.36h180.75v14.02H286.63z"/>
<text x="377" y="1238.37" class="directional-text callback-text"><tspan>Sends noscript-coin-lock-spend-tx</tspan></text>
<path d="M481 1368.05c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M484 1319.8h40.91v14.02H484z"/>
<text x="484" y="1330.8" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M484 1335.8h143.39v14.02H484z"/>
<text x="484" y="1346.8" class="directional-text method-text anchor-start"><tspan>noscript-coin-lock-spend-tx</tspan></text>
<path class="label-text-background" d="M484 1351.8h52.69v14.02H484z"/>
<text x="484" y="1362.8" class="directional-text method-text anchor-start"><tspan>to confirm</tspan></text>
<path class="inline_expression_divider" style="stroke-dasharray:10,5" d="M-39 1470.18h1040"/>
<path class="label-text-background" d="M459.98 1462.92h42.03v14.02h-42.03z"/>
<text x="481" y="1473.93" class="empty-text comment-row-text"><tspan>fail path</tspan></text>
<path d="M481 1557.11c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M484 1508.86h40.91v14.02H484z"/>
<text x="484" y="1519.86" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M484 1524.86h93.36v14.02H484z"/>
<text x="484" y="1535.86" class="directional-text method-text anchor-start"><tspan>script-coin-lock-tx</tspan></text>
<path class="label-text-background" d="M484 1540.86h93.7v14.02H484z"/>
<text x="484" y="1551.86" class="directional-text method-text anchor-start"><tspan>locktime to expire</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 1621.24H273"/>
<path class="label-text-background" d="M359.98 1605.48h34.03v14.02h-34.03z"/>
<text x="377" y="1616.49" class="directional-text callback-text"><tspan>Sends</tspan></text>
<path class="label-text-background" d="M300.64 1623.48h152.72v14.02H300.64z"/>
<text x="377" y="1634.49" class="directional-text callback-text"><tspan>script-coin-lock-pre-refund-tx</tspan></text>
<path class="arc directional return" style="stroke:#080" marker-end="url(#mscgenjsreplacemecallback-#008800)" d="M273 1659.24h208"/>
<path class="label-text-background" d="M300.64 1643.48h152.72v14.02H300.64z"/>
<text x="377" y="1654.49" class="directional-text return-text"><tspan>script-coin-lock-pre-refund-tx</tspan></text>
<path d="M481 1776.17c104 .1 104 22.8 0 22.8" class="arc directional method" style="stroke:red" marker-end="url(#mscgenjsreplacememethod-#FF0000)"/>
<path class="label-text-background" d="M484 1743.91h40.91v14.02H484z"/>
<text x="484" y="1754.92" class="directional-text method-text anchor-start"><tspan>Wait for</tspan></text>
<path class="label-text-background" d="M484 1759.91h124.06v14.02H484z"/>
<text x="484" y="1770.92" class="directional-text method-text anchor-start"><tspan>pre-refund tx to confirm</tspan></text>
<path class="arc directional callback" style="stroke:red" marker-end="url(#mscgenjsreplacemecallback-#FF0000)" d="M481 1832.3H273"/>
<path class="label-text-background" d="M359.98 1816.55h34.03v14.02h-34.03z"/>
<text x="377" y="1827.55" class="directional-text callback-text"><tspan>Sends</tspan></text>
<path class="label-text-background" d="M282.3 1834.55h189.41v14.02H282.3z"/>
<text x="377" y="1845.55" class="directional-text callback-text"><tspan>script-coin-lock-pre-refund-spend-tx</tspan></text>
</g>
<g id="mscgenjsreplaceme_notes">
<path d="m381 209 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="212.75" class="box-text abox-text"><tspan>Bid Receiving</tspan></text>
<path d="m381 247 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="250.75" class="box-text abox-text"><tspan>Bid Received</tspan></text>
<path class="box" style="stroke:red" d="M381 268h200v34H381z"/>
<text x="481" y="288.75" class="box-text"><tspan>User accepts bid</tspan></text>
<path d="M797 306h399v9h9m-9-9 9 9v25H797v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="318.75" class="box-text note-text"><tspan>The BidAccept message contains the pubkeys the offerer will use and a</tspan></text>
<text x="1001" y="334.75" class="box-text note-text"><tspan>DLEAG proof one key will work across both chains of the swapping coins</tspan></text>
<path d="m381 361 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="364.75" class="box-text abox-text"><tspan>Bid Accepted</tspan></text>
<path d="M797 382h399v9h9m-9-9 9 9v25H797v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="394.75" class="box-text note-text"><tspan>The XmrBidLockTxSigsMessage contains the bidder&apos;s signatures for the</tspan></text>
<text x="1001" y="410.75" class="box-text note-text"><tspan>script-coin-lock-refund and script-coin-lock-refund-spend txns.</tspan></text>
<path d="m381 437 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="432.75" class="box-text abox-text"><tspan>Exchanged script lock tx sigs</tspan></text>
<text x="481" y="448.75" class="box-text abox-text"><tspan>msg</tspan></text>
<path d="m381 513 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="516.75" class="box-text abox-text"><tspan>Bid Script coin spend tx valid</tspan></text>
<path d="M797 534h399v9h9m-9-9 9 9v25H797v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="546.75" class="box-text note-text"><tspan>The XmrBidLockSpendTxMessage contains the script-coin-lock-tx and the</tspan></text>
<text x="1001" y="562.75" class="box-text note-text"><tspan>offerer&apos;s signature for it.</tspan></text>
<path d="m381 589 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="584.75" class="box-text abox-text"><tspan>Exchanged script lock spend tx</tspan></text>
<text x="481" y="600.75" class="box-text abox-text"><tspan>msg</tspan></text>
<path d="m381 740.06 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="743.81" class="box-text abox-text"><tspan>Bid Script coin locked</tspan></text>
<path d="M-38 778.06h98.39v11.02l-7 7H-38" class="box inline_expression_label"/>
<text x="-36" y="791.31" class="inline_expression-text alt-text anchor-start"><tspan>alt: success path</tspan></text>
<path d="m381 967.12 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="970.87" class="box-text abox-text"><tspan>Bid Scriptless coin locked</tspan></text>
<path d="M797 988.11h399v9h9m-9-9 9 9v73.02H797v-82.02z" class="box note" style="fill:#ffc"/>
<text x="1001" y="1000.87" class="box-text note-text"><tspan>The XmrBidLockReleaseMessage contains the offerer&apos;s OTVES for the</tspan></text>
<text x="1001" y="1016.87" class="box-text note-text"><tspan>script-coin-lock-tx. The bidder decodes the</tspan></text>
<text x="1001" y="1032.87" class="box-text note-text"><tspan>offerer&apos;s signature from the OTVES. When the</tspan></text>
<text x="1001" y="1048.87" class="box-text note-text"><tspan>offerer has the plaintext signature, they can decode the bidder&apos;s key</tspan></text>
<text x="1001" y="1064.87" class="box-text note-text"><tspan>for the noscript-lock-tx.</tspan></text>
<path d="m381 1091.12 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="1094.87" class="box-text abox-text"><tspan>Bid Script coin lock released</tspan></text>
<path d="m381 1205.12 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="1208.87" class="box-text abox-text"><tspan>Bid Script tx redeemed</tspan></text>
<path d="M797 1188.11h399v9h9m-9-9 9 9v25.02H797v-34.02z" class="box note" style="fill:#ffc"/>
<text x="1001" y="1200.87" class="box-text note-text"><tspan>The offerer extracts the bidder&apos;s plaintext signature and derives the</tspan></text>
<text x="1001" y="1216.87" class="box-text note-text"><tspan>bidder&apos;s noscript-lock-tx keyhalf.</tspan></text>
<path d="m381 1281.12 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="1284.87" class="box-text abox-text"><tspan>Bid Scriptless tx redeemed</tspan></text>
<path d="m381 1432.18 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="1435.93" class="box-text abox-text"><tspan>Bid Completed</tspan></text>
<path d="M797 1604.24h399v9h9m-9-9 9 9v25H797v-34z" class="box note" style="fill:#ffc"/>
<text x="1001" y="1624.99" class="box-text note-text"><tspan>tx can be sent by either party.</tspan></text>
<path d="m381 1697.24 3-17.01h194l3 17.01-3 17.01H384z" class="box abox" style="stroke:red"/>
<text x="481" y="1692.99" class="box-text abox-text"><tspan>Bid Script pre-refund tx in</tspan></text>
<text x="481" y="1708.99" class="box-text abox-text"><tspan>chain</tspan></text>
<path d="M797 1815.29h399v9h9m-9-9 9 9v25.02H797v-34.02z" class="box note" style="fill:#ffc"/>
<text x="1001" y="1828.05" class="box-text note-text"><tspan>Refunds the script lock tx, with the offerer&apos;s cleartext signature</tspan></text>
<text x="1001" y="1844.05" class="box-text note-text"><tspan>the bidder can refund the noscript lock tx.</tspan></text>
<path d="m381 1870.3 3-17h194l3 17-3 17H384z" class="box abox" style="stroke:red"/>
<text x="481" y="1874.05" class="box-text abox-text"><tspan>Bid Failed, refunded</tspan></text>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 36 KiB

View File

@@ -1,15 +0,0 @@
.padded_row td
{
padding-top:1.5em;
}
.bold
{
font-weight:bold;
}
.monospace
{
font-family:monospace;
}

View File

@@ -1,6 +1,57 @@
{% include 'header.html' %}
<div class="container mx-auto">
<p>404 Page Not Found</p>
<section class="bg-white p-5 mt-5">
<div class="flex flex-wrap items-center -m-2">
<div class="w-full md:w-1/2 p-2">
<ul class="flex flex-wrap items-center gap-x-3 mb-2">
<li>
<a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/">
<p>Home</p>
</a>
</li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/404">404</a></li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
</ul>
</div>
</div>
</section>
<p><a href="/">home</a></p>
</body></html>
{% include 'inc_messages.html' %}
<section class="relative py-24 md:py-40 bg-white">
<div class="relative z-10 container px-4 mx-auto">
<div class="flex flex-wrap items-center -mx-4">
<div class="w-full md:w-1/2 px-4 mb-16 md:mb-0">
<div class="md:max-w-xl md:mx-auto text-center md:text-left">
<span class="inline-block mb-6 px-3 py-1 font-semibold bg-blue-100 rounded-full text-sm">Error 404</span>
<h2 class="mb-4 text-4xl md:text-5xl leading-tight font-bold tracking-tighter">Oh no! Error 404</h2>
<p class="mb-6 text-lg md:text-xl text-coolGray-500">Something went wrong, so this page is broken.</p>
<div class="flex flex-wrap">
<div class="w-full lg:w-auto py-1 lg:py-0 lg:mr-6"><a class="inline-block py-5 px-7 w-full text-base md:text-lg leading-4 text-blue-50 font-medium text-center bg-blue-500 hover:bg-blue-600 border border-blue-500 rounded-md shadow-sm focus:ring-0 focus:outline-none" href="/">Go back to Homepage</a></div>
<div class="w-full lg:w-auto py-1 lg:py-0"><a class="inline-block py-5 px-7 w-full text-base md:text-lg leading-4 text-coolGray-800 font-medium text-center bg-white hover:bg-coolGray-100 border border-coolGray-200 rounded-md shadow-sm focus:ring-0 focus:outline-none" href="/refresh">Try Again</a></div> <!-- todo add last URL page visit -->
</div>
</div>
</div>
<div class="w-full md:w-1/3 px-4">
<img class="mx-auto" src="/static/images/other/what-why.gif" alt="">
</div>
</div>
</div>
</section>
</div>
{% include 'footer.html' %}
</div>
</body>
</html>

View File

@@ -1,16 +1,97 @@
{% include 'header.html' %}
<div class="container mx-auto">
<h3>Active Swaps</h3>
{% if refresh %}
<p>Page Refresh: {{ refresh }} seconds</p>
{% endif %}
<section class="bg-white p-5 mt-5">
<div class="flex flex-wrap items-center -m-2">
<div class="w-full md:w-1/2 p-2">
<ul class="flex flex-wrap items-center gap-x-3 mb-2">
<li>
<a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/">
<p>Home</p>
</a>
</li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/active">Swaps In Progress</a></li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
</ul>
</div>
</div>
</section>
<table>
<tr><th>Bid ID</th><th>Offer ID</th><th>Bid Status</th><th>ITX Status</th><th>PTX Status</th></tr>
{% for s in active_swaps %}
<tr><td><a class="monospace" href=/bid/{{ s[0] }}>{{ s[0] }}</a></td><td><a class="monospace" href=/offer/{{ s[1] }}>{{ s[1] }}</a></td><td>{{ s[2] }}</td><td>{{ s[3] }}</td><td>{{ s[4] }}</td></tr>
{% endfor %}
</table>
<section class="py-4">
<div class="container px-4 mx-auto">
<div class="relative py-11 px-16 bg-coolGray-900 rounded-md overflow-hidden">
<img class="absolute z-10 left-4 top-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute z-10 right-4 bottom-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute h-64 left-1/2 top-1/2 transform -translate-x-1/2 -translate-y-1/2 object-cover" src="/static/images/elements/wave.svg" alt="">
<div class="relative z-20 flex flex-wrap items-center">
<div class="w-full md:w-1/2 p-3">
<h2 class="mb-6 text-4xl font-bold text-white tracking-tighter">Swaps in Progress / Active Swaps</h2>
<p class="font-semibold text-coolGray-200">
{% if refresh %}
Page Refresh {{ refresh }} seconds
{% endif %}
</p>
</div>
<div class="w-full md:w-1/2 p-3">
<a id="refresh" href="/active"><button class="block md:ml-auto px-5 py-3 font-medium text-lcg text-white bg-blue-500 hover:bg-blue-600 rounded-md focus:ring-0 focus:outline-none">Refresh</button></a>
</div>
</div>
</div>
</div>
</section>
<p><a href="/">home</a></p>
</body></html>
<section class="bg-white">
<div class="pl-6 pr-6 pt-0 pb-0 mt-5 h-full overflow-hidden bg-white">
<div class="pb-6 border-coolGray-100">
<div class="flex flex-wrap items-center justify-between -m-2">
<div class="w-full pt-2">
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6"> Bid ID </th>
<th scope="col" class="py-3 px-6"> Offer ID </th>
<th scope="col" class="py-3 px-6"> Bid Status </th>
<th scope="col" class="py-4 px-7"> ITX Status </th>
<th scope="col" class="py-3 px-7"> PTX Status </th>
</tr>
</thead>
<tbody>
{% for s in active_swaps %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 text-xs monospace"><a href=/bid/{{ s[0] }}>{{ s[0] }}</a></td>
<td class="py-4 px-6 text-xs monospace"><a href=/offer/{{ s[1] }}>{{ s[1] }}</a></td>
<td class="py-4 px-6">{{ s[2] }}</td>
<td class="py-4 px-6">{{ s[3] }}</td>
<td class="py-4 px-6">{{ s[4] }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</div>
{% include 'footer.html' %}
</body>
</html>

View File

@@ -0,0 +1,173 @@
{% include 'header.html' %}
<div class="container mx-auto">
<section class="bg-white p-5 mt-5">
<div class="flex flex-wrap items-center -m-2">
<div class="w-full md:w-1/2 p-2">
<ul class="flex flex-wrap items-center gap-x-3 mb-2">
<li>
<a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/">
<p>Home</p>
</a>
</li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/automation">Automation Strategies</a></li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
</ul>
</div>
</div>
</section>
<section class="py-4">
<div class="container px-4 mx-auto">
<div class="relative py-11 px-16 bg-coolGray-900 rounded-md overflow-hidden">
<img class="absolute z-10 left-4 top-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute z-10 right-4 bottom-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute h-64 left-1/2 top-1/2 transform -translate-x-1/2 -translate-y-1/2 object-cover" src="/static/elements/wave.svg" alt="">
<div class="relative z-20 flex flex-wrap items-center -m-3">
<div class="w-full md:w-1/2 p-3">
<h2 class="mb-6 text-4xl font-bold text-white tracking-tighter">Automation Strategies</h2>
<p class="font-semibold text-coolGray-200"></p>
</div>
<div class="w-full md:w-1/2 p-3">
<a id="refresh" href="/newautomationstrategy"><button class="block md:ml-auto px-5 py-3 font-medium text-lcg text-white bg-blue-500 hover:bg-blue-600 rounded-md focus:ring-0 focus:outline-none">Create New Strategy</button></a>
</div>
</div>
</div>
</div>
</section>
{% include 'inc_messages.html' %}
<section class="bg-white">
<div class="pl-6 pr-6 pt-0 pb-0 mt-5 h-full overflow-hidden bg-white ">
<div class="pb-6 border-coolGray-100">
<div class="flex flex-wrap items-center justify-between -m-2">
<div class="w-full pt-2">
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<form method="post">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Filter</th>
<th scope="col" class="py-3 px-6"></th>
<th scope="col"></th>
</tr>
</thead>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold w-96">
Sort by:
</td>
<td class="py-4 bold w-96">
<select class="bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5" name="sort_by">
<option value="created_at"{% if filters.sort_by=='created_at' %} selected{% endif %}>Created At</option>
</select>
</td>
<td class="py-4 px-6 pr-5">
<select class="pr-15 bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5" name="sort_dir">
<option value="asc"{% if filters.sort_dir=='asc' %} selected{% endif %}>Ascending</option>
<option value="desc"{% if filters.sort_dir=='desc' %} selected{% endif %}>Descending</option>
</select>
</td>
</tr>
</table>
</div>
</div>
<div class="pt-10 bg-white bg-opacity-60 rounded-b-md">
<div class="w-full md:w-0/12">
<div class="flex flex-wrap justify-end -m-1.5">
<div class="w-full md:w-auto p-1.5">
<button type="submit" name='pageback' value="Page Back" class="outline-none flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<svg aria-hidden="true" class="mr-2 w-5 h-5" fill="#556987" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" d="M7.707 14.707a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414l4-4a1 1 0 011.414 1.414L5.414 9H17a1 1 0 110 2H5.414l2.293 2.293a1 1 0 010 1.414z" clip-rule="evenodd"></path>
</svg> <span>Page Back</span> </button>
</div>
<div class="flex items-center">
<div class="w-full md:w-auto p-1.5">
<p class="text-sm font-heading">Page: {{ filters.page_no }}</p>
</div>
</div>
<div class="w-full md:w-auto p-1.5">
<button type="submit" name='pageforwards' value="Page Forwards" class="outline-none flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none"> <span>Page Forwards</span>
<svg aria-hidden="true" class="ml-2 w-5 h-5" fill="#556987" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" d="M12.293 5.293a1 1 0 011.414 0l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414-1.414L14.586 11H3a1 1 0 110-2h11.586l-2.293-2.293a1 1 0 010-1.414z" clip-rule="evenodd"></path>
</svg>
</button>
</div>
<div class="w-full md:w-auto p-1.5 ml-2">
<button name='clearfilters' value="Clear Filters" class="outline-none flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Clear Filters</span> </button>
</div>
<div class="w-full md:w-auto p-1.5 ml-2">
<button value="Submit" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 bg-blue-500 hover:bg-blue-600 font-medium text-sm text-white border border-blue-500 rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Submit</span> </button>
</div>
</div>
</div>
</div>
<input type="hidden" name="formid" value="{{ form_id }}">
<input type="hidden" name="pageno" value="{{ filters.page_no }}">
</form>
<div class="container px-0 mx-auto mt-10">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Name</th>
<th scope="col" class="py-3">Type</th>
</tr>
</thead>
{% for s in strategies %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold w-96">
<a class="monospace bolder-t" href=/automationstrategy/{{ s[0] }}>{{ s[1] }}</a>
</td>
<td class="py-4 pr-5">{{ s[2] }}
</td>
</tr>
{% endfor %}
</table>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</div>
{% include 'footer.html' %}
</div>
</body>
</html>

View File

@@ -0,0 +1,122 @@
{% include 'header.html' %}
<div class="container mx-auto">
<section class="bg-white p-5 mt-5">
<div class="flex flex-wrap items-center -m-2">
<div class="w-full md:w-1/2 p-2">
<ul class="flex flex-wrap items-center gap-x-3 mb-2">
<li>
<a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/">
<p>Home</p>
</a>
</li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/automation">Automation Strategies</a></li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/automation">ID: {{ strategy_id }}</a></li>
</ul>
</div>
</div>
</section>
<section class="py-4">
<div class="container px-4 mx-auto">
<div class="relative py-11 px-16 bg-coolGray-900 rounded-md overflow-hidden">
<img class="absolute z-10 left-4 top-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute z-10 right-4 bottom-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute h-64 left-1/2 top-1/2 transform -translate-x-1/2 -translate-y-1/2 object-cover" src="/static/images/elements/wave.svg" alt="">
<div class="relative z-20 flex flex-wrap items-center -m-3">
<div class="w-full md:w-1/2 p-3">
<h2 class="mb-6 text-4xl font-bold text-white tracking-tighter">Automation Strategy {{ strategy_id }}</h2>
</div>
</div>
</div>
</div>
</section>
{% include 'inc_messages.html' %}
<section class="bg-white">
<div class="pl-6 pr-6 pt-0 pb-0 mt-5 h-full overflow-hidden bg-white ">
<div class="pb-6 border-coolGray-100">
<div class="flex flex-wrap items-center justify-between -m-2">
<div class="w-full pt-2 text-center ">
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Option</th>
<th scope="col" class="py-3">Type</th>
<th scope="col"></th>
</tr>
</thead>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold w-96">Label</td>
<td>{{ strategy.label }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold w-96">Type</td>
<td>{{ strategy.type }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold w-96">Only known identities</td>
<td>{{ strategy.only_known_identities }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold w-96">Data</td>
<td class="py-4 pr-5">
<textarea class="outline-none block p-2.5 text-sm text-gray-900 bg-gray-50 rounded-lg border border-gray-300 focus:ring-blue-500 focus:border-blue-500 w-full monospace" rows="5" readonly>
{{ strategy.data }}
</textarea>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold w-96">Notes</td>
<td class="py-4 pr-5">
<textarea class="outline-none block p-2.5 text-sm text-gray-900 bg-gray-50 rounded-lg border border-gray-300 focus:ring-blue-500 focus:border-blue-500 w-full monospace" rows="5" readonly>
{{ strategy.note }}
</textarea>
</td>
</tr>
</table>
</div>
</div>
<div class="p-6 pt-10 bg-white bg-opacity-60 rounded-b-md">
<div class="w-full md:w-0/12">
<div class="flex flex-wrap justify-end -m-1.5">
<div class="w-full md:w-auto p-1.5 ml-2">
<a href="/automation" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 bg-blue-500 hover:bg-blue-600 font-medium text-sm text-white border border-blue-500 rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Back</span> </a>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</div>
{% include 'footer.html' %}
</div>
</body>
</html>

View File

@@ -0,0 +1,63 @@
{% include 'header.html' %}
<div class="container mx-auto">
<section class="bg-white p-5 mt-5">
<div class="flex flex-wrap items-center -m-2">
<div class="w-full md:w-1/2 p-2">
<ul class="flex flex-wrap items-center gap-x-3 mb-2">
<li>
<a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/">
<p>Home</p>
</a>
</li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/automation">Automation Strategies</a></li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/newautomationstrategy">New</a></li>
</ul>
</div>
</div>
</section>
<section class="py-4">
<div class="container px-4 mx-auto">
<div class="relative py-11 px-16 bg-coolGray-900 rounded-md overflow-hidden">
<img class="absolute z-10 left-4 top-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute z-10 right-4 bottom-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute h-64 left-1/2 top-1/2 transform -translate-x-1/2 -translate-y-1/2 object-cover" src="/static/images/elements/wave.svg" alt="">
<div class="relative z-20 flex flex-wrap items-center -m-3">
<div class="w-full md:w-1/2 p-3">
<h2 class="mb-6 text-4xl font-bold text-white tracking-tighter">New Automation Strategy (todo)</h2>
</div>
</div>
</div>
</div>
</section>
{% include 'inc_messages.html' %}
<section class="bg-white">
<div class="pl-6 pr-6 pt-0 pb-0 mt-5 h-full overflow-hidden bg-white ">
<div class="pb-6 border-coolGray-100">
<div class="flex flex-wrap items-center justify-between -m-2">
<div class="w-full pt-2 text-center ">
</div>
</div>
</div>
</div>
</section>
</div>
{% include 'footer.html' %}
</div>
</body>
</html>

View File

@@ -1,104 +1,412 @@
{% include 'header.html' %}
<h3>Bid {{ bid_id }}</h3>
{% if refresh %}
<p>Page Refresh: {{ refresh }} seconds</p>
{% endif %}
<div class="container mx-auto">
<section class="bg-white p-5 mt-5">
<div class="flex flex-wrap items-center -m-2">
<div class="w-full md:w-1/2 p-2">
<ul class="flex flex-wrap items-center gap-x-3 mb-2">
<li>
<a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/">
<p>Home</p>
</a>
</li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="#">Bids</a></li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="{{ bid_id }}">BID ID:{{ bid_id }}</a></li>
</ul>
</div>
</div>
</section>
{% for m in messages %}
<p>{{ m }}</p>
{% endfor %}
<section class="py-4">
<div class="container px-4 mx-auto">
<div class="relative py-11 px-16 bg-coolGray-900 rounded-md overflow-hidden">
<img class="absolute z-10 left-4 top-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute z-10 right-4 bottom-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute h-64 left-1/2 top-1/2 transform -translate-x-1/2 -translate-y-1/2 object-cover" src="/static/images/elements/wave.svg" alt="">
<div class="relative z-20 flex flex-wrap items-center -m-3">
<div class="w-full md:w-1/2 p-3">
<h2 class="mb-6 text-4xl font-bold text-white tracking-tighter">Bid
{% if debug_mode == true %}
(Debug: bid template)
{% endif %}
</h2>
<p class="font-semibold text-coolGray-200">Bid ID: {{ bid_id }}</p>
</div>
<div class="w-full md:w-1/2 p-3">
{% if refresh %}
<a id="refresh" href=/bid/{{ bid_id }}><button class="block md:ml-auto px-5 py-3 font-medium text-lcg text-white bg-blue-500 hover:bg-blue-600 rounded-md focus:ring-0 focus:outline-none">Refresh {{ refresh }} seconds</button></a>
{% else %}
<a id="refresh" href=/bid/{{ bid_id }}><button class="block md:ml-auto px-5 py-3 font-medium text-lcg text-white bg-blue-500 hover:bg-blue-600 rounded-md focus:ring-0 focus:outline-none">Refresh</button></a>
{% endif %}
</div>
</div>
</div>
</div>
</section>
<table>
{% if data.was_sent == 'True' %}
<tr><td>Swap</td><td>{{ data.amt_to }} {{ data.ticker_to }} for {{ data.amt_from }} {{ data.ticker_from }}</td></tr>
{% else %}
<tr><td>Swap</td><td>{{ data.amt_from }} {{ data.ticker_from }} for {{ data.amt_to }} {{ data.ticker_to }}</td></tr>
{% endif %}
<tr><td>Bid Rate</td><td>{{ data.bid_rate }}</td></tr>
<tr><td>Bid State</td><td>{{ data.bid_state }}</td></tr>
<tr><td>State Description </td><td>{{ data.state_description }}</td></tr>
<tr><td>ITX State</td><td>{{ data.itx_state }}</td></tr>
<tr><td>PTX State</td><td>{{ data.ptx_state }}</td></tr>
<tr><td>Offer</td><td><a class="monospace" href="/offer/{{ data.offer_id }}">{{ data.offer_id }}</a></td></tr>
<tr><td>Address From</td><td><a class="monospace" href="/identity/{{ data.addr_from }}">{{ data.addr_from }}</a> {{ data.addr_from_label }}</td></tr>
<tr><td>Proof of Funds</td><td>{{ data.proof_address }}</td></tr>
<tr><td>Created At</td><td>{{ data.created_at }}</td></tr>
<tr><td>Expired At</td><td>{{ data.expired_at }}</td></tr>
<tr><td>Sent</td><td>{{ data.was_sent }}</td></tr>
<tr><td>Received</td><td>{{ data.was_received }}</td></tr>
<tr><td>Initiate Tx</td><td class="monospace">{{ data.initiate_tx }}</td></tr>
<tr><td>Initiate Conf</td><td>{{ data.initiate_conf }}</td></tr>
<tr><td>Participate Tx</td><td class="monospace">{{ data.participate_tx }}</td></tr>
<tr><td>Participate Conf</td><td>{{ data.participate_conf }}</td></tr>
{% if data.show_txns %}
<tr><td>Initiate Tx Refund</td><td class="monospace">{{ data.initiate_tx_refund }}</td></tr>
<tr><td>Participate Tx Refund</td><td class="monospace">{{ data.participate_tx_refund }}</td></tr>
<tr><td>Initiate Tx Spend Tx</td><td class="monospace">{{ data.initiate_tx_spend }}</td></tr>
<tr><td>Participate Tx Spend Tx</td><td class="monospace">{{ data.participate_tx_spend }}</td></tr>
{% endif %}
</table>
{% include 'inc_messages.html' %}
<section class="bg-white">
<div class="pl-6 pr-6 pt-0 pb-0 mt-5 h-full overflow-hidden bg-white ">
<div class="pb-6 border-coolGray-100">
<div class="flex flex-wrap items-center justify-between -m-2">
<div class="w-full pt-2">
<form method="post">
{% if edit_bid %}
<h4>Edit Bid</h4>
<table>
<tr><td>Change Bid State</td><td>
<select name="new_state">
{% for s in data.bid_states %}
<option value="{{ s[0] }}"{% if data.bid_state_ind==s[0] %} selected{% endif %}>{{ s[1] }}</option>
{% endfor %}
</select></td></tr>
{% if data.debug_ui == true %}
<tr><td>Debug Option</td><td><select name="debugind">
<option{% if data.debug_ind=="-1" %} selected{% endif %} value="-1">-- None --</option>
{% for a in data.debug_options %}
<option{% if data.debug_ind==a[0] %} selected{% endif %} value="{{ a[0] }}">{{ a[1] }}</option>
{% endfor %}
</select></td></tr>
{% endif %}
</table>
<input name="edit_bid_cancel" type="submit" value="Cancel">
<input name="edit_bid_submit" type="submit" value="Submit">
{% else %}
{% if data.was_received == 'True' %}
<input name="accept_bid" type="submit" value="Accept Bid"><br/>
{% endif %}
{% if data.can_abandon == true %}
<input name="abandon_bid" type="submit" value="Abandon Bid" onclick="return confirmPopup();">
{% endif %}
{% if data.show_txns %}
<input name="hide_txns" type="submit" value="Hide Info">
{% else %}
<input name="show_txns" type="submit" value="Show More Info">
{% endif %}
<input name="edit_bid" type="submit" value="Edit Bid">
{% endif %}
<input type="hidden" name="formid" value="{{ form_id }}">
</form>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<h4>Old States</h4>
<table>
<tr><th>State</th><th>Set At</th></tr>
{% for s in old_states %}
<tr><td>{{ s[1] }}</td><td>{{ s[0] | formatts }}</td></tr>
{% endfor %}
</table>
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<h4>Events</h4>
<table>
<tr><th>At</th><th>Event</th></tr>
{% for e in data.events %}
<tr><td>{{ e.at | formatts }}</td><td>{{ e.desc }}</td></tr>
{% endfor %}
</table>
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Item</th>
<th scope="col">Data </th>
<p><a href="/">home</a></p>
<script>
function confirmPopup() {
return confirm("Are you sure?");
}
</script>
</body></html>
</tr>
</thead>
{% if data.was_sent == 'True' %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Swap</td>
<td>{{ data.amt_to }} {{ data.ticker_to }} for {{ data.amt_from }} {{ data.ticker_from }}</td>
</tr>
{% else %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Swap</td>
<td>{{ data.amt_from }} {{ data.ticker_from }} for {{ data.amt_to }} {{ data.ticker_to }}</td>
</tr>
{% endif %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Bid Rate</td>
<td>{{ data.bid_rate }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Bid State</td>
<td>{{ data.bid_state }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">State Description </td>
<td>{{ data.state_description }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">ITX State</td>
<td>{{ data.itx_state }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">PTX State</td>
<td>{{ data.ptx_state }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Offer</td>
<td><a class="monospace" href="/offer/{{ data.offer_id }}">{{ data.offer_id }}</a></td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Address From</td>
<td><a class="monospace" href="/identity/{{ data.addr_from }}">{{ data.addr_from }}</a> {{ data.addr_from_label }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Proof of Funds</td>
<td>{{ data.proof_address }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Created At</td>
<td>{{ data.created_at }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Expired At</td>
<td>{{ data.expired_at }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Sent</td>
<td>{{ data.was_sent }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Received</td>
<td>{{ data.was_received }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Initiate Tx</td>
<td class="monospace">{{ data.initiate_tx }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Initiate Conf</td>
<td>{{ data.initiate_conf }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Participate Tx</td>
<td class="monospace">{{ data.participate_tx }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Participate Conf</td>
<td>{{ data.participate_conf }}</td>
</tr>
{% if data.show_txns %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Initiate Tx Refund</td>
<td class="monospace">{{ data.initiate_tx_refund }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Participate Tx Refund</td>
<td class="monospace">{{ data.participate_tx_refund }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Initiate Tx Spend Tx</td>
<td class="monospace">{{ data.initiate_tx_spend }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Participate Tx Spend Tx</td>
<td class="monospace">{{ data.participate_tx_spend }}</td>
</tr>
{% endif %}
</table>
</div>
</div>
<section class="bg-white p-6">
<div class="flex flex-wrap items-center">
<div class="w-full">
<h4 class="font-semibold text-black text-2xl">Old states</h4>
</div>
</div>
</section>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Old States</th>
<th scope="col">Set at Time</th>
</tr>
</thead>
{% for s in old_states %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6">{{ s[1] }}</td>
<td>{{ s[0] | formatts }} </td>
</tr>
{% endfor %}
</table>
</div>
</div>
{% if data.events %}
<section class="bg-white p-6">
<div class="flex flex-wrap items-center">
<div class="w-full">
<h4 class="font-semibold text-black text-2xl">Events</h4>
</div>
</div>
</section>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Time</th>
<th scope="col">Events</th>
</tr>
</thead>
{% for e in data.events %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6">{{ e.at | formatts }}</td>
<td>{{ e.desc }}</td>
</tr>
{% endfor %}
</table>
</div>
</div>
{% else %}
{% endif %}
<form method="post">
<div class="p-6 pt-10 bg-white bg-opacity-60 rounded-b-md">
<div class="w-full md:w-0/12">
<div class="flex flex-wrap justify-end -m-1.5">
{% if edit_bid %}
<table>
<tr>
<td class="bold pr-5">Change Bid State:</td>
<td>
<select class="pappearance-none pr-15 bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5" name="new_state">
{% for s in data.bid_states %}
<option value="{{ s[0] }}" {% if data.bid_state_ind==s[0] %} selected{% endif %}>{{ s[1] }}</option>
{% endfor %}
</select>
</td>
</tr>
{% if data.debug_ui == true %}
<tr>
<td class="bold pr-5">Debug Option:</td>
<td>
<select class="apappearance-none pr-15 bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5" name="debugind">
<option{% if data.debug_ind=="-1" %} selected{% endif %} value="-1">None</option>
{% for a in data.debug_options %}
<option{% if data.debug_ind==a[0] %} selected{% endif %} value="{{ a[0] }}">{{ a[1] }}</option>
{% endfor %}
</select>
</td>
</tr>
{% endif %}
</table>
<div class="w-full md:w-auto p-1.5 ml-2">
<button name="edit_bid_cancel" value="Cancel" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Cancel</span> </button>
</div>
<div class="w-full md:w-auto p-1.5">
<button name="edit_bid_submit" value="Submit" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 bg-blue-500 hover:bg-blue-600 font-medium text-sm text-white border border-blue-500 rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Submit Edit Bid</span> </button>
</div>
{% else %}
{% if data.show_bidder_seq_diagram %}
<div class="w-full md:w-auto p-1.5">
<button name="hide_bidder_seq_diagram" type="submit" value="Hide Bidder Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Hide Bidder Sequence Diagram</span>
</button>
</div>
{% else %}
<div class="w-full md:w-auto p-1.5">
<button name="show_bidder_seq_diagram" type="submit" value="Show Bidder Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Show Bidder Sequence Diagram</span>
</button>
</div>
{% endif %}
{% if data.show_offerer_seq_diagram %}
<div class="w-full md:w-auto p-1.5">
<button name="hide_offerer_seq_diagram" type="submit" value="Hide Offerer Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Hide Offerer Sequence Diagram</span>
</button>
</div>
{% else %}
<div class="w-full md:w-auto p-1.5">
<button name="show_offerer_seq_diagram" type="submit" value="Show Offerer Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Show Offerer Sequence Diagram</span>
</button>
</div>
{% endif %}
{% if data.can_abandon == true %}
<div class="w-full md:w-auto p-1.5">
<button name="abandon_bid" type="submit" value="Abandon Bid" onclick="return confirmPopup();" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-red-500 hover:text-red-600 border border-red-400 hover:border-red-500 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Abandon Bid</span> </button>
</div>
{% endif %}
{% if data.show_txns %}
<div class="w-full md:w-auto p-1.5">
<button name="hide_txns" type="submit" value="Hide Info" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Hide info</span> </button>
</div>
{% else %}
<div class="w-full md:w-auto p-1.5">
<button name="show_txns" type="submit" value="Show More Info" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Show More Info</span> </button>
</div>
{% endif %}
<div class="w-full md:w-auto p-1.5">
<button name="edit_bid" type="submit" value="Edit Bid" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Edit bit</span> </button>
</div>
{% endif %}
{% if data.was_received == 'True' %}
<div class="w-full md:w-auto p-1.5">
<button name="accept_bid" value="Accept Bid" type="submit" onclick='return confirmPopup("Accept");' class="flex flex-wrap justify-center w-full px-4 py-2.5 bg-blue-500 hover:bg-blue-600 font-medium text-sm text-white border border-blue-500 rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Accept Bid</span> </button>
</div>
{% endif %}
</div>
</div>
</div>
<input type="hidden" name="formid" value="{{ form_id }}">
</form>
{% if data.show_bidder_seq_diagram %}
<img src="/static/sequence_diagrams/bidder.alt.xu.min.svg" />
{% endif %}
{% if data.show_offerer_seq_diagram %}
<img src="/static/sequence_diagrams/offerer.alt.xu.min.svg" />
{% endif %}
</div>
</div>
</div>
</div>
</section>
<script>
function confirmPopup() {
return confirm("Are you sure?");
}
</script>
</div>
{% include 'footer.html' %}
</body>
</html>

View File

@@ -1,153 +1,554 @@
{% include 'header.html' %}
<h3>Bid {{ bid_id }}</h3>
{% if refresh %}
<p>Page Refresh: {{ refresh }} seconds</p>
{% endif %}
<div class="container mx-auto">
<section class="bg-white p-5 mt-5">
<div class="flex flex-wrap items-center -m-2">
<div class="w-full md:w-1/2 p-2">
<ul class="flex flex-wrap items-center gap-x-3 mb-2">
<li>
<a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="/">
<p>Home</p>
</a>
</li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="#">Bids</a></li>
<li>
<svg width="6" height="15" viewBox="0 0 6 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.34 0.671999L2.076 14.1H0.732L3.984 0.671999H5.34Z" fill="#BBC3CF"></path>
</svg>
</li>
<li><a class="flex font-medium text-xs text-coolGray-500 hover:text-coolGray-700" href="{{ bid_id }}">BID ID: {{ bid_id }}</a></li>
</ul>
</div>
</div>
</section>
{% for m in messages %}
<p>{{ m }}</p>
{% endfor %}
<section class="py-4">
<div class="container px-4 mx-auto">
<div class="relative py-11 px-16 bg-coolGray-900 rounded-md overflow-hidden">
<img class="absolute z-10 left-4 top-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute z-10 right-4 bottom-4" src="/static/images/elements/dots-red.svg" alt="">
<img class="absolute h-64 left-1/2 top-1/2 transform -translate-x-1/2 -translate-y-1/2 object-cover" src="/static/images/elements/wave.svg" alt="">
<div class="relative z-20 flex flex-wrap items-center -m-3">
<div class="w-full md:w-1/2 p-3">
<h2 class="mb-6 text-4xl font-bold text-white tracking-tighter">Bid
{% if debug_mode == true %}
(Debug: bid_xmr template)
{% endif %}
</h2>
<p class="font-semibold text-coolGray-200">Bid ID: {{ bid_id }}</p>
</div>
<div class="w-full md:w-1/2 p-3">
{% if refresh %}
<a id="refresh" href=/bid/{{ bid_id }}><button class="block md:ml-auto px-5 py-3 font-medium text-lcg text-white bg-blue-500 hover:bg-blue-600 rounded-md focus:ring-0 focus:outline-none">Refresh {{ refresh }} seconds</button></a>
{% else %}
<a id="refresh" href=/bid/{{ bid_id }}><button class="block md:ml-auto px-5 py-3 font-medium text-lcg text-white bg-blue-500 hover:bg-blue-600 rounded-md focus:ring-0 focus:outline-none">Refresh</button></a>
{% endif %}
</div>
</div>
</div>
</div>
</section>
<table>
{% if data.was_sent == 'True' %}
<tr><td>Swap</td><td>{{ data.amt_to }} {{ data.ticker_to }} for {{ data.amt_from }} {{ data.ticker_from }}</td></tr>
{% else %}
<tr><td>Swap</td><td>{{ data.amt_from }} {{ data.ticker_from }} for {{ data.amt_to }} {{ data.ticker_to }}</td></tr>
{% endif %}
<tr><td>Bid Rate</td><td>{{ data.bid_rate }}</td></tr>
<tr><td>Coin From</td><td>{{ data.coin_from }}</td></tr>
<tr><td>Coin To</td><td>{{ data.coin_to }}</td></tr>
<tr><td>Bid State</td><td>{{ data.bid_state }}</td></tr>
<tr><td>State Description </td><td>{{ data.state_description }}</td></tr>
<tr><td>Offer</td><td><a class="monospace" href="/offer/{{ data.offer_id }}">{{ data.offer_id }}</a></td></tr>
<tr><td>Address From</td><td><a class="monospace" href="/identity/{{ data.addr_from }}">{{ data.addr_from }}</a> {{ data.addr_from_label }}</td></tr>
<tr><td>Created At</td><td>{{ data.created_at }}</td></tr>
<tr><td>Expired At</td><td>{{ data.expired_at }}</td></tr>
<tr><td>Sent</td><td>{{ data.was_sent }}</td></tr>
<tr><td>Received</td><td>{{ data.was_received }}</td></tr>
{% if data.coin_a_lock_refund_tx_est_final != 'None' %}
<tr><td>{{ data.ticker_from }} lock refund tx valid at</td><td>{{ data.coin_a_lock_refund_tx_est_final | formatts }}</td></tr>
{% if data.coin_a_lock_refund_swipe_tx_est_final != 'None' %}
<tr><td>{{ data.ticker_from }} lock refund tx swipeable at</td><td>{{ data.coin_a_lock_refund_swipe_tx_est_final | formatts }}</td></tr>
{% endif %}
<tr><td>{{ data.ticker_from }} chain median time</td><td>{{ data.coin_a_last_median_time | formatts }}</td></tr>
{% endif %}
{% include 'inc_messages.html' %}
</table>
<section class="bg-white">
<div class="pl-6 pr-6 pt-0 pb-0 mt-5 h-full overflow-hidden bg-white ">
<div class="pb-6 border-coolGray-100">
<div class="flex flex-wrap items-center justify-between -m-2">
<div class="w-full pt-2">
<form method="post">
{% if edit_bid %}
<h4>Edit Bid</h4>
<table>
<tr><td>Change Bid State</td><td>
<select name="new_state">
{% for s in data.bid_states %}
<option value="{{ s[0] }}"{% if data.bid_state_ind==s[0] %} selected{% endif %}>{{ s[1] }}</option>
{% endfor %}
</select></td></tr>
{% if data.debug_ui == true %}
<tr><td>Debug Option</td><td><select name="debugind">
<option{% if data.debug_ind=="-1" %} selected{% endif %} value="-1">-- None --</option>
{% for a in data.debug_options %}
<option{% if data.debug_ind==a[0] %} selected{% endif %} value="{{ a[0] }}">{{ a[1] }}</option>
{% endfor %}
</select></td></tr>
<tr><td>Sweep No-Script TX</td><td><input type="text" id="kbs_other" name="kbs_other"></td></tr>
{% endif %}
</table>
<input name="edit_bid_cancel" type="submit" value="Cancel">
<input name="edit_bid_submit" type="submit" value="Submit">
{% else %}
{% if data.was_received == 'True' %}
<input name="accept_bid" type="submit" value="Accept Bid" onclick='return confirmPopup("Accept");'><br/>
{% endif %}
{% if data.can_abandon == true %}
<input name="abandon_bid" type="submit" value="Abandon Bid" onclick='return confirmPopup("Abandon");'>
{% endif %}
{% if data.show_txns %}
<input name="hide_txns" type="submit" value="Hide Info">
{% else %}
<input name="show_txns" type="submit" value="Show More Info">
{% endif %}
<input name="edit_bid" type="submit" value="Edit Bid">
{% endif %}
<input type="hidden" name="formid" value="{{ form_id }}">
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
{% if data.show_txns %}
{% if data.xmr_b_shared_address %}
<p class="monospace">Shared Address: {{ data.xmr_b_shared_address }}</p>
{% endif %}
{% if data.xmr_b_half_privatekey %}
<p class="monospace">Key Half: {{ data.xmr_b_half_privatekey }}</p>
{% endif %}
<h4>Transactions</h4>
<table>
<tr><th>Tx Type</th><th>Tx ID</th><th>Blocks Deep</th></tr>
{% for tx in data.txns %}
<tr><td>{{ tx.type }}</td><td class="monospace">{{ tx.txid }}</td><td>{{ tx.confirms }}</td></tr>
{% endfor %}
</table>
<table>
<tr><td>View Transaction</td><td>
<select name="view_tx">
{% for tx in data.txns %}
<option value="{{ tx.txid }}"{% if data.view_tx_ind==tx.txid %} selected{% endif %}>{{ tx.type }} {{ tx.txid }}</option>
{% endfor %}
</select></td></tr>
</table>
<input name="view_tx_submit" type="submit" value="View Tx">
<input name="view_lock_transfers" type="submit" value="View Lock Wallet Transfers">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
{% if data.view_tx_hex %}
<p>{{ data.view_tx_hex }}</p>
<textarea class="monospace" id="tx_view" rows="10" cols="150" readonly>
{{ data.view_tx_desc }}
</textarea>
{% endif %}
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Item</th>
<th scope="col">Data </th>
{% if data.lock_transfers %}
<p>
<label for="transfers_view">Lock wallet transfers:</label><br/>
<textarea class="monospace" id="transfers_view" rows="10" cols="150" readonly>
{{ data.lock_transfers }}
</textarea>
</p>
{% endif %}
{% endif %}
</form>
</tr>
</thead>
{% if data.chain_a_lock_tx_inputs %}
<h5>Chain A Lock TX Inputs:</h5>
<table>
<tr><th>txid</th><th>vout</th><th>locked</th></tr>
{% for txi in data.chain_a_lock_tx_inputs %}
<tr><td>{{ txi.txid }}</td><td>{{ txi.vout }}</td><td>{% if txi.islocked %} true {% else %} false {% endif %}</td></tr>
{% endfor %}
</table>
{% endif %}
{% if data.was_sent == 'True' %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Swap</td>
<td>{{ data.amt_to }} {{ data.ticker_to }} for {{ data.amt_from }} {{ data.ticker_from }}</td>
</tr>
{% else %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Swap</td>
<td>{{ data.amt_from }} {{ data.ticker_from }} for {{ data.amt_to }} {{ data.ticker_to }}</td>
</tr>
{% endif %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Bid Rate</td>
<td>{{ data.bid_rate }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Coin From</td>
<td>{{ data.coin_from }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Coin To</td>
<td>{{ data.coin_to }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Bid State</td>
<td>{{ data.bid_state }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">State Description </td>
<td>{{ data.state_description }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Offer</td>
<td><a class="monospace" href="/offer/{{ data.offer_id }}">{{ data.offer_id }}</a></td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Address From</td>
<td><a class="monospace" href="/identity/{{ data.addr_from }}">{{ data.addr_from }}</a> {{ data.addr_from_label }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Created At</td>
<td>{{ data.created_at }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Expired At</td>
<td>{{ data.expired_at }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Sent</td>
<td>{{ data.was_sent }}</td>
</tr>
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Received</td>
<td>{{ data.was_received }}</td>
</tr>
{% if data.coin_a_lock_refund_tx_est_final != 'None' %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">{{ data.ticker_from }} lock refund tx valid at</td>
<td>{{ data.coin_a_lock_refund_tx_est_final | formatts }}</td>
</tr>
{% if data.coin_a_lock_refund_swipe_tx_est_final != 'None' %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">{{ data.ticker_from }} lock refund tx swipeable at</td>
<td>{{ data.coin_a_lock_refund_swipe_tx_est_final | formatts }}</td>
</tr>
{% endif %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">{{ data.ticker_from }} chain median time</td>
<td>{{ data.coin_a_last_median_time | formatts }}</td>
</tr>
{% endif %}
</table>
</div>
</div>
<section class="bg-white p-6">
<div class="flex flex-wrap items-center">
<div class="w-full">
<h4 class="font-semibold text-black text-2xl">Old states</h4>
</div>
</div>
</section>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<h4>Old States</h4>
<table>
<tr><th>State</th><th>Set At</th></tr>
{% for s in old_states %}
<tr><td>{{ s[1] }}</td><td>{{ s[0] | formatts }}</td></tr>
{% endfor %}
</table>
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<h4>Events</h4>
<table>
<tr><th>At</th><th>Event</th></tr>
{% for e in data.events %}
<tr><td>{{ e.at | formatts }}</td><td>{{ e.desc }}</td></tr>
{% endfor %}
</table>
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Old States</th>
<th scope="col">Set at Time</th>
<p><a href="/">home</a></p>
<script>
function confirmPopup(name) {
return confirm(name + " Bid - Are you sure?");
}
</script>
</body></html>
</tr>
</thead>
{% for s in old_states %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6">{{ s[1] }}</td>
<td>{{ s[0] | formatts }} </td>
</tr>
{% endfor %}
</table>
</div>
</div>
{% if data.events %}
<section class="bg-white p-6">
<div class="flex flex-wrap items-center">
<div class="w-full">
<h4 class="font-semibold text-black text-2xl">Events</h4>
</div>
</div>
</section>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Time</th>
<th scope="col">Events</th>
</tr>
</thead>
{% for e in data.events %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6">{{ e.at | formatts }}</td>
<td>{{ e.desc }}</td>
</tr>
{% endfor %}
</table>
</div>
</div>
{% else %}
{% endif %}
<form method="post">
{% if data.show_txns %}
{% if data.xmr_b_shared_address or data.xmr_b_shared_viewkey or data.xmr_b_half_privatekey %}
<section class="bg-white p-6">
<div class="flex flex-wrap items-center">
<div class="w-full">
<h4 class="font-semibold text-black text-2xl">View keys/Shared Address:</h4>
</div>
</div>
</section>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6 w-96">Type</th>
<th scope="col">Output</th>
</tr>
</thead>
{% if data.xmr_b_shared_address %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Shared Address:</td>
<td class="py-4 monospace">{{ data.xmr_b_shared_address }}</td>
</tr>
{% endif %}
{% if data.xmr_b_shared_viewkey %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Shared View Key:</td>
<td class="py-4 monospace">{{ data.xmr_b_shared_viewkey }}</td>
</tr>
{% endif %}
{% if data.xmr_b_half_privatekey %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6 bold">Key Half:</td>
<td class="py-4 monospace">{{ data.xmr_b_half_privatekey }}</td>
</tr>
{% endif %}
</table>
</div>
</div>
{% endif %}
<section class="bg-white p-6">
<div class="flex flex-wrap items-center">
<div class="w-full">
<h4 class="font-semibold text-black text-2xl">Transactions</h4>
</div>
</div>
</section>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">Tx Type</th>
<th scope="col">Tx ID</th>
<th scope="col">Blocks Deep</th>
</tr>
</thead>
{% for tx in data.txns %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6">{{ tx.type }}</td>
<td class="py-4 px-6 monospace">{{ tx.txid }}</td>
<td class="py-4 px-6">{{ tx.confirms }}</td>
</tr>
{% endfor %}
</table>
</div>
</div>
<div class="p-6 pt-10 bg-white bg-opacity-60 rounded-b-md">
<div class="w-full md:w-0/12">
<div class="flex flex-wrap justify-end -m-1.5">
<table>
<tr>
<td class="bold pr-5">View Transaction:</td>
<td>
<select class="pappearance-none pr-15 bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5" name="view_tx">
{% if data.txns|length %}
{% for tx in data.txns %}
<option value="{{ tx.txid }}" {% if data.view_tx_ind==tx.txid %} selected{% endif %}>{{ tx.type }} {{ tx.txid }}</option>
{% endfor %}
{% else %}
<option value="0">None exist yet</option>
{% endif %}
</select>
</td>
</tr>
</table>
<div class="w-full md:w-auto p-1.5 ml-2">
<button name="view_tx_submit" value="View Tx" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<svg class="mr-2" xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 24 24">
<g fill="#556987">
<path fill="#556987" d="M12,3c1.989,0,3.873,0.65,5.43,1.833l-3.604,3.393l9.167,0.983L22.562,0l-3.655,3.442 C16.957,1.862,14.545,1,12,1C5.935,1,1,5.935,1,12h2C3,7.037,7.037,3,12,3z"></path>
<path data-color="#556987" d="M12,21c-1.989,0-3.873-0.65-5.43-1.833l3.604-3.393l-9.167-0.983L1.438,24l3.655-3.442 C7.043,22.138,9.455,23,12,23c6.065,0,11-4.935,11-11h-2C21,16.963,16.963,21,12,21z"></path>
</g>
</svg> <span>View Tx</span> </button>
</div>
<div class="w-full md:w-auto p-1.5 ml-2">
<button name="view_lock_transfers" value="View Lock Wallet Transfers" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<svg class="mr-2" xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 24 24">
<g fill="#556987">
<path fill="#556987" d="M12,3c1.989,0,3.873,0.65,5.43,1.833l-3.604,3.393l9.167,0.983L22.562,0l-3.655,3.442 C16.957,1.862,14.545,1,12,1C5.935,1,1,5.935,1,12h2C3,7.037,7.037,3,12,3z"></path>
<path data-color="#556987" d="M12,21c-1.989,0-3.873-0.65-5.43-1.833l3.604-3.393l-9.167-0.983L1.438,24l3.655-3.442 C7.043,22.138,9.455,23,12,23c6.065,0,11-4.935,11-11h-2C21,16.963,16.963,21,12,21z"></path>
</g>
</svg> <span>View Lock Wallet Transfers</span> </button>
</div>
</div>
</div>
</div>
{% if data.view_tx_hex %}
<label for="transfers_view" class="bold block mb-2 text-sm font-medium text-gray-900">{{ data.view_tx_hex }}</label>
<textarea rows="4" class="block p-2.5 w-full text-sm text-gray-900 bg-gray-50 rounded-lg border border-gray-300 focus:ring-blue-500 focus:border-blue-500 monospace" id="tx_view" readonly>
{{ data.view_tx_desc }}
</textarea>
{% endif %}
{% if data.lock_transfers %}
<label for="transfers_view" class="bold block mb-2 text-sm font-medium text-gray-900">Lock wallet transfers:</label>
<textarea rows="4" class="block p-2.5 w-full text-sm text-gray-900 bg-gray-50 rounded-lg border border-gray-300 focus:ring-blue-500 focus:border-blue-500 monospace" id="transfers_view" readonly>
{{ data.lock_transfers }}
</textarea>
{% endif %}
{% endif %}
{% if data.show_bidder_seq_diagram %}
<img src="/static/sequence_diagrams/xmr.bidder.alt.xu.min.svg" />
{% endif %}
{% if data.show_offerer_seq_diagram %}
<img src="/static/sequence_diagrams/xmr.offerer.alt.xu.min.svg" />
{% endif %}
{% if data.chain_a_lock_tx_inputs %}
<section class="bg-white p-6">
<div class="flex flex-wrap items-center">
<div class="w-full">
<h4 class="font-semibold text-black text-2xl">Chain A Lock TX Inputs:</h4>
</div>
</div>
</section>
<div class="container px-0 mx-auto mt-5">
<div class="overflow-x-auto relative border sm:rounded-lg">
<table class="w-full text-sm text-left text-gray-500 outline-none border-gray-300">
<thead class="text-xs text-gray-700 border-b uppercase bg-gray-50 outline-none border-gray-300">
<tr>
<th scope="col" class="py-3 px-6">txid</th>
<th scope="col">vout</th>
<th scope="col">locked</th>
</tr>
</thead>
{% for txi in data.chain_a_lock_tx_inputs %}
<tr class="bg-white border-t hover:bg-gray-50">
<td class="py-4 px-6">{{ txi.txid }}</td>
<td class="py-4 px-6 monospace">{{ txi.vout }}</td>
<td class="py-4 px-6">{% if txi.islocked %} true {% else %} false {% endif %}</td>
</tr>
{% endfor %}
</table>
</div>
</div>
{% endif %}
<div class="p-6 pt-10 bg-white bg-opacity-60 rounded-b-md">
<div class="w-full md:w-0/12">
<div class="flex flex-wrap justify-end -m-1.5">
{% if edit_bid %}
<table class="mt-1">
<tr>
<td class="bold pr-5 ">Change Bid State:</td>
<td>
<select class="pappearance-none pr-15 bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5" name="new_state">
{% for s in data.bid_states %}
<option value="{{ s[0] }}" {% if data.bid_state_ind==s[0] %} selected{% endif %}>{{ s[1] }}</option>
{% endfor %}
</select>
</td>
</tr>
{% if data.debug_ui == true %}
<tr>
<td class="bold pr-5">Debug Option</td>
<td>
<select class="pappearance-none pr-15 bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block w-full p-2.5" name="debugind">
<option{% if data.debug_ind=="-1" %} selected{% endif %} value="-1">-- None --</option>
{% for a in data.debug_options %}
<option{% if data.debug_ind==a[0] %} selected{% endif %} value="{{ a[0] }}">{{ a[1] }}</option>
{% endfor %}
</select>
</td>
</tr>
<tr>
<td class="bold pr-5">Sweep No-Script TX</td>
<td><input class="appearance-none bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 block p-2.5" type="text" id="kbs_other" name="kbs_other"></td>
</tr>
{% endif %}
</table>
<div class="w-full md:w-auto p-1.5 ml-2">
<button name="edit_bid_cancel" value="Cancel" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Cancel</span> </button>
</div>
<div class="w-full md:w-auto p-1.5">
<button name="edit_bid_submit" value="Submit" type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 bg-blue-500 hover:bg-blue-600 font-medium text-sm text-white border border-blue-500 rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Submit Edit Bid</span> </button>
</div>
{% else %}
{% if data.show_bidder_seq_diagram %}
<div class="w-full md:w-auto p-1.5">
<button name="hide_bidder_seq_diagram" type="submit" value="Hide Bidder Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Hide Bidder Sequence Diagram</span>
</button>
</div>
{% else %}
<div class="w-full md:w-auto p-1.5">
<button name="show_bidder_seq_diagram" type="submit" value="Show Bidder Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Show Bidder Sequence Diagram</span>
</button>
</div>
{% endif %}
{% if data.show_offerer_seq_diagram %}
<div class="w-full md:w-auto p-1.5">
<button name="hide_offerer_seq_diagram" type="submit" value="Hide Offerer Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Hide Offerer Sequence Diagram</span>
</button>
</div>
{% else %}
<div class="w-full md:w-auto p-1.5">
<button name="show_offerer_seq_diagram" type="submit" value="Show Offerer Sequence Diagram" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Show Offerer Sequence Diagram</span>
</button>
</div>
{% endif %}
{% if data.can_abandon == true %}
<div class="w-full md:w-auto p-1.5">
<button name="abandon_bid" value="Abandon Bid" onclick='return confirmPopup("Abandon");' type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-red-500 hover:text-red-600 border border-red-400 hover:border-red-500 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Abandon Bid</span> </button>
</div>
{% endif %}
{% if data.show_txns %}
<div class="w-full md:w-auto p-1.5">
<button name="hide_txns" type="submit" value="Hide Info" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Hide info</span> </button>
</div>
{% else %}
<div class="w-full md:w-auto p-1.5">
<button name="show_txns" type="submit" value="Show More Info" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Show More Info</span> </button>
</div>
{% endif %}
<div class="w-full md:w-auto p-1.5">
<button name="edit_bid" type="submit" value="Edit Bid" class="flex flex-wrap justify-center w-full px-4 py-2.5 font-medium text-sm text-coolGray-500 hover:text-coolGray-600 border border-coolGray-200 hover:border-coolGray-300 bg-white rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Edit bid</span> </button>
</div>
{% endif %}
{% if data.was_received == 'True' %}
<div class="w-full md:w-auto p-1.5">
<button name="accept_bid" value="Accept Bid" onclick='return confirmPopup("Accept");' type="submit" class="flex flex-wrap justify-center w-full px-4 py-2.5 bg-blue-500 hover:bg-blue-600 font-medium text-sm text-white border border-blue-500 rounded-md shadow-button focus:ring-0 focus:outline-none">
<span>Accept Bid</span> </button>
</div>
{% endif %}
</div>
</div>
</div>
<input type="hidden" name="formid" value="{{ form_id }}">
</div>
</div>
</div>
</div> <!-- todo double check -->
</form>
<script>
function confirmPopup(name) {
return confirm(name + " Bid - Are you sure?");
}
</script>
</div>
{% include 'footer.html' %}
</body>
</html>

Some files were not shown because too many files have changed in this diff Show More