├── .gitignore ├── .rustfmt.toml ├── Cargo.lock ├── Cargo.toml ├── LICENSE-APACHE ├── LICENSE-MIT ├── README.md ├── app ├── Cargo.toml └── src │ └── main.rs ├── core ├── Cargo.toml ├── build.rs └── src │ └── lib.rs └── random ├── Cargo.toml └── src └── lib.rs /.gitignore: -------------------------------------------------------------------------------- 1 | target 2 | -------------------------------------------------------------------------------- /.rustfmt.toml: -------------------------------------------------------------------------------- 1 | max_width = 80 2 | tab_spaces = 4 3 | fn_single_line = true 4 | match_block_trailing_comma = true 5 | normalize_comments = true 6 | wrap_comments = true 7 | merge_imports = true 8 | reorder_impl_items = true 9 | use_field_init_shorthand = true 10 | use_try_shorthand = true 11 | normalize_doc_attributes = true 12 | report_todo = "Always" 13 | report_fixme = "Always" 14 | edition = "2018" 15 | -------------------------------------------------------------------------------- /Cargo.lock: -------------------------------------------------------------------------------- 1 | # This file is automatically @generated by Cargo. 2 | # It is not intended for manual editing. 3 | [[package]] 4 | name = "adler32" 5 | version = "1.0.4" 6 | source = "registry+https://github.com/rust-lang/crates.io-index" 7 | 8 | [[package]] 9 | name = "aho-corasick" 10 | version = "0.7.6" 11 | source = "registry+https://github.com/rust-lang/crates.io-index" 12 | dependencies = [ 13 | "memchr 2.2.1 (registry+https://github.com/rust-lang/crates.io-index)", 14 | ] 15 | 16 | [[package]] 17 | name = "arrayvec" 18 | version = "0.4.11" 19 | source = "registry+https://github.com/rust-lang/crates.io-index" 20 | dependencies = [ 21 | "nodrop 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)", 22 | ] 23 | 24 | [[package]] 25 | name = "autocfg" 26 | version = "0.1.6" 27 | source = "registry+https://github.com/rust-lang/crates.io-index" 28 | 29 | [[package]] 30 | name = "backtrace" 31 | version = "0.3.38" 32 | source = "registry+https://github.com/rust-lang/crates.io-index" 33 | dependencies = [ 34 | "backtrace-sys 0.1.31 (registry+https://github.com/rust-lang/crates.io-index)", 35 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 36 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 37 | "rustc-demangle 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)", 38 | ] 39 | 40 | [[package]] 41 | name = "backtrace-sys" 42 | version = "0.1.31" 43 | source = "registry+https://github.com/rust-lang/crates.io-index" 44 | dependencies = [ 45 | "cc 1.0.45 (registry+https://github.com/rust-lang/crates.io-index)", 46 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 47 | ] 48 | 49 | [[package]] 50 | name = "base64" 51 | version = "0.10.1" 52 | source = "registry+https://github.com/rust-lang/crates.io-index" 53 | dependencies = [ 54 | "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", 55 | ] 56 | 57 | [[package]] 58 | name = "bitflags" 59 | version = "1.2.0" 60 | source = "registry+https://github.com/rust-lang/crates.io-index" 61 | 62 | [[package]] 63 | name = "byteorder" 64 | version = "1.3.2" 65 | source = "registry+https://github.com/rust-lang/crates.io-index" 66 | 67 | [[package]] 68 | name = "bytes" 69 | version = "0.4.12" 70 | source = "registry+https://github.com/rust-lang/crates.io-index" 71 | dependencies = [ 72 | "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", 73 | "either 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)", 74 | "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", 75 | ] 76 | 77 | [[package]] 78 | name = "c2-chacha" 79 | version = "0.2.2" 80 | source = "registry+https://github.com/rust-lang/crates.io-index" 81 | dependencies = [ 82 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 83 | "ppv-lite86 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)", 84 | ] 85 | 86 | [[package]] 87 | name = "cc" 88 | version = "1.0.45" 89 | source = "registry+https://github.com/rust-lang/crates.io-index" 90 | 91 | [[package]] 92 | name = "cfg-if" 93 | version = "0.1.10" 94 | source = "registry+https://github.com/rust-lang/crates.io-index" 95 | 96 | [[package]] 97 | name = "cloudabi" 98 | version = "0.0.3" 99 | source = "registry+https://github.com/rust-lang/crates.io-index" 100 | dependencies = [ 101 | "bitflags 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 102 | ] 103 | 104 | [[package]] 105 | name = "cookie" 106 | version = "0.12.0" 107 | source = "registry+https://github.com/rust-lang/crates.io-index" 108 | dependencies = [ 109 | "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", 110 | "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", 111 | ] 112 | 113 | [[package]] 114 | name = "cookie_store" 115 | version = "0.7.0" 116 | source = "registry+https://github.com/rust-lang/crates.io-index" 117 | dependencies = [ 118 | "cookie 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)", 119 | "failure 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", 120 | "idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", 121 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 122 | "publicsuffix 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)", 123 | "serde 1.0.101 (registry+https://github.com/rust-lang/crates.io-index)", 124 | "serde_json 1.0.40 (registry+https://github.com/rust-lang/crates.io-index)", 125 | "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", 126 | "try_from 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", 127 | "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", 128 | ] 129 | 130 | [[package]] 131 | name = "core-foundation" 132 | version = "0.6.4" 133 | source = "registry+https://github.com/rust-lang/crates.io-index" 134 | dependencies = [ 135 | "core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", 136 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 137 | ] 138 | 139 | [[package]] 140 | name = "core-foundation-sys" 141 | version = "0.6.2" 142 | source = "registry+https://github.com/rust-lang/crates.io-index" 143 | 144 | [[package]] 145 | name = "crc32fast" 146 | version = "1.2.0" 147 | source = "registry+https://github.com/rust-lang/crates.io-index" 148 | dependencies = [ 149 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 150 | ] 151 | 152 | [[package]] 153 | name = "crossbeam-deque" 154 | version = "0.7.1" 155 | source = "registry+https://github.com/rust-lang/crates.io-index" 156 | dependencies = [ 157 | "crossbeam-epoch 0.7.2 (registry+https://github.com/rust-lang/crates.io-index)", 158 | "crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)", 159 | ] 160 | 161 | [[package]] 162 | name = "crossbeam-epoch" 163 | version = "0.7.2" 164 | source = "registry+https://github.com/rust-lang/crates.io-index" 165 | dependencies = [ 166 | "arrayvec 0.4.11 (registry+https://github.com/rust-lang/crates.io-index)", 167 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 168 | "crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)", 169 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 170 | "memoffset 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", 171 | "scopeguard 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", 172 | ] 173 | 174 | [[package]] 175 | name = "crossbeam-queue" 176 | version = "0.1.2" 177 | source = "registry+https://github.com/rust-lang/crates.io-index" 178 | dependencies = [ 179 | "crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)", 180 | ] 181 | 182 | [[package]] 183 | name = "crossbeam-utils" 184 | version = "0.6.6" 185 | source = "registry+https://github.com/rust-lang/crates.io-index" 186 | dependencies = [ 187 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 188 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 189 | ] 190 | 191 | [[package]] 192 | name = "dtoa" 193 | version = "0.4.4" 194 | source = "registry+https://github.com/rust-lang/crates.io-index" 195 | 196 | [[package]] 197 | name = "either" 198 | version = "1.5.3" 199 | source = "registry+https://github.com/rust-lang/crates.io-index" 200 | 201 | [[package]] 202 | name = "encoding_rs" 203 | version = "0.8.20" 204 | source = "registry+https://github.com/rust-lang/crates.io-index" 205 | dependencies = [ 206 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 207 | ] 208 | 209 | [[package]] 210 | name = "error-chain" 211 | version = "0.12.1" 212 | source = "registry+https://github.com/rust-lang/crates.io-index" 213 | dependencies = [ 214 | "backtrace 0.3.38 (registry+https://github.com/rust-lang/crates.io-index)", 215 | "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", 216 | ] 217 | 218 | [[package]] 219 | name = "failure" 220 | version = "0.1.5" 221 | source = "registry+https://github.com/rust-lang/crates.io-index" 222 | dependencies = [ 223 | "backtrace 0.3.38 (registry+https://github.com/rust-lang/crates.io-index)", 224 | "failure_derive 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", 225 | ] 226 | 227 | [[package]] 228 | name = "failure_derive" 229 | version = "0.1.5" 230 | source = "registry+https://github.com/rust-lang/crates.io-index" 231 | dependencies = [ 232 | "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", 233 | "quote 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)", 234 | "syn 0.15.44 (registry+https://github.com/rust-lang/crates.io-index)", 235 | "synstructure 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)", 236 | ] 237 | 238 | [[package]] 239 | name = "flate2" 240 | version = "1.0.11" 241 | source = "registry+https://github.com/rust-lang/crates.io-index" 242 | dependencies = [ 243 | "crc32fast 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 244 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 245 | "miniz_oxide 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", 246 | ] 247 | 248 | [[package]] 249 | name = "fnv" 250 | version = "1.0.6" 251 | source = "registry+https://github.com/rust-lang/crates.io-index" 252 | 253 | [[package]] 254 | name = "foreign-types" 255 | version = "0.3.2" 256 | source = "registry+https://github.com/rust-lang/crates.io-index" 257 | dependencies = [ 258 | "foreign-types-shared 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 259 | ] 260 | 261 | [[package]] 262 | name = "foreign-types-shared" 263 | version = "0.1.1" 264 | source = "registry+https://github.com/rust-lang/crates.io-index" 265 | 266 | [[package]] 267 | name = "fuchsia-cprng" 268 | version = "0.1.1" 269 | source = "registry+https://github.com/rust-lang/crates.io-index" 270 | 271 | [[package]] 272 | name = "fuchsia-zircon" 273 | version = "0.3.3" 274 | source = "registry+https://github.com/rust-lang/crates.io-index" 275 | dependencies = [ 276 | "bitflags 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 277 | "fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", 278 | ] 279 | 280 | [[package]] 281 | name = "fuchsia-zircon-sys" 282 | version = "0.3.3" 283 | source = "registry+https://github.com/rust-lang/crates.io-index" 284 | 285 | [[package]] 286 | name = "futures" 287 | version = "0.1.29" 288 | source = "registry+https://github.com/rust-lang/crates.io-index" 289 | 290 | [[package]] 291 | name = "futures-cpupool" 292 | version = "0.1.8" 293 | source = "registry+https://github.com/rust-lang/crates.io-index" 294 | dependencies = [ 295 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 296 | "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", 297 | ] 298 | 299 | [[package]] 300 | name = "getrandom" 301 | version = "0.1.12" 302 | source = "registry+https://github.com/rust-lang/crates.io-index" 303 | dependencies = [ 304 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 305 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 306 | "wasi 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", 307 | ] 308 | 309 | [[package]] 310 | name = "h2" 311 | version = "0.1.26" 312 | source = "registry+https://github.com/rust-lang/crates.io-index" 313 | dependencies = [ 314 | "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", 315 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 316 | "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", 317 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 318 | "http 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)", 319 | "indexmap 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 320 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 321 | "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 322 | "string 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", 323 | "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 324 | ] 325 | 326 | [[package]] 327 | name = "http" 328 | version = "0.1.18" 329 | source = "registry+https://github.com/rust-lang/crates.io-index" 330 | dependencies = [ 331 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 332 | "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", 333 | "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", 334 | ] 335 | 336 | [[package]] 337 | name = "http-body" 338 | version = "0.1.0" 339 | source = "registry+https://github.com/rust-lang/crates.io-index" 340 | dependencies = [ 341 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 342 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 343 | "http 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)", 344 | "tokio-buf 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 345 | ] 346 | 347 | [[package]] 348 | name = "httparse" 349 | version = "1.3.4" 350 | source = "registry+https://github.com/rust-lang/crates.io-index" 351 | 352 | [[package]] 353 | name = "hyper" 354 | version = "0.12.35" 355 | source = "registry+https://github.com/rust-lang/crates.io-index" 356 | dependencies = [ 357 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 358 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 359 | "futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 360 | "h2 0.1.26 (registry+https://github.com/rust-lang/crates.io-index)", 361 | "http 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)", 362 | "http-body 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 363 | "httparse 1.3.4 (registry+https://github.com/rust-lang/crates.io-index)", 364 | "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", 365 | "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", 366 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 367 | "net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", 368 | "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", 369 | "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", 370 | "tokio 0.1.22 (registry+https://github.com/rust-lang/crates.io-index)", 371 | "tokio-buf 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 372 | "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 373 | "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 374 | "tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", 375 | "tokio-tcp 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", 376 | "tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", 377 | "tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", 378 | "want 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 379 | ] 380 | 381 | [[package]] 382 | name = "hyper-tls" 383 | version = "0.3.2" 384 | source = "registry+https://github.com/rust-lang/crates.io-index" 385 | dependencies = [ 386 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 387 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 388 | "hyper 0.12.35 (registry+https://github.com/rust-lang/crates.io-index)", 389 | "native-tls 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", 390 | "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 391 | ] 392 | 393 | [[package]] 394 | name = "idna" 395 | version = "0.1.5" 396 | source = "registry+https://github.com/rust-lang/crates.io-index" 397 | dependencies = [ 398 | "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 399 | "unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)", 400 | "unicode-normalization 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 401 | ] 402 | 403 | [[package]] 404 | name = "idna" 405 | version = "0.2.0" 406 | source = "registry+https://github.com/rust-lang/crates.io-index" 407 | dependencies = [ 408 | "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 409 | "unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)", 410 | "unicode-normalization 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 411 | ] 412 | 413 | [[package]] 414 | name = "indexmap" 415 | version = "1.2.0" 416 | source = "registry+https://github.com/rust-lang/crates.io-index" 417 | 418 | [[package]] 419 | name = "iovec" 420 | version = "0.1.2" 421 | source = "registry+https://github.com/rust-lang/crates.io-index" 422 | dependencies = [ 423 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 424 | "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", 425 | ] 426 | 427 | [[package]] 428 | name = "itoa" 429 | version = "0.4.4" 430 | source = "registry+https://github.com/rust-lang/crates.io-index" 431 | 432 | [[package]] 433 | name = "kernel32-sys" 434 | version = "0.2.2" 435 | source = "registry+https://github.com/rust-lang/crates.io-index" 436 | dependencies = [ 437 | "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", 438 | "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 439 | ] 440 | 441 | [[package]] 442 | name = "lazy_static" 443 | version = "1.4.0" 444 | source = "registry+https://github.com/rust-lang/crates.io-index" 445 | 446 | [[package]] 447 | name = "libc" 448 | version = "0.2.62" 449 | source = "registry+https://github.com/rust-lang/crates.io-index" 450 | 451 | [[package]] 452 | name = "libloading" 453 | version = "0.5.2" 454 | source = "registry+https://github.com/rust-lang/crates.io-index" 455 | dependencies = [ 456 | "cc 1.0.45 (registry+https://github.com/rust-lang/crates.io-index)", 457 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 458 | ] 459 | 460 | [[package]] 461 | name = "lock_api" 462 | version = "0.1.5" 463 | source = "registry+https://github.com/rust-lang/crates.io-index" 464 | dependencies = [ 465 | "owning_ref 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 466 | "scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", 467 | ] 468 | 469 | [[package]] 470 | name = "log" 471 | version = "0.4.8" 472 | source = "registry+https://github.com/rust-lang/crates.io-index" 473 | dependencies = [ 474 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 475 | ] 476 | 477 | [[package]] 478 | name = "matches" 479 | version = "0.1.8" 480 | source = "registry+https://github.com/rust-lang/crates.io-index" 481 | 482 | [[package]] 483 | name = "memchr" 484 | version = "2.2.1" 485 | source = "registry+https://github.com/rust-lang/crates.io-index" 486 | 487 | [[package]] 488 | name = "memoffset" 489 | version = "0.5.1" 490 | source = "registry+https://github.com/rust-lang/crates.io-index" 491 | dependencies = [ 492 | "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", 493 | ] 494 | 495 | [[package]] 496 | name = "mime" 497 | version = "0.3.14" 498 | source = "registry+https://github.com/rust-lang/crates.io-index" 499 | 500 | [[package]] 501 | name = "mime_guess" 502 | version = "2.0.1" 503 | source = "registry+https://github.com/rust-lang/crates.io-index" 504 | dependencies = [ 505 | "mime 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)", 506 | "unicase 2.5.1 (registry+https://github.com/rust-lang/crates.io-index)", 507 | ] 508 | 509 | [[package]] 510 | name = "miniz_oxide" 511 | version = "0.3.2" 512 | source = "registry+https://github.com/rust-lang/crates.io-index" 513 | dependencies = [ 514 | "adler32 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", 515 | ] 516 | 517 | [[package]] 518 | name = "mio" 519 | version = "0.6.19" 520 | source = "registry+https://github.com/rust-lang/crates.io-index" 521 | dependencies = [ 522 | "fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", 523 | "fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", 524 | "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", 525 | "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", 526 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 527 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 528 | "miow 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", 529 | "net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", 530 | "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 531 | "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", 532 | ] 533 | 534 | [[package]] 535 | name = "miow" 536 | version = "0.2.1" 537 | source = "registry+https://github.com/rust-lang/crates.io-index" 538 | dependencies = [ 539 | "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", 540 | "net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", 541 | "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", 542 | "ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", 543 | ] 544 | 545 | [[package]] 546 | name = "native-tls" 547 | version = "0.2.3" 548 | source = "registry+https://github.com/rust-lang/crates.io-index" 549 | dependencies = [ 550 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 551 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 552 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 553 | "openssl 0.10.24 (registry+https://github.com/rust-lang/crates.io-index)", 554 | "openssl-probe 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", 555 | "openssl-sys 0.9.49 (registry+https://github.com/rust-lang/crates.io-index)", 556 | "schannel 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)", 557 | "security-framework 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 558 | "security-framework-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 559 | "tempfile 3.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 560 | ] 561 | 562 | [[package]] 563 | name = "net2" 564 | version = "0.2.33" 565 | source = "registry+https://github.com/rust-lang/crates.io-index" 566 | dependencies = [ 567 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 568 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 569 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 570 | ] 571 | 572 | [[package]] 573 | name = "nodrop" 574 | version = "0.1.13" 575 | source = "registry+https://github.com/rust-lang/crates.io-index" 576 | 577 | [[package]] 578 | name = "num_cpus" 579 | version = "1.10.1" 580 | source = "registry+https://github.com/rust-lang/crates.io-index" 581 | dependencies = [ 582 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 583 | ] 584 | 585 | [[package]] 586 | name = "openssl" 587 | version = "0.10.24" 588 | source = "registry+https://github.com/rust-lang/crates.io-index" 589 | dependencies = [ 590 | "bitflags 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 591 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 592 | "foreign-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", 593 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 594 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 595 | "openssl-sys 0.9.49 (registry+https://github.com/rust-lang/crates.io-index)", 596 | ] 597 | 598 | [[package]] 599 | name = "openssl-probe" 600 | version = "0.1.2" 601 | source = "registry+https://github.com/rust-lang/crates.io-index" 602 | 603 | [[package]] 604 | name = "openssl-sys" 605 | version = "0.9.49" 606 | source = "registry+https://github.com/rust-lang/crates.io-index" 607 | dependencies = [ 608 | "autocfg 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", 609 | "cc 1.0.45 (registry+https://github.com/rust-lang/crates.io-index)", 610 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 611 | "pkg-config 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", 612 | "vcpkg 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)", 613 | ] 614 | 615 | [[package]] 616 | name = "owning_ref" 617 | version = "0.4.0" 618 | source = "registry+https://github.com/rust-lang/crates.io-index" 619 | dependencies = [ 620 | "stable_deref_trait 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 621 | ] 622 | 623 | [[package]] 624 | name = "parking_lot" 625 | version = "0.7.1" 626 | source = "registry+https://github.com/rust-lang/crates.io-index" 627 | dependencies = [ 628 | "lock_api 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", 629 | "parking_lot_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 630 | ] 631 | 632 | [[package]] 633 | name = "parking_lot_core" 634 | version = "0.4.0" 635 | source = "registry+https://github.com/rust-lang/crates.io-index" 636 | dependencies = [ 637 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 638 | "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", 639 | "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", 640 | "smallvec 0.6.10 (registry+https://github.com/rust-lang/crates.io-index)", 641 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 642 | ] 643 | 644 | [[package]] 645 | name = "percent-encoding" 646 | version = "1.0.1" 647 | source = "registry+https://github.com/rust-lang/crates.io-index" 648 | 649 | [[package]] 650 | name = "percent-encoding" 651 | version = "2.1.0" 652 | source = "registry+https://github.com/rust-lang/crates.io-index" 653 | 654 | [[package]] 655 | name = "pkg-config" 656 | version = "0.3.16" 657 | source = "registry+https://github.com/rust-lang/crates.io-index" 658 | 659 | [[package]] 660 | name = "plugins_app" 661 | version = "0.1.0" 662 | dependencies = [ 663 | "libloading 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", 664 | "plugins_core 0.1.0", 665 | ] 666 | 667 | [[package]] 668 | name = "plugins_core" 669 | version = "0.1.0" 670 | dependencies = [ 671 | "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", 672 | ] 673 | 674 | [[package]] 675 | name = "plugins_random" 676 | version = "0.1.0" 677 | dependencies = [ 678 | "plugins_core 0.1.0", 679 | "reqwest 0.9.20 (registry+https://github.com/rust-lang/crates.io-index)", 680 | ] 681 | 682 | [[package]] 683 | name = "ppv-lite86" 684 | version = "0.2.5" 685 | source = "registry+https://github.com/rust-lang/crates.io-index" 686 | 687 | [[package]] 688 | name = "proc-macro2" 689 | version = "0.4.30" 690 | source = "registry+https://github.com/rust-lang/crates.io-index" 691 | dependencies = [ 692 | "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 693 | ] 694 | 695 | [[package]] 696 | name = "proc-macro2" 697 | version = "1.0.4" 698 | source = "registry+https://github.com/rust-lang/crates.io-index" 699 | dependencies = [ 700 | "unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 701 | ] 702 | 703 | [[package]] 704 | name = "publicsuffix" 705 | version = "1.5.3" 706 | source = "registry+https://github.com/rust-lang/crates.io-index" 707 | dependencies = [ 708 | "error-chain 0.12.1 (registry+https://github.com/rust-lang/crates.io-index)", 709 | "idna 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 710 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 711 | "regex 1.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 712 | "url 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 713 | ] 714 | 715 | [[package]] 716 | name = "quote" 717 | version = "0.6.13" 718 | source = "registry+https://github.com/rust-lang/crates.io-index" 719 | dependencies = [ 720 | "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", 721 | ] 722 | 723 | [[package]] 724 | name = "quote" 725 | version = "1.0.2" 726 | source = "registry+https://github.com/rust-lang/crates.io-index" 727 | dependencies = [ 728 | "proc-macro2 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", 729 | ] 730 | 731 | [[package]] 732 | name = "rand" 733 | version = "0.6.5" 734 | source = "registry+https://github.com/rust-lang/crates.io-index" 735 | dependencies = [ 736 | "autocfg 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", 737 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 738 | "rand_chacha 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 739 | "rand_core 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 740 | "rand_hc 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 741 | "rand_isaac 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 742 | "rand_jitter 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", 743 | "rand_os 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", 744 | "rand_pcg 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", 745 | "rand_xorshift 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 746 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 747 | ] 748 | 749 | [[package]] 750 | name = "rand" 751 | version = "0.7.2" 752 | source = "registry+https://github.com/rust-lang/crates.io-index" 753 | dependencies = [ 754 | "getrandom 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 755 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 756 | "rand_chacha 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", 757 | "rand_core 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", 758 | "rand_hc 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 759 | ] 760 | 761 | [[package]] 762 | name = "rand_chacha" 763 | version = "0.1.1" 764 | source = "registry+https://github.com/rust-lang/crates.io-index" 765 | dependencies = [ 766 | "autocfg 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", 767 | "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 768 | ] 769 | 770 | [[package]] 771 | name = "rand_chacha" 772 | version = "0.2.1" 773 | source = "registry+https://github.com/rust-lang/crates.io-index" 774 | dependencies = [ 775 | "c2-chacha 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", 776 | "rand_core 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", 777 | ] 778 | 779 | [[package]] 780 | name = "rand_core" 781 | version = "0.3.1" 782 | source = "registry+https://github.com/rust-lang/crates.io-index" 783 | dependencies = [ 784 | "rand_core 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 785 | ] 786 | 787 | [[package]] 788 | name = "rand_core" 789 | version = "0.4.2" 790 | source = "registry+https://github.com/rust-lang/crates.io-index" 791 | 792 | [[package]] 793 | name = "rand_core" 794 | version = "0.5.1" 795 | source = "registry+https://github.com/rust-lang/crates.io-index" 796 | dependencies = [ 797 | "getrandom 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 798 | ] 799 | 800 | [[package]] 801 | name = "rand_hc" 802 | version = "0.1.0" 803 | source = "registry+https://github.com/rust-lang/crates.io-index" 804 | dependencies = [ 805 | "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 806 | ] 807 | 808 | [[package]] 809 | name = "rand_hc" 810 | version = "0.2.0" 811 | source = "registry+https://github.com/rust-lang/crates.io-index" 812 | dependencies = [ 813 | "rand_core 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", 814 | ] 815 | 816 | [[package]] 817 | name = "rand_isaac" 818 | version = "0.1.1" 819 | source = "registry+https://github.com/rust-lang/crates.io-index" 820 | dependencies = [ 821 | "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 822 | ] 823 | 824 | [[package]] 825 | name = "rand_jitter" 826 | version = "0.1.4" 827 | source = "registry+https://github.com/rust-lang/crates.io-index" 828 | dependencies = [ 829 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 830 | "rand_core 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 831 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 832 | ] 833 | 834 | [[package]] 835 | name = "rand_os" 836 | version = "0.1.3" 837 | source = "registry+https://github.com/rust-lang/crates.io-index" 838 | dependencies = [ 839 | "cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)", 840 | "fuchsia-cprng 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 841 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 842 | "rand_core 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 843 | "rdrand 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 844 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 845 | ] 846 | 847 | [[package]] 848 | name = "rand_pcg" 849 | version = "0.1.2" 850 | source = "registry+https://github.com/rust-lang/crates.io-index" 851 | dependencies = [ 852 | "autocfg 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", 853 | "rand_core 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 854 | ] 855 | 856 | [[package]] 857 | name = "rand_xorshift" 858 | version = "0.1.1" 859 | source = "registry+https://github.com/rust-lang/crates.io-index" 860 | dependencies = [ 861 | "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 862 | ] 863 | 864 | [[package]] 865 | name = "rdrand" 866 | version = "0.4.0" 867 | source = "registry+https://github.com/rust-lang/crates.io-index" 868 | dependencies = [ 869 | "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 870 | ] 871 | 872 | [[package]] 873 | name = "redox_syscall" 874 | version = "0.1.56" 875 | source = "registry+https://github.com/rust-lang/crates.io-index" 876 | 877 | [[package]] 878 | name = "regex" 879 | version = "1.3.1" 880 | source = "registry+https://github.com/rust-lang/crates.io-index" 881 | dependencies = [ 882 | "aho-corasick 0.7.6 (registry+https://github.com/rust-lang/crates.io-index)", 883 | "memchr 2.2.1 (registry+https://github.com/rust-lang/crates.io-index)", 884 | "regex-syntax 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", 885 | "thread_local 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", 886 | ] 887 | 888 | [[package]] 889 | name = "regex-syntax" 890 | version = "0.6.12" 891 | source = "registry+https://github.com/rust-lang/crates.io-index" 892 | 893 | [[package]] 894 | name = "remove_dir_all" 895 | version = "0.5.2" 896 | source = "registry+https://github.com/rust-lang/crates.io-index" 897 | dependencies = [ 898 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 899 | ] 900 | 901 | [[package]] 902 | name = "reqwest" 903 | version = "0.9.20" 904 | source = "registry+https://github.com/rust-lang/crates.io-index" 905 | dependencies = [ 906 | "base64 0.10.1 (registry+https://github.com/rust-lang/crates.io-index)", 907 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 908 | "cookie 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)", 909 | "cookie_store 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", 910 | "encoding_rs 0.8.20 (registry+https://github.com/rust-lang/crates.io-index)", 911 | "flate2 1.0.11 (registry+https://github.com/rust-lang/crates.io-index)", 912 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 913 | "http 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)", 914 | "hyper 0.12.35 (registry+https://github.com/rust-lang/crates.io-index)", 915 | "hyper-tls 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", 916 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 917 | "mime 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)", 918 | "mime_guess 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)", 919 | "native-tls 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", 920 | "serde 1.0.101 (registry+https://github.com/rust-lang/crates.io-index)", 921 | "serde_json 1.0.40 (registry+https://github.com/rust-lang/crates.io-index)", 922 | "serde_urlencoded 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)", 923 | "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", 924 | "tokio 0.1.22 (registry+https://github.com/rust-lang/crates.io-index)", 925 | "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 926 | "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 927 | "tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", 928 | "tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", 929 | "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", 930 | "uuid 0.7.4 (registry+https://github.com/rust-lang/crates.io-index)", 931 | "winreg 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", 932 | ] 933 | 934 | [[package]] 935 | name = "rustc-demangle" 936 | version = "0.1.16" 937 | source = "registry+https://github.com/rust-lang/crates.io-index" 938 | 939 | [[package]] 940 | name = "rustc_version" 941 | version = "0.2.3" 942 | source = "registry+https://github.com/rust-lang/crates.io-index" 943 | dependencies = [ 944 | "semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)", 945 | ] 946 | 947 | [[package]] 948 | name = "ryu" 949 | version = "1.0.0" 950 | source = "registry+https://github.com/rust-lang/crates.io-index" 951 | 952 | [[package]] 953 | name = "schannel" 954 | version = "0.1.16" 955 | source = "registry+https://github.com/rust-lang/crates.io-index" 956 | dependencies = [ 957 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 958 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 959 | ] 960 | 961 | [[package]] 962 | name = "scopeguard" 963 | version = "0.3.3" 964 | source = "registry+https://github.com/rust-lang/crates.io-index" 965 | 966 | [[package]] 967 | name = "scopeguard" 968 | version = "1.0.0" 969 | source = "registry+https://github.com/rust-lang/crates.io-index" 970 | 971 | [[package]] 972 | name = "security-framework" 973 | version = "0.3.1" 974 | source = "registry+https://github.com/rust-lang/crates.io-index" 975 | dependencies = [ 976 | "core-foundation 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)", 977 | "core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", 978 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 979 | "security-framework-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", 980 | ] 981 | 982 | [[package]] 983 | name = "security-framework-sys" 984 | version = "0.3.1" 985 | source = "registry+https://github.com/rust-lang/crates.io-index" 986 | dependencies = [ 987 | "core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", 988 | ] 989 | 990 | [[package]] 991 | name = "semver" 992 | version = "0.9.0" 993 | source = "registry+https://github.com/rust-lang/crates.io-index" 994 | dependencies = [ 995 | "semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", 996 | ] 997 | 998 | [[package]] 999 | name = "semver-parser" 1000 | version = "0.7.0" 1001 | source = "registry+https://github.com/rust-lang/crates.io-index" 1002 | 1003 | [[package]] 1004 | name = "serde" 1005 | version = "1.0.101" 1006 | source = "registry+https://github.com/rust-lang/crates.io-index" 1007 | dependencies = [ 1008 | "serde_derive 1.0.101 (registry+https://github.com/rust-lang/crates.io-index)", 1009 | ] 1010 | 1011 | [[package]] 1012 | name = "serde_derive" 1013 | version = "1.0.101" 1014 | source = "registry+https://github.com/rust-lang/crates.io-index" 1015 | dependencies = [ 1016 | "proc-macro2 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", 1017 | "quote 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)", 1018 | "syn 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)", 1019 | ] 1020 | 1021 | [[package]] 1022 | name = "serde_json" 1023 | version = "1.0.40" 1024 | source = "registry+https://github.com/rust-lang/crates.io-index" 1025 | dependencies = [ 1026 | "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", 1027 | "ryu 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", 1028 | "serde 1.0.101 (registry+https://github.com/rust-lang/crates.io-index)", 1029 | ] 1030 | 1031 | [[package]] 1032 | name = "serde_urlencoded" 1033 | version = "0.5.5" 1034 | source = "registry+https://github.com/rust-lang/crates.io-index" 1035 | dependencies = [ 1036 | "dtoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", 1037 | "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", 1038 | "serde 1.0.101 (registry+https://github.com/rust-lang/crates.io-index)", 1039 | "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", 1040 | ] 1041 | 1042 | [[package]] 1043 | name = "slab" 1044 | version = "0.4.2" 1045 | source = "registry+https://github.com/rust-lang/crates.io-index" 1046 | 1047 | [[package]] 1048 | name = "smallvec" 1049 | version = "0.6.10" 1050 | source = "registry+https://github.com/rust-lang/crates.io-index" 1051 | 1052 | [[package]] 1053 | name = "stable_deref_trait" 1054 | version = "1.1.1" 1055 | source = "registry+https://github.com/rust-lang/crates.io-index" 1056 | 1057 | [[package]] 1058 | name = "string" 1059 | version = "0.2.1" 1060 | source = "registry+https://github.com/rust-lang/crates.io-index" 1061 | dependencies = [ 1062 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 1063 | ] 1064 | 1065 | [[package]] 1066 | name = "syn" 1067 | version = "0.15.44" 1068 | source = "registry+https://github.com/rust-lang/crates.io-index" 1069 | dependencies = [ 1070 | "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", 1071 | "quote 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)", 1072 | "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 1073 | ] 1074 | 1075 | [[package]] 1076 | name = "syn" 1077 | version = "1.0.5" 1078 | source = "registry+https://github.com/rust-lang/crates.io-index" 1079 | dependencies = [ 1080 | "proc-macro2 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", 1081 | "quote 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)", 1082 | "unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 1083 | ] 1084 | 1085 | [[package]] 1086 | name = "synstructure" 1087 | version = "0.10.2" 1088 | source = "registry+https://github.com/rust-lang/crates.io-index" 1089 | dependencies = [ 1090 | "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", 1091 | "quote 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)", 1092 | "syn 0.15.44 (registry+https://github.com/rust-lang/crates.io-index)", 1093 | "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 1094 | ] 1095 | 1096 | [[package]] 1097 | name = "tempfile" 1098 | version = "3.1.0" 1099 | source = "registry+https://github.com/rust-lang/crates.io-index" 1100 | dependencies = [ 1101 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 1102 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 1103 | "rand 0.7.2 (registry+https://github.com/rust-lang/crates.io-index)", 1104 | "redox_syscall 0.1.56 (registry+https://github.com/rust-lang/crates.io-index)", 1105 | "remove_dir_all 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", 1106 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 1107 | ] 1108 | 1109 | [[package]] 1110 | name = "thread_local" 1111 | version = "0.3.6" 1112 | source = "registry+https://github.com/rust-lang/crates.io-index" 1113 | dependencies = [ 1114 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 1115 | ] 1116 | 1117 | [[package]] 1118 | name = "time" 1119 | version = "0.1.42" 1120 | source = "registry+https://github.com/rust-lang/crates.io-index" 1121 | dependencies = [ 1122 | "libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)", 1123 | "redox_syscall 0.1.56 (registry+https://github.com/rust-lang/crates.io-index)", 1124 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 1125 | ] 1126 | 1127 | [[package]] 1128 | name = "tokio" 1129 | version = "0.1.22" 1130 | source = "registry+https://github.com/rust-lang/crates.io-index" 1131 | dependencies = [ 1132 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 1133 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1134 | "mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)", 1135 | "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", 1136 | "tokio-current-thread 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", 1137 | "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1138 | "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 1139 | "tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", 1140 | "tokio-tcp 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", 1141 | "tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", 1142 | "tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", 1143 | ] 1144 | 1145 | [[package]] 1146 | name = "tokio-buf" 1147 | version = "0.1.1" 1148 | source = "registry+https://github.com/rust-lang/crates.io-index" 1149 | dependencies = [ 1150 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 1151 | "either 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)", 1152 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1153 | ] 1154 | 1155 | [[package]] 1156 | name = "tokio-current-thread" 1157 | version = "0.1.6" 1158 | source = "registry+https://github.com/rust-lang/crates.io-index" 1159 | dependencies = [ 1160 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1161 | "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1162 | ] 1163 | 1164 | [[package]] 1165 | name = "tokio-executor" 1166 | version = "0.1.8" 1167 | source = "registry+https://github.com/rust-lang/crates.io-index" 1168 | dependencies = [ 1169 | "crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)", 1170 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1171 | ] 1172 | 1173 | [[package]] 1174 | name = "tokio-io" 1175 | version = "0.1.12" 1176 | source = "registry+https://github.com/rust-lang/crates.io-index" 1177 | dependencies = [ 1178 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 1179 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1180 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 1181 | ] 1182 | 1183 | [[package]] 1184 | name = "tokio-reactor" 1185 | version = "0.1.9" 1186 | source = "registry+https://github.com/rust-lang/crates.io-index" 1187 | dependencies = [ 1188 | "crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)", 1189 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1190 | "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 1191 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 1192 | "mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)", 1193 | "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", 1194 | "parking_lot 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)", 1195 | "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 1196 | "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1197 | "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 1198 | "tokio-sync 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", 1199 | ] 1200 | 1201 | [[package]] 1202 | name = "tokio-sync" 1203 | version = "0.1.6" 1204 | source = "registry+https://github.com/rust-lang/crates.io-index" 1205 | dependencies = [ 1206 | "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", 1207 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1208 | ] 1209 | 1210 | [[package]] 1211 | name = "tokio-tcp" 1212 | version = "0.1.3" 1213 | source = "registry+https://github.com/rust-lang/crates.io-index" 1214 | dependencies = [ 1215 | "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", 1216 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1217 | "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", 1218 | "mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)", 1219 | "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", 1220 | "tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", 1221 | ] 1222 | 1223 | [[package]] 1224 | name = "tokio-threadpool" 1225 | version = "0.1.15" 1226 | source = "registry+https://github.com/rust-lang/crates.io-index" 1227 | dependencies = [ 1228 | "crossbeam-deque 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)", 1229 | "crossbeam-queue 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", 1230 | "crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)", 1231 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1232 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 1233 | "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", 1234 | "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", 1235 | "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 1236 | "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1237 | ] 1238 | 1239 | [[package]] 1240 | name = "tokio-timer" 1241 | version = "0.2.11" 1242 | source = "registry+https://github.com/rust-lang/crates.io-index" 1243 | dependencies = [ 1244 | "crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)", 1245 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1246 | "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", 1247 | "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1248 | ] 1249 | 1250 | [[package]] 1251 | name = "try-lock" 1252 | version = "0.2.2" 1253 | source = "registry+https://github.com/rust-lang/crates.io-index" 1254 | 1255 | [[package]] 1256 | name = "try_from" 1257 | version = "0.3.2" 1258 | source = "registry+https://github.com/rust-lang/crates.io-index" 1259 | dependencies = [ 1260 | "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", 1261 | ] 1262 | 1263 | [[package]] 1264 | name = "unicase" 1265 | version = "2.5.1" 1266 | source = "registry+https://github.com/rust-lang/crates.io-index" 1267 | dependencies = [ 1268 | "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", 1269 | ] 1270 | 1271 | [[package]] 1272 | name = "unicode-bidi" 1273 | version = "0.3.4" 1274 | source = "registry+https://github.com/rust-lang/crates.io-index" 1275 | dependencies = [ 1276 | "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1277 | ] 1278 | 1279 | [[package]] 1280 | name = "unicode-normalization" 1281 | version = "0.1.8" 1282 | source = "registry+https://github.com/rust-lang/crates.io-index" 1283 | dependencies = [ 1284 | "smallvec 0.6.10 (registry+https://github.com/rust-lang/crates.io-index)", 1285 | ] 1286 | 1287 | [[package]] 1288 | name = "unicode-xid" 1289 | version = "0.1.0" 1290 | source = "registry+https://github.com/rust-lang/crates.io-index" 1291 | 1292 | [[package]] 1293 | name = "unicode-xid" 1294 | version = "0.2.0" 1295 | source = "registry+https://github.com/rust-lang/crates.io-index" 1296 | 1297 | [[package]] 1298 | name = "url" 1299 | version = "1.7.2" 1300 | source = "registry+https://github.com/rust-lang/crates.io-index" 1301 | dependencies = [ 1302 | "idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", 1303 | "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1304 | "percent-encoding 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", 1305 | ] 1306 | 1307 | [[package]] 1308 | name = "url" 1309 | version = "2.1.0" 1310 | source = "registry+https://github.com/rust-lang/crates.io-index" 1311 | dependencies = [ 1312 | "idna 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", 1313 | "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", 1314 | "percent-encoding 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)", 1315 | ] 1316 | 1317 | [[package]] 1318 | name = "uuid" 1319 | version = "0.7.4" 1320 | source = "registry+https://github.com/rust-lang/crates.io-index" 1321 | dependencies = [ 1322 | "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", 1323 | ] 1324 | 1325 | [[package]] 1326 | name = "vcpkg" 1327 | version = "0.2.7" 1328 | source = "registry+https://github.com/rust-lang/crates.io-index" 1329 | 1330 | [[package]] 1331 | name = "version_check" 1332 | version = "0.1.5" 1333 | source = "registry+https://github.com/rust-lang/crates.io-index" 1334 | 1335 | [[package]] 1336 | name = "want" 1337 | version = "0.2.0" 1338 | source = "registry+https://github.com/rust-lang/crates.io-index" 1339 | dependencies = [ 1340 | "futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)", 1341 | "log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)", 1342 | "try-lock 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", 1343 | ] 1344 | 1345 | [[package]] 1346 | name = "wasi" 1347 | version = "0.7.0" 1348 | source = "registry+https://github.com/rust-lang/crates.io-index" 1349 | 1350 | [[package]] 1351 | name = "winapi" 1352 | version = "0.2.8" 1353 | source = "registry+https://github.com/rust-lang/crates.io-index" 1354 | 1355 | [[package]] 1356 | name = "winapi" 1357 | version = "0.3.8" 1358 | source = "registry+https://github.com/rust-lang/crates.io-index" 1359 | dependencies = [ 1360 | "winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 1361 | "winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", 1362 | ] 1363 | 1364 | [[package]] 1365 | name = "winapi-build" 1366 | version = "0.1.1" 1367 | source = "registry+https://github.com/rust-lang/crates.io-index" 1368 | 1369 | [[package]] 1370 | name = "winapi-i686-pc-windows-gnu" 1371 | version = "0.4.0" 1372 | source = "registry+https://github.com/rust-lang/crates.io-index" 1373 | 1374 | [[package]] 1375 | name = "winapi-x86_64-pc-windows-gnu" 1376 | version = "0.4.0" 1377 | source = "registry+https://github.com/rust-lang/crates.io-index" 1378 | 1379 | [[package]] 1380 | name = "winreg" 1381 | version = "0.6.2" 1382 | source = "registry+https://github.com/rust-lang/crates.io-index" 1383 | dependencies = [ 1384 | "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", 1385 | ] 1386 | 1387 | [[package]] 1388 | name = "ws2_32-sys" 1389 | version = "0.2.1" 1390 | source = "registry+https://github.com/rust-lang/crates.io-index" 1391 | dependencies = [ 1392 | "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", 1393 | "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", 1394 | ] 1395 | 1396 | [metadata] 1397 | "checksum adler32 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)" = "5d2e7343e7fc9de883d1b0341e0b13970f764c14101234857d2ddafa1cb1cac2" 1398 | "checksum aho-corasick 0.7.6 (registry+https://github.com/rust-lang/crates.io-index)" = "58fb5e95d83b38284460a5fda7d6470aa0b8844d283a0b614b8535e880800d2d" 1399 | "checksum arrayvec 0.4.11 (registry+https://github.com/rust-lang/crates.io-index)" = "b8d73f9beda665eaa98ab9e4f7442bd4e7de6652587de55b2525e52e29c1b0ba" 1400 | "checksum autocfg 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "b671c8fb71b457dd4ae18c4ba1e59aa81793daacc361d82fcd410cef0d491875" 1401 | "checksum backtrace 0.3.38 (registry+https://github.com/rust-lang/crates.io-index)" = "690a62be8920ccf773ee00ef0968649b0e724cda8bd5b12286302b4ae955fdf5" 1402 | "checksum backtrace-sys 0.1.31 (registry+https://github.com/rust-lang/crates.io-index)" = "82a830b4ef2d1124a711c71d263c5abdc710ef8e907bd508c88be475cebc422b" 1403 | "checksum base64 0.10.1 (registry+https://github.com/rust-lang/crates.io-index)" = "0b25d992356d2eb0ed82172f5248873db5560c4721f564b13cb5193bda5e668e" 1404 | "checksum bitflags 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8a606a02debe2813760609f57a64a2ffd27d9fdf5b2f133eaca0b248dd92cdd2" 1405 | "checksum byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "a7c3dd8985a7111efc5c80b44e23ecdd8c007de8ade3b96595387e812b957cf5" 1406 | "checksum bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)" = "206fdffcfa2df7cbe15601ef46c813fce0965eb3286db6b56c583b814b51c81c" 1407 | "checksum c2-chacha 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7d64d04786e0f528460fc884753cf8dddcc466be308f6026f8e355c41a0e4101" 1408 | "checksum cc 1.0.45 (registry+https://github.com/rust-lang/crates.io-index)" = "4fc9a35e1f4290eb9e5fc54ba6cf40671ed2a2514c3eeb2b2a908dda2ea5a1be" 1409 | "checksum cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)" = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822" 1410 | "checksum cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "ddfc5b9aa5d4507acaf872de71051dfd0e309860e88966e1051e462a077aac4f" 1411 | "checksum cookie 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)" = "888604f00b3db336d2af898ec3c1d5d0ddf5e6d462220f2ededc33a87ac4bbd5" 1412 | "checksum cookie_store 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "46750b3f362965f197996c4448e4a0935e791bf7d6631bfce9ee0af3d24c919c" 1413 | "checksum core-foundation 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)" = "25b9e03f145fd4f2bf705e07b900cd41fc636598fe5dc452fd0db1441c3f496d" 1414 | "checksum core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e7ca8a5221364ef15ce201e8ed2f609fc312682a8f4e0e3d4aa5879764e0fa3b" 1415 | "checksum crc32fast 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ba125de2af0df55319f41944744ad91c71113bf74a4646efff39afe1f6842db1" 1416 | "checksum crossbeam-deque 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b18cd2e169ad86297e6bc0ad9aa679aee9daa4f19e8163860faf7c164e4f5a71" 1417 | "checksum crossbeam-epoch 0.7.2 (registry+https://github.com/rust-lang/crates.io-index)" = "fedcd6772e37f3da2a9af9bf12ebe046c0dfe657992377b4df982a2b54cd37a9" 1418 | "checksum crossbeam-queue 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7c979cd6cfe72335896575c6b5688da489e420d36a27a0b9eb0c73db574b4a4b" 1419 | "checksum crossbeam-utils 0.6.6 (registry+https://github.com/rust-lang/crates.io-index)" = "04973fa96e96579258a5091af6003abde64af786b860f18622b82e026cca60e6" 1420 | "checksum dtoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "ea57b42383d091c85abcc2706240b94ab2a8fa1fc81c10ff23c4de06e2a90b5e" 1421 | "checksum either 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)" = "bb1f6b1ce1c140482ea30ddd3335fc0024ac7ee112895426e0a629a6c20adfe3" 1422 | "checksum encoding_rs 0.8.20 (registry+https://github.com/rust-lang/crates.io-index)" = "87240518927716f79692c2ed85bfe6e98196d18c6401ec75355760233a7e12e9" 1423 | "checksum error-chain 0.12.1 (registry+https://github.com/rust-lang/crates.io-index)" = "3ab49e9dcb602294bc42f9a7dfc9bc6e936fca4418ea300dbfb84fe16de0b7d9" 1424 | "checksum failure 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "795bd83d3abeb9220f257e597aa0080a508b27533824adf336529648f6abf7e2" 1425 | "checksum failure_derive 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "ea1063915fd7ef4309e222a5a07cf9c319fb9c7836b1f89b85458672dbb127e1" 1426 | "checksum flate2 1.0.11 (registry+https://github.com/rust-lang/crates.io-index)" = "2adaffba6388640136149e18ed080b77a78611c1e1d6de75aedcdf78df5d4682" 1427 | "checksum fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "2fad85553e09a6f881f739c29f0b00b0f01357c743266d478b68951ce23285f3" 1428 | "checksum foreign-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" 1429 | "checksum foreign-types-shared 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" 1430 | "checksum fuchsia-cprng 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a06f77d526c1a601b7c4cdd98f54b5eaabffc14d5f2f0296febdc7f357c6d3ba" 1431 | "checksum fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2e9763c69ebaae630ba35f74888db465e49e259ba1bc0eda7d06f4a067615d82" 1432 | "checksum fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7" 1433 | "checksum futures 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)" = "1b980f2816d6ee8673b6517b52cb0e808a180efc92e5c19d02cdda79066703ef" 1434 | "checksum futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "ab90cde24b3319636588d0c35fe03b1333857621051837ed769faefb4c2162e4" 1435 | "checksum getrandom 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)" = "473a1265acc8ff1e808cd0a1af8cee3c2ee5200916058a2ca113c29f2d903571" 1436 | "checksum h2 0.1.26 (registry+https://github.com/rust-lang/crates.io-index)" = "a5b34c246847f938a410a03c5458c7fee2274436675e76d8b903c08efc29c462" 1437 | "checksum http 0.1.18 (registry+https://github.com/rust-lang/crates.io-index)" = "372bcb56f939e449117fb0869c2e8fd8753a8223d92a172c6e808cf123a5b6e4" 1438 | "checksum http-body 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "6741c859c1b2463a423a1dbce98d418e6c3c3fc720fb0d45528657320920292d" 1439 | "checksum httparse 1.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "cd179ae861f0c2e53da70d892f5f3029f9594be0c41dc5269cd371691b1dc2f9" 1440 | "checksum hyper 0.12.35 (registry+https://github.com/rust-lang/crates.io-index)" = "9dbe6ed1438e1f8ad955a4701e9a944938e9519f6888d12d8558b645e247d5f6" 1441 | "checksum hyper-tls 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "3a800d6aa50af4b5850b2b0f659625ce9504df908e9733b635720483be26174f" 1442 | "checksum idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "38f09e0f0b1fb55fdee1f17470ad800da77af5186a1a76c026b679358b7e844e" 1443 | "checksum idna 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "02e2673c30ee86b5b96a9cb52ad15718aa1f966f5ab9ad54a8b95d5ca33120a9" 1444 | "checksum indexmap 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a61202fbe46c4a951e9404a720a0180bcf3212c750d735cb5c4ba4dc551299f3" 1445 | "checksum iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dbe6e417e7d0975db6512b90796e8ce223145ac4e33c377e4a42882a0e88bb08" 1446 | "checksum itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "501266b7edd0174f8530248f87f99c88fbe60ca4ef3dd486835b8d8d53136f7f" 1447 | "checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d" 1448 | "checksum lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" 1449 | "checksum libc 0.2.62 (registry+https://github.com/rust-lang/crates.io-index)" = "34fcd2c08d2f832f376f4173a231990fa5aef4e99fb569867318a227ef4c06ba" 1450 | "checksum libloading 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "f2b111a074963af1d37a139918ac6d49ad1d0d5e47f72fd55388619691a7d753" 1451 | "checksum lock_api 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "62ebf1391f6acad60e5c8b43706dde4582df75c06698ab44511d15016bc2442c" 1452 | "checksum log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)" = "14b6052be84e6b71ab17edffc2eeabf5c2c3ae1fdb464aae35ac50c67a44e1f7" 1453 | "checksum matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "7ffc5c5338469d4d3ea17d269fa8ea3512ad247247c30bd2df69e68309ed0a08" 1454 | "checksum memchr 2.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "88579771288728879b57485cc7d6b07d648c9f0141eb955f8ab7f9d45394468e" 1455 | "checksum memoffset 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ce6075db033bbbb7ee5a0bbd3a3186bbae616f57fb001c485c7ff77955f8177f" 1456 | "checksum mime 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)" = "dd1d63acd1b78403cc0c325605908475dd9b9a3acbf65ed8bcab97e27014afcf" 1457 | "checksum mime_guess 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "1a0ed03949aef72dbdf3116a383d7b38b4768e6f960528cd6a6044aa9ed68599" 1458 | "checksum miniz_oxide 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7108aff85b876d06f22503dcce091e29f76733b2bfdd91eebce81f5e68203a10" 1459 | "checksum mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)" = "83f51996a3ed004ef184e16818edc51fadffe8e7ca68be67f9dee67d84d0ff23" 1460 | "checksum miow 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "8c1f2f3b1cf331de6896aabf6e9d55dca90356cc9960cca7eaaf408a355ae919" 1461 | "checksum native-tls 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "4b2df1a4c22fd44a62147fd8f13dd0f95c9d8ca7b2610299b2a2f9cf8964274e" 1462 | "checksum net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)" = "42550d9fb7b6684a6d404d9fa7250c2eb2646df731d1c06afc06dcee9e1bcf88" 1463 | "checksum nodrop 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)" = "2f9667ddcc6cc8a43afc9b7917599d7216aa09c463919ea32c59ed6cac8bc945" 1464 | "checksum num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)" = "bcef43580c035376c0705c42792c294b66974abbfd2789b511784023f71f3273" 1465 | "checksum openssl 0.10.24 (registry+https://github.com/rust-lang/crates.io-index)" = "8152bb5a9b5b721538462336e3bef9a539f892715e5037fda0f984577311af15" 1466 | "checksum openssl-probe 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "77af24da69f9d9341038eba93a073b1fdaaa1b788221b00a69bce9e762cb32de" 1467 | "checksum openssl-sys 0.9.49 (registry+https://github.com/rust-lang/crates.io-index)" = "f4fad9e54bd23bd4cbbe48fdc08a1b8091707ac869ef8508edea2fec77dcc884" 1468 | "checksum owning_ref 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "49a4b8ea2179e6a2e27411d3bca09ca6dd630821cf6894c6c7c8467a8ee7ef13" 1469 | "checksum parking_lot 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ab41b4aed082705d1056416ae4468b6ea99d52599ecf3169b00088d43113e337" 1470 | "checksum parking_lot_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "94c8c7923936b28d546dfd14d4472eaf34c99b14e1c973a32b3e6d4eb04298c9" 1471 | "checksum percent-encoding 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "31010dd2e1ac33d5b46a5b413495239882813e0369f8ed8a5e266f173602f831" 1472 | "checksum percent-encoding 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d4fd5641d01c8f18a23da7b6fe29298ff4b55afcccdf78973b24cf3175fee32e" 1473 | "checksum pkg-config 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)" = "72d5370d90f49f70bd033c3d75e87fc529fbfff9d6f7cccef07d6170079d91ea" 1474 | "checksum ppv-lite86 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)" = "e3cbf9f658cdb5000fcf6f362b8ea2ba154b9f146a61c7a20d647034c6b6561b" 1475 | "checksum proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)" = "cf3d2011ab5c909338f7887f4fc896d35932e29146c12c8d01da6b22a80ba759" 1476 | "checksum proc-macro2 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)" = "afdc77cc74ec70ed262262942ebb7dac3d479e9e5cfa2da1841c0806f6cdabcc" 1477 | "checksum publicsuffix 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)" = "9bf259a81de2b2eb9850ec990ec78e6a25319715584fd7652b9b26f96fcb1510" 1478 | "checksum quote 0.6.13 (registry+https://github.com/rust-lang/crates.io-index)" = "6ce23b6b870e8f94f81fb0a363d65d86675884b34a09043c81e5562f11c1f8e1" 1479 | "checksum quote 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "053a8c8bcc71fcce321828dc897a98ab9760bef03a4fc36693c231e5b3216cfe" 1480 | "checksum rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)" = "6d71dacdc3c88c1fde3885a3be3fbab9f35724e6ce99467f7d9c5026132184ca" 1481 | "checksum rand 0.7.2 (registry+https://github.com/rust-lang/crates.io-index)" = "3ae1b169243eaf61759b8475a998f0a385e42042370f3a7dbaf35246eacc8412" 1482 | "checksum rand_chacha 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "556d3a1ca6600bfcbab7c7c91ccb085ac7fbbcd70e008a98742e7847f4f7bcef" 1483 | "checksum rand_chacha 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "03a2a90da8c7523f554344f921aa97283eadf6ac484a6d2a7d0212fa7f8d6853" 1484 | "checksum rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6fdeb83b075e8266dcc8762c22776f6877a63111121f5f8c7411e5be7eed4b" 1485 | "checksum rand_core 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "9c33a3c44ca05fa6f1807d8e6743f3824e8509beca625669633be0acbdf509dc" 1486 | "checksum rand_core 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" 1487 | "checksum rand_hc 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7b40677c7be09ae76218dc623efbf7b18e34bced3f38883af07bb75630a21bc4" 1488 | "checksum rand_hc 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" 1489 | "checksum rand_isaac 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ded997c9d5f13925be2a6fd7e66bf1872597f759fd9dd93513dd7e92e5a5ee08" 1490 | "checksum rand_jitter 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "1166d5c91dc97b88d1decc3285bb0a99ed84b05cfd0bc2341bdf2d43fc41e39b" 1491 | "checksum rand_os 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "7b75f676a1e053fc562eafbb47838d67c84801e38fc1ba459e8f180deabd5071" 1492 | "checksum rand_pcg 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "abf9b09b01790cfe0364f52bf32995ea3c39f4d2dd011eac241d2914146d0b44" 1493 | "checksum rand_xorshift 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "cbf7e9e623549b0e21f6e97cf8ecf247c1a8fd2e8a992ae265314300b2455d5c" 1494 | "checksum rdrand 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "678054eb77286b51581ba43620cc911abf02758c91f93f479767aed0f90458b2" 1495 | "checksum redox_syscall 0.1.56 (registry+https://github.com/rust-lang/crates.io-index)" = "2439c63f3f6139d1b57529d16bc3b8bb855230c8efcc5d3a896c8bea7c3b1e84" 1496 | "checksum regex 1.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "dc220bd33bdce8f093101afe22a037b8eb0e5af33592e6a9caafff0d4cb81cbd" 1497 | "checksum regex-syntax 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)" = "11a7e20d1cce64ef2fed88b66d347f88bd9babb82845b2b858f3edbf59a4f716" 1498 | "checksum remove_dir_all 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "4a83fa3702a688b9359eccba92d153ac33fd2e8462f9e0e3fdf155239ea7792e" 1499 | "checksum reqwest 0.9.20 (registry+https://github.com/rust-lang/crates.io-index)" = "0f6d896143a583047512e59ac54a215cb203c29cc941917343edea3be8df9c78" 1500 | "checksum rustc-demangle 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)" = "4c691c0e608126e00913e33f0ccf3727d5fc84573623b8d65b2df340b5201783" 1501 | "checksum rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "138e3e0acb6c9fb258b19b67cb8abd63c00679d2851805ea151465464fe9030a" 1502 | "checksum ryu 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c92464b447c0ee8c4fb3824ecc8383b81717b9f1e74ba2e72540aef7b9f82997" 1503 | "checksum schannel 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)" = "87f550b06b6cba9c8b8be3ee73f391990116bf527450d2556e9b9ce263b9a021" 1504 | "checksum scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "94258f53601af11e6a49f722422f6e3425c52b06245a5cf9bc09908b174f5e27" 1505 | "checksum scopeguard 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b42e15e59b18a828bbf5c58ea01debb36b9b096346de35d941dcb89009f24a0d" 1506 | "checksum security-framework 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "eee63d0f4a9ec776eeb30e220f0bc1e092c3ad744b2a379e3993070364d3adc2" 1507 | "checksum security-framework-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9636f8989cbf61385ae4824b98c1aaa54c994d7d8b41f11c601ed799f0549a56" 1508 | "checksum semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1d7eb9ef2c18661902cc47e535f9bc51b78acd254da71d375c2f6720d9a40403" 1509 | "checksum semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" 1510 | "checksum serde 1.0.101 (registry+https://github.com/rust-lang/crates.io-index)" = "9796c9b7ba2ffe7a9ce53c2287dfc48080f4b2b362fcc245a259b3a7201119dd" 1511 | "checksum serde_derive 1.0.101 (registry+https://github.com/rust-lang/crates.io-index)" = "4b133a43a1ecd55d4086bd5b4dc6c1751c68b1bfbeba7a5040442022c7e7c02e" 1512 | "checksum serde_json 1.0.40 (registry+https://github.com/rust-lang/crates.io-index)" = "051c49229f282f7c6f3813f8286cc1e3323e8051823fce42c7ea80fe13521704" 1513 | "checksum serde_urlencoded 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)" = "642dd69105886af2efd227f75a520ec9b44a820d65bc133a9131f7d229fd165a" 1514 | "checksum slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "c111b5bd5695e56cffe5129854aa230b39c93a305372fdbb2668ca2394eea9f8" 1515 | "checksum smallvec 0.6.10 (registry+https://github.com/rust-lang/crates.io-index)" = "ab606a9c5e214920bb66c458cd7be8ef094f813f20fe77a54cc7dbfff220d4b7" 1516 | "checksum stable_deref_trait 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "dba1a27d3efae4351c8051072d619e3ade2820635c3958d826bfea39d59b54c8" 1517 | "checksum string 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d24114bfcceb867ca7f71a0d3fe45d45619ec47a6fbfa98cb14e14250bfa5d6d" 1518 | "checksum syn 0.15.44 (registry+https://github.com/rust-lang/crates.io-index)" = "9ca4b3b69a77cbe1ffc9e198781b7acb0c7365a883670e8f1c1bc66fba79a5c5" 1519 | "checksum syn 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)" = "66850e97125af79138385e9b88339cbcd037e3f28ceab8c5ad98e64f0f1f80bf" 1520 | "checksum synstructure 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)" = "02353edf96d6e4dc81aea2d8490a7e9db177bf8acb0e951c24940bf866cb313f" 1521 | "checksum tempfile 3.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6e24d9338a0a5be79593e2fa15a648add6138caa803e2d5bc782c371732ca9" 1522 | "checksum thread_local 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "c6b53e329000edc2b34dbe8545fd20e55a333362d0a321909685a19bd28c3f1b" 1523 | "checksum time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)" = "db8dcfca086c1143c9270ac42a2bbd8a7ee477b78ac8e45b19abfb0cbede4b6f" 1524 | "checksum tokio 0.1.22 (registry+https://github.com/rust-lang/crates.io-index)" = "5a09c0b5bb588872ab2f09afa13ee6e9dac11e10a0ec9e8e3ba39a5a5d530af6" 1525 | "checksum tokio-buf 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "8fb220f46c53859a4b7ec083e41dec9778ff0b1851c0942b211edb89e0ccdc46" 1526 | "checksum tokio-current-thread 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "d16217cad7f1b840c5a97dfb3c43b0c871fef423a6e8d2118c604e843662a443" 1527 | "checksum tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "0f27ee0e6db01c5f0b2973824547ce7e637b2ed79b891a9677b0de9bd532b6ac" 1528 | "checksum tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)" = "5090db468dad16e1a7a54c8c67280c5e4b544f3d3e018f0b913b400261f85926" 1529 | "checksum tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)" = "6af16bfac7e112bea8b0442542161bfc41cbfa4466b580bdda7d18cb88b911ce" 1530 | "checksum tokio-sync 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "2162248ff317e2bc713b261f242b69dbb838b85248ed20bb21df56d60ea4cae7" 1531 | "checksum tokio-tcp 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "1d14b10654be682ac43efee27401d792507e30fd8d26389e1da3b185de2e4119" 1532 | "checksum tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)" = "90ca01319dea1e376a001e8dc192d42ebde6dd532532a5bad988ac37db365b19" 1533 | "checksum tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "f2106812d500ed25a4f38235b9cae8f78a09edf43203e16e59c3b769a342a60e" 1534 | "checksum try-lock 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e604eb7b43c06650e854be16a2a03155743d3752dd1c943f6829e26b7a36e382" 1535 | "checksum try_from 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "283d3b89e1368717881a9d51dad843cc435380d8109c9e47d38780a324698d8b" 1536 | "checksum unicase 2.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2e2e6bd1e59e56598518beb94fd6db628ded570326f0a98c679a304bd9f00150" 1537 | "checksum unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "49f2bd0c6468a8230e1db229cff8029217cf623c767ea5d60bfbd42729ea54d5" 1538 | "checksum unicode-normalization 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "141339a08b982d942be2ca06ff8b076563cbe223d1befd5450716790d44e2426" 1539 | "checksum unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc" 1540 | "checksum unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "826e7639553986605ec5979c7dd957c7895e93eabed50ab2ffa7f6128a75097c" 1541 | "checksum url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dd4e7c0d531266369519a4aa4f399d748bd37043b00bde1e4ff1f60a120b355a" 1542 | "checksum url 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "75b414f6c464c879d7f9babf951f23bc3743fb7313c081b2e6ca719067ea9d61" 1543 | "checksum uuid 0.7.4 (registry+https://github.com/rust-lang/crates.io-index)" = "90dbc611eb48397705a6b0f6e917da23ae517e4d127123d2cf7674206627d32a" 1544 | "checksum vcpkg 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)" = "33dd455d0f96e90a75803cfeb7f948768c08d70a6de9a8d2362461935698bf95" 1545 | "checksum version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "914b1a6776c4c929a602fafd8bc742e06365d4bcbe48c30f9cca5824f70dc9dd" 1546 | "checksum want 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b6395efa4784b027708f7451087e647ec73cc74f5d9bc2e418404248d679a230" 1547 | "checksum wasi 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b89c3ce4ce14bdc6fb6beaf9ec7928ca331de5df7e5ea278375642a2f478570d" 1548 | "checksum winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a" 1549 | "checksum winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)" = "8093091eeb260906a183e6ae1abdba2ef5ef2257a21801128899c3fc699229c6" 1550 | "checksum winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc" 1551 | "checksum winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" 1552 | "checksum winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" 1553 | "checksum winreg 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)" = "b2986deb581c4fe11b621998a5e53361efe6b48a151178d0cd9eeffa4dc6acc9" 1554 | "checksum ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d59cefebd0c892fa2dd6de581e937301d8552cb44489cdff035c6187cb63fa5e" 1555 | -------------------------------------------------------------------------------- /Cargo.toml: -------------------------------------------------------------------------------- 1 | [workspace] 2 | members = ["core", "random", "app"] 3 | -------------------------------------------------------------------------------- /LICENSE-APACHE: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 6 | 7 | 1. Definitions. 8 | 9 | "License" shall mean the terms and conditions for use, reproduction, 10 | and distribution as defined by Sections 1 through 9 of this document. 11 | 12 | "Licensor" shall mean the copyright owner or entity authorized by 13 | the copyright owner that is granting the License. 14 | 15 | "Legal Entity" shall mean the union of the acting entity and all 16 | other entities that control, are controlled by, or are under common 17 | control with that entity. For the purposes of this definition, 18 | "control" means (i) the power, direct or indirect, to cause the 19 | direction or management of such entity, whether by contract or 20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 21 | outstanding shares, or (iii) beneficial ownership of such entity. 22 | 23 | "You" (or "Your") shall mean an individual or Legal Entity 24 | exercising permissions granted by this License. 25 | 26 | "Source" form shall mean the preferred form for making modifications, 27 | including but not limited to software source code, documentation 28 | source, and configuration files. 29 | 30 | "Object" form shall mean any form resulting from mechanical 31 | transformation or translation of a Source form, including but 32 | not limited to compiled object code, generated documentation, 33 | and conversions to other media types. 34 | 35 | "Work" shall mean the work of authorship, whether in Source or 36 | Object form, made available under the License, as indicated by a 37 | copyright notice that is included in or attached to the work 38 | (an example is provided in the Appendix below). 39 | 40 | "Derivative Works" shall mean any work, whether in Source or Object 41 | form, that is based on (or derived from) the Work and for which the 42 | editorial revisions, annotations, elaborations, or other modifications 43 | represent, as a whole, an original work of authorship. For the purposes 44 | of this License, Derivative Works shall not include works that remain 45 | separable from, or merely link (or bind by name) to the interfaces of, 46 | the Work and Derivative Works thereof. 47 | 48 | "Contribution" shall mean any work of authorship, including 49 | the original version of the Work and any modifications or additions 50 | to that Work or Derivative Works thereof, that is intentionally 51 | submitted to Licensor for inclusion in the Work by the copyright owner 52 | or by an individual or Legal Entity authorized to submit on behalf of 53 | the copyright owner. For the purposes of this definition, "submitted" 54 | means any form of electronic, verbal, or written communication sent 55 | to the Licensor or its representatives, including but not limited to 56 | communication on electronic mailing lists, source code control systems, 57 | and issue tracking systems that are managed by, or on behalf of, the 58 | Licensor for the purpose of discussing and improving the Work, but 59 | excluding communication that is conspicuously marked or otherwise 60 | designated in writing by the copyright owner as "Not a Contribution." 61 | 62 | "Contributor" shall mean Licensor and any individual or Legal Entity 63 | on behalf of whom a Contribution has been received by Licensor and 64 | subsequently incorporated within the Work. 65 | 66 | 2. Grant of Copyright License. Subject to the terms and conditions of 67 | this License, each Contributor hereby grants to You a perpetual, 68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 69 | copyright license to reproduce, prepare Derivative Works of, 70 | publicly display, publicly perform, sublicense, and distribute the 71 | Work and such Derivative Works in Source or Object form. 72 | 73 | 3. Grant of Patent License. Subject to the terms and conditions of 74 | this License, each Contributor hereby grants to You a perpetual, 75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 76 | (except as stated in this section) patent license to make, have made, 77 | use, offer to sell, sell, import, and otherwise transfer the Work, 78 | where such license applies only to those patent claims licensable 79 | by such Contributor that are necessarily infringed by their 80 | Contribution(s) alone or by combination of their Contribution(s) 81 | with the Work to which such Contribution(s) was submitted. If You 82 | institute patent litigation against any entity (including a 83 | cross-claim or counterclaim in a lawsuit) alleging that the Work 84 | or a Contribution incorporated within the Work constitutes direct 85 | or contributory patent infringement, then any patent licenses 86 | granted to You under this License for that Work shall terminate 87 | as of the date such litigation is filed. 88 | 89 | 4. Redistribution. You may reproduce and distribute copies of the 90 | Work or Derivative Works thereof in any medium, with or without 91 | modifications, and in Source or Object form, provided that You 92 | meet the following conditions: 93 | 94 | (a) You must give any other recipients of the Work or 95 | Derivative Works a copy of this License; and 96 | 97 | (b) You must cause any modified files to carry prominent notices 98 | stating that You changed the files; and 99 | 100 | (c) You must retain, in the Source form of any Derivative Works 101 | that You distribute, all copyright, patent, trademark, and 102 | attribution notices from the Source form of the Work, 103 | excluding those notices that do not pertain to any part of 104 | the Derivative Works; and 105 | 106 | (d) If the Work includes a "NOTICE" text file as part of its 107 | distribution, then any Derivative Works that You distribute must 108 | include a readable copy of the attribution notices contained 109 | within such NOTICE file, excluding those notices that do not 110 | pertain to any part of the Derivative Works, in at least one 111 | of the following places: within a NOTICE text file distributed 112 | as part of the Derivative Works; within the Source form or 113 | documentation, if provided along with the Derivative Works; or, 114 | within a display generated by the Derivative Works, if and 115 | wherever such third-party notices normally appear. The contents 116 | of the NOTICE file are for informational purposes only and 117 | do not modify the License. You may add Your own attribution 118 | notices within Derivative Works that You distribute, alongside 119 | or as an addendum to the NOTICE text from the Work, provided 120 | that such additional attribution notices cannot be construed 121 | as modifying the License. 122 | 123 | You may add Your own copyright statement to Your modifications and 124 | may provide additional or different license terms and conditions 125 | for use, reproduction, or distribution of Your modifications, or 126 | for any such Derivative Works as a whole, provided Your use, 127 | reproduction, and distribution of the Work otherwise complies with 128 | the conditions stated in this License. 129 | 130 | 5. Submission of Contributions. Unless You explicitly state otherwise, 131 | any Contribution intentionally submitted for inclusion in the Work 132 | by You to the Licensor shall be under the terms and conditions of 133 | this License, without any additional terms or conditions. 134 | Notwithstanding the above, nothing herein shall supersede or modify 135 | the terms of any separate license agreement you may have executed 136 | with Licensor regarding such Contributions. 137 | 138 | 6. Trademarks. This License does not grant permission to use the trade 139 | names, trademarks, service marks, or product names of the Licensor, 140 | except as required for reasonable and customary use in describing the 141 | origin of the Work and reproducing the content of the NOTICE file. 142 | 143 | 7. Disclaimer of Warranty. Unless required by applicable law or 144 | agreed to in writing, Licensor provides the Work (and each 145 | Contributor provides its Contributions) on an "AS IS" BASIS, 146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 147 | implied, including, without limitation, any warranties or conditions 148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 149 | PARTICULAR PURPOSE. You are solely responsible for determining the 150 | appropriateness of using or redistributing the Work and assume any 151 | risks associated with Your exercise of permissions under this License. 152 | 153 | 8. Limitation of Liability. In no event and under no legal theory, 154 | whether in tort (including negligence), contract, or otherwise, 155 | unless required by applicable law (such as deliberate and grossly 156 | negligent acts) or agreed to in writing, shall any Contributor be 157 | liable to You for damages, including any direct, indirect, special, 158 | incidental, or consequential damages of any character arising as a 159 | result of this License or out of the use or inability to use the 160 | Work (including but not limited to damages for loss of goodwill, 161 | work stoppage, computer failure or malfunction, or any and all 162 | other commercial damages or losses), even if such Contributor 163 | has been advised of the possibility of such damages. 164 | 165 | 9. Accepting Warranty or Additional Liability. While redistributing 166 | the Work or Derivative Works thereof, You may choose to offer, 167 | and charge a fee for, acceptance of support, warranty, indemnity, 168 | or other liability obligations and/or rights consistent with this 169 | License. However, in accepting such obligations, You may act only 170 | on Your own behalf and on Your sole responsibility, not on behalf 171 | of any other Contributor, and only if You agree to indemnify, 172 | defend, and hold each Contributor harmless for any liability 173 | incurred by, or claims asserted against, such Contributor by reason 174 | of your accepting any such warranty or additional liability. 175 | 176 | END OF TERMS AND CONDITIONS 177 | 178 | APPENDIX: How to apply the Apache License to your work. 179 | 180 | To apply the Apache License to your work, attach the following 181 | boilerplate notice, with the fields enclosed by brackets "{}" 182 | replaced with your own identifying information. (Don't include 183 | the brackets!) The text should be enclosed in the appropriate 184 | comment syntax for the file format. We also recommend that a 185 | file or class name and description of purpose be included on the 186 | same "printed page" as the copyright notice for easier 187 | identification within third-party archives. 188 | 189 | Copyright {yyyy} {name of copyright owner} 190 | 191 | Licensed under the Apache License, Version 2.0 (the "License"); 192 | you may not use this file except in compliance with the License. 193 | You may obtain a copy of the License at 194 | 195 | http://www.apache.org/licenses/LICENSE-2.0 196 | 197 | Unless required by applicable law or agreed to in writing, software 198 | distributed under the License is distributed on an "AS IS" BASIS, 199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 200 | See the License for the specific language governing permissions and 201 | limitations under the License. 202 | 203 | -------------------------------------------------------------------------------- /LICENSE-MIT: -------------------------------------------------------------------------------- 1 | Copyright (c) 2019 Michael-F-Bryan 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in all 11 | copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 19 | SOFTWARE. 20 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Plugins in Rust 2 | 3 | The code to accompany my [*Plugins in Rust*][pir] blog post. 4 | 5 | This project explores ways of implementing a plugin architecture in Rust by 6 | dynamically loading a library into memory at runtime. 7 | 8 | ## License 9 | 10 | Licensed under either of 11 | 12 | * Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or 13 | http://www.apache.org/licenses/LICENSE-2.0) 14 | * MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT) 15 | 16 | at your option. 17 | 18 | ## Contribution 19 | 20 | Unless you explicitly state otherwise, any contribution intentionally 21 | submitted for inclusion in the work by you, as defined in the Apache-2.0 22 | license, shall be dual licensed as above, without any additional terms or 23 | conditions. 24 | 25 | [pir]: http://adventures.michaelfbryan.com/posts/plugins-in-rust/ -------------------------------------------------------------------------------- /app/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "plugins_app" 3 | version = "0.1.0" 4 | authors = ["Michael Bryan "] 5 | edition = "2018" 6 | 7 | # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html 8 | 9 | [dependencies] 10 | libloading = "0.5.2" 11 | plugins_core = { path = "../core" } 12 | -------------------------------------------------------------------------------- /app/src/main.rs: -------------------------------------------------------------------------------- 1 | use libloading::Library; 2 | use plugins_core::{Function, InvocationError, PluginDeclaration}; 3 | use std::{ 4 | alloc::System, collections::HashMap, env, ffi::OsStr, io, path::PathBuf, 5 | rc::Rc, 6 | }; 7 | 8 | #[global_allocator] 9 | static ALLOCATOR: System = System; 10 | 11 | fn main() { 12 | // parse arguments 13 | let args = env::args().skip(1); 14 | let args = Args::parse(args) 15 | .expect("Usage: app ..."); 16 | 17 | // create our functions table and load the plugin 18 | let mut functions = ExternalFunctions::new(); 19 | 20 | unsafe { 21 | functions 22 | .load(&args.plugin_library) 23 | .expect("Function loading failed"); 24 | } 25 | 26 | // then call the function 27 | let result = functions 28 | .call(&args.function, &args.arguments) 29 | .expect("Invocation failed"); 30 | 31 | // print out the result 32 | println!( 33 | "{}({}) = {}", 34 | args.function, 35 | args.arguments 36 | .iter() 37 | .map(ToString::to_string) 38 | .collect::>() 39 | .join(", "), 40 | result 41 | ); 42 | } 43 | 44 | struct Args { 45 | plugin_library: PathBuf, 46 | function: String, 47 | arguments: Vec, 48 | } 49 | 50 | impl Args { 51 | fn parse(mut args: impl Iterator) -> Option { 52 | let plugin_library = PathBuf::from(args.next()?); 53 | let function = args.next()?; 54 | let mut arguments = Vec::new(); 55 | 56 | for arg in args { 57 | arguments.push(arg.parse().ok()?); 58 | } 59 | 60 | Some(Args { 61 | plugin_library, 62 | function, 63 | arguments, 64 | }) 65 | } 66 | } 67 | 68 | /// A map of all externally provided functions. 69 | #[derive(Default)] 70 | pub struct ExternalFunctions { 71 | functions: HashMap, 72 | libraries: Vec>, 73 | } 74 | 75 | impl ExternalFunctions { 76 | pub fn new() -> ExternalFunctions { ExternalFunctions::default() } 77 | 78 | pub fn call( 79 | &self, 80 | function: &str, 81 | arguments: &[f64], 82 | ) -> Result { 83 | self.functions 84 | .get(function) 85 | .ok_or_else(|| format!("\"{}\" not found", function))? 86 | .call(arguments) 87 | } 88 | 89 | /// Load a plugin library and add all contained functions to the internal 90 | /// function table. 91 | /// 92 | /// # Safety 93 | /// 94 | /// A plugin library **must** be implemented using the 95 | /// [`plugins_core::plugin_declaration!()`] macro. Trying manually implement 96 | /// a plugin without going through that macro will result in undefined 97 | /// behaviour. 98 | pub unsafe fn load>( 99 | &mut self, 100 | library_path: P, 101 | ) -> io::Result<()> { 102 | // load the library into memory 103 | let library = Rc::new(Library::new(library_path)?); 104 | 105 | // get a pointer to the plugin_declaration symbol. 106 | let decl = library 107 | .get::<*mut PluginDeclaration>(b"plugin_declaration\0")? 108 | .read(); 109 | 110 | // version checks to prevent accidental ABI incompatibilities 111 | if decl.rustc_version != plugins_core::RUSTC_VERSION 112 | || decl.core_version != plugins_core::CORE_VERSION 113 | { 114 | return Err(io::Error::new( 115 | io::ErrorKind::Other, 116 | "Version mismatch", 117 | )); 118 | } 119 | 120 | let mut registrar = PluginRegistrar::new(Rc::clone(&library)); 121 | 122 | (decl.register)(&mut registrar); 123 | 124 | // add all loaded plugins to the functions map 125 | self.functions.extend(registrar.functions); 126 | // and make sure ExternalFunctions keeps a reference to the library 127 | self.libraries.push(library); 128 | 129 | Ok(()) 130 | } 131 | } 132 | 133 | struct PluginRegistrar { 134 | functions: HashMap, 135 | lib: Rc, 136 | } 137 | 138 | impl PluginRegistrar { 139 | fn new(lib: Rc) -> PluginRegistrar { 140 | PluginRegistrar { 141 | lib, 142 | functions: HashMap::default(), 143 | } 144 | } 145 | } 146 | 147 | impl plugins_core::PluginRegistrar for PluginRegistrar { 148 | fn register_function(&mut self, name: &str, function: Box) { 149 | let proxy = FunctionProxy { 150 | function, 151 | _lib: Rc::clone(&self.lib), 152 | }; 153 | self.functions.insert(name.to_string(), proxy); 154 | } 155 | } 156 | 157 | /// A proxy object which wraps a [`Function`] and makes sure it can't outlive 158 | /// the library it came from. 159 | pub struct FunctionProxy { 160 | function: Box, 161 | _lib: Rc, 162 | } 163 | 164 | impl Function for FunctionProxy { 165 | fn call(&self, args: &[f64]) -> Result { 166 | self.function.call(args) 167 | } 168 | 169 | fn help(&self) -> Option<&str> { self.function.help() } 170 | } 171 | -------------------------------------------------------------------------------- /core/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "plugins_core" 3 | version = "0.1.0" 4 | authors = ["Michael Bryan "] 5 | edition = "2018" 6 | 7 | # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html 8 | 9 | [dependencies] 10 | 11 | [build-dependencies] 12 | rustc_version = "0.2.3" 13 | -------------------------------------------------------------------------------- /core/build.rs: -------------------------------------------------------------------------------- 1 | fn main() { 2 | let version = rustc_version::version().unwrap(); 3 | println!("cargo:rustc-env=RUSTC_VERSION={}", version); 4 | } 5 | -------------------------------------------------------------------------------- /core/src/lib.rs: -------------------------------------------------------------------------------- 1 | pub static CORE_VERSION: &str = env!("CARGO_PKG_VERSION"); 2 | pub static RUSTC_VERSION: &str = env!("RUSTC_VERSION"); 3 | 4 | pub trait Function { 5 | fn call(&self, args: &[f64]) -> Result; 6 | 7 | /// Help text that may be used to display information about this function. 8 | fn help(&self) -> Option<&str> { None } 9 | } 10 | 11 | #[derive(Debug, Clone, PartialEq)] 12 | pub enum InvocationError { 13 | InvalidArgumentCount { expected: usize, found: usize }, 14 | Other { msg: String }, 15 | } 16 | 17 | impl From for InvocationError { 18 | fn from(other: S) -> InvocationError { 19 | InvocationError::Other { 20 | msg: other.to_string(), 21 | } 22 | } 23 | } 24 | 25 | #[derive(Copy, Clone)] 26 | pub struct PluginDeclaration { 27 | pub rustc_version: &'static str, 28 | pub core_version: &'static str, 29 | pub register: unsafe extern "C" fn(&mut dyn PluginRegistrar), 30 | } 31 | 32 | pub trait PluginRegistrar { 33 | fn register_function(&mut self, name: &str, function: Box); 34 | } 35 | 36 | #[macro_export] 37 | macro_rules! export_plugin { 38 | ($register:expr) => { 39 | #[doc(hidden)] 40 | #[no_mangle] 41 | pub static plugin_declaration: $crate::PluginDeclaration = 42 | $crate::PluginDeclaration { 43 | rustc_version: $crate::RUSTC_VERSION, 44 | core_version: $crate::CORE_VERSION, 45 | register: $register, 46 | }; 47 | }; 48 | } 49 | -------------------------------------------------------------------------------- /random/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "plugins_random" 3 | version = "0.1.0" 4 | authors = ["Michael Bryan "] 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib"] 9 | 10 | [dependencies] 11 | plugins_core = { path = "../core" } 12 | reqwest = "0.9.20" 13 | -------------------------------------------------------------------------------- /random/src/lib.rs: -------------------------------------------------------------------------------- 1 | use plugins_core::{Function, InvocationError, PluginRegistrar}; 2 | 3 | plugins_core::export_plugin!(register); 4 | 5 | extern "C" fn register(registrar: &mut dyn PluginRegistrar) { 6 | registrar.register_function("random", Box::new(Random)); 7 | } 8 | 9 | #[derive(Debug, Clone, PartialEq)] 10 | pub struct Random; 11 | 12 | impl Function for Random { 13 | fn call(&self, args: &[f64]) -> Result { 14 | parse_args(args).and_then(fetch) 15 | } 16 | } 17 | 18 | fn parse_args(args: &[f64]) -> Result { 19 | match args.len() { 20 | 0 => Ok(RequestInfo { min: 0, max: 100 }), 21 | 1 => Ok(RequestInfo { 22 | min: 0, 23 | max: args[0].round() as i32, 24 | }), 25 | 2 => Ok(RequestInfo { 26 | min: args[0].round() as i32, 27 | max: args[1].round() as i32, 28 | }), 29 | _ => Err("0, 1, or 2 arguments are required".into()), 30 | } 31 | } 32 | 33 | fn fetch(request: RequestInfo) -> Result { 34 | let url = request.format(); 35 | let response_body = reqwest::get(&url)?.text()?; 36 | response_body.trim().parse().map_err(Into::into) 37 | } 38 | 39 | #[derive(Debug, Copy, Clone, PartialEq)] 40 | struct RequestInfo { 41 | min: i32, 42 | max: i32, 43 | } 44 | 45 | impl RequestInfo { 46 | pub fn format(self) -> String { 47 | format!( 48 | "https://www.random.org/integers/?num=1&min={}&max={}&col=1&base=10&format=plain", 49 | self.min, self.max 50 | ) 51 | } 52 | } 53 | 54 | #[cfg(test)] 55 | mod tests { 56 | use super::*; 57 | 58 | #[test] 59 | fn get_a_random_number() { 60 | let request = RequestInfo { min: 0, max: 10 }; 61 | 62 | let got = fetch(request).unwrap() as i32; 63 | 64 | assert!(request.min <= got && got <= request.max); 65 | } 66 | } 67 | --------------------------------------------------------------------------------