├── .gitignore ├── Anchor.toml ├── Cargo.lock ├── Cargo.toml ├── README.md ├── migrations └── deploy.ts ├── package.json ├── programs ├── 0-signer-authorization │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 1-account-data-matching │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 10-sysvar-address-checking │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 2-owner-checks │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 3-type-cosplay │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 4-initialization │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 5-arbitrary-cpi │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 6-duplicate-mutable-accounts │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 7-bump-seed-canonicalization │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs ├── 8-pda-sharing │ ├── insecure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ ├── recommended │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ │ └── lib.rs │ └── secure │ │ ├── Cargo.toml │ │ ├── Xargo.toml │ │ └── src │ │ └── lib.rs └── 9-closing-accounts │ ├── insecure-still-still │ ├── Cargo.toml │ ├── Xargo.toml │ └── src │ │ └── lib.rs │ ├── insecure-still │ ├── Cargo.toml │ ├── Xargo.toml │ └── src │ │ └── lib.rs │ ├── insecure │ ├── Cargo.toml │ ├── Xargo.toml │ └── src │ │ └── lib.rs │ ├── recommended │ ├── Cargo.toml │ ├── Xargo.toml │ └── src │ │ └── lib.rs │ └── secure │ ├── Cargo.toml │ ├── Xargo.toml │ └── src │ └── lib.rs ├── tests └── raw.ts ├── tsconfig.json └── yarn.lock /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | .anchor 3 | .DS_Store 4 | target 5 | **/*.rs.bk 6 | node_modules 7 | -------------------------------------------------------------------------------- /Anchor.toml: -------------------------------------------------------------------------------- 1 | [programs.localnet] 2 | raw = "Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS" 3 | 4 | [registry] 5 | url = "https://anchor.projectserum.com" 6 | 7 | [provider] 8 | cluster = "localnet" 9 | wallet = "/home/armaniferrante/.config/solana/id.json" 10 | 11 | [scripts] 12 | test = "yarn run ts-mocha -p ./tsconfig.json -t 1000000 tests/**/*.ts" 13 | -------------------------------------------------------------------------------- /Cargo.lock: -------------------------------------------------------------------------------- 1 | # This file is automatically @generated by Cargo. 2 | # It is not intended for manual editing. 3 | version = 3 4 | 5 | [[package]] 6 | name = "account-data-matching-insecure" 7 | version = "0.1.0" 8 | dependencies = [ 9 | "anchor-lang 0.20.1", 10 | "anchor-spl", 11 | "spl-token", 12 | ] 13 | 14 | [[package]] 15 | name = "account-data-matching-recommended" 16 | version = "0.1.0" 17 | dependencies = [ 18 | "anchor-lang 0.20.1", 19 | "anchor-spl", 20 | "spl-token", 21 | ] 22 | 23 | [[package]] 24 | name = "account-data-matching-secure" 25 | version = "0.1.0" 26 | dependencies = [ 27 | "anchor-lang 0.20.1", 28 | "anchor-spl", 29 | "spl-token", 30 | ] 31 | 32 | [[package]] 33 | name = "ahash" 34 | version = "0.4.7" 35 | source = "registry+https://github.com/rust-lang/crates.io-index" 36 | checksum = "739f4a8db6605981345c5654f3a85b056ce52f37a39d34da03f25bf2151ea16e" 37 | 38 | [[package]] 39 | name = "aho-corasick" 40 | version = "0.7.18" 41 | source = "registry+https://github.com/rust-lang/crates.io-index" 42 | checksum = "1e37cfd5e7657ada45f742d6e99ca5788580b5c529dc78faf11ece6dc702656f" 43 | dependencies = [ 44 | "memchr", 45 | ] 46 | 47 | [[package]] 48 | name = "anchor-attribute-access-control" 49 | version = "0.20.1" 50 | source = "registry+https://github.com/rust-lang/crates.io-index" 51 | checksum = "105c443a613f29212755fb6c5f946fa82dcf94a80528f643e0faa9d9faeb626b" 52 | dependencies = [ 53 | "anchor-syn 0.20.1", 54 | "anyhow", 55 | "proc-macro2", 56 | "quote", 57 | "regex", 58 | "syn", 59 | ] 60 | 61 | [[package]] 62 | name = "anchor-attribute-access-control" 63 | version = "0.25.0" 64 | source = "registry+https://github.com/rust-lang/crates.io-index" 65 | checksum = "70f6ee9518f50ff4d434471ccf569186022bdd5ef65a21d14da3ea5231af944f" 66 | dependencies = [ 67 | "anchor-syn 0.25.0", 68 | "anyhow", 69 | "proc-macro2", 70 | "quote", 71 | "regex", 72 | "syn", 73 | ] 74 | 75 | [[package]] 76 | name = "anchor-attribute-account" 77 | version = "0.20.1" 78 | source = "registry+https://github.com/rust-lang/crates.io-index" 79 | checksum = "fdae15851aa41972e9c18c987613c50a916c48c88c97ea3316156a5c772e5faa" 80 | dependencies = [ 81 | "anchor-syn 0.20.1", 82 | "anyhow", 83 | "bs58 0.4.0", 84 | "proc-macro2", 85 | "quote", 86 | "rustversion", 87 | "syn", 88 | ] 89 | 90 | [[package]] 91 | name = "anchor-attribute-account" 92 | version = "0.25.0" 93 | source = "registry+https://github.com/rust-lang/crates.io-index" 94 | checksum = "32c92bcf5388b52676d990f85bbfd838a8f5672393135063a50dc79b2b837c79" 95 | dependencies = [ 96 | "anchor-syn 0.25.0", 97 | "anyhow", 98 | "bs58 0.4.0", 99 | "proc-macro2", 100 | "quote", 101 | "rustversion", 102 | "syn", 103 | ] 104 | 105 | [[package]] 106 | name = "anchor-attribute-constant" 107 | version = "0.20.1" 108 | source = "registry+https://github.com/rust-lang/crates.io-index" 109 | checksum = "6356865217881d0bbea8aa70625937bec6d9952610f1ba2a2452a8e427000687" 110 | dependencies = [ 111 | "anchor-syn 0.20.1", 112 | "proc-macro2", 113 | "syn", 114 | ] 115 | 116 | [[package]] 117 | name = "anchor-attribute-constant" 118 | version = "0.25.0" 119 | source = "registry+https://github.com/rust-lang/crates.io-index" 120 | checksum = "0844974ac35e8ced62056b0d63777ebcdc5807438b8b189c881e2b647450b70a" 121 | dependencies = [ 122 | "anchor-syn 0.25.0", 123 | "proc-macro2", 124 | "syn", 125 | ] 126 | 127 | [[package]] 128 | name = "anchor-attribute-error" 129 | version = "0.20.1" 130 | source = "registry+https://github.com/rust-lang/crates.io-index" 131 | checksum = "ebe998ce4e6e0cb0e291d1a1626bd30791cdfdd9d05523111bdf4fd053f08636" 132 | dependencies = [ 133 | "anchor-syn 0.20.1", 134 | "proc-macro2", 135 | "quote", 136 | "syn", 137 | ] 138 | 139 | [[package]] 140 | name = "anchor-attribute-error" 141 | version = "0.25.0" 142 | source = "registry+https://github.com/rust-lang/crates.io-index" 143 | checksum = "0f7467345e67a6f1d4b862b9763a4160ad89d18c247b8c902807768f7b6e23df" 144 | dependencies = [ 145 | "anchor-syn 0.25.0", 146 | "proc-macro2", 147 | "quote", 148 | "syn", 149 | ] 150 | 151 | [[package]] 152 | name = "anchor-attribute-event" 153 | version = "0.20.1" 154 | source = "registry+https://github.com/rust-lang/crates.io-index" 155 | checksum = "c5810498a20554c20354f5648b6041172f2035e58d09ad40dc051dc0d1501f80" 156 | dependencies = [ 157 | "anchor-syn 0.20.1", 158 | "anyhow", 159 | "proc-macro2", 160 | "quote", 161 | "syn", 162 | ] 163 | 164 | [[package]] 165 | name = "anchor-attribute-event" 166 | version = "0.25.0" 167 | source = "registry+https://github.com/rust-lang/crates.io-index" 168 | checksum = "8774e4c1ac71f71a5aea7e4932fb69c30e3b8155c4fa59fd69401195434528a9" 169 | dependencies = [ 170 | "anchor-syn 0.25.0", 171 | "anyhow", 172 | "proc-macro2", 173 | "quote", 174 | "syn", 175 | ] 176 | 177 | [[package]] 178 | name = "anchor-attribute-interface" 179 | version = "0.20.1" 180 | source = "registry+https://github.com/rust-lang/crates.io-index" 181 | checksum = "ac83f085b2be8b3a3412989cf96cf7f683561db7d357c5aa4aa11d48bbb22213" 182 | dependencies = [ 183 | "anchor-syn 0.20.1", 184 | "anyhow", 185 | "heck", 186 | "proc-macro2", 187 | "quote", 188 | "syn", 189 | ] 190 | 191 | [[package]] 192 | name = "anchor-attribute-interface" 193 | version = "0.25.0" 194 | source = "registry+https://github.com/rust-lang/crates.io-index" 195 | checksum = "90eeb6e1c80f9f94fcef93a52813f6472186200e275e83cb3fac92b801de92f7" 196 | dependencies = [ 197 | "anchor-syn 0.25.0", 198 | "anyhow", 199 | "heck", 200 | "proc-macro2", 201 | "quote", 202 | "syn", 203 | ] 204 | 205 | [[package]] 206 | name = "anchor-attribute-program" 207 | version = "0.20.1" 208 | source = "registry+https://github.com/rust-lang/crates.io-index" 209 | checksum = "73c56be575d89abcb192afa29deb87b2cdb3c39033abc02f2d16e6af999b23b7" 210 | dependencies = [ 211 | "anchor-syn 0.20.1", 212 | "anyhow", 213 | "proc-macro2", 214 | "quote", 215 | "syn", 216 | ] 217 | 218 | [[package]] 219 | name = "anchor-attribute-program" 220 | version = "0.25.0" 221 | source = "registry+https://github.com/rust-lang/crates.io-index" 222 | checksum = "ac515a7a5a4fea7fc768b1cec40ddb948e148ea657637c75f94f283212326cb9" 223 | dependencies = [ 224 | "anchor-syn 0.25.0", 225 | "anyhow", 226 | "proc-macro2", 227 | "quote", 228 | "syn", 229 | ] 230 | 231 | [[package]] 232 | name = "anchor-attribute-state" 233 | version = "0.20.1" 234 | source = "registry+https://github.com/rust-lang/crates.io-index" 235 | checksum = "62ab002353b01fcb4f72cca256d5d62db39f9ff39b1d072280deee9798f1f524" 236 | dependencies = [ 237 | "anchor-syn 0.20.1", 238 | "anyhow", 239 | "proc-macro2", 240 | "quote", 241 | "syn", 242 | ] 243 | 244 | [[package]] 245 | name = "anchor-attribute-state" 246 | version = "0.25.0" 247 | source = "registry+https://github.com/rust-lang/crates.io-index" 248 | checksum = "43dc667b62ff71450f19dcfcc37b0c408fd4ddd89e8650368c2b0984b110603f" 249 | dependencies = [ 250 | "anchor-syn 0.25.0", 251 | "anyhow", 252 | "proc-macro2", 253 | "quote", 254 | "syn", 255 | ] 256 | 257 | [[package]] 258 | name = "anchor-derive-accounts" 259 | version = "0.20.1" 260 | source = "registry+https://github.com/rust-lang/crates.io-index" 261 | checksum = "e9e653cdb322078d95221384c4a527a403560e509ac7cb2b53d3bd664b23c4d6" 262 | dependencies = [ 263 | "anchor-syn 0.20.1", 264 | "anyhow", 265 | "proc-macro2", 266 | "quote", 267 | "syn", 268 | ] 269 | 270 | [[package]] 271 | name = "anchor-derive-accounts" 272 | version = "0.25.0" 273 | source = "registry+https://github.com/rust-lang/crates.io-index" 274 | checksum = "7354d583a06701d24800a8ec4c2b0491f62581a331af349205e23421e0b56643" 275 | dependencies = [ 276 | "anchor-syn 0.25.0", 277 | "anyhow", 278 | "proc-macro2", 279 | "quote", 280 | "syn", 281 | ] 282 | 283 | [[package]] 284 | name = "anchor-lang" 285 | version = "0.20.1" 286 | source = "registry+https://github.com/rust-lang/crates.io-index" 287 | checksum = "4815ad6334fd2f561f7ddcc3cfbeed87ed3003724171bd80ebe6383d5173ee8f" 288 | dependencies = [ 289 | "anchor-attribute-access-control 0.20.1", 290 | "anchor-attribute-account 0.20.1", 291 | "anchor-attribute-constant 0.20.1", 292 | "anchor-attribute-error 0.20.1", 293 | "anchor-attribute-event 0.20.1", 294 | "anchor-attribute-interface 0.20.1", 295 | "anchor-attribute-program 0.20.1", 296 | "anchor-attribute-state 0.20.1", 297 | "anchor-derive-accounts 0.20.1", 298 | "arrayref", 299 | "base64 0.13.0", 300 | "bincode", 301 | "borsh", 302 | "bytemuck", 303 | "solana-program", 304 | "thiserror", 305 | ] 306 | 307 | [[package]] 308 | name = "anchor-lang" 309 | version = "0.25.0" 310 | source = "registry+https://github.com/rust-lang/crates.io-index" 311 | checksum = "ff5f57ec5e12fa6874b27f3d5c1f6f44302d3ad86c1266197ff7611bf6f5d251" 312 | dependencies = [ 313 | "anchor-attribute-access-control 0.25.0", 314 | "anchor-attribute-account 0.25.0", 315 | "anchor-attribute-constant 0.25.0", 316 | "anchor-attribute-error 0.25.0", 317 | "anchor-attribute-event 0.25.0", 318 | "anchor-attribute-interface 0.25.0", 319 | "anchor-attribute-program 0.25.0", 320 | "anchor-attribute-state 0.25.0", 321 | "anchor-derive-accounts 0.25.0", 322 | "arrayref", 323 | "base64 0.13.0", 324 | "bincode", 325 | "borsh", 326 | "bytemuck", 327 | "solana-program", 328 | "thiserror", 329 | ] 330 | 331 | [[package]] 332 | name = "anchor-spl" 333 | version = "0.20.1" 334 | source = "registry+https://github.com/rust-lang/crates.io-index" 335 | checksum = "9ea94b04fc9a0aaae4d4473b0595fb5f55b6c9b38e0d6f596df8c8060f95f096" 336 | dependencies = [ 337 | "anchor-lang 0.20.1", 338 | "solana-program", 339 | "spl-associated-token-account", 340 | "spl-token", 341 | ] 342 | 343 | [[package]] 344 | name = "anchor-syn" 345 | version = "0.20.1" 346 | source = "registry+https://github.com/rust-lang/crates.io-index" 347 | checksum = "3be7bfb6991d79cce3495fb6ce0892f58a5c75a74c8d1c2fc6f62926066eb9f4" 348 | dependencies = [ 349 | "anyhow", 350 | "bs58 0.3.1", 351 | "heck", 352 | "proc-macro2", 353 | "proc-macro2-diagnostics", 354 | "quote", 355 | "serde", 356 | "serde_json", 357 | "sha2 0.9.9", 358 | "syn", 359 | "thiserror", 360 | ] 361 | 362 | [[package]] 363 | name = "anchor-syn" 364 | version = "0.25.0" 365 | source = "registry+https://github.com/rust-lang/crates.io-index" 366 | checksum = "55aa1e680d9471342122ed5b6bc13bf5da473b0f7e4677d41a6954e5cc8ad155" 367 | dependencies = [ 368 | "anyhow", 369 | "bs58 0.3.1", 370 | "heck", 371 | "proc-macro2", 372 | "proc-macro2-diagnostics", 373 | "quote", 374 | "serde", 375 | "serde_json", 376 | "sha2 0.9.9", 377 | "syn", 378 | "thiserror", 379 | ] 380 | 381 | [[package]] 382 | name = "anyhow" 383 | version = "1.0.52" 384 | source = "registry+https://github.com/rust-lang/crates.io-index" 385 | checksum = "84450d0b4a8bd1ba4144ce8ce718fbc5d071358b1e5384bace6536b3d1f2d5b3" 386 | 387 | [[package]] 388 | name = "arbitrary-cpi-insecure" 389 | version = "0.1.0" 390 | dependencies = [ 391 | "anchor-lang 0.20.1", 392 | "anchor-spl", 393 | "spl-token", 394 | ] 395 | 396 | [[package]] 397 | name = "arbitrary-cpi-recommended" 398 | version = "0.1.0" 399 | dependencies = [ 400 | "anchor-lang 0.20.1", 401 | "anchor-spl", 402 | "spl-token", 403 | ] 404 | 405 | [[package]] 406 | name = "arbitrary-cpi-secure" 407 | version = "0.1.0" 408 | dependencies = [ 409 | "anchor-lang 0.20.1", 410 | "anchor-spl", 411 | "spl-token", 412 | ] 413 | 414 | [[package]] 415 | name = "arrayref" 416 | version = "0.3.6" 417 | source = "registry+https://github.com/rust-lang/crates.io-index" 418 | checksum = "a4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544" 419 | 420 | [[package]] 421 | name = "arrayvec" 422 | version = "0.7.2" 423 | source = "registry+https://github.com/rust-lang/crates.io-index" 424 | checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" 425 | 426 | [[package]] 427 | name = "autocfg" 428 | version = "1.1.0" 429 | source = "registry+https://github.com/rust-lang/crates.io-index" 430 | checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" 431 | 432 | [[package]] 433 | name = "base64" 434 | version = "0.12.3" 435 | source = "registry+https://github.com/rust-lang/crates.io-index" 436 | checksum = "3441f0f7b02788e948e47f457ca01f1d7e6d92c693bc132c22b087d3141c03ff" 437 | 438 | [[package]] 439 | name = "base64" 440 | version = "0.13.0" 441 | source = "registry+https://github.com/rust-lang/crates.io-index" 442 | checksum = "904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fd" 443 | 444 | [[package]] 445 | name = "bincode" 446 | version = "1.3.3" 447 | source = "registry+https://github.com/rust-lang/crates.io-index" 448 | checksum = "b1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcad" 449 | dependencies = [ 450 | "serde", 451 | ] 452 | 453 | [[package]] 454 | name = "bitflags" 455 | version = "1.3.2" 456 | source = "registry+https://github.com/rust-lang/crates.io-index" 457 | checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" 458 | 459 | [[package]] 460 | name = "bitmaps" 461 | version = "2.1.0" 462 | source = "registry+https://github.com/rust-lang/crates.io-index" 463 | checksum = "031043d04099746d8db04daf1fa424b2bc8bd69d92b25962dcde24da39ab64a2" 464 | dependencies = [ 465 | "typenum", 466 | ] 467 | 468 | [[package]] 469 | name = "blake3" 470 | version = "1.3.0" 471 | source = "registry+https://github.com/rust-lang/crates.io-index" 472 | checksum = "882e99e4a0cb2ae6cb6e442102e8e6b7131718d94110e64c3e6a34ea9b106f37" 473 | dependencies = [ 474 | "arrayref", 475 | "arrayvec", 476 | "cc", 477 | "cfg-if", 478 | "constant_time_eq", 479 | "digest 0.10.3", 480 | ] 481 | 482 | [[package]] 483 | name = "block-buffer" 484 | version = "0.9.0" 485 | source = "registry+https://github.com/rust-lang/crates.io-index" 486 | checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" 487 | dependencies = [ 488 | "generic-array", 489 | ] 490 | 491 | [[package]] 492 | name = "block-buffer" 493 | version = "0.10.0" 494 | source = "registry+https://github.com/rust-lang/crates.io-index" 495 | checksum = "f1d36a02058e76b040de25a4464ba1c80935655595b661505c8b39b664828b95" 496 | dependencies = [ 497 | "generic-array", 498 | ] 499 | 500 | [[package]] 501 | name = "borsh" 502 | version = "0.9.1" 503 | source = "registry+https://github.com/rust-lang/crates.io-index" 504 | checksum = "18dda7dc709193c0d86a1a51050a926dc3df1cf262ec46a23a25dba421ea1924" 505 | dependencies = [ 506 | "borsh-derive", 507 | "hashbrown", 508 | ] 509 | 510 | [[package]] 511 | name = "borsh-derive" 512 | version = "0.9.1" 513 | source = "registry+https://github.com/rust-lang/crates.io-index" 514 | checksum = "684155372435f578c0fa1acd13ebbb182cc19d6b38b64ae7901da4393217d264" 515 | dependencies = [ 516 | "borsh-derive-internal", 517 | "borsh-schema-derive-internal", 518 | "proc-macro-crate 0.1.5", 519 | "proc-macro2", 520 | "syn", 521 | ] 522 | 523 | [[package]] 524 | name = "borsh-derive-internal" 525 | version = "0.9.1" 526 | source = "registry+https://github.com/rust-lang/crates.io-index" 527 | checksum = "2102f62f8b6d3edeab871830782285b64cc1830168094db05c8e458f209bc5c3" 528 | dependencies = [ 529 | "proc-macro2", 530 | "quote", 531 | "syn", 532 | ] 533 | 534 | [[package]] 535 | name = "borsh-schema-derive-internal" 536 | version = "0.9.1" 537 | source = "registry+https://github.com/rust-lang/crates.io-index" 538 | checksum = "196c978c4c9b0b142d446ef3240690bf5a8a33497074a113ff9a337ccb750483" 539 | dependencies = [ 540 | "proc-macro2", 541 | "quote", 542 | "syn", 543 | ] 544 | 545 | [[package]] 546 | name = "bs58" 547 | version = "0.3.1" 548 | source = "registry+https://github.com/rust-lang/crates.io-index" 549 | checksum = "476e9cd489f9e121e02ffa6014a8ef220ecb15c05ed23fc34cca13925dc283fb" 550 | 551 | [[package]] 552 | name = "bs58" 553 | version = "0.4.0" 554 | source = "registry+https://github.com/rust-lang/crates.io-index" 555 | checksum = "771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3" 556 | 557 | [[package]] 558 | name = "bump-seed-canonicalization-insecure" 559 | version = "0.1.0" 560 | dependencies = [ 561 | "anchor-lang 0.20.1", 562 | ] 563 | 564 | [[package]] 565 | name = "bump-seed-canonicalization-recommended" 566 | version = "0.1.0" 567 | dependencies = [ 568 | "anchor-lang 0.20.1", 569 | ] 570 | 571 | [[package]] 572 | name = "bump-seed-canonicalization-secure" 573 | version = "0.1.0" 574 | dependencies = [ 575 | "anchor-lang 0.20.1", 576 | ] 577 | 578 | [[package]] 579 | name = "bumpalo" 580 | version = "3.9.1" 581 | source = "registry+https://github.com/rust-lang/crates.io-index" 582 | checksum = "a4a45a46ab1f2412e53d3a0ade76ffad2025804294569aae387231a0cd6e0899" 583 | 584 | [[package]] 585 | name = "bv" 586 | version = "0.11.1" 587 | source = "registry+https://github.com/rust-lang/crates.io-index" 588 | checksum = "8834bb1d8ee5dc048ee3124f2c7c1afcc6bc9aed03f11e9dfd8c69470a5db340" 589 | dependencies = [ 590 | "feature-probe", 591 | "serde", 592 | ] 593 | 594 | [[package]] 595 | name = "bytemuck" 596 | version = "1.7.3" 597 | source = "registry+https://github.com/rust-lang/crates.io-index" 598 | checksum = "439989e6b8c38d1b6570a384ef1e49c8848128f5a97f3914baef02920842712f" 599 | dependencies = [ 600 | "bytemuck_derive", 601 | ] 602 | 603 | [[package]] 604 | name = "bytemuck_derive" 605 | version = "1.0.1" 606 | source = "registry+https://github.com/rust-lang/crates.io-index" 607 | checksum = "8e215f8c2f9f79cb53c8335e687ffd07d5bfcb6fe5fc80723762d0be46e7cc54" 608 | dependencies = [ 609 | "proc-macro2", 610 | "quote", 611 | "syn", 612 | ] 613 | 614 | [[package]] 615 | name = "byteorder" 616 | version = "1.4.3" 617 | source = "registry+https://github.com/rust-lang/crates.io-index" 618 | checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" 619 | 620 | [[package]] 621 | name = "cc" 622 | version = "1.0.72" 623 | source = "registry+https://github.com/rust-lang/crates.io-index" 624 | checksum = "22a9137b95ea06864e018375b72adfb7db6e6f68cfc8df5a04d00288050485ee" 625 | 626 | [[package]] 627 | name = "cfg-if" 628 | version = "1.0.0" 629 | source = "registry+https://github.com/rust-lang/crates.io-index" 630 | checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" 631 | 632 | [[package]] 633 | name = "closing-accounts-insecure" 634 | version = "0.1.0" 635 | dependencies = [ 636 | "anchor-lang 0.20.1", 637 | ] 638 | 639 | [[package]] 640 | name = "closing-accounts-insecure-still" 641 | version = "0.1.0" 642 | dependencies = [ 643 | "anchor-lang 0.20.1", 644 | ] 645 | 646 | [[package]] 647 | name = "closing-accounts-insecure-still-still" 648 | version = "0.1.0" 649 | dependencies = [ 650 | "anchor-lang 0.20.1", 651 | ] 652 | 653 | [[package]] 654 | name = "closing-accounts-recommended" 655 | version = "0.1.0" 656 | dependencies = [ 657 | "anchor-lang 0.20.1", 658 | ] 659 | 660 | [[package]] 661 | name = "closing-accounts-secure" 662 | version = "0.1.0" 663 | dependencies = [ 664 | "anchor-lang 0.20.1", 665 | ] 666 | 667 | [[package]] 668 | name = "console_error_panic_hook" 669 | version = "0.1.7" 670 | source = "registry+https://github.com/rust-lang/crates.io-index" 671 | checksum = "a06aeb73f470f66dcdbf7223caeebb85984942f22f1adb2a088cf9668146bbbc" 672 | dependencies = [ 673 | "cfg-if", 674 | "wasm-bindgen", 675 | ] 676 | 677 | [[package]] 678 | name = "console_log" 679 | version = "0.2.0" 680 | source = "registry+https://github.com/rust-lang/crates.io-index" 681 | checksum = "501a375961cef1a0d44767200e66e4a559283097e91d0730b1d75dfb2f8a1494" 682 | dependencies = [ 683 | "log", 684 | "web-sys", 685 | ] 686 | 687 | [[package]] 688 | name = "constant_time_eq" 689 | version = "0.1.5" 690 | source = "registry+https://github.com/rust-lang/crates.io-index" 691 | checksum = "245097e9a4535ee1e3e3931fcfcd55a796a44c643e8596ff6566d68f09b87bbc" 692 | 693 | [[package]] 694 | name = "cpufeatures" 695 | version = "0.2.1" 696 | source = "registry+https://github.com/rust-lang/crates.io-index" 697 | checksum = "95059428f66df56b63431fdb4e1947ed2190586af5c5a8a8b71122bdf5a7f469" 698 | dependencies = [ 699 | "libc", 700 | ] 701 | 702 | [[package]] 703 | name = "crossbeam-channel" 704 | version = "0.5.5" 705 | source = "registry+https://github.com/rust-lang/crates.io-index" 706 | checksum = "4c02a4d71819009c192cf4872265391563fd6a84c81ff2c0f2a7026ca4c1d85c" 707 | dependencies = [ 708 | "cfg-if", 709 | "crossbeam-utils", 710 | ] 711 | 712 | [[package]] 713 | name = "crossbeam-deque" 714 | version = "0.8.1" 715 | source = "registry+https://github.com/rust-lang/crates.io-index" 716 | checksum = "6455c0ca19f0d2fbf751b908d5c55c1f5cbc65e03c4225427254b46890bdde1e" 717 | dependencies = [ 718 | "cfg-if", 719 | "crossbeam-epoch", 720 | "crossbeam-utils", 721 | ] 722 | 723 | [[package]] 724 | name = "crossbeam-epoch" 725 | version = "0.9.9" 726 | source = "registry+https://github.com/rust-lang/crates.io-index" 727 | checksum = "07db9d94cbd326813772c968ccd25999e5f8ae22f4f8d1b11effa37ef6ce281d" 728 | dependencies = [ 729 | "autocfg", 730 | "cfg-if", 731 | "crossbeam-utils", 732 | "memoffset", 733 | "once_cell", 734 | "scopeguard", 735 | ] 736 | 737 | [[package]] 738 | name = "crossbeam-utils" 739 | version = "0.8.10" 740 | source = "registry+https://github.com/rust-lang/crates.io-index" 741 | checksum = "7d82ee10ce34d7bc12c2122495e7593a9c41347ecdd64185af4ecf72cb1a7f83" 742 | dependencies = [ 743 | "cfg-if", 744 | "once_cell", 745 | ] 746 | 747 | [[package]] 748 | name = "crunchy" 749 | version = "0.2.2" 750 | source = "registry+https://github.com/rust-lang/crates.io-index" 751 | checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" 752 | 753 | [[package]] 754 | name = "crypto-common" 755 | version = "0.1.5" 756 | source = "registry+https://github.com/rust-lang/crates.io-index" 757 | checksum = "2ccfd8c0ee4cce11e45b3fd6f9d5e69e0cc62912aa6a0cb1bf4617b0eba5a12f" 758 | dependencies = [ 759 | "generic-array", 760 | "typenum", 761 | ] 762 | 763 | [[package]] 764 | name = "crypto-mac" 765 | version = "0.8.0" 766 | source = "registry+https://github.com/rust-lang/crates.io-index" 767 | checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" 768 | dependencies = [ 769 | "generic-array", 770 | "subtle", 771 | ] 772 | 773 | [[package]] 774 | name = "curve25519-dalek" 775 | version = "3.2.1" 776 | source = "registry+https://github.com/rust-lang/crates.io-index" 777 | checksum = "90f9d052967f590a76e62eb387bd0bbb1b000182c3cefe5364db6b7211651bc0" 778 | dependencies = [ 779 | "byteorder", 780 | "digest 0.9.0", 781 | "rand_core 0.5.1", 782 | "subtle", 783 | "zeroize", 784 | ] 785 | 786 | [[package]] 787 | name = "digest" 788 | version = "0.9.0" 789 | source = "registry+https://github.com/rust-lang/crates.io-index" 790 | checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" 791 | dependencies = [ 792 | "generic-array", 793 | ] 794 | 795 | [[package]] 796 | name = "digest" 797 | version = "0.10.3" 798 | source = "registry+https://github.com/rust-lang/crates.io-index" 799 | checksum = "f2fb860ca6fafa5552fb6d0e816a69c8e49f0908bf524e30a90d97c85892d506" 800 | dependencies = [ 801 | "block-buffer 0.10.0", 802 | "crypto-common", 803 | "subtle", 804 | ] 805 | 806 | [[package]] 807 | name = "duplicate-mutable-accounts-insecure" 808 | version = "0.1.0" 809 | dependencies = [ 810 | "anchor-lang 0.20.1", 811 | ] 812 | 813 | [[package]] 814 | name = "duplicate-mutable-accounts-recommended" 815 | version = "0.1.0" 816 | dependencies = [ 817 | "anchor-lang", 818 | ] 819 | 820 | [[package]] 821 | name = "duplicate-mutable-accounts-secure" 822 | version = "0.1.0" 823 | dependencies = [ 824 | "anchor-lang 0.20.1", 825 | ] 826 | 827 | [[package]] 828 | name = "either" 829 | version = "1.6.1" 830 | source = "registry+https://github.com/rust-lang/crates.io-index" 831 | checksum = "e78d4f1cc4ae33bbfc157ed5d5a5ef3bc29227303d595861deb238fcec4e9457" 832 | 833 | [[package]] 834 | name = "feature-probe" 835 | version = "0.1.1" 836 | source = "registry+https://github.com/rust-lang/crates.io-index" 837 | checksum = "835a3dc7d1ec9e75e2b5fb4ba75396837112d2060b03f7d43bc1897c7f7211da" 838 | 839 | [[package]] 840 | name = "generic-array" 841 | version = "0.14.5" 842 | source = "registry+https://github.com/rust-lang/crates.io-index" 843 | checksum = "fd48d33ec7f05fbfa152300fdad764757cbded343c1aa1cff2fbaf4134851803" 844 | dependencies = [ 845 | "serde", 846 | "typenum", 847 | "version_check", 848 | ] 849 | 850 | [[package]] 851 | name = "getrandom" 852 | version = "0.1.16" 853 | source = "registry+https://github.com/rust-lang/crates.io-index" 854 | checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" 855 | dependencies = [ 856 | "cfg-if", 857 | "js-sys", 858 | "libc", 859 | "wasi", 860 | "wasm-bindgen", 861 | ] 862 | 863 | [[package]] 864 | name = "hashbrown" 865 | version = "0.9.1" 866 | source = "registry+https://github.com/rust-lang/crates.io-index" 867 | checksum = "d7afe4a420e3fe79967a00898cc1f4db7c8a49a9333a29f8a4bd76a253d5cd04" 868 | dependencies = [ 869 | "ahash", 870 | ] 871 | 872 | [[package]] 873 | name = "heck" 874 | version = "0.3.3" 875 | source = "registry+https://github.com/rust-lang/crates.io-index" 876 | checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" 877 | dependencies = [ 878 | "unicode-segmentation", 879 | ] 880 | 881 | [[package]] 882 | name = "hermit-abi" 883 | version = "0.1.19" 884 | source = "registry+https://github.com/rust-lang/crates.io-index" 885 | checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" 886 | dependencies = [ 887 | "libc", 888 | ] 889 | 890 | [[package]] 891 | name = "hmac" 892 | version = "0.8.1" 893 | source = "registry+https://github.com/rust-lang/crates.io-index" 894 | checksum = "126888268dcc288495a26bf004b38c5fdbb31682f992c84ceb046a1f0fe38840" 895 | dependencies = [ 896 | "crypto-mac", 897 | "digest 0.9.0", 898 | ] 899 | 900 | [[package]] 901 | name = "hmac-drbg" 902 | version = "0.3.0" 903 | source = "registry+https://github.com/rust-lang/crates.io-index" 904 | checksum = "17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1" 905 | dependencies = [ 906 | "digest 0.9.0", 907 | "generic-array", 908 | "hmac", 909 | ] 910 | 911 | [[package]] 912 | name = "im" 913 | version = "15.1.0" 914 | source = "registry+https://github.com/rust-lang/crates.io-index" 915 | checksum = "d0acd33ff0285af998aaf9b57342af478078f53492322fafc47450e09397e0e9" 916 | dependencies = [ 917 | "bitmaps", 918 | "rand_core 0.6.3", 919 | "rand_xoshiro", 920 | "rayon", 921 | "serde", 922 | "sized-chunks", 923 | "typenum", 924 | "version_check", 925 | ] 926 | 927 | [[package]] 928 | name = "initialization-insecure" 929 | version = "0.1.0" 930 | dependencies = [ 931 | "anchor-lang 0.20.1", 932 | ] 933 | 934 | [[package]] 935 | name = "insecure" 936 | version = "0.1.0" 937 | dependencies = [ 938 | "anchor-lang 0.25.0", 939 | ] 940 | 941 | [[package]] 942 | name = "itertools" 943 | version = "0.10.3" 944 | source = "registry+https://github.com/rust-lang/crates.io-index" 945 | checksum = "a9a9d19fa1e79b6215ff29b9d6880b706147f16e9b1dbb1e4e5947b5b02bc5e3" 946 | dependencies = [ 947 | "either", 948 | ] 949 | 950 | [[package]] 951 | name = "itoa" 952 | version = "1.0.1" 953 | source = "registry+https://github.com/rust-lang/crates.io-index" 954 | checksum = "1aab8fc367588b89dcee83ab0fd66b72b50b72fa1904d7095045ace2b0c81c35" 955 | 956 | [[package]] 957 | name = "js-sys" 958 | version = "0.3.55" 959 | source = "registry+https://github.com/rust-lang/crates.io-index" 960 | checksum = "7cc9ffccd38c451a86bf13657df244e9c3f37493cce8e5e21e940963777acc84" 961 | dependencies = [ 962 | "wasm-bindgen", 963 | ] 964 | 965 | [[package]] 966 | name = "keccak" 967 | version = "0.1.0" 968 | source = "registry+https://github.com/rust-lang/crates.io-index" 969 | checksum = "67c21572b4949434e4fc1e1978b99c5f77064153c59d998bf13ecd96fb5ecba7" 970 | 971 | [[package]] 972 | name = "lazy_static" 973 | version = "1.4.0" 974 | source = "registry+https://github.com/rust-lang/crates.io-index" 975 | checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" 976 | 977 | [[package]] 978 | name = "libc" 979 | version = "0.2.112" 980 | source = "registry+https://github.com/rust-lang/crates.io-index" 981 | checksum = "1b03d17f364a3a042d5e5d46b053bbbf82c92c9430c592dd4c064dc6ee997125" 982 | 983 | [[package]] 984 | name = "libsecp256k1" 985 | version = "0.6.0" 986 | source = "registry+https://github.com/rust-lang/crates.io-index" 987 | checksum = "c9d220bc1feda2ac231cb78c3d26f27676b8cf82c96971f7aeef3d0cf2797c73" 988 | dependencies = [ 989 | "arrayref", 990 | "base64 0.12.3", 991 | "digest 0.9.0", 992 | "hmac-drbg", 993 | "libsecp256k1-core", 994 | "libsecp256k1-gen-ecmult", 995 | "libsecp256k1-gen-genmult", 996 | "rand", 997 | "serde", 998 | "sha2 0.9.9", 999 | "typenum", 1000 | ] 1001 | 1002 | [[package]] 1003 | name = "libsecp256k1-core" 1004 | version = "0.2.2" 1005 | source = "registry+https://github.com/rust-lang/crates.io-index" 1006 | checksum = "d0f6ab710cec28cef759c5f18671a27dae2a5f952cdaaee1d8e2908cb2478a80" 1007 | dependencies = [ 1008 | "crunchy", 1009 | "digest 0.9.0", 1010 | "subtle", 1011 | ] 1012 | 1013 | [[package]] 1014 | name = "libsecp256k1-gen-ecmult" 1015 | version = "0.2.1" 1016 | source = "registry+https://github.com/rust-lang/crates.io-index" 1017 | checksum = "ccab96b584d38fac86a83f07e659f0deafd0253dc096dab5a36d53efe653c5c3" 1018 | dependencies = [ 1019 | "libsecp256k1-core", 1020 | ] 1021 | 1022 | [[package]] 1023 | name = "libsecp256k1-gen-genmult" 1024 | version = "0.2.1" 1025 | source = "registry+https://github.com/rust-lang/crates.io-index" 1026 | checksum = "67abfe149395e3aa1c48a2beb32b068e2334402df8181f818d3aee2b304c4f5d" 1027 | dependencies = [ 1028 | "libsecp256k1-core", 1029 | ] 1030 | 1031 | [[package]] 1032 | name = "lock_api" 1033 | version = "0.4.7" 1034 | source = "registry+https://github.com/rust-lang/crates.io-index" 1035 | checksum = "327fa5b6a6940e4699ec49a9beae1ea4845c6bab9314e4f84ac68742139d8c53" 1036 | dependencies = [ 1037 | "autocfg", 1038 | "scopeguard", 1039 | ] 1040 | 1041 | [[package]] 1042 | name = "log" 1043 | version = "0.4.14" 1044 | source = "registry+https://github.com/rust-lang/crates.io-index" 1045 | checksum = "51b9bbe6c47d51fc3e1a9b945965946b4c44142ab8792c50835a980d362c2710" 1046 | dependencies = [ 1047 | "cfg-if", 1048 | ] 1049 | 1050 | [[package]] 1051 | name = "memchr" 1052 | version = "2.4.1" 1053 | source = "registry+https://github.com/rust-lang/crates.io-index" 1054 | checksum = "308cc39be01b73d0d18f82a0e7b2a3df85245f84af96fdddc5d202d27e47b86a" 1055 | 1056 | [[package]] 1057 | name = "memmap2" 1058 | version = "0.5.5" 1059 | source = "registry+https://github.com/rust-lang/crates.io-index" 1060 | checksum = "3a79b39c93a7a5a27eeaf9a23b5ff43f1b9e0ad6b1cdd441140ae53c35613fc7" 1061 | dependencies = [ 1062 | "libc", 1063 | ] 1064 | 1065 | [[package]] 1066 | name = "memoffset" 1067 | version = "0.6.5" 1068 | source = "registry+https://github.com/rust-lang/crates.io-index" 1069 | checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" 1070 | dependencies = [ 1071 | "autocfg", 1072 | ] 1073 | 1074 | [[package]] 1075 | name = "num-derive" 1076 | version = "0.3.3" 1077 | source = "registry+https://github.com/rust-lang/crates.io-index" 1078 | checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" 1079 | dependencies = [ 1080 | "proc-macro2", 1081 | "quote", 1082 | "syn", 1083 | ] 1084 | 1085 | [[package]] 1086 | name = "num-traits" 1087 | version = "0.2.14" 1088 | source = "registry+https://github.com/rust-lang/crates.io-index" 1089 | checksum = "9a64b1ec5cda2586e284722486d802acf1f7dbdc623e2bfc57e65ca1cd099290" 1090 | dependencies = [ 1091 | "autocfg", 1092 | ] 1093 | 1094 | [[package]] 1095 | name = "num_cpus" 1096 | version = "1.13.1" 1097 | source = "registry+https://github.com/rust-lang/crates.io-index" 1098 | checksum = "19e64526ebdee182341572e50e9ad03965aa510cd94427a4549448f285e957a1" 1099 | dependencies = [ 1100 | "hermit-abi", 1101 | "libc", 1102 | ] 1103 | 1104 | [[package]] 1105 | name = "num_enum" 1106 | version = "0.5.6" 1107 | source = "registry+https://github.com/rust-lang/crates.io-index" 1108 | checksum = "720d3ea1055e4e4574c0c0b0f8c3fd4f24c4cdaf465948206dea090b57b526ad" 1109 | dependencies = [ 1110 | "num_enum_derive", 1111 | ] 1112 | 1113 | [[package]] 1114 | name = "num_enum_derive" 1115 | version = "0.5.6" 1116 | source = "registry+https://github.com/rust-lang/crates.io-index" 1117 | checksum = "0d992b768490d7fe0d8586d9b5745f6c49f557da6d81dc982b1d167ad4edbb21" 1118 | dependencies = [ 1119 | "proc-macro-crate 1.1.0", 1120 | "proc-macro2", 1121 | "quote", 1122 | "syn", 1123 | ] 1124 | 1125 | [[package]] 1126 | name = "once_cell" 1127 | version = "1.13.0" 1128 | source = "registry+https://github.com/rust-lang/crates.io-index" 1129 | checksum = "18a6dbe30758c9f83eb00cbea4ac95966305f5a7772f3f42ebfc7fc7eddbd8e1" 1130 | 1131 | [[package]] 1132 | name = "opaque-debug" 1133 | version = "0.3.0" 1134 | source = "registry+https://github.com/rust-lang/crates.io-index" 1135 | checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" 1136 | 1137 | [[package]] 1138 | name = "owner-checks-insecure" 1139 | version = "0.1.0" 1140 | dependencies = [ 1141 | "anchor-lang 0.20.1", 1142 | "anchor-spl", 1143 | "spl-token", 1144 | ] 1145 | 1146 | [[package]] 1147 | name = "owner-checks-recommended" 1148 | version = "0.1.0" 1149 | dependencies = [ 1150 | "anchor-lang 0.20.1", 1151 | "anchor-spl", 1152 | "spl-token", 1153 | ] 1154 | 1155 | [[package]] 1156 | name = "owner-checks-secure" 1157 | version = "0.1.0" 1158 | dependencies = [ 1159 | "anchor-lang 0.20.1", 1160 | "anchor-spl", 1161 | "spl-token", 1162 | ] 1163 | 1164 | [[package]] 1165 | name = "parking_lot" 1166 | version = "0.12.1" 1167 | source = "registry+https://github.com/rust-lang/crates.io-index" 1168 | checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" 1169 | dependencies = [ 1170 | "lock_api", 1171 | "parking_lot_core", 1172 | ] 1173 | 1174 | [[package]] 1175 | name = "parking_lot_core" 1176 | version = "0.9.3" 1177 | source = "registry+https://github.com/rust-lang/crates.io-index" 1178 | checksum = "09a279cbf25cb0757810394fbc1e359949b59e348145c643a939a525692e6929" 1179 | dependencies = [ 1180 | "cfg-if", 1181 | "libc", 1182 | "redox_syscall", 1183 | "smallvec", 1184 | "windows-sys", 1185 | ] 1186 | 1187 | [[package]] 1188 | name = "pda-sharing-insecure" 1189 | version = "0.1.0" 1190 | dependencies = [ 1191 | "anchor-lang 0.20.1", 1192 | "anchor-spl", 1193 | ] 1194 | 1195 | [[package]] 1196 | name = "pda-sharing-recommended" 1197 | version = "0.1.0" 1198 | dependencies = [ 1199 | "anchor-lang 0.20.1", 1200 | "anchor-spl", 1201 | ] 1202 | 1203 | [[package]] 1204 | name = "pda-sharing-secure" 1205 | version = "0.1.0" 1206 | dependencies = [ 1207 | "anchor-lang 0.20.1", 1208 | "anchor-spl", 1209 | ] 1210 | 1211 | [[package]] 1212 | name = "ppv-lite86" 1213 | version = "0.2.16" 1214 | source = "registry+https://github.com/rust-lang/crates.io-index" 1215 | checksum = "eb9f9e6e233e5c4a35559a617bf40a4ec447db2e84c20b55a6f83167b7e57872" 1216 | 1217 | [[package]] 1218 | name = "proc-macro-crate" 1219 | version = "0.1.5" 1220 | source = "registry+https://github.com/rust-lang/crates.io-index" 1221 | checksum = "1d6ea3c4595b96363c13943497db34af4460fb474a95c43f4446ad341b8c9785" 1222 | dependencies = [ 1223 | "toml", 1224 | ] 1225 | 1226 | [[package]] 1227 | name = "proc-macro-crate" 1228 | version = "1.1.0" 1229 | source = "registry+https://github.com/rust-lang/crates.io-index" 1230 | checksum = "1ebace6889caf889b4d3f76becee12e90353f2b8c7d875534a71e5742f8f6f83" 1231 | dependencies = [ 1232 | "thiserror", 1233 | "toml", 1234 | ] 1235 | 1236 | [[package]] 1237 | name = "proc-macro2" 1238 | version = "1.0.40" 1239 | source = "registry+https://github.com/rust-lang/crates.io-index" 1240 | checksum = "dd96a1e8ed2596c337f8eae5f24924ec83f5ad5ab21ea8e455d3566c69fbcaf7" 1241 | dependencies = [ 1242 | "unicode-ident", 1243 | ] 1244 | 1245 | [[package]] 1246 | name = "proc-macro2-diagnostics" 1247 | version = "0.9.1" 1248 | source = "registry+https://github.com/rust-lang/crates.io-index" 1249 | checksum = "4bf29726d67464d49fa6224a1d07936a8c08bb3fba727c7493f6cf1616fdaada" 1250 | dependencies = [ 1251 | "proc-macro2", 1252 | "quote", 1253 | "syn", 1254 | "version_check", 1255 | "yansi", 1256 | ] 1257 | 1258 | [[package]] 1259 | name = "quote" 1260 | version = "1.0.14" 1261 | source = "registry+https://github.com/rust-lang/crates.io-index" 1262 | checksum = "47aa80447ce4daf1717500037052af176af5d38cc3e571d9ec1c7353fc10c87d" 1263 | dependencies = [ 1264 | "proc-macro2", 1265 | ] 1266 | 1267 | [[package]] 1268 | name = "rand" 1269 | version = "0.7.3" 1270 | source = "registry+https://github.com/rust-lang/crates.io-index" 1271 | checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" 1272 | dependencies = [ 1273 | "getrandom", 1274 | "libc", 1275 | "rand_chacha", 1276 | "rand_core 0.5.1", 1277 | "rand_hc", 1278 | ] 1279 | 1280 | [[package]] 1281 | name = "rand_chacha" 1282 | version = "0.2.2" 1283 | source = "registry+https://github.com/rust-lang/crates.io-index" 1284 | checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" 1285 | dependencies = [ 1286 | "ppv-lite86", 1287 | "rand_core 0.5.1", 1288 | ] 1289 | 1290 | [[package]] 1291 | name = "rand_core" 1292 | version = "0.5.1" 1293 | source = "registry+https://github.com/rust-lang/crates.io-index" 1294 | checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" 1295 | dependencies = [ 1296 | "getrandom", 1297 | ] 1298 | 1299 | [[package]] 1300 | name = "rand_core" 1301 | version = "0.6.3" 1302 | source = "registry+https://github.com/rust-lang/crates.io-index" 1303 | checksum = "d34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7" 1304 | 1305 | [[package]] 1306 | name = "rand_hc" 1307 | version = "0.2.0" 1308 | source = "registry+https://github.com/rust-lang/crates.io-index" 1309 | checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" 1310 | dependencies = [ 1311 | "rand_core 0.5.1", 1312 | ] 1313 | 1314 | [[package]] 1315 | name = "rand_xoshiro" 1316 | version = "0.6.0" 1317 | source = "registry+https://github.com/rust-lang/crates.io-index" 1318 | checksum = "6f97cdb2a36ed4183de61b2f824cc45c9f1037f28afe0a322e9fff4c108b5aaa" 1319 | dependencies = [ 1320 | "rand_core 0.6.3", 1321 | ] 1322 | 1323 | [[package]] 1324 | name = "rayon" 1325 | version = "1.5.3" 1326 | source = "registry+https://github.com/rust-lang/crates.io-index" 1327 | checksum = "bd99e5772ead8baa5215278c9b15bf92087709e9c1b2d1f97cdb5a183c933a7d" 1328 | dependencies = [ 1329 | "autocfg", 1330 | "crossbeam-deque", 1331 | "either", 1332 | "rayon-core", 1333 | ] 1334 | 1335 | [[package]] 1336 | name = "rayon-core" 1337 | version = "1.9.3" 1338 | source = "registry+https://github.com/rust-lang/crates.io-index" 1339 | checksum = "258bcdb5ac6dad48491bb2992db6b7cf74878b0384908af124823d118c99683f" 1340 | dependencies = [ 1341 | "crossbeam-channel", 1342 | "crossbeam-deque", 1343 | "crossbeam-utils", 1344 | "num_cpus", 1345 | ] 1346 | 1347 | [[package]] 1348 | name = "recommended" 1349 | version = "0.1.0" 1350 | dependencies = [ 1351 | "anchor-lang 0.25.0", 1352 | ] 1353 | 1354 | [[package]] 1355 | name = "redox_syscall" 1356 | version = "0.2.10" 1357 | source = "registry+https://github.com/rust-lang/crates.io-index" 1358 | checksum = "8383f39639269cde97d255a32bdb68c047337295414940c68bdd30c2e13203ff" 1359 | dependencies = [ 1360 | "bitflags", 1361 | ] 1362 | 1363 | [[package]] 1364 | name = "regex" 1365 | version = "1.5.4" 1366 | source = "registry+https://github.com/rust-lang/crates.io-index" 1367 | checksum = "d07a8629359eb56f1e2fb1652bb04212c072a87ba68546a04065d525673ac461" 1368 | dependencies = [ 1369 | "aho-corasick", 1370 | "memchr", 1371 | "regex-syntax", 1372 | ] 1373 | 1374 | [[package]] 1375 | name = "regex-syntax" 1376 | version = "0.6.25" 1377 | source = "registry+https://github.com/rust-lang/crates.io-index" 1378 | checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b" 1379 | 1380 | [[package]] 1381 | name = "reinitialization-secure" 1382 | version = "0.1.0" 1383 | dependencies = [ 1384 | "anchor-lang 0.20.1", 1385 | ] 1386 | 1387 | [[package]] 1388 | name = "reinitialization-secure-recommended" 1389 | version = "0.1.0" 1390 | dependencies = [ 1391 | "anchor-lang 0.20.1", 1392 | ] 1393 | 1394 | [[package]] 1395 | name = "rustc_version" 1396 | version = "0.4.0" 1397 | source = "registry+https://github.com/rust-lang/crates.io-index" 1398 | checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" 1399 | dependencies = [ 1400 | "semver", 1401 | ] 1402 | 1403 | [[package]] 1404 | name = "rustversion" 1405 | version = "1.0.6" 1406 | source = "registry+https://github.com/rust-lang/crates.io-index" 1407 | checksum = "f2cc38e8fa666e2de3c4aba7edeb5ffc5246c1c2ed0e3d17e560aeeba736b23f" 1408 | 1409 | [[package]] 1410 | name = "ryu" 1411 | version = "1.0.9" 1412 | source = "registry+https://github.com/rust-lang/crates.io-index" 1413 | checksum = "73b4b750c782965c211b42f022f59af1fbceabdd026623714f104152f1ec149f" 1414 | 1415 | [[package]] 1416 | name = "scopeguard" 1417 | version = "1.1.0" 1418 | source = "registry+https://github.com/rust-lang/crates.io-index" 1419 | checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" 1420 | 1421 | [[package]] 1422 | name = "secure" 1423 | version = "0.1.0" 1424 | dependencies = [ 1425 | "anchor-lang 0.25.0", 1426 | ] 1427 | 1428 | [[package]] 1429 | name = "semver" 1430 | version = "1.0.4" 1431 | source = "registry+https://github.com/rust-lang/crates.io-index" 1432 | checksum = "568a8e6258aa33c13358f81fd834adb854c6f7c9468520910a9b1e8fac068012" 1433 | 1434 | [[package]] 1435 | name = "serde" 1436 | version = "1.0.139" 1437 | source = "registry+https://github.com/rust-lang/crates.io-index" 1438 | checksum = "0171ebb889e45aa68b44aee0859b3eede84c6f5f5c228e6f140c0b2a0a46cad6" 1439 | dependencies = [ 1440 | "serde_derive", 1441 | ] 1442 | 1443 | [[package]] 1444 | name = "serde_bytes" 1445 | version = "0.11.5" 1446 | source = "registry+https://github.com/rust-lang/crates.io-index" 1447 | checksum = "16ae07dd2f88a366f15bd0632ba725227018c69a1c8550a927324f8eb8368bb9" 1448 | dependencies = [ 1449 | "serde", 1450 | ] 1451 | 1452 | [[package]] 1453 | name = "serde_derive" 1454 | version = "1.0.139" 1455 | source = "registry+https://github.com/rust-lang/crates.io-index" 1456 | checksum = "dc1d3230c1de7932af58ad8ffbe1d784bd55efd5a9d84ac24f69c72d83543dfb" 1457 | dependencies = [ 1458 | "proc-macro2", 1459 | "quote", 1460 | "syn", 1461 | ] 1462 | 1463 | [[package]] 1464 | name = "serde_json" 1465 | version = "1.0.74" 1466 | source = "registry+https://github.com/rust-lang/crates.io-index" 1467 | checksum = "ee2bb9cd061c5865d345bb02ca49fcef1391741b672b54a0bf7b679badec3142" 1468 | dependencies = [ 1469 | "itoa", 1470 | "ryu", 1471 | "serde", 1472 | ] 1473 | 1474 | [[package]] 1475 | name = "sha2" 1476 | version = "0.9.9" 1477 | source = "registry+https://github.com/rust-lang/crates.io-index" 1478 | checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" 1479 | dependencies = [ 1480 | "block-buffer 0.9.0", 1481 | "cfg-if", 1482 | "cpufeatures", 1483 | "digest 0.9.0", 1484 | "opaque-debug", 1485 | ] 1486 | 1487 | [[package]] 1488 | name = "sha2" 1489 | version = "0.10.2" 1490 | source = "registry+https://github.com/rust-lang/crates.io-index" 1491 | checksum = "55deaec60f81eefe3cce0dc50bda92d6d8e88f2a27df7c5033b42afeb1ed2676" 1492 | dependencies = [ 1493 | "cfg-if", 1494 | "cpufeatures", 1495 | "digest 0.10.3", 1496 | ] 1497 | 1498 | [[package]] 1499 | name = "sha3" 1500 | version = "0.10.1" 1501 | source = "registry+https://github.com/rust-lang/crates.io-index" 1502 | checksum = "881bf8156c87b6301fc5ca6b27f11eeb2761224c7081e69b409d5a1951a70c86" 1503 | dependencies = [ 1504 | "digest 0.10.3", 1505 | "keccak", 1506 | ] 1507 | 1508 | [[package]] 1509 | name = "signer-authorization-insecure" 1510 | version = "0.1.0" 1511 | dependencies = [ 1512 | "anchor-lang 0.20.1", 1513 | ] 1514 | 1515 | [[package]] 1516 | name = "signer-authorization-recommended" 1517 | version = "0.1.0" 1518 | dependencies = [ 1519 | "anchor-lang 0.20.1", 1520 | ] 1521 | 1522 | [[package]] 1523 | name = "signer-authorization-secure" 1524 | version = "0.1.0" 1525 | dependencies = [ 1526 | "anchor-lang 0.20.1", 1527 | ] 1528 | 1529 | [[package]] 1530 | name = "sized-chunks" 1531 | version = "0.6.5" 1532 | source = "registry+https://github.com/rust-lang/crates.io-index" 1533 | checksum = "16d69225bde7a69b235da73377861095455d298f2b970996eec25ddbb42b3d1e" 1534 | dependencies = [ 1535 | "bitmaps", 1536 | "typenum", 1537 | ] 1538 | 1539 | [[package]] 1540 | name = "smallvec" 1541 | version = "1.7.0" 1542 | source = "registry+https://github.com/rust-lang/crates.io-index" 1543 | checksum = "1ecab6c735a6bb4139c0caafd0cc3635748bbb3acf4550e8138122099251f309" 1544 | 1545 | [[package]] 1546 | name = "solana-frozen-abi" 1547 | version = "1.10.31" 1548 | source = "registry+https://github.com/rust-lang/crates.io-index" 1549 | checksum = "68f2b153f8eb8c4d22f2b739d3d31bac4122ca17376869cb717bf3a45200ea63" 1550 | dependencies = [ 1551 | "bs58 0.4.0", 1552 | "bv", 1553 | "generic-array", 1554 | "im", 1555 | "lazy_static", 1556 | "log", 1557 | "memmap2", 1558 | "rustc_version", 1559 | "serde", 1560 | "serde_bytes", 1561 | "serde_derive", 1562 | "sha2 0.10.2", 1563 | "solana-frozen-abi-macro", 1564 | "thiserror", 1565 | ] 1566 | 1567 | [[package]] 1568 | name = "solana-frozen-abi-macro" 1569 | version = "1.10.31" 1570 | source = "registry+https://github.com/rust-lang/crates.io-index" 1571 | checksum = "0cd23aad847403a28dd1452611490b5e8f040470ed251882cca0492c5e566280" 1572 | dependencies = [ 1573 | "proc-macro2", 1574 | "quote", 1575 | "rustc_version", 1576 | "syn", 1577 | ] 1578 | 1579 | [[package]] 1580 | name = "solana-program" 1581 | version = "1.10.31" 1582 | source = "registry+https://github.com/rust-lang/crates.io-index" 1583 | checksum = "37be82a1fe85b24aa036153650053fd9628489c07c834b6b2dc027c4052bdbe5" 1584 | dependencies = [ 1585 | "base64 0.13.0", 1586 | "bincode", 1587 | "bitflags", 1588 | "blake3", 1589 | "borsh", 1590 | "borsh-derive", 1591 | "bs58 0.4.0", 1592 | "bv", 1593 | "bytemuck", 1594 | "console_error_panic_hook", 1595 | "console_log", 1596 | "curve25519-dalek", 1597 | "getrandom", 1598 | "itertools", 1599 | "js-sys", 1600 | "lazy_static", 1601 | "libsecp256k1", 1602 | "log", 1603 | "num-derive", 1604 | "num-traits", 1605 | "parking_lot", 1606 | "rand", 1607 | "rustc_version", 1608 | "rustversion", 1609 | "serde", 1610 | "serde_bytes", 1611 | "serde_derive", 1612 | "sha2 0.10.2", 1613 | "sha3", 1614 | "solana-frozen-abi", 1615 | "solana-frozen-abi-macro", 1616 | "solana-sdk-macro", 1617 | "thiserror", 1618 | "wasm-bindgen", 1619 | ] 1620 | 1621 | [[package]] 1622 | name = "solana-sdk-macro" 1623 | version = "1.10.31" 1624 | source = "registry+https://github.com/rust-lang/crates.io-index" 1625 | checksum = "275c52edaaaa86ce649a226c03f75579d570c01880a43ee1de77a973994754ce" 1626 | dependencies = [ 1627 | "bs58 0.4.0", 1628 | "proc-macro2", 1629 | "quote", 1630 | "rustversion", 1631 | "syn", 1632 | ] 1633 | 1634 | [[package]] 1635 | name = "spl-associated-token-account" 1636 | version = "1.0.3" 1637 | source = "registry+https://github.com/rust-lang/crates.io-index" 1638 | checksum = "393e2240d521c3dd770806bff25c2c00d761ac962be106e14e22dd912007f428" 1639 | dependencies = [ 1640 | "solana-program", 1641 | "spl-token", 1642 | ] 1643 | 1644 | [[package]] 1645 | name = "spl-token" 1646 | version = "3.2.0" 1647 | source = "registry+https://github.com/rust-lang/crates.io-index" 1648 | checksum = "93bfdd5bd7c869cb565c7d7635c4fafe189b988a0bdef81063cd9585c6b8dc01" 1649 | dependencies = [ 1650 | "arrayref", 1651 | "num-derive", 1652 | "num-traits", 1653 | "num_enum", 1654 | "solana-program", 1655 | "thiserror", 1656 | ] 1657 | 1658 | [[package]] 1659 | name = "subtle" 1660 | version = "2.4.1" 1661 | source = "registry+https://github.com/rust-lang/crates.io-index" 1662 | checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" 1663 | 1664 | [[package]] 1665 | name = "syn" 1666 | version = "1.0.98" 1667 | source = "registry+https://github.com/rust-lang/crates.io-index" 1668 | checksum = "c50aef8a904de4c23c788f104b7dddc7d6f79c647c7c8ce4cc8f73eb0ca773dd" 1669 | dependencies = [ 1670 | "proc-macro2", 1671 | "quote", 1672 | "unicode-ident", 1673 | ] 1674 | 1675 | [[package]] 1676 | name = "thiserror" 1677 | version = "1.0.30" 1678 | source = "registry+https://github.com/rust-lang/crates.io-index" 1679 | checksum = "854babe52e4df1653706b98fcfc05843010039b406875930a70e4d9644e5c417" 1680 | dependencies = [ 1681 | "thiserror-impl", 1682 | ] 1683 | 1684 | [[package]] 1685 | name = "thiserror-impl" 1686 | version = "1.0.30" 1687 | source = "registry+https://github.com/rust-lang/crates.io-index" 1688 | checksum = "aa32fd3f627f367fe16f893e2597ae3c05020f8bba2666a4e6ea73d377e5714b" 1689 | dependencies = [ 1690 | "proc-macro2", 1691 | "quote", 1692 | "syn", 1693 | ] 1694 | 1695 | [[package]] 1696 | name = "toml" 1697 | version = "0.5.8" 1698 | source = "registry+https://github.com/rust-lang/crates.io-index" 1699 | checksum = "a31142970826733df8241ef35dc040ef98c679ab14d7c3e54d827099b3acecaa" 1700 | dependencies = [ 1701 | "serde", 1702 | ] 1703 | 1704 | [[package]] 1705 | name = "type-cosplay-insecure" 1706 | version = "0.1.0" 1707 | dependencies = [ 1708 | "anchor-lang 0.20.1", 1709 | ] 1710 | 1711 | [[package]] 1712 | name = "type-cosplay-recommended" 1713 | version = "0.1.0" 1714 | dependencies = [ 1715 | "anchor-lang 0.20.1", 1716 | ] 1717 | 1718 | [[package]] 1719 | name = "type-cosplay-secure" 1720 | version = "0.1.0" 1721 | dependencies = [ 1722 | "anchor-lang 0.20.1", 1723 | ] 1724 | 1725 | [[package]] 1726 | name = "typenum" 1727 | version = "1.15.0" 1728 | source = "registry+https://github.com/rust-lang/crates.io-index" 1729 | checksum = "dcf81ac59edc17cc8697ff311e8f5ef2d99fcbd9817b34cec66f90b6c3dfd987" 1730 | 1731 | [[package]] 1732 | name = "unicode-ident" 1733 | version = "1.0.1" 1734 | source = "registry+https://github.com/rust-lang/crates.io-index" 1735 | checksum = "5bd2fe26506023ed7b5e1e315add59d6f584c621d037f9368fea9cfb988f368c" 1736 | 1737 | [[package]] 1738 | name = "unicode-segmentation" 1739 | version = "1.8.0" 1740 | source = "registry+https://github.com/rust-lang/crates.io-index" 1741 | checksum = "8895849a949e7845e06bd6dc1aa51731a103c42707010a5b591c0038fb73385b" 1742 | 1743 | [[package]] 1744 | name = "version_check" 1745 | version = "0.9.4" 1746 | source = "registry+https://github.com/rust-lang/crates.io-index" 1747 | checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" 1748 | 1749 | [[package]] 1750 | name = "wasi" 1751 | version = "0.9.0+wasi-snapshot-preview1" 1752 | source = "registry+https://github.com/rust-lang/crates.io-index" 1753 | checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" 1754 | 1755 | [[package]] 1756 | name = "wasm-bindgen" 1757 | version = "0.2.78" 1758 | source = "registry+https://github.com/rust-lang/crates.io-index" 1759 | checksum = "632f73e236b219150ea279196e54e610f5dbafa5d61786303d4da54f84e47fce" 1760 | dependencies = [ 1761 | "cfg-if", 1762 | "wasm-bindgen-macro", 1763 | ] 1764 | 1765 | [[package]] 1766 | name = "wasm-bindgen-backend" 1767 | version = "0.2.78" 1768 | source = "registry+https://github.com/rust-lang/crates.io-index" 1769 | checksum = "a317bf8f9fba2476b4b2c85ef4c4af8ff39c3c7f0cdfeed4f82c34a880aa837b" 1770 | dependencies = [ 1771 | "bumpalo", 1772 | "lazy_static", 1773 | "log", 1774 | "proc-macro2", 1775 | "quote", 1776 | "syn", 1777 | "wasm-bindgen-shared", 1778 | ] 1779 | 1780 | [[package]] 1781 | name = "wasm-bindgen-macro" 1782 | version = "0.2.78" 1783 | source = "registry+https://github.com/rust-lang/crates.io-index" 1784 | checksum = "d56146e7c495528bf6587663bea13a8eb588d39b36b679d83972e1a2dbbdacf9" 1785 | dependencies = [ 1786 | "quote", 1787 | "wasm-bindgen-macro-support", 1788 | ] 1789 | 1790 | [[package]] 1791 | name = "wasm-bindgen-macro-support" 1792 | version = "0.2.78" 1793 | source = "registry+https://github.com/rust-lang/crates.io-index" 1794 | checksum = "7803e0eea25835f8abdc585cd3021b3deb11543c6fe226dcd30b228857c5c5ab" 1795 | dependencies = [ 1796 | "proc-macro2", 1797 | "quote", 1798 | "syn", 1799 | "wasm-bindgen-backend", 1800 | "wasm-bindgen-shared", 1801 | ] 1802 | 1803 | [[package]] 1804 | name = "wasm-bindgen-shared" 1805 | version = "0.2.78" 1806 | source = "registry+https://github.com/rust-lang/crates.io-index" 1807 | checksum = "0237232789cf037d5480773fe568aac745bfe2afbc11a863e97901780a6b47cc" 1808 | 1809 | [[package]] 1810 | name = "web-sys" 1811 | version = "0.3.55" 1812 | source = "registry+https://github.com/rust-lang/crates.io-index" 1813 | checksum = "38eb105f1c59d9eaa6b5cdc92b859d85b926e82cb2e0945cd0c9259faa6fe9fb" 1814 | dependencies = [ 1815 | "js-sys", 1816 | "wasm-bindgen", 1817 | ] 1818 | 1819 | [[package]] 1820 | name = "windows-sys" 1821 | version = "0.36.1" 1822 | source = "registry+https://github.com/rust-lang/crates.io-index" 1823 | checksum = "ea04155a16a59f9eab786fe12a4a450e75cdb175f9e0d80da1e17db09f55b8d2" 1824 | dependencies = [ 1825 | "windows_aarch64_msvc", 1826 | "windows_i686_gnu", 1827 | "windows_i686_msvc", 1828 | "windows_x86_64_gnu", 1829 | "windows_x86_64_msvc", 1830 | ] 1831 | 1832 | [[package]] 1833 | name = "windows_aarch64_msvc" 1834 | version = "0.36.1" 1835 | source = "registry+https://github.com/rust-lang/crates.io-index" 1836 | checksum = "9bb8c3fd39ade2d67e9874ac4f3db21f0d710bee00fe7cab16949ec184eeaa47" 1837 | 1838 | [[package]] 1839 | name = "windows_i686_gnu" 1840 | version = "0.36.1" 1841 | source = "registry+https://github.com/rust-lang/crates.io-index" 1842 | checksum = "180e6ccf01daf4c426b846dfc66db1fc518f074baa793aa7d9b9aaeffad6a3b6" 1843 | 1844 | [[package]] 1845 | name = "windows_i686_msvc" 1846 | version = "0.36.1" 1847 | source = "registry+https://github.com/rust-lang/crates.io-index" 1848 | checksum = "e2e7917148b2812d1eeafaeb22a97e4813dfa60a3f8f78ebe204bcc88f12f024" 1849 | 1850 | [[package]] 1851 | name = "windows_x86_64_gnu" 1852 | version = "0.36.1" 1853 | source = "registry+https://github.com/rust-lang/crates.io-index" 1854 | checksum = "4dcd171b8776c41b97521e5da127a2d86ad280114807d0b2ab1e462bc764d9e1" 1855 | 1856 | [[package]] 1857 | name = "windows_x86_64_msvc" 1858 | version = "0.36.1" 1859 | source = "registry+https://github.com/rust-lang/crates.io-index" 1860 | checksum = "c811ca4a8c853ef420abd8592ba53ddbbac90410fab6903b3e79972a631f7680" 1861 | 1862 | [[package]] 1863 | name = "yansi" 1864 | version = "0.5.0" 1865 | source = "registry+https://github.com/rust-lang/crates.io-index" 1866 | checksum = "9fc79f4a1e39857fc00c3f662cbf2651c771f00e9c15fe2abc341806bd46bd71" 1867 | 1868 | [[package]] 1869 | name = "zeroize" 1870 | version = "1.3.0" 1871 | source = "registry+https://github.com/rust-lang/crates.io-index" 1872 | checksum = "4756f7db3f7b5574938c3eb1c117038b8e07f95ee6718c0efad4ac21508f1efd" 1873 | -------------------------------------------------------------------------------- /Cargo.toml: -------------------------------------------------------------------------------- 1 | [workspace] 2 | members = [ 3 | "programs/0-signer-authorization/*", 4 | "programs/1-account-data-matching/*", 5 | "programs/2-owner-checks/*", 6 | "programs/3-type-cosplay/*", 7 | "programs/4-initialization/*", 8 | "programs/5-arbitrary-cpi/*", 9 | "programs/6-duplicate-mutable-accounts/*", 10 | "programs/7-bump-seed-canonicalization/*", 11 | "programs/8-pda-sharing/*", 12 | "programs/9-closing-accounts/*", 13 | "programs/10-sysvar-address-checking/*" 14 | ] 15 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Sealevel Attacks 2 | 3 | Examples of common exploits unique to the Solana programming model and recommended idioms for 4 | avoiding these attacks using the Anchor framework. 5 | 6 | The examples in this repo are purposefully not complete. Each program here is meant to showcase a 7 | specific issue and recommended fix in isolation. 8 | -------------------------------------------------------------------------------- /migrations/deploy.ts: -------------------------------------------------------------------------------- 1 | // Migrations are an early feature. Currently, they're nothing more than this 2 | // single deploy script that's invoked from the CLI, injecting a provider 3 | // configured from the workspace's Anchor.toml. 4 | 5 | const anchor = require("@project-serum/anchor"); 6 | 7 | module.exports = async function (provider) { 8 | // Configure client to use the provider. 9 | anchor.setProvider(provider); 10 | 11 | // Add your deploy script here. 12 | } 13 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "@project-serum/anchor": "^0.20.0" 4 | }, 5 | "devDependencies": { 6 | "chai": "^4.3.4", 7 | "mocha": "^9.0.3", 8 | "ts-mocha": "^8.0.0", 9 | "@types/mocha": "^9.0.0", 10 | "typescript": "^4.3.5" 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "signer-authorization-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "signer_authorization_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.0" 20 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | #[program] 5 | pub mod signer_authorization_insecure { 6 | use super::*; 7 | 8 | pub fn log_message(ctx: Context) -> ProgramResult { 9 | msg!("GM {}", ctx.accounts.authority.key().to_string()); 10 | Ok(()) 11 | } 12 | } 13 | 14 | #[derive(Accounts)] 15 | pub struct LogMessage<'info> { 16 | authority: AccountInfo<'info>, 17 | } 18 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "signer-authorization-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "signer_authorization_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.0" 20 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod signer_authorization_recommended { 7 | use super::*; 8 | 9 | pub fn log_message(ctx: Context) -> ProgramResult { 10 | msg!("GM {}", ctx.accounts.authority.key().to_string()); 11 | Ok(()) 12 | } 13 | } 14 | 15 | #[derive(Accounts)] 16 | pub struct LogMessage<'info> { 17 | authority: Signer<'info>, 18 | } 19 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "signer-authorization-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "signer_authorization_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.0" 20 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/0-signer-authorization/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod signer_authorization_secure { 7 | use super::*; 8 | 9 | pub fn log_message(ctx: Context) -> ProgramResult { 10 | if !ctx.accounts.authority.is_signer { 11 | return Err(ProgramError::MissingRequiredSignature); 12 | } 13 | msg!("GM {}", ctx.accounts.authority.key().to_string()); 14 | Ok(()) 15 | } 16 | } 17 | 18 | #[derive(Accounts)] 19 | pub struct LogMessage<'info> { 20 | authority: AccountInfo<'info>, 21 | } 22 | -------------------------------------------------------------------------------- /programs/1-account-data-matching/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "account-data-matching-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "account_data_matching_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = "3.2.0" -------------------------------------------------------------------------------- /programs/1-account-data-matching/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/1-account-data-matching/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_lang::solana_program::program_pack::Pack; 3 | use spl_token::state::Account as SplTokenAccount; 4 | 5 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 6 | 7 | #[program] 8 | pub mod account_data_matching_insecure { 9 | use super::*; 10 | 11 | pub fn log_message(ctx: Context) -> ProgramResult { 12 | let token = SplTokenAccount::unpack(&ctx.accounts.token.data.borrow())?; 13 | msg!("Your account balance is: {}", token.amount); 14 | Ok(()) 15 | } 16 | } 17 | 18 | #[derive(Accounts)] 19 | pub struct LogMessage<'info> { 20 | token: AccountInfo<'info>, 21 | authority: Signer<'info>, 22 | } 23 | -------------------------------------------------------------------------------- /programs/1-account-data-matching/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "account-data-matching-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "account_data_matching_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = "3.2.0" -------------------------------------------------------------------------------- /programs/1-account-data-matching/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/1-account-data-matching/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_spl::token::TokenAccount; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod account_data_matching_recommended { 8 | use super::*; 9 | 10 | pub fn log_message(ctx: Context) -> ProgramResult { 11 | msg!("Your account balance is: {}", ctx.accounts.token.amount); 12 | Ok(()) 13 | } 14 | } 15 | 16 | #[derive(Accounts)] 17 | pub struct LogMessage<'info> { 18 | #[account(constraint = authority.key == &token.owner)] 19 | token: Account<'info, TokenAccount>, 20 | authority: Signer<'info>, 21 | } 22 | -------------------------------------------------------------------------------- /programs/1-account-data-matching/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "account-data-matching-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "account_data_matching_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = "3.2.0" -------------------------------------------------------------------------------- /programs/1-account-data-matching/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/1-account-data-matching/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_lang::solana_program::program_pack::Pack; 3 | use spl_token::state::Account as SplTokenAccount; 4 | 5 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 6 | 7 | #[program] 8 | pub mod account_data_matching_secure { 9 | use super::*; 10 | 11 | pub fn log_message(ctx: Context) -> ProgramResult { 12 | let token = SplTokenAccount::unpack(&ctx.accounts.token.data.borrow())?; 13 | if ctx.accounts.authority.key != &token.owner { 14 | return Err(ProgramError::InvalidAccountData); 15 | } 16 | msg!("Your acocunt balance is: {}", token.amount); 17 | Ok(()) 18 | } 19 | } 20 | 21 | #[derive(Accounts)] 22 | pub struct LogMessage<'info> { 23 | token: AccountInfo<'info>, 24 | authority: Signer<'info>, 25 | } 26 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2021" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [profile.release] 19 | overflow-checks = true 20 | 21 | [dependencies] 22 | anchor-lang = "0.25.0" 23 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod insecure { 7 | use super::*; 8 | 9 | pub fn check_sysvar_address(ctx: Context) -> Result<()> { 10 | msg!("Rent Key -> {}", ctx.accounts.rent.key().to_string()); 11 | Ok(()) 12 | } 13 | } 14 | 15 | #[derive(Accounts)] 16 | pub struct CheckSysvarAddress<'info> { 17 | rent: AccountInfo<'info>, 18 | } 19 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2021" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [profile.release] 19 | overflow-checks = true 20 | 21 | [dependencies] 22 | anchor-lang = "0.25.0" 23 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod recommended { 7 | use super::*; 8 | 9 | pub fn check_sysvar_address(ctx: Context) -> Result<()> { 10 | msg!("Rent Key -> {}", ctx.accounts.rent.key().to_string()); 11 | Ok(()) 12 | } 13 | } 14 | 15 | #[derive(Accounts)] 16 | pub struct CheckSysvarAddress<'info> { 17 | rent: Sysvar<'info, Rent>, 18 | } 19 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2021" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.25.0" 20 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/10-sysvar-address-checking/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_lang::solana_program::sysvar; 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod secure { 7 | use super::*; 8 | 9 | pub fn check_sysvar_address(ctx: Context) -> Result<()> { 10 | require_eq!(ctx.accounts.rent.key(), sysvar::rent::ID); 11 | msg!("Rent Key -> {}", ctx.accounts.rent.key().to_string()); 12 | Ok(()) 13 | } 14 | } 15 | 16 | #[derive(Accounts)] 17 | pub struct CheckSysvarAddress<'info> { 18 | rent: AccountInfo<'info>, 19 | } 20 | -------------------------------------------------------------------------------- /programs/2-owner-checks/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "owner-checks-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "owner_checks_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = "3.2.0" 22 | -------------------------------------------------------------------------------- /programs/2-owner-checks/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/2-owner-checks/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_lang::solana_program::program_error::ProgramError; 3 | use anchor_lang::solana_program::program_pack::Pack; 4 | use spl_token::state::Account as SplTokenAccount; 5 | 6 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 7 | 8 | #[program] 9 | pub mod owner_checks_insecure { 10 | use super::*; 11 | 12 | pub fn log_message(ctx: Context) -> ProgramResult { 13 | let token = SplTokenAccount::unpack(&ctx.accounts.token.data.borrow())?; 14 | if ctx.accounts.authority.key != &token.owner { 15 | return Err(ProgramError::InvalidAccountData); 16 | } 17 | msg!("Your account balance is: {}", token.amount); 18 | Ok(()) 19 | } 20 | } 21 | 22 | #[derive(Accounts)] 23 | pub struct LogMessage<'info> { 24 | token: AccountInfo<'info>, 25 | authority: Signer<'info>, 26 | } 27 | -------------------------------------------------------------------------------- /programs/2-owner-checks/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "owner-checks-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "owner_checks_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = "3.2.0" 22 | -------------------------------------------------------------------------------- /programs/2-owner-checks/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/2-owner-checks/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_spl::token::TokenAccount; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod owner_checks_recommended { 8 | use super::*; 9 | 10 | pub fn log_message(ctx: Context) -> ProgramResult { 11 | msg!("Your account balance is: {}", ctx.accounts.token.amount); 12 | Ok(()) 13 | } 14 | } 15 | 16 | #[derive(Accounts)] 17 | pub struct LogMessage<'info> { 18 | #[account(constraint = authority.key == &token.owner)] 19 | token: Account<'info, TokenAccount>, 20 | authority: Signer<'info>, 21 | } 22 | -------------------------------------------------------------------------------- /programs/2-owner-checks/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "owner-checks-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "owner_checks_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = "3.2.0" 22 | -------------------------------------------------------------------------------- /programs/2-owner-checks/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/2-owner-checks/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_lang::solana_program::program_error::ProgramError; 3 | use anchor_lang::solana_program::program_pack::Pack; 4 | use spl_token::state::Account as SplTokenAccount; 5 | 6 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 7 | 8 | #[program] 9 | pub mod owner_checks_secure { 10 | use super::*; 11 | 12 | pub fn log_message(ctx: Context) -> ProgramResult { 13 | let token = SplTokenAccount::unpack(&ctx.accounts.token.data.borrow())?; 14 | if ctx.accounts.token.owner != &spl_token::ID { 15 | return Err(ProgramError::InvalidAccountData); 16 | } 17 | if ctx.accounts.authority.key != &token.owner { 18 | return Err(ProgramError::InvalidAccountData); 19 | } 20 | msg!("Your account balance is: {}", token.amount); 21 | Ok(()) 22 | } 23 | } 24 | 25 | #[derive(Accounts)] 26 | pub struct LogMessage<'info> { 27 | token: AccountInfo<'info>, 28 | authority: Signer<'info>, 29 | } 30 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "type-cosplay-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "type_cosplay_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use borsh::{BorshDeserialize, BorshSerialize}; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod type_cosplay_insecure { 8 | use super::*; 9 | 10 | pub fn update_user(ctx: Context) -> ProgramResult { 11 | let user = User::try_from_slice(&ctx.accounts.user.data.borrow()).unwrap(); 12 | if ctx.accounts.user.owner != ctx.program_id { 13 | return Err(ProgramError::IllegalOwner); 14 | } 15 | if user.authority != ctx.accounts.authority.key() { 16 | return Err(ProgramError::InvalidAccountData); 17 | } 18 | msg!("GM {}", user.authority); 19 | Ok(()) 20 | } 21 | } 22 | 23 | #[derive(Accounts)] 24 | pub struct UpdateUser<'info> { 25 | user: AccountInfo<'info>, 26 | authority: Signer<'info>, 27 | } 28 | 29 | #[derive(BorshSerialize, BorshDeserialize)] 30 | pub struct User { 31 | authority: Pubkey, 32 | } 33 | 34 | #[derive(BorshSerialize, BorshDeserialize)] 35 | pub struct Metadata { 36 | account: Pubkey, 37 | } 38 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "type-cosplay-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "type_cosplay_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use borsh::{BorshDeserialize, BorshSerialize}; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod type_cosplay_recommended { 8 | use super::*; 9 | 10 | pub fn update_user(ctx: Context) -> ProgramResult { 11 | msg!("GM {}", ctx.accounts.user.authority); 12 | Ok(()) 13 | } 14 | } 15 | 16 | #[derive(Accounts)] 17 | pub struct UpdateUser<'info> { 18 | #[account(has_one = authority)] 19 | user: Account<'info, User>, 20 | authority: Signer<'info>, 21 | } 22 | 23 | #[account] 24 | pub struct User { 25 | authority: Pubkey, 26 | } 27 | 28 | #[account] 29 | pub struct Metadata { 30 | account: Pubkey, 31 | } 32 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "type-cosplay-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "type_cosplay_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/3-type-cosplay/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use borsh::{BorshDeserialize, BorshSerialize}; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod type_cosplay_secure { 8 | use super::*; 9 | 10 | pub fn update_user(ctx: Context) -> ProgramResult { 11 | let user = User::try_from_slice(&ctx.accounts.user.data.borrow()).unwrap(); 12 | if ctx.accounts.user.owner != ctx.program_id { 13 | return Err(ProgramError::IllegalOwner); 14 | } 15 | if user.authority != ctx.accounts.authority.key() { 16 | return Err(ProgramError::InvalidAccountData); 17 | } 18 | if user.discriminant != AccountDiscriminant::User { 19 | return Err(ProgramError::InvalidAccountData); 20 | } 21 | msg!("GM {}", user.authority); 22 | Ok(()) 23 | } 24 | } 25 | 26 | #[derive(Accounts)] 27 | pub struct UpdateUser<'info> { 28 | user: AccountInfo<'info>, 29 | authority: Signer<'info>, 30 | } 31 | 32 | #[derive(BorshSerialize, BorshDeserialize)] 33 | pub struct User { 34 | discriminant: AccountDiscriminant, 35 | authority: Pubkey, 36 | } 37 | 38 | #[derive(BorshSerialize, BorshDeserialize)] 39 | pub struct Metadata { 40 | discriminant: AccountDiscriminant, 41 | account: Pubkey, 42 | } 43 | 44 | #[derive(BorshSerialize, BorshDeserialize, PartialEq)] 45 | pub enum AccountDiscriminant { 46 | User, 47 | Metadata, 48 | } 49 | -------------------------------------------------------------------------------- /programs/4-initialization/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "initialization-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "initialization_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/4-initialization/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/4-initialization/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use borsh::{BorshDeserialize, BorshSerialize}; 3 | use std::ops::DerefMut; 4 | 5 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 6 | 7 | #[program] 8 | pub mod initialization_insecure { 9 | use super::*; 10 | 11 | pub fn initialize(ctx: Context) -> ProgramResult { 12 | let mut user = User::try_from_slice(&ctx.accounts.user.data.borrow()).unwrap(); 13 | 14 | user.authority = ctx.accounts.authority.key(); 15 | 16 | let mut storage = ctx.accounts.user.try_borrow_mut_data()?; 17 | user.serialize(storage.deref_mut()).unwrap(); 18 | Ok(()) 19 | } 20 | } 21 | 22 | /* 23 | - reinitialize 24 | - create and dont initialize 25 | - passing previously initialzed accounts from other programs 26 | (e.g. token program => need to check delegate and authority) 27 | */ 28 | 29 | #[derive(Accounts)] 30 | pub struct Initialize<'info> { 31 | user: AccountInfo<'info>, 32 | authority: Signer<'info>, 33 | } 34 | 35 | #[derive(BorshSerialize, BorshDeserialize)] 36 | pub struct User { 37 | authority: Pubkey, 38 | } 39 | -------------------------------------------------------------------------------- /programs/4-initialization/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "reinitialization-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "reinitialization_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/4-initialization/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/4-initialization/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod reinitialization_4 { 7 | use super::*; 8 | 9 | pub fn init(_ctx: Context) -> ProgramResult { 10 | msg!("GM"); 11 | Ok(()) 12 | } 13 | } 14 | 15 | 16 | #[derive(Accounts)] 17 | pub struct Init<'info> { 18 | #[account(init, payer = authority, space = 8+32)] 19 | user: Account<'info, User>, 20 | #[account(mut)] 21 | authority: Signer<'info>, 22 | system_program: Program<'info, System>, 23 | } 24 | 25 | #[account] 26 | pub struct User { 27 | authority: Pubkey, 28 | } 29 | -------------------------------------------------------------------------------- /programs/4-initialization/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "reinitialization-secure-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "reinitialization_secure_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/4-initialization/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/4-initialization/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use borsh::{BorshDeserialize, BorshSerialize}; 3 | use std::ops::DerefMut; 4 | 5 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 6 | 7 | #[program] 8 | pub mod reinitialization_secure_recommended { 9 | use super::*; 10 | 11 | pub fn initialize(ctx: Context) -> ProgramResult { 12 | let mut user = User::try_from_slice(&ctx.accounts.user.data.borrow()).unwrap(); 13 | if !user.discriminator { 14 | return Err(ProgramError::InvalidAccountData); 15 | } 16 | 17 | user.authority = ctx.accounts.authority.key(); 18 | user.discriminator = true; 19 | 20 | let mut storage = ctx.accounts.user.try_borrow_mut_data()?; 21 | user.serialize(storage.deref_mut()).unwrap(); 22 | 23 | msg!("GM"); 24 | Ok(()) 25 | } 26 | } 27 | 28 | #[derive(Accounts)] 29 | pub struct Initialize<'info> { 30 | user: AccountInfo<'info>, 31 | authority: Signer<'info>, 32 | } 33 | 34 | #[derive(BorshSerialize, BorshDeserialize)] 35 | pub struct User { 36 | discriminator: bool, 37 | authority: Pubkey, 38 | } 39 | -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "arbitrary-cpi-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "arbitrary_cpi_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = { version = "3.1.1", features = ["no-entrypoint"] } -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_lang::solana_program; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod arbitrary_cpi_insecure { 8 | use super::*; 9 | 10 | pub fn cpi(ctx: Context, amount: u64) -> ProgramResult { 11 | solana_program::program::invoke( 12 | &spl_token::instruction::transfer( 13 | ctx.accounts.token_program.key, 14 | ctx.accounts.source.key, 15 | ctx.accounts.destination.key, 16 | ctx.accounts.authority.key, 17 | &[], 18 | amount, 19 | )?, 20 | &[ 21 | ctx.accounts.source.clone(), 22 | ctx.accounts.destination.clone(), 23 | ctx.accounts.authority.clone(), 24 | ], 25 | ) 26 | } 27 | } 28 | 29 | #[derive(Accounts)] 30 | pub struct Cpi<'info> { 31 | source: AccountInfo<'info>, 32 | destination: AccountInfo<'info>, 33 | authority: AccountInfo<'info>, 34 | token_program: AccountInfo<'info>, 35 | } 36 | -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "arbitrary-cpi-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "arbitrary_cpi_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = { version = "3.1.1", features = ["no-entrypoint"] } -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_spl::token::{self, Token, TokenAccount}; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod arbitrary_cpi_recommended { 8 | use super::*; 9 | 10 | pub fn cpi(ctx: Context, amount: u64) -> ProgramResult { 11 | token::transfer(ctx.accounts.transfer_ctx(), amount) 12 | } 13 | } 14 | 15 | #[derive(Accounts)] 16 | pub struct Cpi<'info> { 17 | source: Account<'info, TokenAccount>, 18 | destination: Account<'info, TokenAccount>, 19 | authority: Signer<'info>, 20 | token_program: Program<'info, Token>, 21 | } 22 | 23 | impl<'info> Cpi<'info> { 24 | pub fn transfer_ctx(&self) -> CpiContext<'_, '_, '_, 'info, token::Transfer<'info>> { 25 | let program = self.token_program.to_account_info(); 26 | let accounts = token::Transfer { 27 | from: self.source.to_account_info(), 28 | to: self.destination.to_account_info(), 29 | authority: self.authority.to_account_info(), 30 | }; 31 | CpiContext::new(program, accounts) 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "arbitrary-cpi-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "arbitrary_cpi_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | spl-token = { version = "3.1.1", features = ["no-entrypoint"] } 22 | -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/5-arbitrary-cpi/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_lang::solana_program; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod arbitrary_cpi_secure { 8 | use super::*; 9 | 10 | pub fn cpi_secure(ctx: Context, amount: u64) -> ProgramResult { 11 | if &spl_token::ID != ctx.accounts.token_program.key { 12 | return Err(ProgramError::IncorrectProgramId); 13 | } 14 | solana_program::program::invoke( 15 | &spl_token::instruction::transfer( 16 | ctx.accounts.token_program.key, 17 | ctx.accounts.source.key, 18 | ctx.accounts.destination.key, 19 | ctx.accounts.authority.key, 20 | &[], 21 | amount, 22 | )?, 23 | &[ 24 | ctx.accounts.source.clone(), 25 | ctx.accounts.destination.clone(), 26 | ctx.accounts.authority.clone(), 27 | ], 28 | ) 29 | } 30 | } 31 | 32 | #[derive(Accounts)] 33 | pub struct Cpi<'info> { 34 | source: AccountInfo<'info>, 35 | destination: AccountInfo<'info>, 36 | authority: AccountInfo<'info>, 37 | token_program: AccountInfo<'info>, 38 | } 39 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "duplicate-mutable-accounts-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "duplicate_mutable_accounts_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod duplicate_mutable_accounts_insecure { 7 | use super::*; 8 | 9 | pub fn update(ctx: Context, a: u64, b: u64) -> ProgramResult { 10 | let user_a = &mut ctx.accounts.user_a; 11 | let user_b = &mut ctx.accounts.user_b; 12 | 13 | user_a.data = a; 14 | user_b.data = b; 15 | Ok(()) 16 | } 17 | } 18 | 19 | #[derive(Accounts)] 20 | pub struct Update<'info> { 21 | user_a: Account<'info, User>, 22 | user_b: Account<'info, User>, 23 | } 24 | 25 | #[account] 26 | pub struct User { 27 | data: u64, 28 | } 29 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "duplicate-mutable-accounts-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "duplicate_mutable_accounts_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod duplicate_mutable_accounts_recommended { 7 | use super::*; 8 | 9 | pub fn update(ctx: Context, a: u64, b: u64) -> ProgramResult { 10 | let user_a = &mut ctx.accounts.user_a; 11 | let user_b = &mut ctx.accounts.user_b; 12 | 13 | user_a.data = a; 14 | user_b.data = b; 15 | Ok(()) 16 | } 17 | } 18 | 19 | #[derive(Accounts)] 20 | pub struct Update<'info> { 21 | #[account(constraint = user_a.key() != user_b.key())] 22 | user_a: Account<'info, User>, 23 | user_b: Account<'info, User>, 24 | } 25 | 26 | #[account] 27 | pub struct User { 28 | data: u64, 29 | } 30 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "duplicate-mutable-accounts-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "duplicate_mutable_accounts_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/6-duplicate-mutable-accounts/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod duplicate_mutable_accounts_secure { 7 | use super::*; 8 | 9 | pub fn update(ctx: Context, a: u64, b: u64) -> ProgramResult { 10 | if ctx.accounts.user_a.key() == ctx.accounts.user_b.key() { 11 | return Err(ProgramError::InvalidArgument) 12 | } 13 | let user_a = &mut ctx.accounts.user_a; 14 | let user_b = &mut ctx.accounts.user_b; 15 | 16 | user_a.data = a; 17 | user_b.data = b; 18 | Ok(()) 19 | } 20 | } 21 | 22 | #[derive(Accounts)] 23 | pub struct Update<'info> { 24 | user_a: Account<'info, User>, 25 | user_b: Account<'info, User>, 26 | } 27 | 28 | #[account] 29 | pub struct User { 30 | data: u64, 31 | } 32 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "bump-seed-canonicalization-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "bump_seed_canonicalization_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod bump_seed_canonicalization_insecure { 7 | use super::*; 8 | 9 | pub fn set_value(ctx: Context, key: u64, new_value: u64, bump: u8) -> ProgramResult { 10 | let address = 11 | Pubkey::create_program_address(&[key.to_le_bytes().as_ref(), &[bump]], ctx.program_id)?; 12 | if address != ctx.accounts.data.key() { 13 | return Err(ProgramError::InvalidArgument); 14 | } 15 | 16 | ctx.accounts.data.value = new_value; 17 | 18 | Ok(()) 19 | } 20 | } 21 | 22 | #[derive(Accounts)] 23 | pub struct BumpSeed<'info> { 24 | data: Account<'info, Data>, 25 | } 26 | 27 | #[account] 28 | pub struct Data { 29 | value: u64, 30 | } 31 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "bump-seed-canonicalization-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "bump_seed_canonicalization_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod bump_seed_canonicalization_recommended { 7 | use super::*; 8 | 9 | pub fn set_value(ctx: Context, key: u64, new_value: u64) -> ProgramResult { 10 | ctx.accounts.data.value = new_value; 11 | Ok(()) 12 | } 13 | } 14 | 15 | #[derive(Accounts)] 16 | #[instruction(key: u64)] 17 | pub struct BumpSeed<'info> { 18 | // Note a subtle pattern that is not displayed here. 19 | // 20 | // Usually, the usage of PDAs is broken into two parts: 21 | // 22 | // 1) allocation via `#[account(init, seeds = [...], bump)]` 23 | // 2) using the account via `#[account(init, seeds = [...], bump = data.bump)] 24 | // 25 | // When using a PDA, it's usually recommend to store the bump seed in the 26 | // account data, so that you can use it as demonstrated in 2), which will 27 | // provide a more efficient check. 28 | #[account(seeds = [key.to_le_bytes().as_ref()], bump)] 29 | data: Account<'info, Data>, 30 | } 31 | 32 | #[account] 33 | pub struct Data { 34 | value: u64, 35 | } 36 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "bump-seed-canonicalization-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "bump_seed_canonicalization_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/7-bump-seed-canonicalization/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod bump_seed_canonicalization_secure { 7 | use super::*; 8 | 9 | pub fn set_value_secure( 10 | ctx: Context, 11 | key: u64, 12 | new_value: u64, 13 | bump: u8, 14 | ) -> ProgramResult { 15 | let (address, expected_bump) = 16 | Pubkey::find_program_address(&[key.to_le_bytes().as_ref()], ctx.program_id); 17 | 18 | if address != ctx.accounts.data.key() { 19 | return Err(ProgramError::InvalidArgument); 20 | } 21 | if expected_bump != bump { 22 | return Err(ProgramError::InvalidArgument); 23 | } 24 | 25 | ctx.accounts.data.value = new_value; 26 | Ok(()) 27 | } 28 | } 29 | 30 | #[derive(Accounts)] 31 | pub struct BumpSeed<'info> { 32 | data: Account<'info, Data>, 33 | } 34 | 35 | #[account] 36 | pub struct Data { 37 | value: u64, 38 | } 39 | -------------------------------------------------------------------------------- /programs/8-pda-sharing/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "pda-sharing-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "pda_sharing_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" -------------------------------------------------------------------------------- /programs/8-pda-sharing/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/8-pda-sharing/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_spl::token::{self, Token, TokenAccount}; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod pda_sharing_insecure { 8 | use super::*; 9 | 10 | pub fn withdraw_tokens(ctx: Context) -> ProgramResult { 11 | let amount = ctx.accounts.vault.amount; 12 | let seeds = &[ctx.accounts.pool.mint.as_ref(), &[ctx.accounts.pool.bump]]; 13 | token::transfer(ctx.accounts.transfer_ctx().with_signer(&[seeds]), amount) 14 | } 15 | } 16 | 17 | #[derive(Accounts)] 18 | pub struct WithdrawTokens<'info> { 19 | #[account(has_one = vault, has_one = withdraw_destination)] 20 | pool: Account<'info, TokenPool>, 21 | vault: Account<'info, TokenAccount>, 22 | withdraw_destination: Account<'info, TokenAccount>, 23 | authority: Signer<'info>, 24 | token_program: Program<'info, Token>, 25 | } 26 | 27 | impl<'info> WithdrawTokens<'info> { 28 | pub fn transfer_ctx(&self) -> CpiContext<'_, '_, '_, 'info, token::Transfer<'info>> { 29 | let program = self.token_program.to_account_info(); 30 | let accounts = token::Transfer { 31 | from: self.vault.to_account_info(), 32 | to: self.withdraw_destination.to_account_info(), 33 | authority: self.authority.to_account_info(), 34 | }; 35 | CpiContext::new(program, accounts) 36 | } 37 | } 38 | 39 | #[account] 40 | pub struct TokenPool { 41 | vault: Pubkey, 42 | mint: Pubkey, 43 | withdraw_destination: Pubkey, 44 | bump: u8, 45 | } 46 | -------------------------------------------------------------------------------- /programs/8-pda-sharing/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "pda-sharing-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "pda_sharing_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" -------------------------------------------------------------------------------- /programs/8-pda-sharing/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/8-pda-sharing/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_spl::token::{self, Token, TokenAccount}; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod pda_sharing_recommended { 8 | use super::*; 9 | 10 | pub fn withdraw_tokens(ctx: Context) -> ProgramResult { 11 | let amount = ctx.accounts.vault.amount; 12 | let seeds = &[ 13 | ctx.accounts.pool.withdraw_destination.as_ref(), 14 | &[ctx.accounts.pool.bump], 15 | ]; 16 | token::transfer(ctx.accounts.transfer_ctx().with_signer(&[seeds]), amount) 17 | } 18 | } 19 | 20 | #[derive(Accounts)] 21 | pub struct WithdrawTokens<'info> { 22 | #[account( 23 | has_one = vault, 24 | has_one = withdraw_destination, 25 | seeds = [withdraw_destination.key().as_ref()], 26 | bump = pool.bump, 27 | )] 28 | pool: Account<'info, TokenPool>, 29 | vault: Account<'info, TokenAccount>, 30 | withdraw_destination: Account<'info, TokenAccount>, 31 | authority: Signer<'info>, 32 | token_program: Program<'info, Token>, 33 | } 34 | 35 | impl<'info> WithdrawTokens<'info> { 36 | pub fn transfer_ctx(&self) -> CpiContext<'_, '_, '_, 'info, token::Transfer<'info>> { 37 | let program = self.token_program.to_account_info(); 38 | let accounts = token::Transfer { 39 | from: self.vault.to_account_info(), 40 | to: self.withdraw_destination.to_account_info(), 41 | authority: self.authority.to_account_info(), 42 | }; 43 | CpiContext::new(program, accounts) 44 | } 45 | } 46 | 47 | #[account] 48 | pub struct TokenPool { 49 | vault: Pubkey, 50 | mint: Pubkey, 51 | withdraw_destination: Pubkey, 52 | bump: u8, 53 | } 54 | -------------------------------------------------------------------------------- /programs/8-pda-sharing/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "pda-sharing-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "pda_sharing_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | anchor-spl = "0.20.1" 21 | -------------------------------------------------------------------------------- /programs/8-pda-sharing/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/8-pda-sharing/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use anchor_spl::token::{self, Token, TokenAccount}; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod pda_sharing_secure { 8 | use super::*; 9 | 10 | pub fn withdraw_tokens(ctx: Context) -> ProgramResult { 11 | let amount = ctx.accounts.vault.amount; 12 | let seeds = &[ 13 | ctx.accounts.pool.withdraw_destination.as_ref(), 14 | &[ctx.accounts.pool.bump], 15 | ]; 16 | token::transfer(ctx.accounts.transfer_ctx().with_signer(&[seeds]), amount) 17 | } 18 | } 19 | 20 | #[derive(Accounts)] 21 | pub struct WithdrawTokens<'info> { 22 | #[account(has_one = vault, has_one = withdraw_destination)] 23 | pool: Account<'info, TokenPool>, 24 | vault: Account<'info, TokenAccount>, 25 | withdraw_destination: Account<'info, TokenAccount>, 26 | authority: Signer<'info>, 27 | token_program: Program<'info, Token>, 28 | } 29 | 30 | impl<'info> WithdrawTokens<'info> { 31 | pub fn transfer_ctx(&self) -> CpiContext<'_, '_, '_, 'info, token::Transfer<'info>> { 32 | let program = self.token_program.to_account_info(); 33 | let accounts = token::Transfer { 34 | from: self.vault.to_account_info(), 35 | to: self.withdraw_destination.to_account_info(), 36 | authority: self.authority.to_account_info(), 37 | }; 38 | CpiContext::new(program, accounts) 39 | } 40 | } 41 | 42 | #[account] 43 | pub struct TokenPool { 44 | vault: Pubkey, 45 | mint: Pubkey, 46 | withdraw_destination: Pubkey, 47 | bump: u8, 48 | } 49 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure-still-still/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "closing-accounts-insecure-still-still" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "closing_accounts_insecure_still" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure-still-still/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure-still-still/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use std::io::Write; 3 | use std::ops::DerefMut; 4 | 5 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 6 | 7 | #[program] 8 | pub mod closing_accounts_insecure_still_still { 9 | use super::*; 10 | 11 | pub fn close(ctx: Context) -> ProgramResult { 12 | let account = ctx.accounts.account.to_account_info(); 13 | 14 | let dest_starting_lamports = ctx.accounts.destination.lamports(); 15 | 16 | **ctx.accounts.destination.lamports.borrow_mut() = dest_starting_lamports 17 | .checked_add(account.lamports()) 18 | .unwrap(); 19 | **account.lamports.borrow_mut() = 0; 20 | 21 | let mut data = account.try_borrow_mut_data()?; 22 | for byte in data.deref_mut().iter_mut() { 23 | *byte = 0; 24 | } 25 | 26 | let dst: &mut [u8] = &mut data; 27 | let mut cursor = std::io::Cursor::new(dst); 28 | cursor 29 | .write_all(&anchor_lang::__private::CLOSED_ACCOUNT_DISCRIMINATOR) 30 | .unwrap(); 31 | 32 | Ok(()) 33 | } 34 | } 35 | 36 | #[derive(Accounts)] 37 | pub struct Close<'info> { 38 | account: Account<'info, Data>, 39 | destination: AccountInfo<'info>, 40 | } 41 | 42 | #[account] 43 | pub struct Data { 44 | data: u64, 45 | } 46 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure-still/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "closing-accounts-insecure-still" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "closing_accounts_insecure_still" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure-still/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure-still/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | use std::ops::DerefMut; 3 | 4 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 5 | 6 | #[program] 7 | pub mod closing_accounts_insecure_still { 8 | use super::*; 9 | 10 | pub fn close(ctx: Context) -> ProgramResult { 11 | let account = ctx.accounts.account.to_account_info(); 12 | 13 | let dest_starting_lamports = ctx.accounts.destination.lamports(); 14 | 15 | **ctx.accounts.destination.lamports.borrow_mut() = dest_starting_lamports 16 | .checked_add(account.lamports()) 17 | .unwrap(); 18 | **account.lamports.borrow_mut() = 0; 19 | 20 | let mut data = account.try_borrow_mut_data()?; 21 | for byte in data.deref_mut().iter_mut() { 22 | *byte = 0; 23 | } 24 | 25 | Ok(()) 26 | } 27 | } 28 | 29 | #[derive(Accounts)] 30 | pub struct Initialize<'info> { 31 | #[account(zero)] 32 | account: Account<'info, Data>, 33 | authority: Signer<'info>, 34 | } 35 | 36 | #[derive(Accounts)] 37 | pub struct Close<'info> { 38 | account: Account<'info, Data>, 39 | destination: AccountInfo<'info>, 40 | } 41 | 42 | #[account] 43 | pub struct Data { 44 | data: u64, 45 | } 46 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "closing-accounts-insecure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "closing_accounts_insecure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/insecure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod closing_accounts_insecure { 7 | use super::*; 8 | 9 | pub fn close(ctx: Context) -> ProgramResult { 10 | let dest_starting_lamports = ctx.accounts.destination.lamports(); 11 | 12 | **ctx.accounts.destination.lamports.borrow_mut() = dest_starting_lamports 13 | .checked_add(ctx.accounts.account.to_account_info().lamports()) 14 | .unwrap(); 15 | **ctx.accounts.account.to_account_info().lamports.borrow_mut() = 0; 16 | 17 | Ok(()) 18 | } 19 | } 20 | 21 | #[derive(Accounts)] 22 | pub struct Close<'info> { 23 | account: Account<'info, Data>, 24 | destination: AccountInfo<'info>, 25 | } 26 | 27 | #[account] 28 | pub struct Data { 29 | data: u64, 30 | } 31 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/recommended/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "closing-accounts-recommended" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "closing_accounts_recommended" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/recommended/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/recommended/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::prelude::*; 2 | 3 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 4 | 5 | #[program] 6 | pub mod closing_accounts_recommended { 7 | use super::*; 8 | 9 | pub fn close(ctx: Context) -> ProgramResult { 10 | Ok(()) 11 | } 12 | } 13 | 14 | #[derive(Accounts)] 15 | pub struct Close<'info> { 16 | #[account(mut, close = destination)] 17 | account: Account<'info, Data>, 18 | #[account(mut)] 19 | destination: AccountInfo<'info>, 20 | } 21 | 22 | #[account] 23 | pub struct Data { 24 | data: u64, 25 | } 26 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/secure/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "closing-accounts-secure" 3 | version = "0.1.0" 4 | description = "Created with Anchor" 5 | edition = "2018" 6 | 7 | [lib] 8 | crate-type = ["cdylib", "lib"] 9 | name = "closing_accounts_secure" 10 | 11 | [features] 12 | no-entrypoint = [] 13 | no-idl = [] 14 | no-log-ix-name = [] 15 | cpi = ["no-entrypoint"] 16 | default = [] 17 | 18 | [dependencies] 19 | anchor-lang = "0.20.1" 20 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/secure/Xargo.toml: -------------------------------------------------------------------------------- 1 | [target.bpfel-unknown-unknown.dependencies.std] 2 | features = [] 3 | -------------------------------------------------------------------------------- /programs/9-closing-accounts/secure/src/lib.rs: -------------------------------------------------------------------------------- 1 | use anchor_lang::__private::CLOSED_ACCOUNT_DISCRIMINATOR; 2 | use anchor_lang::prelude::*; 3 | use std::io::{Cursor, Write}; 4 | use std::ops::DerefMut; 5 | 6 | declare_id!("Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS"); 7 | 8 | #[program] 9 | pub mod closing_accounts_secure { 10 | use super::*; 11 | 12 | pub fn close(ctx: Context) -> ProgramResult { 13 | let dest_starting_lamports = ctx.accounts.destination.lamports(); 14 | 15 | let account = ctx.accounts.account.to_account_info(); 16 | **ctx.accounts.destination.lamports.borrow_mut() = dest_starting_lamports 17 | .checked_add(account.lamports()) 18 | .unwrap(); 19 | **account.lamports.borrow_mut() = 0; 20 | 21 | let mut data = account.try_borrow_mut_data()?; 22 | for byte in data.deref_mut().iter_mut() { 23 | *byte = 0; 24 | } 25 | 26 | let dst: &mut [u8] = &mut data; 27 | let mut cursor = Cursor::new(dst); 28 | cursor.write_all(&CLOSED_ACCOUNT_DISCRIMINATOR).unwrap(); 29 | 30 | Ok(()) 31 | } 32 | 33 | pub fn force_defund(ctx: Context) -> ProgramResult { 34 | let account = &ctx.accounts.account; 35 | 36 | let data = account.try_borrow_data()?; 37 | assert!(data.len() > 8); 38 | 39 | let mut discriminator = [0u8; 8]; 40 | discriminator.copy_from_slice(&data[0..8]); 41 | if discriminator != CLOSED_ACCOUNT_DISCRIMINATOR { 42 | return Err(ProgramError::InvalidAccountData); 43 | } 44 | 45 | let dest_starting_lamports = ctx.accounts.destination.lamports(); 46 | 47 | **ctx.accounts.destination.lamports.borrow_mut() = dest_starting_lamports 48 | .checked_add(account.lamports()) 49 | .unwrap(); 50 | **account.lamports.borrow_mut() = 0; 51 | 52 | Ok(()) 53 | } 54 | } 55 | 56 | #[derive(Accounts)] 57 | pub struct Close<'info> { 58 | account: Account<'info, Data>, 59 | destination: AccountInfo<'info>, 60 | } 61 | 62 | #[derive(Accounts)] 63 | pub struct ForceDefund<'info> { 64 | account: AccountInfo<'info>, 65 | destination: AccountInfo<'info>, 66 | } 67 | 68 | #[account] 69 | pub struct Data { 70 | data: u64, 71 | } 72 | -------------------------------------------------------------------------------- /tests/raw.ts: -------------------------------------------------------------------------------- 1 | import * as anchor from '@project-serum/anchor'; 2 | import { Program } from '@project-serum/anchor'; 3 | import { Raw } from '../target/types/raw'; 4 | 5 | describe('raw', () => { 6 | // Configure the client to use the local cluster. 7 | anchor.setProvider(anchor.Provider.env()); 8 | 9 | const program = anchor.workspace.Raw as Program; 10 | 11 | it('Is initialized!', async () => { 12 | 13 | }); 14 | }); 15 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "types": ["mocha", "chai"], 4 | "typeRoots": ["./node_modules/@types"], 5 | "lib": ["es2015"], 6 | "module": "commonjs", 7 | "target": "es6", 8 | "esModuleInterop": true 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /yarn.lock: -------------------------------------------------------------------------------- 1 | # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. 2 | # yarn lockfile v1 3 | 4 | 5 | "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.5": 6 | version "7.16.7" 7 | resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.16.7.tgz#03ff99f64106588c9c403c6ecb8c3bafbbdff1fa" 8 | integrity sha512-9E9FJowqAsytyOY6LG+1KuueckRL+aQW+mKvXRXnuFGyRAyepJPmEo9vgMfXUA6O9u3IeEdv9MAkppFcaQwogQ== 9 | dependencies: 10 | regenerator-runtime "^0.13.4" 11 | 12 | "@ethersproject/bytes@^5.5.0": 13 | version "5.5.0" 14 | resolved "https://registry.yarnpkg.com/@ethersproject/bytes/-/bytes-5.5.0.tgz#cb11c526de657e7b45d2e0f0246fb3b9d29a601c" 15 | integrity sha512-ABvc7BHWhZU9PNM/tANm/Qx4ostPGadAuQzWTr3doklZOhDlmcBqclrQe/ZXUIj3K8wC28oYeuRa+A37tX9kog== 16 | dependencies: 17 | "@ethersproject/logger" "^5.5.0" 18 | 19 | "@ethersproject/logger@^5.5.0": 20 | version "5.5.0" 21 | resolved "https://registry.yarnpkg.com/@ethersproject/logger/-/logger-5.5.0.tgz#0c2caebeff98e10aefa5aef27d7441c7fd18cf5d" 22 | integrity sha512-rIY/6WPm7T8n3qS2vuHTUBPdXHl+rGxWxW5okDfo9J4Z0+gRRZT0msvUdIJkE4/HS29GUMziwGaaKO2bWONBrg== 23 | 24 | "@ethersproject/sha2@^5.5.0": 25 | version "5.5.0" 26 | resolved "https://registry.yarnpkg.com/@ethersproject/sha2/-/sha2-5.5.0.tgz#a40a054c61f98fd9eee99af2c3cc6ff57ec24db7" 27 | integrity sha512-B5UBoglbCiHamRVPLA110J+2uqsifpZaTmid2/7W5rbtYVz6gus6/hSDieIU/6gaKIDcOj12WnOdiymEUHIAOA== 28 | dependencies: 29 | "@ethersproject/bytes" "^5.5.0" 30 | "@ethersproject/logger" "^5.5.0" 31 | hash.js "1.1.7" 32 | 33 | "@project-serum/anchor@^0.20.0": 34 | version "0.20.1" 35 | resolved "https://registry.yarnpkg.com/@project-serum/anchor/-/anchor-0.20.1.tgz#0937807e807e8332aa708cfef4bcb6cbb88b4129" 36 | integrity sha512-2TuBmGUn9qeYz6sJINJlElrBuPsaUAtYyUsJ3XplEBf1pczrANAgs5ceJUFzdiqGEWLn+84ObSdBeChT/AXYFA== 37 | dependencies: 38 | "@project-serum/borsh" "^0.2.2" 39 | "@solana/web3.js" "^1.17.0" 40 | base64-js "^1.5.1" 41 | bn.js "^5.1.2" 42 | bs58 "^4.0.1" 43 | buffer-layout "^1.2.2" 44 | camelcase "^5.3.1" 45 | crypto-hash "^1.3.0" 46 | eventemitter3 "^4.0.7" 47 | find "^0.3.0" 48 | js-sha256 "^0.9.0" 49 | pako "^2.0.3" 50 | snake-case "^3.0.4" 51 | toml "^3.0.0" 52 | 53 | "@project-serum/borsh@^0.2.2": 54 | version "0.2.3" 55 | resolved "https://registry.yarnpkg.com/@project-serum/borsh/-/borsh-0.2.3.tgz#1d705c5887484cb6a127dd5feff58e90cbfcb558" 56 | integrity sha512-lH9zEYADZE3cxrgiFym8+jbUE3NM/LH+WOKYcUjs65CT10Q64Hv45bcAAa/phwYk4Tpz0uQ1x+ergFaAoGt67Q== 57 | dependencies: 58 | bn.js "^5.1.2" 59 | buffer-layout "^1.2.0" 60 | 61 | "@solana/buffer-layout@^3.0.0": 62 | version "3.0.0" 63 | resolved "https://registry.yarnpkg.com/@solana/buffer-layout/-/buffer-layout-3.0.0.tgz#b9353caeb9a1589cb77a1b145bcb1a9a93114326" 64 | integrity sha512-MVdgAKKL39tEs0l8je0hKaXLQFb7Rdfb0Xg2LjFZd8Lfdazkg6xiS98uAZrEKvaoF3i4M95ei9RydkGIDMeo3w== 65 | dependencies: 66 | buffer "~6.0.3" 67 | 68 | "@solana/web3.js@^1.17.0": 69 | version "1.31.0" 70 | resolved "https://registry.yarnpkg.com/@solana/web3.js/-/web3.js-1.31.0.tgz#7a313d4c1a90b77f27ddbfe845a10d6883e06452" 71 | integrity sha512-7nHHx1JNFnrt15e9y8m38I/EJCbaB+bFC3KZVM1+QhybCikFxGMtGA5r7PDC3GEL1R2RZA8yKoLkDKo3vzzqnw== 72 | dependencies: 73 | "@babel/runtime" "^7.12.5" 74 | "@ethersproject/sha2" "^5.5.0" 75 | "@solana/buffer-layout" "^3.0.0" 76 | bn.js "^5.0.0" 77 | borsh "^0.4.0" 78 | bs58 "^4.0.1" 79 | buffer "6.0.1" 80 | cross-fetch "^3.1.4" 81 | jayson "^3.4.4" 82 | js-sha3 "^0.8.0" 83 | rpc-websockets "^7.4.2" 84 | secp256k1 "^4.0.2" 85 | superstruct "^0.14.2" 86 | tweetnacl "^1.0.0" 87 | 88 | "@types/bn.js@^4.11.5": 89 | version "4.11.6" 90 | resolved "https://registry.yarnpkg.com/@types/bn.js/-/bn.js-4.11.6.tgz#c306c70d9358aaea33cd4eda092a742b9505967c" 91 | integrity sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg== 92 | dependencies: 93 | "@types/node" "*" 94 | 95 | "@types/connect@^3.4.33": 96 | version "3.4.35" 97 | resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.35.tgz#5fcf6ae445e4021d1fc2219a4873cc73a3bb2ad1" 98 | integrity sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ== 99 | dependencies: 100 | "@types/node" "*" 101 | 102 | "@types/express-serve-static-core@^4.17.9": 103 | version "4.17.27" 104 | resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.17.27.tgz#7a776191e47295d2a05962ecbb3a4ce97e38b401" 105 | integrity sha512-e/sVallzUTPdyOTiqi8O8pMdBBphscvI6E4JYaKlja4Lm+zh7UFSSdW5VMkRbhDtmrONqOUHOXRguPsDckzxNA== 106 | dependencies: 107 | "@types/node" "*" 108 | "@types/qs" "*" 109 | "@types/range-parser" "*" 110 | 111 | "@types/json5@^0.0.29": 112 | version "0.0.29" 113 | resolved "https://registry.yarnpkg.com/@types/json5/-/json5-0.0.29.tgz#ee28707ae94e11d2b827bcbe5270bcea7f3e71ee" 114 | integrity sha1-7ihweulOEdK4J7y+UnC86n8+ce4= 115 | 116 | "@types/lodash@^4.14.159": 117 | version "4.14.178" 118 | resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.178.tgz#341f6d2247db528d4a13ddbb374bcdc80406f4f8" 119 | integrity sha512-0d5Wd09ItQWH1qFbEyQ7oTQ3GZrMfth5JkbN3EvTKLXcHLRDSXeLnlvlOn0wvxVIwK5o2M8JzP/OWz7T3NRsbw== 120 | 121 | "@types/mocha@^9.0.0": 122 | version "9.0.0" 123 | resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-9.0.0.tgz#3205bcd15ada9bc681ac20bef64e9e6df88fd297" 124 | integrity sha512-scN0hAWyLVAvLR9AyW7HoFF5sJZglyBsbPuHO4fv7JRvfmPBMfp1ozWqOf/e4wwPNxezBZXRfWzMb6iFLgEVRA== 125 | 126 | "@types/node@*": 127 | version "17.0.8" 128 | resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.8.tgz#50d680c8a8a78fe30abe6906453b21ad8ab0ad7b" 129 | integrity sha512-YofkM6fGv4gDJq78g4j0mMuGMkZVxZDgtU0JRdx6FgiJDG+0fY0GKVolOV8WqVmEhLCXkQRjwDdKyPxJp/uucg== 130 | 131 | "@types/node@^12.12.54": 132 | version "12.20.41" 133 | resolved "https://registry.yarnpkg.com/@types/node/-/node-12.20.41.tgz#81d7734c5257da9f04354bd9084a6ebbdd5198a5" 134 | integrity sha512-f6xOqucbDirG7LOzedpvzjP3UTmHttRou3Mosx3vL9wr9AIQGhcPgVnqa8ihpZYnxyM1rxeNCvTyukPKZtq10Q== 135 | 136 | "@types/qs@*": 137 | version "6.9.7" 138 | resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.7.tgz#63bb7d067db107cc1e457c303bc25d511febf6cb" 139 | integrity sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw== 140 | 141 | "@types/range-parser@*": 142 | version "1.2.4" 143 | resolved "https://registry.yarnpkg.com/@types/range-parser/-/range-parser-1.2.4.tgz#cd667bcfdd025213aafb7ca5915a932590acdcdc" 144 | integrity sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw== 145 | 146 | "@types/ws@^7.4.4": 147 | version "7.4.7" 148 | resolved "https://registry.yarnpkg.com/@types/ws/-/ws-7.4.7.tgz#f7c390a36f7a0679aa69de2d501319f4f8d9b702" 149 | integrity sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww== 150 | dependencies: 151 | "@types/node" "*" 152 | 153 | "@ungap/promise-all-settled@1.1.2": 154 | version "1.1.2" 155 | resolved "https://registry.yarnpkg.com/@ungap/promise-all-settled/-/promise-all-settled-1.1.2.tgz#aa58042711d6e3275dd37dc597e5d31e8c290a44" 156 | integrity sha512-sL/cEvJWAnClXw0wHk85/2L0G6Sj8UB0Ctc1TEMbKSsmpRosqhwj9gWgFRZSrBr2f9tiXISwNhCPmlfqUqyb9Q== 157 | 158 | JSONStream@^1.3.5: 159 | version "1.3.5" 160 | resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.3.5.tgz#3208c1f08d3a4d99261ab64f92302bc15e111ca0" 161 | integrity sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ== 162 | dependencies: 163 | jsonparse "^1.2.0" 164 | through ">=2.2.7 <3" 165 | 166 | ansi-colors@4.1.1: 167 | version "4.1.1" 168 | resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-4.1.1.tgz#cbb9ae256bf750af1eab344f229aa27fe94ba348" 169 | integrity sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA== 170 | 171 | ansi-regex@^5.0.1: 172 | version "5.0.1" 173 | resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" 174 | integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== 175 | 176 | ansi-styles@^4.0.0, ansi-styles@^4.1.0: 177 | version "4.3.0" 178 | resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" 179 | integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== 180 | dependencies: 181 | color-convert "^2.0.1" 182 | 183 | anymatch@~3.1.2: 184 | version "3.1.2" 185 | resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.2.tgz#c0557c096af32f106198f4f4e2a383537e378716" 186 | integrity sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg== 187 | dependencies: 188 | normalize-path "^3.0.0" 189 | picomatch "^2.0.4" 190 | 191 | argparse@^2.0.1: 192 | version "2.0.1" 193 | resolved "https://registry.yarnpkg.com/argparse/-/argparse-2.0.1.tgz#246f50f3ca78a3240f6c997e8a9bd1eac49e4b38" 194 | integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== 195 | 196 | arrify@^1.0.0: 197 | version "1.0.1" 198 | resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" 199 | integrity sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0= 200 | 201 | assertion-error@^1.1.0: 202 | version "1.1.0" 203 | resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.1.0.tgz#e60b6b0e8f301bd97e5375215bda406c85118c0b" 204 | integrity sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw== 205 | 206 | balanced-match@^1.0.0: 207 | version "1.0.2" 208 | resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" 209 | integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== 210 | 211 | base-x@^3.0.2: 212 | version "3.0.9" 213 | resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.9.tgz#6349aaabb58526332de9f60995e548a53fe21320" 214 | integrity sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ== 215 | dependencies: 216 | safe-buffer "^5.0.1" 217 | 218 | base64-js@^1.3.1, base64-js@^1.5.1: 219 | version "1.5.1" 220 | resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" 221 | integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== 222 | 223 | binary-extensions@^2.0.0: 224 | version "2.2.0" 225 | resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" 226 | integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== 227 | 228 | bn.js@^4.11.9: 229 | version "4.12.0" 230 | resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" 231 | integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== 232 | 233 | bn.js@^5.0.0, bn.js@^5.1.2: 234 | version "5.2.0" 235 | resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.2.0.tgz#358860674396c6997771a9d051fcc1b57d4ae002" 236 | integrity sha512-D7iWRBvnZE8ecXiLj/9wbxH7Tk79fAh8IHaTNq1RWRixsS02W+5qS+iE9yq6RYl0asXx5tw0bLhmT5pIfbSquw== 237 | 238 | borsh@^0.4.0: 239 | version "0.4.0" 240 | resolved "https://registry.yarnpkg.com/borsh/-/borsh-0.4.0.tgz#9dd6defe741627f1315eac2a73df61421f6ddb9f" 241 | integrity sha512-aX6qtLya3K0AkT66CmYWCCDr77qsE9arV05OmdFpmat9qu8Pg9J5tBUPDztAW5fNh/d/MyVG/OYziP52Ndzx1g== 242 | dependencies: 243 | "@types/bn.js" "^4.11.5" 244 | bn.js "^5.0.0" 245 | bs58 "^4.0.0" 246 | text-encoding-utf-8 "^1.0.2" 247 | 248 | brace-expansion@^1.1.7: 249 | version "1.1.11" 250 | resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" 251 | integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== 252 | dependencies: 253 | balanced-match "^1.0.0" 254 | concat-map "0.0.1" 255 | 256 | braces@~3.0.2: 257 | version "3.0.2" 258 | resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" 259 | integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== 260 | dependencies: 261 | fill-range "^7.0.1" 262 | 263 | brorand@^1.1.0: 264 | version "1.1.0" 265 | resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" 266 | integrity sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8= 267 | 268 | browser-stdout@1.3.1: 269 | version "1.3.1" 270 | resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60" 271 | integrity sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw== 272 | 273 | bs58@^4.0.0, bs58@^4.0.1: 274 | version "4.0.1" 275 | resolved "https://registry.yarnpkg.com/bs58/-/bs58-4.0.1.tgz#be161e76c354f6f788ae4071f63f34e8c4f0a42a" 276 | integrity sha1-vhYedsNU9veIrkBx9j806MTwpCo= 277 | dependencies: 278 | base-x "^3.0.2" 279 | 280 | buffer-from@^1.0.0, buffer-from@^1.1.0: 281 | version "1.1.2" 282 | resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" 283 | integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== 284 | 285 | buffer-layout@^1.2.0, buffer-layout@^1.2.2: 286 | version "1.2.2" 287 | resolved "https://registry.yarnpkg.com/buffer-layout/-/buffer-layout-1.2.2.tgz#b9814e7c7235783085f9ca4966a0cfff112259d5" 288 | integrity sha512-kWSuLN694+KTk8SrYvCqwP2WcgQjoRCiF5b4QDvkkz8EmgD+aWAIceGFKMIAdmF/pH+vpgNV3d3kAKorcdAmWA== 289 | 290 | buffer@6.0.1: 291 | version "6.0.1" 292 | resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.1.tgz#3cbea8c1463e5a0779e30b66d4c88c6ffa182ac2" 293 | integrity sha512-rVAXBwEcEoYtxnHSO5iWyhzV/O1WMtkUYWlfdLS7FjU4PnSJJHEfHXi/uHPI5EwltmOA794gN3bm3/pzuctWjQ== 294 | dependencies: 295 | base64-js "^1.3.1" 296 | ieee754 "^1.2.1" 297 | 298 | buffer@~6.0.3: 299 | version "6.0.3" 300 | resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6" 301 | integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== 302 | dependencies: 303 | base64-js "^1.3.1" 304 | ieee754 "^1.2.1" 305 | 306 | bufferutil@^4.0.1: 307 | version "4.0.6" 308 | resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.6.tgz#ebd6c67c7922a0e902f053e5d8be5ec850e48433" 309 | integrity sha512-jduaYOYtnio4aIAyc6UbvPCVcgq7nYpVnucyxr6eCYg/Woad9Hf/oxxBRDnGGjPfjUm6j5O/uBWhIu4iLebFaw== 310 | dependencies: 311 | node-gyp-build "^4.3.0" 312 | 313 | camelcase@^5.3.1: 314 | version "5.3.1" 315 | resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" 316 | integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== 317 | 318 | camelcase@^6.0.0: 319 | version "6.3.0" 320 | resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" 321 | integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== 322 | 323 | chai@^4.3.4: 324 | version "4.3.4" 325 | resolved "https://registry.yarnpkg.com/chai/-/chai-4.3.4.tgz#b55e655b31e1eac7099be4c08c21964fce2e6c49" 326 | integrity sha512-yS5H68VYOCtN1cjfwumDSuzn/9c+yza4f3reKXlE5rUg7SFcCEy90gJvydNgOYtblyf4Zi6jIWRnXOgErta0KA== 327 | dependencies: 328 | assertion-error "^1.1.0" 329 | check-error "^1.0.2" 330 | deep-eql "^3.0.1" 331 | get-func-name "^2.0.0" 332 | pathval "^1.1.1" 333 | type-detect "^4.0.5" 334 | 335 | chalk@^4.1.0: 336 | version "4.1.2" 337 | resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" 338 | integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== 339 | dependencies: 340 | ansi-styles "^4.1.0" 341 | supports-color "^7.1.0" 342 | 343 | check-error@^1.0.2: 344 | version "1.0.2" 345 | resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.2.tgz#574d312edd88bb5dd8912e9286dd6c0aed4aac82" 346 | integrity sha1-V00xLt2Iu13YkS6Sht1sCu1KrII= 347 | 348 | chokidar@3.5.2: 349 | version "3.5.2" 350 | resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.2.tgz#dba3976fcadb016f66fd365021d91600d01c1e75" 351 | integrity sha512-ekGhOnNVPgT77r4K/U3GDhu+FQ2S8TnK/s2KbIGXi0SZWuwkZ2QNyfWdZW+TVfn84DpEP7rLeCt2UI6bJ8GwbQ== 352 | dependencies: 353 | anymatch "~3.1.2" 354 | braces "~3.0.2" 355 | glob-parent "~5.1.2" 356 | is-binary-path "~2.1.0" 357 | is-glob "~4.0.1" 358 | normalize-path "~3.0.0" 359 | readdirp "~3.6.0" 360 | optionalDependencies: 361 | fsevents "~2.3.2" 362 | 363 | circular-json@^0.5.9: 364 | version "0.5.9" 365 | resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.5.9.tgz#932763ae88f4f7dead7a0d09c8a51a4743a53b1d" 366 | integrity sha512-4ivwqHpIFJZBuhN3g/pEcdbnGUywkBblloGbkglyloVjjR3uT6tieI89MVOfbP2tHX5sgb01FuLgAOzebNlJNQ== 367 | 368 | cliui@^7.0.2: 369 | version "7.0.4" 370 | resolved "https://registry.yarnpkg.com/cliui/-/cliui-7.0.4.tgz#a0265ee655476fc807aea9df3df8df7783808b4f" 371 | integrity sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ== 372 | dependencies: 373 | string-width "^4.2.0" 374 | strip-ansi "^6.0.0" 375 | wrap-ansi "^7.0.0" 376 | 377 | color-convert@^2.0.1: 378 | version "2.0.1" 379 | resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" 380 | integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== 381 | dependencies: 382 | color-name "~1.1.4" 383 | 384 | color-name@~1.1.4: 385 | version "1.1.4" 386 | resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" 387 | integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== 388 | 389 | commander@^2.20.3: 390 | version "2.20.3" 391 | resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" 392 | integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== 393 | 394 | concat-map@0.0.1: 395 | version "0.0.1" 396 | resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" 397 | integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= 398 | 399 | cross-fetch@^3.1.4: 400 | version "3.1.4" 401 | resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-3.1.4.tgz#9723f3a3a247bf8b89039f3a380a9244e8fa2f39" 402 | integrity sha512-1eAtFWdIubi6T4XPy6ei9iUFoKpUkIF971QLN8lIvvvwueI65+Nw5haMNKUwfJxabqlIIDODJKGrQ66gxC0PbQ== 403 | dependencies: 404 | node-fetch "2.6.1" 405 | 406 | crypto-hash@^1.3.0: 407 | version "1.3.0" 408 | resolved "https://registry.yarnpkg.com/crypto-hash/-/crypto-hash-1.3.0.tgz#b402cb08f4529e9f4f09346c3e275942f845e247" 409 | integrity sha512-lyAZ0EMyjDkVvz8WOeVnuCPvKVBXcMv1l5SVqO1yC7PzTwrD/pPje/BIRbWhMoPe436U+Y2nD7f5bFx0kt+Sbg== 410 | 411 | debug@4.3.2: 412 | version "4.3.2" 413 | resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.2.tgz#f0a49c18ac8779e31d4a0c6029dfb76873c7428b" 414 | integrity sha512-mOp8wKcvj7XxC78zLgw/ZA+6TSgkoE2C/ienthhRD298T7UNwAg9diBpLRxC0mOezLl4B0xV7M0cCO6P/O0Xhw== 415 | dependencies: 416 | ms "2.1.2" 417 | 418 | decamelize@^4.0.0: 419 | version "4.0.0" 420 | resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-4.0.0.tgz#aa472d7bf660eb15f3494efd531cab7f2a709837" 421 | integrity sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ== 422 | 423 | deep-eql@^3.0.1: 424 | version "3.0.1" 425 | resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-3.0.1.tgz#dfc9404400ad1c8fe023e7da1df1c147c4b444df" 426 | integrity sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw== 427 | dependencies: 428 | type-detect "^4.0.0" 429 | 430 | delay@^5.0.0: 431 | version "5.0.0" 432 | resolved "https://registry.yarnpkg.com/delay/-/delay-5.0.0.tgz#137045ef1b96e5071060dd5be60bf9334436bd1d" 433 | integrity sha512-ReEBKkIfe4ya47wlPYf/gu5ib6yUG0/Aez0JQZQz94kiWtRQvZIQbTiehsnwHvLSWJnQdhVeqYue7Id1dKr0qw== 434 | 435 | diff@5.0.0: 436 | version "5.0.0" 437 | resolved "https://registry.yarnpkg.com/diff/-/diff-5.0.0.tgz#7ed6ad76d859d030787ec35855f5b1daf31d852b" 438 | integrity sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w== 439 | 440 | diff@^3.1.0: 441 | version "3.5.0" 442 | resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" 443 | integrity sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA== 444 | 445 | dot-case@^3.0.4: 446 | version "3.0.4" 447 | resolved "https://registry.yarnpkg.com/dot-case/-/dot-case-3.0.4.tgz#9b2b670d00a431667a8a75ba29cd1b98809ce751" 448 | integrity sha512-Kv5nKlh6yRrdrGvxeJ2e5y2eRUpkUosIW4A2AS38zwSz27zu7ufDwQPi5Jhs3XAlGNetl3bmnGhQsMtkKJnj3w== 449 | dependencies: 450 | no-case "^3.0.4" 451 | tslib "^2.0.3" 452 | 453 | elliptic@^6.5.4: 454 | version "6.5.4" 455 | resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.4.tgz#da37cebd31e79a1367e941b592ed1fbebd58abbb" 456 | integrity sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ== 457 | dependencies: 458 | bn.js "^4.11.9" 459 | brorand "^1.1.0" 460 | hash.js "^1.0.0" 461 | hmac-drbg "^1.0.1" 462 | inherits "^2.0.4" 463 | minimalistic-assert "^1.0.1" 464 | minimalistic-crypto-utils "^1.0.1" 465 | 466 | emoji-regex@^8.0.0: 467 | version "8.0.0" 468 | resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" 469 | integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== 470 | 471 | es6-promise@^4.0.3: 472 | version "4.2.8" 473 | resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.8.tgz#4eb21594c972bc40553d276e510539143db53e0a" 474 | integrity sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w== 475 | 476 | es6-promisify@^5.0.0: 477 | version "5.0.0" 478 | resolved "https://registry.yarnpkg.com/es6-promisify/-/es6-promisify-5.0.0.tgz#5109d62f3e56ea967c4b63505aef08291c8a5203" 479 | integrity sha1-UQnWLz5W6pZ8S2NQWu8IKRyKUgM= 480 | dependencies: 481 | es6-promise "^4.0.3" 482 | 483 | escalade@^3.1.1: 484 | version "3.1.1" 485 | resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" 486 | integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== 487 | 488 | escape-string-regexp@4.0.0: 489 | version "4.0.0" 490 | resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" 491 | integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== 492 | 493 | eventemitter3@^4.0.7: 494 | version "4.0.7" 495 | resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f" 496 | integrity sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw== 497 | 498 | eyes@^0.1.8: 499 | version "0.1.8" 500 | resolved "https://registry.yarnpkg.com/eyes/-/eyes-0.1.8.tgz#62cf120234c683785d902348a800ef3e0cc20bc0" 501 | integrity sha1-Ys8SAjTGg3hdkCNIqADvPgzCC8A= 502 | 503 | fill-range@^7.0.1: 504 | version "7.0.1" 505 | resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" 506 | integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== 507 | dependencies: 508 | to-regex-range "^5.0.1" 509 | 510 | find-up@5.0.0: 511 | version "5.0.0" 512 | resolved "https://registry.yarnpkg.com/find-up/-/find-up-5.0.0.tgz#4c92819ecb7083561e4f4a240a86be5198f536fc" 513 | integrity sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng== 514 | dependencies: 515 | locate-path "^6.0.0" 516 | path-exists "^4.0.0" 517 | 518 | find@^0.3.0: 519 | version "0.3.0" 520 | resolved "https://registry.yarnpkg.com/find/-/find-0.3.0.tgz#4082e8fc8d8320f1a382b5e4f521b9bc50775cb8" 521 | integrity sha512-iSd+O4OEYV/I36Zl8MdYJO0xD82wH528SaCieTVHhclgiYNe9y+yPKSwK+A7/WsmHL1EZ+pYUJBXWTL5qofksw== 522 | dependencies: 523 | traverse-chain "~0.1.0" 524 | 525 | flat@^5.0.2: 526 | version "5.0.2" 527 | resolved "https://registry.yarnpkg.com/flat/-/flat-5.0.2.tgz#8ca6fe332069ffa9d324c327198c598259ceb241" 528 | integrity sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ== 529 | 530 | fs.realpath@^1.0.0: 531 | version "1.0.0" 532 | resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" 533 | integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= 534 | 535 | fsevents@~2.3.2: 536 | version "2.3.2" 537 | resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" 538 | integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== 539 | 540 | get-caller-file@^2.0.5: 541 | version "2.0.5" 542 | resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" 543 | integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== 544 | 545 | get-func-name@^2.0.0: 546 | version "2.0.0" 547 | resolved "https://registry.yarnpkg.com/get-func-name/-/get-func-name-2.0.0.tgz#ead774abee72e20409433a066366023dd6887a41" 548 | integrity sha1-6td0q+5y4gQJQzoGY2YCPdaIekE= 549 | 550 | glob-parent@~5.1.2: 551 | version "5.1.2" 552 | resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" 553 | integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== 554 | dependencies: 555 | is-glob "^4.0.1" 556 | 557 | glob@7.1.7: 558 | version "7.1.7" 559 | resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.7.tgz#3b193e9233f01d42d0b3f78294bbeeb418f94a90" 560 | integrity sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ== 561 | dependencies: 562 | fs.realpath "^1.0.0" 563 | inflight "^1.0.4" 564 | inherits "2" 565 | minimatch "^3.0.4" 566 | once "^1.3.0" 567 | path-is-absolute "^1.0.0" 568 | 569 | growl@1.10.5: 570 | version "1.10.5" 571 | resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" 572 | integrity sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA== 573 | 574 | has-flag@^4.0.0: 575 | version "4.0.0" 576 | resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" 577 | integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== 578 | 579 | hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3: 580 | version "1.1.7" 581 | resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.7.tgz#0babca538e8d4ee4a0f8988d68866537a003cf42" 582 | integrity sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA== 583 | dependencies: 584 | inherits "^2.0.3" 585 | minimalistic-assert "^1.0.1" 586 | 587 | he@1.2.0: 588 | version "1.2.0" 589 | resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f" 590 | integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== 591 | 592 | hmac-drbg@^1.0.1: 593 | version "1.0.1" 594 | resolved "https://registry.yarnpkg.com/hmac-drbg/-/hmac-drbg-1.0.1.tgz#d2745701025a6c775a6c545793ed502fc0c649a1" 595 | integrity sha1-0nRXAQJabHdabFRXk+1QL8DGSaE= 596 | dependencies: 597 | hash.js "^1.0.3" 598 | minimalistic-assert "^1.0.0" 599 | minimalistic-crypto-utils "^1.0.1" 600 | 601 | ieee754@^1.2.1: 602 | version "1.2.1" 603 | resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" 604 | integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== 605 | 606 | inflight@^1.0.4: 607 | version "1.0.6" 608 | resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" 609 | integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= 610 | dependencies: 611 | once "^1.3.0" 612 | wrappy "1" 613 | 614 | inherits@2, inherits@^2.0.3, inherits@^2.0.4: 615 | version "2.0.4" 616 | resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" 617 | integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== 618 | 619 | is-binary-path@~2.1.0: 620 | version "2.1.0" 621 | resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09" 622 | integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== 623 | dependencies: 624 | binary-extensions "^2.0.0" 625 | 626 | is-extglob@^2.1.1: 627 | version "2.1.1" 628 | resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" 629 | integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= 630 | 631 | is-fullwidth-code-point@^3.0.0: 632 | version "3.0.0" 633 | resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" 634 | integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== 635 | 636 | is-glob@^4.0.1, is-glob@~4.0.1: 637 | version "4.0.3" 638 | resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084" 639 | integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg== 640 | dependencies: 641 | is-extglob "^2.1.1" 642 | 643 | is-number@^7.0.0: 644 | version "7.0.0" 645 | resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" 646 | integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== 647 | 648 | is-plain-obj@^2.1.0: 649 | version "2.1.0" 650 | resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-2.1.0.tgz#45e42e37fccf1f40da8e5f76ee21515840c09287" 651 | integrity sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA== 652 | 653 | is-unicode-supported@^0.1.0: 654 | version "0.1.0" 655 | resolved "https://registry.yarnpkg.com/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz#3f26c76a809593b52bfa2ecb5710ed2779b522a7" 656 | integrity sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw== 657 | 658 | isexe@^2.0.0: 659 | version "2.0.0" 660 | resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" 661 | integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= 662 | 663 | isomorphic-ws@^4.0.1: 664 | version "4.0.1" 665 | resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-4.0.1.tgz#55fd4cd6c5e6491e76dc125938dd863f5cd4f2dc" 666 | integrity sha512-BhBvN2MBpWTaSHdWRb/bwdZJ1WaehQ2L1KngkCkfLUGF0mAWAT1sQUQacEmQ0jXkFw/czDXPNQSL5u2/Krsz1w== 667 | 668 | jayson@^3.4.4: 669 | version "3.6.6" 670 | resolved "https://registry.yarnpkg.com/jayson/-/jayson-3.6.6.tgz#189984f624e398f831bd2be8e8c80eb3abf764a1" 671 | integrity sha512-f71uvrAWTtrwoww6MKcl9phQTC+56AopLyEenWvKVAIMz+q0oVGj6tenLZ7Z6UiPBkJtKLj4kt0tACllFQruGQ== 672 | dependencies: 673 | "@types/connect" "^3.4.33" 674 | "@types/express-serve-static-core" "^4.17.9" 675 | "@types/lodash" "^4.14.159" 676 | "@types/node" "^12.12.54" 677 | "@types/ws" "^7.4.4" 678 | JSONStream "^1.3.5" 679 | commander "^2.20.3" 680 | delay "^5.0.0" 681 | es6-promisify "^5.0.0" 682 | eyes "^0.1.8" 683 | isomorphic-ws "^4.0.1" 684 | json-stringify-safe "^5.0.1" 685 | lodash "^4.17.20" 686 | uuid "^8.3.2" 687 | ws "^7.4.5" 688 | 689 | js-sha256@^0.9.0: 690 | version "0.9.0" 691 | resolved "https://registry.yarnpkg.com/js-sha256/-/js-sha256-0.9.0.tgz#0b89ac166583e91ef9123644bd3c5334ce9d0966" 692 | integrity sha512-sga3MHh9sgQN2+pJ9VYZ+1LPwXOxuBJBA5nrR5/ofPfuiJBE2hnjsaN8se8JznOmGLN2p49Pe5U/ttafcs/apA== 693 | 694 | js-sha3@^0.8.0: 695 | version "0.8.0" 696 | resolved "https://registry.yarnpkg.com/js-sha3/-/js-sha3-0.8.0.tgz#b9b7a5da73afad7dedd0f8c463954cbde6818840" 697 | integrity sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q== 698 | 699 | js-yaml@4.1.0: 700 | version "4.1.0" 701 | resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-4.1.0.tgz#c1fb65f8f5017901cdd2c951864ba18458a10602" 702 | integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA== 703 | dependencies: 704 | argparse "^2.0.1" 705 | 706 | json-stringify-safe@^5.0.1: 707 | version "5.0.1" 708 | resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" 709 | integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= 710 | 711 | json5@^1.0.1: 712 | version "1.0.1" 713 | resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.1.tgz#779fb0018604fa854eacbf6252180d83543e3dbe" 714 | integrity sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow== 715 | dependencies: 716 | minimist "^1.2.0" 717 | 718 | jsonparse@^1.2.0: 719 | version "1.3.1" 720 | resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280" 721 | integrity sha1-P02uSpH6wxX3EGL4UhzCOfE2YoA= 722 | 723 | locate-path@^6.0.0: 724 | version "6.0.0" 725 | resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-6.0.0.tgz#55321eb309febbc59c4801d931a72452a681d286" 726 | integrity sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw== 727 | dependencies: 728 | p-locate "^5.0.0" 729 | 730 | lodash@^4.17.20: 731 | version "4.17.21" 732 | resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" 733 | integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== 734 | 735 | log-symbols@4.1.0: 736 | version "4.1.0" 737 | resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-4.1.0.tgz#3fbdbb95b4683ac9fc785111e792e558d4abd503" 738 | integrity sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg== 739 | dependencies: 740 | chalk "^4.1.0" 741 | is-unicode-supported "^0.1.0" 742 | 743 | lower-case@^2.0.2: 744 | version "2.0.2" 745 | resolved "https://registry.yarnpkg.com/lower-case/-/lower-case-2.0.2.tgz#6fa237c63dbdc4a82ca0fd882e4722dc5e634e28" 746 | integrity sha512-7fm3l3NAF9WfN6W3JOmf5drwpVqX78JtoGJ3A6W0a6ZnldM41w2fV5D490psKFTpMds8TJse/eHLFFsNHHjHgg== 747 | dependencies: 748 | tslib "^2.0.3" 749 | 750 | make-error@^1.1.1: 751 | version "1.3.6" 752 | resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" 753 | integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== 754 | 755 | minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: 756 | version "1.0.1" 757 | resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" 758 | integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== 759 | 760 | minimalistic-crypto-utils@^1.0.1: 761 | version "1.0.1" 762 | resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" 763 | integrity sha1-9sAMHAsIIkblxNmd+4x8CDsrWCo= 764 | 765 | minimatch@3.0.4, minimatch@^3.0.4: 766 | version "3.0.4" 767 | resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" 768 | integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== 769 | dependencies: 770 | brace-expansion "^1.1.7" 771 | 772 | minimist@^1.2.0, minimist@^1.2.5: 773 | version "1.2.5" 774 | resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" 775 | integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== 776 | 777 | mkdirp@^0.5.1: 778 | version "0.5.5" 779 | resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.5.tgz#d91cefd62d1436ca0f41620e251288d420099def" 780 | integrity sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ== 781 | dependencies: 782 | minimist "^1.2.5" 783 | 784 | mocha@^9.0.3: 785 | version "9.1.3" 786 | resolved "https://registry.yarnpkg.com/mocha/-/mocha-9.1.3.tgz#8a623be6b323810493d8c8f6f7667440fa469fdb" 787 | integrity sha512-Xcpl9FqXOAYqI3j79pEtHBBnQgVXIhpULjGQa7DVb0Po+VzmSIK9kanAiWLHoRR/dbZ2qpdPshuXr8l1VaHCzw== 788 | dependencies: 789 | "@ungap/promise-all-settled" "1.1.2" 790 | ansi-colors "4.1.1" 791 | browser-stdout "1.3.1" 792 | chokidar "3.5.2" 793 | debug "4.3.2" 794 | diff "5.0.0" 795 | escape-string-regexp "4.0.0" 796 | find-up "5.0.0" 797 | glob "7.1.7" 798 | growl "1.10.5" 799 | he "1.2.0" 800 | js-yaml "4.1.0" 801 | log-symbols "4.1.0" 802 | minimatch "3.0.4" 803 | ms "2.1.3" 804 | nanoid "3.1.25" 805 | serialize-javascript "6.0.0" 806 | strip-json-comments "3.1.1" 807 | supports-color "8.1.1" 808 | which "2.0.2" 809 | workerpool "6.1.5" 810 | yargs "16.2.0" 811 | yargs-parser "20.2.4" 812 | yargs-unparser "2.0.0" 813 | 814 | ms@2.1.2: 815 | version "2.1.2" 816 | resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" 817 | integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== 818 | 819 | ms@2.1.3: 820 | version "2.1.3" 821 | resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" 822 | integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== 823 | 824 | nanoid@3.1.25: 825 | version "3.1.25" 826 | resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.1.25.tgz#09ca32747c0e543f0e1814b7d3793477f9c8e152" 827 | integrity sha512-rdwtIXaXCLFAQbnfqDRnI6jaRHp9fTcYBjtFKE8eezcZ7LuLjhUaQGNeMXf1HmRoCH32CLz6XwX0TtxEOS/A3Q== 828 | 829 | no-case@^3.0.4: 830 | version "3.0.4" 831 | resolved "https://registry.yarnpkg.com/no-case/-/no-case-3.0.4.tgz#d361fd5c9800f558551a8369fc0dcd4662b6124d" 832 | integrity sha512-fgAN3jGAh+RoxUGZHTSOLJIqUc2wmoBwGR4tbpNAKmmovFoWq0OdRkb0VkldReO2a2iBT/OEulG9XSUc10r3zg== 833 | dependencies: 834 | lower-case "^2.0.2" 835 | tslib "^2.0.3" 836 | 837 | node-addon-api@^2.0.0: 838 | version "2.0.2" 839 | resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-2.0.2.tgz#432cfa82962ce494b132e9d72a15b29f71ff5d32" 840 | integrity sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA== 841 | 842 | node-fetch@2.6.1: 843 | version "2.6.1" 844 | resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.1.tgz#045bd323631f76ed2e2b55573394416b639a0052" 845 | integrity sha512-V4aYg89jEoVRxRb2fJdAg8FHvI7cEyYdVAh94HH0UIK8oJxUfkjlDQN9RbMx+bEjP7+ggMiFRprSti032Oipxw== 846 | 847 | node-gyp-build@^4.2.0, node-gyp-build@^4.3.0: 848 | version "4.3.0" 849 | resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.3.0.tgz#9f256b03e5826150be39c764bf51e993946d71a3" 850 | integrity sha512-iWjXZvmboq0ja1pUGULQBexmxq8CV4xBhX7VDOTbL7ZR4FOowwY/VOtRxBN/yKxmdGoIp4j5ysNT4u3S2pDQ3Q== 851 | 852 | normalize-path@^3.0.0, normalize-path@~3.0.0: 853 | version "3.0.0" 854 | resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" 855 | integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== 856 | 857 | once@^1.3.0: 858 | version "1.4.0" 859 | resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" 860 | integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= 861 | dependencies: 862 | wrappy "1" 863 | 864 | p-limit@^3.0.2: 865 | version "3.1.0" 866 | resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-3.1.0.tgz#e1daccbe78d0d1388ca18c64fea38e3e57e3706b" 867 | integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== 868 | dependencies: 869 | yocto-queue "^0.1.0" 870 | 871 | p-locate@^5.0.0: 872 | version "5.0.0" 873 | resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-5.0.0.tgz#83c8315c6785005e3bd021839411c9e110e6d834" 874 | integrity sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw== 875 | dependencies: 876 | p-limit "^3.0.2" 877 | 878 | pako@^2.0.3: 879 | version "2.0.4" 880 | resolved "https://registry.yarnpkg.com/pako/-/pako-2.0.4.tgz#6cebc4bbb0b6c73b0d5b8d7e8476e2b2fbea576d" 881 | integrity sha512-v8tweI900AUkZN6heMU/4Uy4cXRc2AYNRggVmTR+dEncawDJgCdLMximOVA2p4qO57WMynangsfGRb5WD6L1Bg== 882 | 883 | path-exists@^4.0.0: 884 | version "4.0.0" 885 | resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" 886 | integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== 887 | 888 | path-is-absolute@^1.0.0: 889 | version "1.0.1" 890 | resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" 891 | integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= 892 | 893 | pathval@^1.1.1: 894 | version "1.1.1" 895 | resolved "https://registry.yarnpkg.com/pathval/-/pathval-1.1.1.tgz#8534e77a77ce7ac5a2512ea21e0fdb8fcf6c3d8d" 896 | integrity sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ== 897 | 898 | picomatch@^2.0.4, picomatch@^2.2.1: 899 | version "2.3.1" 900 | resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" 901 | integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== 902 | 903 | randombytes@^2.1.0: 904 | version "2.1.0" 905 | resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" 906 | integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== 907 | dependencies: 908 | safe-buffer "^5.1.0" 909 | 910 | readdirp@~3.6.0: 911 | version "3.6.0" 912 | resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7" 913 | integrity sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA== 914 | dependencies: 915 | picomatch "^2.2.1" 916 | 917 | regenerator-runtime@^0.13.4: 918 | version "0.13.9" 919 | resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.9.tgz#8925742a98ffd90814988d7566ad30ca3b263b52" 920 | integrity sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA== 921 | 922 | require-directory@^2.1.1: 923 | version "2.1.1" 924 | resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" 925 | integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= 926 | 927 | rpc-websockets@^7.4.2: 928 | version "7.4.16" 929 | resolved "https://registry.yarnpkg.com/rpc-websockets/-/rpc-websockets-7.4.16.tgz#eb701cdef577d4357ba5f526d50e25f370396fac" 930 | integrity sha512-0b7OVhutzwRIaYAtJo5tqtaQTWKfwAsKnaThOSOy+VkhVdleNUgb8eZnWSdWITRZZEigV5uPEIDr5KZe4DBrdQ== 931 | dependencies: 932 | "@babel/runtime" "^7.11.2" 933 | circular-json "^0.5.9" 934 | eventemitter3 "^4.0.7" 935 | uuid "^8.3.0" 936 | ws "^7.4.5" 937 | optionalDependencies: 938 | bufferutil "^4.0.1" 939 | utf-8-validate "^5.0.2" 940 | 941 | safe-buffer@^5.0.1, safe-buffer@^5.1.0: 942 | version "5.2.1" 943 | resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" 944 | integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== 945 | 946 | secp256k1@^4.0.2: 947 | version "4.0.3" 948 | resolved "https://registry.yarnpkg.com/secp256k1/-/secp256k1-4.0.3.tgz#c4559ecd1b8d3c1827ed2d1b94190d69ce267303" 949 | integrity sha512-NLZVf+ROMxwtEj3Xa562qgv2BK5e2WNmXPiOdVIPLgs6lyTzMvBq0aWTYMI5XCP9jZMVKOcqZLw/Wc4vDkuxhA== 950 | dependencies: 951 | elliptic "^6.5.4" 952 | node-addon-api "^2.0.0" 953 | node-gyp-build "^4.2.0" 954 | 955 | serialize-javascript@6.0.0: 956 | version "6.0.0" 957 | resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-6.0.0.tgz#efae5d88f45d7924141da8b5c3a7a7e663fefeb8" 958 | integrity sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag== 959 | dependencies: 960 | randombytes "^2.1.0" 961 | 962 | snake-case@^3.0.4: 963 | version "3.0.4" 964 | resolved "https://registry.yarnpkg.com/snake-case/-/snake-case-3.0.4.tgz#4f2bbd568e9935abdfd593f34c691dadb49c452c" 965 | integrity sha512-LAOh4z89bGQvl9pFfNF8V146i7o7/CqFPbqzYgP+yYzDIDeS9HaNFtXABamRW+AQzEVODcvE79ljJ+8a9YSdMg== 966 | dependencies: 967 | dot-case "^3.0.4" 968 | tslib "^2.0.3" 969 | 970 | source-map-support@^0.5.6: 971 | version "0.5.21" 972 | resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" 973 | integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== 974 | dependencies: 975 | buffer-from "^1.0.0" 976 | source-map "^0.6.0" 977 | 978 | source-map@^0.6.0: 979 | version "0.6.1" 980 | resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" 981 | integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== 982 | 983 | string-width@^4.1.0, string-width@^4.2.0: 984 | version "4.2.3" 985 | resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" 986 | integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== 987 | dependencies: 988 | emoji-regex "^8.0.0" 989 | is-fullwidth-code-point "^3.0.0" 990 | strip-ansi "^6.0.1" 991 | 992 | strip-ansi@^6.0.0, strip-ansi@^6.0.1: 993 | version "6.0.1" 994 | resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" 995 | integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== 996 | dependencies: 997 | ansi-regex "^5.0.1" 998 | 999 | strip-bom@^3.0.0: 1000 | version "3.0.0" 1001 | resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" 1002 | integrity sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM= 1003 | 1004 | strip-json-comments@3.1.1: 1005 | version "3.1.1" 1006 | resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" 1007 | integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== 1008 | 1009 | superstruct@^0.14.2: 1010 | version "0.14.2" 1011 | resolved "https://registry.yarnpkg.com/superstruct/-/superstruct-0.14.2.tgz#0dbcdf3d83676588828f1cf5ed35cda02f59025b" 1012 | integrity sha512-nPewA6m9mR3d6k7WkZ8N8zpTWfenFH3q9pA2PkuiZxINr9DKB2+40wEQf0ixn8VaGuJ78AB6iWOtStI+/4FKZQ== 1013 | 1014 | supports-color@8.1.1: 1015 | version "8.1.1" 1016 | resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" 1017 | integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== 1018 | dependencies: 1019 | has-flag "^4.0.0" 1020 | 1021 | supports-color@^7.1.0: 1022 | version "7.2.0" 1023 | resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" 1024 | integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== 1025 | dependencies: 1026 | has-flag "^4.0.0" 1027 | 1028 | text-encoding-utf-8@^1.0.2: 1029 | version "1.0.2" 1030 | resolved "https://registry.yarnpkg.com/text-encoding-utf-8/-/text-encoding-utf-8-1.0.2.tgz#585b62197b0ae437e3c7b5d0af27ac1021e10d13" 1031 | integrity sha512-8bw4MY9WjdsD2aMtO0OzOCY3pXGYNx2d2FfHRVUKkiCPDWjKuOlhLVASS+pD7VkLTVjW268LYJHwsnPFlBpbAg== 1032 | 1033 | "through@>=2.2.7 <3": 1034 | version "2.3.8" 1035 | resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" 1036 | integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= 1037 | 1038 | to-regex-range@^5.0.1: 1039 | version "5.0.1" 1040 | resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" 1041 | integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== 1042 | dependencies: 1043 | is-number "^7.0.0" 1044 | 1045 | toml@^3.0.0: 1046 | version "3.0.0" 1047 | resolved "https://registry.yarnpkg.com/toml/-/toml-3.0.0.tgz#342160f1af1904ec9d204d03a5d61222d762c5ee" 1048 | integrity sha512-y/mWCZinnvxjTKYhJ+pYxwD0mRLVvOtdS2Awbgxln6iEnt4rk0yBxeSBHkGJcPucRiG0e55mwWp+g/05rsrd6w== 1049 | 1050 | traverse-chain@~0.1.0: 1051 | version "0.1.0" 1052 | resolved "https://registry.yarnpkg.com/traverse-chain/-/traverse-chain-0.1.0.tgz#61dbc2d53b69ff6091a12a168fd7d433107e40f1" 1053 | integrity sha1-YdvC1Ttp/2CRoSoWj9fUMxB+QPE= 1054 | 1055 | ts-mocha@^8.0.0: 1056 | version "8.0.0" 1057 | resolved "https://registry.yarnpkg.com/ts-mocha/-/ts-mocha-8.0.0.tgz#962d0fa12eeb6468aa1a6b594bb3bbc818da3ef0" 1058 | integrity sha512-Kou1yxTlubLnD5C3unlCVO7nh0HERTezjoVhVw/M5S1SqoUec0WgllQvPk3vzPMc6by8m6xD1uR1yRf8lnVUbA== 1059 | dependencies: 1060 | ts-node "7.0.1" 1061 | optionalDependencies: 1062 | tsconfig-paths "^3.5.0" 1063 | 1064 | ts-node@7.0.1: 1065 | version "7.0.1" 1066 | resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-7.0.1.tgz#9562dc2d1e6d248d24bc55f773e3f614337d9baf" 1067 | integrity sha512-BVwVbPJRspzNh2yfslyT1PSbl5uIk03EZlb493RKHN4qej/D06n1cEhjlOJG69oFsE7OT8XjpTUcYf6pKTLMhw== 1068 | dependencies: 1069 | arrify "^1.0.0" 1070 | buffer-from "^1.1.0" 1071 | diff "^3.1.0" 1072 | make-error "^1.1.1" 1073 | minimist "^1.2.0" 1074 | mkdirp "^0.5.1" 1075 | source-map-support "^0.5.6" 1076 | yn "^2.0.0" 1077 | 1078 | tsconfig-paths@^3.5.0: 1079 | version "3.12.0" 1080 | resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.12.0.tgz#19769aca6ee8f6a1a341e38c8fa45dd9fb18899b" 1081 | integrity sha512-e5adrnOYT6zqVnWqZu7i/BQ3BnhzvGbjEjejFXO20lKIKpwTaupkCPgEfv4GZK1IBciJUEhYs3J3p75FdaTFVg== 1082 | dependencies: 1083 | "@types/json5" "^0.0.29" 1084 | json5 "^1.0.1" 1085 | minimist "^1.2.0" 1086 | strip-bom "^3.0.0" 1087 | 1088 | tslib@^2.0.3: 1089 | version "2.3.1" 1090 | resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.3.1.tgz#e8a335add5ceae51aa261d32a490158ef042ef01" 1091 | integrity sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw== 1092 | 1093 | tweetnacl@^1.0.0: 1094 | version "1.0.3" 1095 | resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.3.tgz#ac0af71680458d8a6378d0d0d050ab1407d35596" 1096 | integrity sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw== 1097 | 1098 | type-detect@^4.0.0, type-detect@^4.0.5: 1099 | version "4.0.8" 1100 | resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" 1101 | integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== 1102 | 1103 | typescript@^4.3.5: 1104 | version "4.5.4" 1105 | resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.5.4.tgz#a17d3a0263bf5c8723b9c52f43c5084edf13c2e8" 1106 | integrity sha512-VgYs2A2QIRuGphtzFV7aQJduJ2gyfTljngLzjpfW9FoYZF6xuw1W0vW9ghCKLfcWrCFxK81CSGRAvS1pn4fIUg== 1107 | 1108 | utf-8-validate@^5.0.2: 1109 | version "5.0.8" 1110 | resolved "https://registry.yarnpkg.com/utf-8-validate/-/utf-8-validate-5.0.8.tgz#4a735a61661dbb1c59a0868c397d2fe263f14e58" 1111 | integrity sha512-k4dW/Qja1BYDl2qD4tOMB9PFVha/UJtxTc1cXYOe3WwA/2m0Yn4qB7wLMpJyLJ/7DR0XnTut3HsCSzDT4ZvKgA== 1112 | dependencies: 1113 | node-gyp-build "^4.3.0" 1114 | 1115 | uuid@^8.3.0, uuid@^8.3.2: 1116 | version "8.3.2" 1117 | resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" 1118 | integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== 1119 | 1120 | which@2.0.2: 1121 | version "2.0.2" 1122 | resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" 1123 | integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== 1124 | dependencies: 1125 | isexe "^2.0.0" 1126 | 1127 | workerpool@6.1.5: 1128 | version "6.1.5" 1129 | resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.1.5.tgz#0f7cf076b6215fd7e1da903ff6f22ddd1886b581" 1130 | integrity sha512-XdKkCK0Zqc6w3iTxLckiuJ81tiD/o5rBE/m+nXpRCB+/Sq4DqkfXZ/x0jW02DG1tGsfUGXbTJyZDP+eu67haSw== 1131 | 1132 | wrap-ansi@^7.0.0: 1133 | version "7.0.0" 1134 | resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" 1135 | integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== 1136 | dependencies: 1137 | ansi-styles "^4.0.0" 1138 | string-width "^4.1.0" 1139 | strip-ansi "^6.0.0" 1140 | 1141 | wrappy@1: 1142 | version "1.0.2" 1143 | resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" 1144 | integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= 1145 | 1146 | ws@^7.4.5: 1147 | version "7.5.6" 1148 | resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.6.tgz#e59fc509fb15ddfb65487ee9765c5a51dec5fe7b" 1149 | integrity sha512-6GLgCqo2cy2A2rjCNFlxQS6ZljG/coZfZXclldI8FB/1G3CCI36Zd8xy2HrFVACi8tfk5XrgLQEk+P0Tnz9UcA== 1150 | 1151 | y18n@^5.0.5: 1152 | version "5.0.8" 1153 | resolved "https://registry.yarnpkg.com/y18n/-/y18n-5.0.8.tgz#7f4934d0f7ca8c56f95314939ddcd2dd91ce1d55" 1154 | integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== 1155 | 1156 | yargs-parser@20.2.4: 1157 | version "20.2.4" 1158 | resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.4.tgz#b42890f14566796f85ae8e3a25290d205f154a54" 1159 | integrity sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA== 1160 | 1161 | yargs-parser@^20.2.2: 1162 | version "20.2.9" 1163 | resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.9.tgz#2eb7dc3b0289718fc295f362753845c41a0c94ee" 1164 | integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w== 1165 | 1166 | yargs-unparser@2.0.0: 1167 | version "2.0.0" 1168 | resolved "https://registry.yarnpkg.com/yargs-unparser/-/yargs-unparser-2.0.0.tgz#f131f9226911ae5d9ad38c432fe809366c2325eb" 1169 | integrity sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA== 1170 | dependencies: 1171 | camelcase "^6.0.0" 1172 | decamelize "^4.0.0" 1173 | flat "^5.0.2" 1174 | is-plain-obj "^2.1.0" 1175 | 1176 | yargs@16.2.0: 1177 | version "16.2.0" 1178 | resolved "https://registry.yarnpkg.com/yargs/-/yargs-16.2.0.tgz#1c82bf0f6b6a66eafce7ef30e376f49a12477f66" 1179 | integrity sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw== 1180 | dependencies: 1181 | cliui "^7.0.2" 1182 | escalade "^3.1.1" 1183 | get-caller-file "^2.0.5" 1184 | require-directory "^2.1.1" 1185 | string-width "^4.2.0" 1186 | y18n "^5.0.5" 1187 | yargs-parser "^20.2.2" 1188 | 1189 | yn@^2.0.0: 1190 | version "2.0.0" 1191 | resolved "https://registry.yarnpkg.com/yn/-/yn-2.0.0.tgz#e5adabc8acf408f6385fc76495684c88e6af689a" 1192 | integrity sha1-5a2ryKz0CPY4X8dklWhMiOavaJo= 1193 | 1194 | yocto-queue@^0.1.0: 1195 | version "0.1.0" 1196 | resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" 1197 | integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== 1198 | --------------------------------------------------------------------------------