Cargo.toml 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306
  1. [package]
  2. name = "darkfi"
  3. version = "0.3.0"
  4. homepage = "https://dark.fi"
  5. description = "Anonymous. Uncensored. Sovereign."
  6. authors = ["darkfi <dev@dark.fi>"]
  7. repository = "https://github.com/darkrenaissance/darkfi"
  8. license = "AGPL-3.0-only"
  9. edition = "2021"
  10. [lib]
  11. name = "darkfi"
  12. [workspace]
  13. members = [
  14. "bin/zkas",
  15. "bin/cashierd",
  16. "bin/darkfid",
  17. "bin/drk",
  18. "bin/gatewayd",
  19. "bin/ircd",
  20. "bin/dnetview",
  21. "bin/daod",
  22. "bin/dao-cli",
  23. "bin/tau/taud",
  24. "bin/tau/tau-cli",
  25. "bin/vanityaddr",
  26. "src/sdk",
  27. "src/util/derive",
  28. "src/util/derive-internal",
  29. ]
  30. [dependencies]
  31. # Hard dependencies
  32. libc = "0.2.121"
  33. log = "0.4.16"
  34. thiserror = "1.0.30"
  35. # async-runtime
  36. smol = {version = "1.2.5", optional = true}
  37. futures = {version = "0.3.21", optional = true}
  38. async-std = {version = "1.11.0", features = ["attributes"], optional = true}
  39. async-trait = {version = "0.1.53", optional = true}
  40. async-channel = {version = "1.6.1", optional = true}
  41. async-executor = {version = "1.4.1", optional = true}
  42. # async-net
  43. async-native-tls = {version = "0.4.0", optional = true}
  44. native-tls = {version = "0.2.8", optional = true}
  45. # Networking
  46. socket2 = {version = "0.4.4", optional = true}
  47. futures-rustls = {version = "0.22.1", features = ["dangerous_configuration"], optional = true}
  48. # TLS cert utilities
  49. ed25519-compact = {version = "1.0.11", features = ["pem"], optional = true}
  50. rcgen = {version = "0.9.2", features = ["pem"], optional = true}
  51. rustls-pemfile = {version = "0.3.0", optional = true}
  52. # Encoding
  53. hex = {version = "0.4.3", optional = true}
  54. bs58 = {version = "0.4.0", optional = true}
  55. toml = {version = "0.5.8", optional = true}
  56. bytes = {version = "1.1.0", optional = true}
  57. bincode = {version = "1.3.3", optional = true}
  58. num-bigint = {version = "0.4.3", optional = true}
  59. serde_json = {version = "1.0.79", optional = true}
  60. serde = {version = "1.0.136", features = ["derive"], optional = true}
  61. # Utilities
  62. url = {version = "2.2.2", optional = true}
  63. dirs = {version = "4.0.0", optional = true}
  64. subtle = {version = "2.4.1", optional = true}
  65. lazy_static = {version = "1.4.0", optional = true}
  66. fxhash = {version = "0.2.1", optional = true}
  67. indexmap = {version = "1.8.0", optional = true}
  68. itertools = {version = "0.10.3", optional = true}
  69. darkfi-derive = {path = "src/util/derive", optional = true}
  70. darkfi-derive-internal = {path = "src/util/derive-internal", optional = true}
  71. chrono = {version = "0.4.19", optional = true}
  72. regex = {version = "1.1.9", optional = true}
  73. # Misc
  74. termion = {version = "1.5.6", optional = true}
  75. simplelog = {version = "0.12.0-alpha1", optional = true}
  76. # Websockets
  77. tungstenite = {version = "0.17.2", optional = true}
  78. async-tungstenite = {version = "0.17.2", optional = true}
  79. # socks5
  80. fast-socks5 = {git = "https://github.com/ghassmo/fast-socks5", optional = true}
  81. # Crypto
  82. bitvec = {version = "1.0.0", optional = true}
  83. rand = {version = "0.8.5", optional = true}
  84. blake3 = {version = "1.3.1", optional = true}
  85. sha2 = {version = "0.10.2", optional = true}
  86. group = {version = "0.11.0", optional = true}
  87. arrayvec = {version = "0.7.2", optional = true}
  88. blake2b_simd = {version = "1.0.0", optional = true}
  89. pasta_curves = {version = "0.3.0", optional = true}
  90. crypto_api_chachapoly = {version = "0.5.0", optional = true}
  91. incrementalmerkletree = {version = "0.2.0", optional = true}
  92. halo2_proofs = {version = "0.1.0-beta.4", features = ["dev-graph", "gadget-traces", "sanity-checks"], optional = true}
  93. halo2_gadgets = {version = "0.1.0-beta.3", features = ["dev-graph", "test-dependencies"], optional = true}
  94. # Smart contract runtime
  95. drk-sdk = {path = "src/sdk", optional = true}
  96. wasmer = {version = "2.2.1", optional = true}
  97. wasmer-compiler-singlepass = {version = "2.2.1", optional = true}
  98. wasmer-middlewares = {version = "2.2.1", optional = true}
  99. # Wallet management
  100. sqlx = {version = "0.5.11", features = ["runtime-async-std-native-tls", "sqlite"], optional = true}
  101. libsqlite3-sys = {version = "0.23.2", features = ["bundled-sqlcipher"], optional = true }
  102. # Blockchain store
  103. sled = {version = "0.34.7", optional = true}
  104. # Node utilities
  105. signal-hook = {version = "0.3.13", optional = true}
  106. signal-hook-async-std = {version = "0.2.2", optional = true}
  107. # Node protocol
  108. [dependencies.zeromq]
  109. version = "0.3.3"
  110. default-features = false
  111. features = ["async-std-runtime", "all-transport"]
  112. optional = true
  113. [dependencies.rocksdb]
  114. # TODO: Revert to upstream after bd966750ec861d687913d59a9939a1408ac53131 is merged.
  115. git = "https://github.com/parazyd/rust-rocksdb"
  116. rev = "bd966750ec861d687913d59a9939a1408ac53131"
  117. default-features = false
  118. features = ["zstd"]
  119. optional = true
  120. [dev-dependencies]
  121. clap = {version = "3.1.6", features = ["derive"]}
  122. [features]
  123. async-runtime = [
  124. "async-std",
  125. "async-channel",
  126. "async-executor",
  127. "async-trait",
  128. "futures",
  129. "smol",
  130. ]
  131. async-net = [
  132. "async-native-tls",
  133. "native-tls",
  134. ]
  135. websockets = [
  136. "async-tungstenite",
  137. "tungstenite",
  138. ]
  139. util = [
  140. "hex",
  141. "bincode",
  142. "serde",
  143. "toml",
  144. "url",
  145. "simplelog",
  146. "serde_json",
  147. "dirs",
  148. "num-bigint",
  149. "fxhash",
  150. "darkfi-derive",
  151. "darkfi-derive-internal",
  152. ]
  153. rpc = [
  154. "rand",
  155. "url",
  156. "fast-socks5",
  157. "async-net",
  158. "async-runtime",
  159. "websockets",
  160. "util",
  161. ]
  162. blockchain = [
  163. "rocksdb",
  164. "sled",
  165. "chrono",
  166. "rand",
  167. "async-runtime",
  168. "util",
  169. "crypto",
  170. "net",
  171. "blockchain2",
  172. ]
  173. blockchain2 = [
  174. "blake3",
  175. "sled",
  176. "util",
  177. ]
  178. system = [
  179. "fxhash",
  180. "rand",
  181. "async-runtime",
  182. ]
  183. net = [
  184. "fxhash",
  185. "socket2",
  186. "futures-rustls",
  187. "fast-socks5",
  188. "ed25519-compact",
  189. "rcgen",
  190. "regex",
  191. "rustls-pemfile",
  192. "util",
  193. "system",
  194. ]
  195. crypto = [
  196. "bitvec",
  197. "blake3",
  198. "rand",
  199. "pasta_curves",
  200. "blake2b_simd",
  201. "incrementalmerkletree",
  202. "halo2_proofs",
  203. "halo2_gadgets",
  204. "subtle",
  205. "lazy_static",
  206. "group",
  207. "arrayvec",
  208. "crypto_api_chachapoly",
  209. "sha2",
  210. "bs58",
  211. "util",
  212. "zkas",
  213. ]
  214. wallet = [
  215. "sqlx",
  216. "libsqlite3-sys",
  217. ]
  218. wasm-runtime = [
  219. "drk-sdk",
  220. "wasmer",
  221. "wasmer-compiler-singlepass",
  222. "wasmer-middlewares",
  223. ]
  224. node = [
  225. "url",
  226. "bytes",
  227. "zeromq",
  228. "signal-hook",
  229. "signal-hook-async-std",
  230. "async-runtime",
  231. "blockchain",
  232. "crypto",
  233. "wallet",
  234. "util",
  235. "net",
  236. ]
  237. zkas = [
  238. "termion",
  239. "indexmap",
  240. "itertools",
  241. "util",
  242. ]
  243. raft = [
  244. "blake3",
  245. "sled",
  246. "util",
  247. "net",
  248. "rpc",
  249. ]
  250. [[example]]
  251. name = "net"
  252. path = "example/net.rs"
  253. required-features = ["async-runtime", "net"]
  254. [[example]]
  255. name = "tx"
  256. path = "example/tx.rs"
  257. required-features = ["node"]