mirror of
https://github.com/conduition/dlctix.git
synced 2025-12-17 08:34:18 +01:00
update deps to latest possible (#1)
* update deps to latest supported * update all deps and handle type conversion * clean up * fix test expectation and point conversion * update dep, revert test assert
This commit is contained in:
247
Cargo.lock
generated
247
Cargo.lock
generated
@@ -1,6 +1,12 @@
|
||||
# This file is automatically @generated by Cargo.
|
||||
# It is not intended for manual editing.
|
||||
version = 3
|
||||
version = 4
|
||||
|
||||
[[package]]
|
||||
name = "arrayvec"
|
||||
version = "0.7.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50"
|
||||
|
||||
[[package]]
|
||||
name = "base16ct"
|
||||
@@ -8,6 +14,16 @@ version = "0.2.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf"
|
||||
|
||||
[[package]]
|
||||
name = "base58ck"
|
||||
version = "0.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "2c8d66485a3a2ea485c1913c4572ce0256067a5377ac8c75c4960e1cda98605f"
|
||||
dependencies = [
|
||||
"bitcoin-internals",
|
||||
"bitcoin_hashes",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "base64"
|
||||
version = "0.13.1"
|
||||
@@ -16,50 +32,69 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8"
|
||||
|
||||
[[package]]
|
||||
name = "bech32"
|
||||
version = "0.10.0-beta"
|
||||
version = "0.11.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "98f7eed2b2781a6f0b5c903471d48e15f56fb4e1165df8a9a2337fd1a59d45ea"
|
||||
checksum = "d965446196e3b7decd44aa7ee49e31d630118f90ef12f97900f262eb915c951d"
|
||||
|
||||
[[package]]
|
||||
name = "bitcoin"
|
||||
version = "0.31.1"
|
||||
version = "0.32.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "fd00f3c09b5f21fb357abe32d29946eb8bb7a0862bae62c0b5e4a692acbbe73c"
|
||||
checksum = "ce6bc65742dea50536e35ad42492b234c27904a27f0abdcbce605015cb4ea026"
|
||||
dependencies = [
|
||||
"base58ck",
|
||||
"bech32",
|
||||
"bitcoin-internals",
|
||||
"bitcoin-io",
|
||||
"bitcoin-units",
|
||||
"bitcoin_hashes",
|
||||
"hex-conservative",
|
||||
"hex_lit",
|
||||
"secp256k1",
|
||||
"secp256k1 0.29.1",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bitcoin-internals"
|
||||
version = "0.2.0"
|
||||
version = "0.3.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9425c3bf7089c983facbae04de54513cce73b41c7f9ff8c845b54e7bc64ebbfb"
|
||||
checksum = "30bdbe14aa07b06e6cfeffc529a1f099e5fbe249524f8125358604df99a4bed2"
|
||||
dependencies = [
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bitcoin_hashes"
|
||||
version = "0.13.0"
|
||||
name = "bitcoin-io"
|
||||
version = "0.1.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1930a4dabfebb8d7d9992db18ebe3ae2876f0a305fab206fd168df931ede293b"
|
||||
checksum = "0b47c4ab7a93edb0c7198c5535ed9b52b63095f4e9b45279c6736cec4b856baf"
|
||||
|
||||
[[package]]
|
||||
name = "bitcoin-units"
|
||||
version = "0.1.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5285c8bcaa25876d07f37e3d30c303f2609179716e11d688f51e8f1fe70063e2"
|
||||
dependencies = [
|
||||
"bitcoin-internals",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bitcoin_hashes"
|
||||
version = "0.14.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "bb18c03d0db0247e147a21a6faafd5a7eb851c743db062de72018b6b7e8e4d16"
|
||||
dependencies = [
|
||||
"bitcoin-io",
|
||||
"hex-conservative",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bitcoincore-rpc"
|
||||
version = "0.18.0"
|
||||
version = "0.19.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "8eb70725a621848c83b3809913d5314c0d20ca84877d99dd909504b564edab00"
|
||||
checksum = "aedd23ae0fd321affb4bbbc36126c6f49a32818dc6b979395d24da8c9d4e80ee"
|
||||
dependencies = [
|
||||
"bitcoincore-rpc-json",
|
||||
"jsonrpc",
|
||||
@@ -70,9 +105,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "bitcoincore-rpc-json"
|
||||
version = "0.18.0"
|
||||
version = "0.19.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "856ffbee2e492c23bca715d72ea34aae80d58400f2bda26a82015d6bc2ec3662"
|
||||
checksum = "d8909583c5fab98508e80ef73e5592a651c954993dc6b7739963257d19f0e71a"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"serde",
|
||||
@@ -89,10 +124,19 @@ dependencies = [
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "cc"
|
||||
version = "1.0.90"
|
||||
name = "byteorder"
|
||||
version = "1.5.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "8cd6604a82acf3039f1144f54b8eb34e91ffba622051189e71b781822d5ee1f5"
|
||||
checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b"
|
||||
|
||||
[[package]]
|
||||
name = "cc"
|
||||
version = "1.2.9"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c8293772165d9345bdaaa39b45b2109591e63fe5e6fbc23c6ff930a048aa310b"
|
||||
dependencies = [
|
||||
"shlex",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "cfg-if"
|
||||
@@ -102,9 +146,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
|
||||
|
||||
[[package]]
|
||||
name = "cpufeatures"
|
||||
version = "0.2.12"
|
||||
version = "0.2.16"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504"
|
||||
checksum = "16b80225097f2e5ae4e7179dd2266824648f3e2f49d9134d584b76389d31c4c3"
|
||||
dependencies = [
|
||||
"libc",
|
||||
]
|
||||
@@ -142,7 +186,6 @@ dependencies = [
|
||||
"once_cell",
|
||||
"rand 0.8.5",
|
||||
"secp",
|
||||
"secp256k1",
|
||||
"serde",
|
||||
"serde_cbor",
|
||||
"serde_json",
|
||||
@@ -175,9 +218,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "getrandom"
|
||||
version = "0.2.12"
|
||||
version = "0.2.15"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "190092ea657667030ac6a35e305e62fc4dd69fd98ac98631e5d3a2b1575a12b5"
|
||||
checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7"
|
||||
dependencies = [
|
||||
"cfg-if",
|
||||
"libc",
|
||||
@@ -198,9 +241,12 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70"
|
||||
|
||||
[[package]]
|
||||
name = "hex-conservative"
|
||||
version = "0.1.1"
|
||||
version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "30ed443af458ccb6d81c1e7e661545f94d3176752fb1df2f543b902a1e0f51e2"
|
||||
checksum = "5313b072ce3c597065a808dbf612c4c8e8590bdbf8b579508bf7a762c5eae6cd"
|
||||
dependencies = [
|
||||
"arrayvec",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "hex_lit"
|
||||
@@ -219,45 +265,63 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "itoa"
|
||||
version = "1.0.10"
|
||||
version = "1.0.14"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c"
|
||||
checksum = "d75a2a4b1b190afb6f5425f10f6a8f959d2ea0b9c2b1d79553551850539e4674"
|
||||
|
||||
[[package]]
|
||||
name = "jsonrpc"
|
||||
version = "0.14.1"
|
||||
version = "0.18.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "8128f36b47411cd3f044be8c1f5cc0c9e24d1d1bfdc45f0a57897b32513053f2"
|
||||
checksum = "3662a38d341d77efecb73caf01420cfa5aa63c0253fd7bc05289ef9f6616e1bf"
|
||||
dependencies = [
|
||||
"base64",
|
||||
"minreq",
|
||||
"serde",
|
||||
"serde_json",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "libc"
|
||||
version = "0.2.153"
|
||||
version = "0.2.169"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd"
|
||||
checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a"
|
||||
|
||||
[[package]]
|
||||
name = "log"
|
||||
version = "0.4.21"
|
||||
version = "0.4.25"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c"
|
||||
checksum = "04cbf5b083de1c7e0222a7a51dbfdba1cbe1c6ab0b15e29fff3f6c077fd9cd9f"
|
||||
|
||||
[[package]]
|
||||
name = "memchr"
|
||||
version = "2.7.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3"
|
||||
|
||||
[[package]]
|
||||
name = "minreq"
|
||||
version = "2.13.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "36a8e50e917e18a37d500d27d40b7bc7d127e71c0c94fb2d83f43b4afd308390"
|
||||
dependencies = [
|
||||
"log",
|
||||
"serde",
|
||||
"serde_json",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "musig2"
|
||||
version = "0.0.11"
|
||||
version = "0.2.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "bed08befaac75bfb31ca5e87678c4e8490bcd21d0c98ccb4f12f4065a7567e83"
|
||||
checksum = "d89eb08ce8778538f84198774795f418358360a29841cfea8dbbb28c04d777e2"
|
||||
dependencies = [
|
||||
"base16ct",
|
||||
"hmac",
|
||||
"once_cell",
|
||||
"rand 0.8.5",
|
||||
"secp",
|
||||
"secp256k1",
|
||||
"secp256k1 0.30.0",
|
||||
"serde",
|
||||
"serdect",
|
||||
"sha2",
|
||||
@@ -266,30 +330,33 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "once_cell"
|
||||
version = "1.19.0"
|
||||
version = "1.20.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92"
|
||||
checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775"
|
||||
|
||||
[[package]]
|
||||
name = "ppv-lite86"
|
||||
version = "0.2.17"
|
||||
version = "0.2.20"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de"
|
||||
checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04"
|
||||
dependencies = [
|
||||
"zerocopy",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "proc-macro2"
|
||||
version = "1.0.78"
|
||||
version = "1.0.93"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae"
|
||||
checksum = "60946a68e5f9d28b0dc1c21bb8a97ee7d018a8b322fa57838ba31cc878e22d99"
|
||||
dependencies = [
|
||||
"unicode-ident",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "quote"
|
||||
version = "1.0.35"
|
||||
version = "1.0.38"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef"
|
||||
checksum = "0e4dccaaaf89514f546c693ddc140f729f958c247918a13380cccc6078391acc"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
]
|
||||
@@ -372,20 +439,20 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ryu"
|
||||
version = "1.0.17"
|
||||
version = "1.0.18"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1"
|
||||
checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f"
|
||||
|
||||
[[package]]
|
||||
name = "secp"
|
||||
version = "0.2.3"
|
||||
version = "0.5.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1507279bb0404bb566f85523e48fcf37a158daa5380577ee0d93f3ef4df39ccc"
|
||||
checksum = "d7ac68feda6cce08c5091b4e87cf93d4b7fa04b4afd9988d4b36121d949f79ec"
|
||||
dependencies = [
|
||||
"base16ct",
|
||||
"once_cell",
|
||||
"rand 0.8.5",
|
||||
"secp256k1",
|
||||
"secp256k1 0.30.0",
|
||||
"serde",
|
||||
"serdect",
|
||||
"subtle",
|
||||
@@ -393,9 +460,21 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "secp256k1"
|
||||
version = "0.28.2"
|
||||
version = "0.29.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d24b59d129cdadea20aea4fb2352fa053712e5d713eee47d700cd4b2bc002f10"
|
||||
checksum = "9465315bc9d4566e1724f0fffcbcc446268cb522e60f9a27bcded6b19c108113"
|
||||
dependencies = [
|
||||
"bitcoin_hashes",
|
||||
"rand 0.8.5",
|
||||
"secp256k1-sys",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "secp256k1"
|
||||
version = "0.30.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b50c5943d326858130af85e049f2661ba3c78b26589b8ab98e65e80ae44a1252"
|
||||
dependencies = [
|
||||
"bitcoin_hashes",
|
||||
"rand 0.8.5",
|
||||
@@ -405,18 +484,18 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "secp256k1-sys"
|
||||
version = "0.9.2"
|
||||
version = "0.10.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e5d1746aae42c19d583c3c1a8c646bfad910498e2051c551a7f2e3c0c9fbb7eb"
|
||||
checksum = "d4387882333d3aa8cb20530a17c69a3752e97837832f34f6dccc760e715001d9"
|
||||
dependencies = [
|
||||
"cc",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "serde"
|
||||
version = "1.0.197"
|
||||
version = "1.0.217"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3fb1c873e1b9b056a4dc4c0c198b24c3ffa059243875552b2bd0933b1aee4ce2"
|
||||
checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70"
|
||||
dependencies = [
|
||||
"serde_derive",
|
||||
]
|
||||
@@ -433,9 +512,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "serde_derive"
|
||||
version = "1.0.197"
|
||||
version = "1.0.217"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7eb0b34b42edc17f6b7cac84a52a1c5f0e1bb2227e997ca9011ea3dd34e8610b"
|
||||
checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
@@ -444,20 +523,21 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "serde_json"
|
||||
version = "1.0.114"
|
||||
version = "1.0.135"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c5f09b1bd632ef549eaa9f60a1f8de742bdbc698e6cee2095fc84dde5f549ae0"
|
||||
checksum = "2b0d7ba2887406110130a978386c4e1befb98c674b4fba677954e4db976630d9"
|
||||
dependencies = [
|
||||
"itoa",
|
||||
"memchr",
|
||||
"ryu",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "serdect"
|
||||
version = "0.2.0"
|
||||
version = "0.3.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a84f14a19e9a014bb9f4512488d9829a68e04ecabffb0f9904cd1ace94598177"
|
||||
checksum = "f42f67da2385b51a5f9652db9c93d78aeaf7610bf5ec366080b6de810604af53"
|
||||
dependencies = [
|
||||
"base16ct",
|
||||
"serde",
|
||||
@@ -475,16 +555,22 @@ dependencies = [
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "subtle"
|
||||
version = "2.5.0"
|
||||
name = "shlex"
|
||||
version = "1.3.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc"
|
||||
checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64"
|
||||
|
||||
[[package]]
|
||||
name = "subtle"
|
||||
version = "2.6.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292"
|
||||
|
||||
[[package]]
|
||||
name = "syn"
|
||||
version = "2.0.52"
|
||||
version = "2.0.96"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b699d15b36d1f02c3e7c69f8ffef53de37aefae075d8488d4ba1a7788d574a07"
|
||||
checksum = "d5d0adab1ae378d7f53bdebc67a39f1f151407ef230f0ce2883572f5d8985c80"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
@@ -509,15 +595,15 @@ checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825"
|
||||
|
||||
[[package]]
|
||||
name = "unicode-ident"
|
||||
version = "1.0.12"
|
||||
version = "1.0.14"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b"
|
||||
checksum = "adb9e6ca4f869e1180728b7950e35922a7fc6397f7b641499e8f3ef06e50dc83"
|
||||
|
||||
[[package]]
|
||||
name = "version_check"
|
||||
version = "0.9.4"
|
||||
version = "0.9.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f"
|
||||
checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a"
|
||||
|
||||
[[package]]
|
||||
name = "wasi"
|
||||
@@ -546,3 +632,24 @@ name = "winapi-x86_64-pc-windows-gnu"
|
||||
version = "0.4.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
|
||||
|
||||
[[package]]
|
||||
name = "zerocopy"
|
||||
version = "0.7.35"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0"
|
||||
dependencies = [
|
||||
"byteorder",
|
||||
"zerocopy-derive",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "zerocopy-derive"
|
||||
version = "0.7.35"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn",
|
||||
]
|
||||
|
||||
30
Cargo.toml
30
Cargo.toml
@@ -11,23 +11,31 @@ keywords = ["dlc", "smart", "contract", "ticket", "auction"]
|
||||
exclude = ["/img"]
|
||||
|
||||
[dependencies]
|
||||
bitcoin = { version = "0.31.1", default-features = false, features = ["std", "serde"] }
|
||||
bitcoin = { version = "0.32.0", default-features = false, features = [
|
||||
"std",
|
||||
"serde",
|
||||
] }
|
||||
hex = { version = "0.4.3", default-features = false, features = ["alloc"] }
|
||||
musig2 = { version = "0.0.11", default-features = false, features = ["secp256k1", "rand", "serde"] }
|
||||
musig2 = { version = "0.2.4", default-features = false, features = [
|
||||
"secp256k1",
|
||||
"rand",
|
||||
"serde",
|
||||
] }
|
||||
rand = { version = "0.8.5", default-features = false }
|
||||
secp = { version = "0.2.3", default-features = false, features = ["serde"] }
|
||||
secp256k1 = { version = "0.28.2", default-features = false, features = ["global-context"] }
|
||||
serde = { version = "1.0.197", default-features = false, features = ["derive"] }
|
||||
serdect = { version = "0.2.0", default-features = false, features = ["alloc"] }
|
||||
secp = { version = "0.5.0", default-features = false, features = ["serde"] }
|
||||
serde = { version = "1.0.217", default-features = false, features = ["derive"] }
|
||||
serdect = { version = "0.3.0", default-features = false, features = ["alloc"] }
|
||||
sha2 = { version = "0.10.8", default-features = false }
|
||||
|
||||
[dev-dependencies]
|
||||
bitcoincore-rpc = "0.18.0"
|
||||
bitcoincore-rpc = "0.19.0"
|
||||
dotenv = "0.15.0"
|
||||
once_cell = "1.19.0"
|
||||
serde = { version = "1.0.197", default-features = false, features = ["derive"] }
|
||||
serde_cbor = { version = "0.11.2", default-features = false, features = ["std"] }
|
||||
serde_json = { version = "1.0.114", default-features = false, features = [] }
|
||||
once_cell = "1.20.1"
|
||||
serde = { version = "1.0.217", default-features = false, features = ["derive"] }
|
||||
serde_cbor = { version = "0.11.2", default-features = false, features = [
|
||||
"std",
|
||||
] }
|
||||
serde_json = { version = "1.0.135", default-features = false, features = [] }
|
||||
tempdir = "0.3.7"
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
|
||||
@@ -14,6 +14,6 @@ mod tests {
|
||||
let xonly = bitcoin::XOnlyPublicKey::from_slice(&[1; 32]).unwrap();
|
||||
let tweaked = bitcoin::key::TweakedPublicKey::dangerous_assume_tweaked(xonly);
|
||||
let script = bitcoin::ScriptBuf::new_p2tr_tweaked(tweaked);
|
||||
assert_eq!(script.dust_value(), P2TR_DUST_VALUE);
|
||||
assert_eq!(script.minimal_non_dust(), P2TR_DUST_VALUE);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -387,7 +387,7 @@ pub(crate) fn outcome_tx_prevout<'x>(
|
||||
|
||||
let outcome_input = TxIn {
|
||||
previous_output: OutPoint {
|
||||
txid: outcome_tx.txid(),
|
||||
txid: outcome_tx.compute_txid(),
|
||||
vout: 0,
|
||||
},
|
||||
sequence: Sequence::from_height(block_delay),
|
||||
|
||||
@@ -345,7 +345,7 @@ pub(crate) fn split_tx_prevout<'x>(
|
||||
|
||||
let input = TxIn {
|
||||
previous_output: OutPoint {
|
||||
txid: split_tx.txid(),
|
||||
txid: split_tx.compute_txid(),
|
||||
vout: split_tx_output_index as u32,
|
||||
},
|
||||
sequence: Sequence::from_height(block_delay),
|
||||
|
||||
@@ -58,8 +58,8 @@ impl From<bitcoin::taproot::IncompleteBuilderError> for Error {
|
||||
}
|
||||
}
|
||||
|
||||
impl From<bitcoin::sighash::Error> for Error {
|
||||
fn from(_: bitcoin::sighash::Error) -> Self {
|
||||
impl From<bitcoin::sighash::TaprootError> for Error {
|
||||
fn from(_: bitcoin::sighash::TaprootError) -> Self {
|
||||
Error
|
||||
}
|
||||
}
|
||||
|
||||
32
src/lib.rs
32
src/lib.rs
@@ -28,23 +28,41 @@ use errors::Error;
|
||||
use hashlock::{sha256, Preimage};
|
||||
|
||||
use bitcoin::{
|
||||
sighash::Prevouts, transaction::InputWeightPrediction, OutPoint, Transaction, TxIn, TxOut,
|
||||
secp256k1::XOnlyPublicKey as BitcoinXOnly, sighash::Prevouts,
|
||||
transaction::InputWeightPrediction, OutPoint, Transaction, TxIn, TxOut,
|
||||
};
|
||||
use musig2::{
|
||||
secp256k1::XOnlyPublicKey as Musig2XOnly, AdaptorSignature, AggNonce, CompactSignature,
|
||||
PartialSignature, PubNonce, SecNonce,
|
||||
};
|
||||
use musig2::{AdaptorSignature, AggNonce, CompactSignature, PartialSignature, PubNonce, SecNonce};
|
||||
use secp::{MaybeScalar, Point, Scalar};
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use std::{
|
||||
borrow::Borrow,
|
||||
collections::{BTreeMap, BTreeSet},
|
||||
};
|
||||
|
||||
pub use contract::{
|
||||
ContractParameters, Outcome, OutcomeIndex, PayoutWeights, PlayerIndex, SigMap, WinCondition,
|
||||
};
|
||||
pub use oracles::{attestation_locking_point, attestation_secret, EventLockingConditions};
|
||||
pub use parties::{MarketMaker, Player};
|
||||
|
||||
use std::{
|
||||
borrow::Borrow,
|
||||
collections::{BTreeMap, BTreeSet},
|
||||
};
|
||||
|
||||
/// Used to convert musig2 xonly key into bitcoin xonly key only needed
|
||||
/// until crate bitcoin updates secp256k1 to v0.30
|
||||
/// will be removed/deprecated once the dependency has upgraded
|
||||
pub fn convert_xonly_key(key: Musig2XOnly) -> BitcoinXOnly {
|
||||
BitcoinXOnly::from_slice(&key.serialize()).expect("Valid key")
|
||||
}
|
||||
|
||||
/// Used to convert secp point into bitcoin xonly key
|
||||
/// only needed until crate bitcoin updates secp256k1 to v0.30
|
||||
/// will be removed/deprecated once the dependency has upgraded
|
||||
pub fn convert_point(key: Point) -> BitcoinXOnly {
|
||||
BitcoinXOnly::from_slice(&key.serialize_xonly()).expect("Valid key")
|
||||
}
|
||||
|
||||
/// Represents the combined output of building all transactions and precomputing
|
||||
/// all necessary data for a ticketed DLC.
|
||||
///
|
||||
|
||||
@@ -28,14 +28,14 @@ use std::{
|
||||
/// Generate a P2TR address which pays to the given pubkey (no tweak added).
|
||||
fn p2tr_address(pubkey: Point) -> Address {
|
||||
let (xonly, _) = pubkey.into();
|
||||
let tweaked = TweakedPublicKey::dangerous_assume_tweaked(xonly);
|
||||
let tweaked = TweakedPublicKey::dangerous_assume_tweaked(convert_xonly_key(xonly));
|
||||
Address::p2tr_tweaked(tweaked, Network::Regtest)
|
||||
}
|
||||
|
||||
/// Generate a P2TR script pubkey which pays to the given pubkey (no tweak added).
|
||||
fn p2tr_script_pubkey(pubkey: Point) -> ScriptBuf {
|
||||
let (xonly, _) = pubkey.into();
|
||||
let tweaked = TweakedPublicKey::dangerous_assume_tweaked(xonly);
|
||||
let tweaked = TweakedPublicKey::dangerous_assume_tweaked(convert_xonly_key(xonly));
|
||||
ScriptBuf::new_p2tr_tweaked(tweaked)
|
||||
}
|
||||
|
||||
@@ -523,7 +523,7 @@ impl SimulationManager {
|
||||
&mm_utxo_prevout,
|
||||
);
|
||||
let funding_outpoint = OutPoint {
|
||||
txid: funding_tx.txid(),
|
||||
txid: funding_tx.compute_txid(),
|
||||
vout: 0,
|
||||
};
|
||||
|
||||
@@ -813,7 +813,6 @@ fn with_on_chain_resolutions() {
|
||||
manager.market_maker_seckey,
|
||||
)
|
||||
.expect("failed to sign win TX");
|
||||
|
||||
let err = manager
|
||||
.rpc
|
||||
.send_raw_transaction(&invalid_reclaim_tx)
|
||||
|
||||
@@ -185,11 +185,10 @@ mod tests {
|
||||
let cbor_serialized_hex: String = serde_cbor::to_vec(&player).unwrap().encode_hex();
|
||||
assert_eq!(
|
||||
&cbor_serialized_hex,
|
||||
"a3667075626b657998210318a01843184d189e184718f318c8186218351847187c187b181a18\
|
||||
e618ae185d1834184218d4189b1819184318c218b7185218a6188e182a184718e2184718c76b\
|
||||
7469636b65745f6861736898200a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a\
|
||||
0a0a0a0a0a0a0a6b7061796f75745f6861736898201414141414141414141414141414141414\
|
||||
141414141414141414141414141414"
|
||||
"a3667075626b6579582103a0434d9e47f3c86235477c7b1ae6ae5d3442d49b1943c2b752a68e\
|
||||
2a47e247c76b7469636b65745f6861736858200a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a\
|
||||
0a0a0a0a0a0a0a0a0a0a0a0a0a6b7061796f75745f6861736858201414141414141414141414\
|
||||
141414141414141414141414141414141414141414"
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ use musig2::{CompactSignature, KeyAggContext};
|
||||
use secp::{Point, Scalar};
|
||||
|
||||
use crate::{
|
||||
convert_xonly_key,
|
||||
errors::Error,
|
||||
parties::{MarketMaker, Player},
|
||||
};
|
||||
@@ -57,7 +58,8 @@ impl FundingSpendInfo {
|
||||
// This is safe because the musig key aggregation formula prevents
|
||||
// participants from hiding tapscript commitments in the aggregated key.
|
||||
let (xonly, _) = self.key_agg_ctx.aggregated_pubkey();
|
||||
let tweaked = bitcoin::key::TweakedPublicKey::dangerous_assume_tweaked(xonly);
|
||||
let tweaked =
|
||||
bitcoin::key::TweakedPublicKey::dangerous_assume_tweaked(convert_xonly_key(xonly));
|
||||
ScriptBuf::new_p2tr_tweaked(tweaked)
|
||||
}
|
||||
|
||||
@@ -65,7 +67,7 @@ impl FundingSpendInfo {
|
||||
pub(crate) fn sighash_tx_outcome(
|
||||
&self,
|
||||
outcome_tx: &Transaction,
|
||||
) -> Result<TapSighash, bitcoin::sighash::Error> {
|
||||
) -> Result<TapSighash, bitcoin::sighash::TaprootError> {
|
||||
let funding_prevouts = [self.funding_output()];
|
||||
|
||||
SighashCache::new(outcome_tx).taproot_key_spend_signature_hash(
|
||||
|
||||
@@ -13,6 +13,7 @@ use secp::{Point, Scalar};
|
||||
|
||||
use crate::{
|
||||
contract::PlayerIndex,
|
||||
convert_point,
|
||||
errors::Error,
|
||||
hashlock::{Preimage, PREIMAGE_SIZE},
|
||||
parties::{MarketMaker, Player},
|
||||
@@ -111,9 +112,10 @@ impl OutcomeSpendInfo {
|
||||
.map(|script| (1, script))
|
||||
.chain([(u32::MAX, reclaim_script.clone())]); // reclaim script gets highest priority
|
||||
|
||||
let secp = bitcoin::secp256k1::Secp256k1::verification_only();
|
||||
let tr_spend_info = TaprootSpendInfo::with_huffman_tree(
|
||||
secp256k1::SECP256K1,
|
||||
joint_outcome_pubkey.into(),
|
||||
&secp,
|
||||
convert_point(joint_outcome_pubkey.into()),
|
||||
weighted_script_leaves,
|
||||
)?;
|
||||
|
||||
|
||||
@@ -12,6 +12,7 @@ use secp::{Point, Scalar};
|
||||
use std::borrow::Borrow;
|
||||
|
||||
use crate::{
|
||||
convert_point,
|
||||
errors::Error,
|
||||
hashlock::{Preimage, PREIMAGE_SIZE},
|
||||
parties::{MarketMaker, Player},
|
||||
@@ -99,9 +100,11 @@ impl SplitSpendInfo {
|
||||
(1, win_script.clone()),
|
||||
(1, reclaim_script.clone()),
|
||||
];
|
||||
|
||||
let secp = bitcoin::secp256k1::Secp256k1::verification_only();
|
||||
let tr_spend_info = TaprootSpendInfo::with_huffman_tree(
|
||||
secp256k1::SECP256K1,
|
||||
joint_payout_pubkey.into(),
|
||||
&secp,
|
||||
convert_point(joint_payout_pubkey),
|
||||
weighted_script_leaves,
|
||||
)?;
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
use dlctix::bitcoin;
|
||||
use dlctix::convert_xonly_key;
|
||||
use dlctix::musig2;
|
||||
use dlctix::secp::{MaybePoint, Point, Scalar};
|
||||
use dlctix::{
|
||||
@@ -202,7 +203,7 @@ fn two_player_example() -> Result<(), Box<dyn std::error::Error>> {
|
||||
// first needs players' signatures to ensure he can recover his money
|
||||
// if they disappear.
|
||||
let funding_outpoint = bitcoin::OutPoint {
|
||||
txid: funding_tx.txid(),
|
||||
txid: funding_tx.compute_txid(),
|
||||
vout: 0,
|
||||
};
|
||||
|
||||
@@ -235,7 +236,7 @@ fn two_player_example() -> Result<(), Box<dyn std::error::Error>> {
|
||||
// Once the market maker is ready, they can broadcast the funding TX to lock in the Ticketed DLC.
|
||||
sign_transaction(&mut funding_tx);
|
||||
broadcast_transaction(&funding_tx);
|
||||
wait_for_confs(&funding_tx.txid(), 1);
|
||||
wait_for_confs(&funding_tx.compute_txid(), 1);
|
||||
|
||||
// Once the funding TX is confirmed, players can begin buying their ticket preimages
|
||||
// from the market maker. This would probably take place via the lightning network,
|
||||
@@ -272,7 +273,7 @@ fn two_player_example() -> Result<(), Box<dyn std::error::Error>> {
|
||||
|
||||
// Alice must wait for the relative locktime to expire before she can use the split transaction.
|
||||
wait_for_confs(
|
||||
&outcome_tx.txid(),
|
||||
&outcome_tx.compute_txid(),
|
||||
signed_contract.params().relative_locktime_block_delta,
|
||||
);
|
||||
|
||||
@@ -283,7 +284,7 @@ fn two_player_example() -> Result<(), Box<dyn std::error::Error>> {
|
||||
// Alice must wait for the relative locktime to expire before she can extract her money
|
||||
// from the split transaction output.
|
||||
wait_for_confs(
|
||||
&split_tx.txid(),
|
||||
&split_tx.compute_txid(),
|
||||
signed_contract.params().relative_locktime_block_delta,
|
||||
);
|
||||
|
||||
@@ -312,7 +313,7 @@ fn two_player_example() -> Result<(), Box<dyn std::error::Error>> {
|
||||
)?;
|
||||
|
||||
broadcast_transaction(&alice_win_tx);
|
||||
wait_for_confs(&alice_win_tx.txid(), 1);
|
||||
wait_for_confs(&alice_win_tx.compute_txid(), 1);
|
||||
|
||||
// Alice now has 100% control over her winnings.
|
||||
Ok(())
|
||||
@@ -405,7 +406,7 @@ fn two_player_example() -> Result<(), Box<dyn std::error::Error>> {
|
||||
// The reclaim TX spending path is only unlocked after double the locktime
|
||||
// needed for the split TX.
|
||||
wait_for_confs(
|
||||
&outcome_tx.txid(),
|
||||
&outcome_tx.compute_txid(),
|
||||
2 * signed_contract.params().relative_locktime_block_delta,
|
||||
);
|
||||
|
||||
@@ -536,7 +537,8 @@ fn wait_for_confs(_: &bitcoin::Txid, _: u16) {}
|
||||
/// Generate a P2TR script pubkey which pays to the given pubkey (no tweak added).
|
||||
fn p2tr_script_pubkey(pubkey: Point) -> bitcoin::ScriptBuf {
|
||||
let (xonly, _) = pubkey.into();
|
||||
let tweaked = bitcoin::key::TweakedPublicKey::dangerous_assume_tweaked(xonly);
|
||||
let tweaked =
|
||||
bitcoin::key::TweakedPublicKey::dangerous_assume_tweaked(convert_xonly_key(xonly));
|
||||
bitcoin::ScriptBuf::new_p2tr_tweaked(tweaked)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user