├── .gitignore ├── LICENSE ├── README.md ├── cli ├── .gitignore ├── README.MD ├── app.js ├── err.out ├── package-lock.json ├── package.json └── utils │ ├── constants.js │ ├── err.out │ ├── logger.js │ ├── setup.js │ ├── sign.js │ ├── spawn.js │ └── wallet.js ├── client ├── app │ ├── build │ │ ├── asset-manifest.json │ │ ├── favicon.ico │ │ ├── index.html │ │ ├── manifest.json │ │ ├── semantic.min.css │ │ ├── service-worker.js │ │ └── static │ │ │ └── js │ │ │ ├── main.10e408d1.js │ │ │ └── main.10e408d1.js.map │ ├── index.html │ ├── main.js │ ├── package-lock.json │ └── package.json └── ui │ ├── .gitignore │ ├── README.md │ ├── package-lock.json │ ├── package.json │ ├── public │ ├── favicon.ico │ ├── index.html │ └── manifest.json │ └── src │ ├── App.js │ ├── components │ ├── Loading.js │ └── MainContainer.js │ ├── index.js │ └── registerServiceWorker.js └── web ├── .gitignore ├── README.md ├── package-lock.json ├── package.json ├── public ├── favicon.ico ├── index.html └── manifest.json ├── src ├── App.css ├── App.js ├── App.test.js ├── components │ ├── InitialForm.js │ ├── Loading.js │ ├── MainContainer.js │ ├── TransactionSummary.js │ ├── VerefiedHash.js │ └── Wallets.js ├── constants │ └── Provider.js ├── index.css ├── index.js ├── logo.svg └── registerServiceWorker.js └── yarn.lock /.gitignore: -------------------------------------------------------------------------------- 1 | ./local/.idea/ 2 | .idea/ 3 | node_modules/ 4 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 3, 29 June 2007 3 | 4 | Copyright (c) 2018 ChainSafe Systems 5 | Everyone is permitted to copy and distribute verbatim copies 6 | of this license document, but changing it is not allowed. 7 | 8 | Preamble 9 | 10 | The GNU General Public License is a free, copyleft license for 11 | software and other kinds of works. 12 | 13 | The licenses for most software and other practical works are designed 14 | to take away your freedom to share and change the works. By contrast, 15 | the GNU General Public License is intended to guarantee your freedom to 16 | share and change all versions of a program--to make sure it remains free 17 | software for all its users. We, the Free Software Foundation, use the 18 | GNU General Public License for most of our software; it applies also to 19 | any other work released this way by its authors. You can apply it to 20 | your programs, too. 21 | 22 | When we speak of free software, we are referring to freedom, not 23 | price. Our General Public Licenses are designed to make sure that you 24 | have the freedom to distribute copies of free software (and charge for 25 | them if you wish), that you receive source code or can get it if you 26 | want it, that you can change the software or use pieces of it in new 27 | free programs, and that you know you can do these things. 28 | 29 | To protect your rights, we need to prevent others from denying you 30 | these rights or asking you to surrender the rights. Therefore, you have 31 | certain responsibilities if you distribute copies of the software, or if 32 | you modify it: responsibilities to respect the freedom of others. 33 | 34 | For example, if you distribute copies of such a program, whether 35 | gratis or for a fee, you must pass on to the recipients the same 36 | freedoms that you received. You must make sure that they, too, receive 37 | or can get the source code. And you must show them these terms so they 38 | know their rights. 39 | 40 | Developers that use the GNU GPL protect your rights with two steps: 41 | (1) assert copyright on the software, and (2) offer you this License 42 | giving you legal permission to copy, distribute and/or modify it. 43 | 44 | For the developers' and authors' protection, the GPL clearly explains 45 | that there is no warranty for this free software. For both users' and 46 | authors' sake, the GPL requires that modified versions be marked as 47 | changed, so that their problems will not be attributed erroneously to 48 | authors of previous versions. 49 | 50 | Some devices are designed to deny users access to install or run 51 | modified versions of the software inside them, although the manufacturer 52 | can do so. This is fundamentally incompatible with the aim of 53 | protecting users' freedom to change the software. The systematic 54 | pattern of such abuse occurs in the area of products for individuals to 55 | use, which is precisely where it is most unacceptable. Therefore, we 56 | have designed this version of the GPL to prohibit the practice for those 57 | products. If such problems arise substantially in other domains, we 58 | stand ready to extend this provision to those domains in future versions 59 | of the GPL, as needed to protect the freedom of users. 60 | 61 | Finally, every program is threatened constantly by software patents. 62 | States should not allow patents to restrict development and use of 63 | software on general-purpose computers, but in those that do, we wish to 64 | avoid the special danger that patents applied to a free program could 65 | make it effectively proprietary. To prevent this, the GPL assures that 66 | patents cannot be used to render the program non-free. 67 | 68 | The precise terms and conditions for copying, distribution and 69 | modification follow. 70 | 71 | TERMS AND CONDITIONS 72 | 73 | 0. Definitions. 74 | 75 | "This License" refers to version 3 of the GNU General Public License. 76 | 77 | "Copyright" also means copyright-like laws that apply to other kinds of 78 | works, such as semiconductor masks. 79 | 80 | "The Program" refers to any copyrightable work licensed under this 81 | License. Each licensee is addressed as "you". "Licensees" and 82 | "recipients" may be individuals or organizations. 83 | 84 | To "modify" a work means to copy from or adapt all or part of the work 85 | in a fashion requiring copyright permission, other than the making of an 86 | exact copy. The resulting work is called a "modified version" of the 87 | earlier work or a work "based on" the earlier work. 88 | 89 | A "covered work" means either the unmodified Program or a work based 90 | on the Program. 91 | 92 | To "propagate" a work means to do anything with it that, without 93 | permission, would make you directly or secondarily liable for 94 | infringement under applicable copyright law, except executing it on a 95 | computer or modifying a private copy. Propagation includes copying, 96 | distribution (with or without modification), making available to the 97 | public, and in some countries other activities as well. 98 | 99 | To "convey" a work means any kind of propagation that enables other 100 | parties to make or receive copies. Mere interaction with a user through 101 | a computer network, with no transfer of a copy, is not conveying. 102 | 103 | An interactive user interface displays "Appropriate Legal Notices" 104 | to the extent that it includes a convenient and prominently visible 105 | feature that (1) displays an appropriate copyright notice, and (2) 106 | tells the user that there is no warranty for the work (except to the 107 | extent that warranties are provided), that licensees may convey the 108 | work under this License, and how to view a copy of this License. If 109 | the interface presents a list of user commands or options, such as a 110 | menu, a prominent item in the list meets this criterion. 111 | 112 | 1. Source Code. 113 | 114 | The "source code" for a work means the preferred form of the work 115 | for making modifications to it. "Object code" means any non-source 116 | form of a work. 117 | 118 | A "Standard Interface" means an interface that either is an official 119 | standard defined by a recognized standards body, or, in the case of 120 | interfaces specified for a particular programming language, one that 121 | is widely used among developers working in that language. 122 | 123 | The "System Libraries" of an executable work include anything, other 124 | than the work as a whole, that (a) is included in the normal form of 125 | packaging a Major Component, but which is not part of that Major 126 | Component, and (b) serves only to enable use of the work with that 127 | Major Component, or to implement a Standard Interface for which an 128 | implementation is available to the public in source code form. A 129 | "Major Component", in this context, means a major essential component 130 | (kernel, window system, and so on) of the specific operating system 131 | (if any) on which the executable work runs, or a compiler used to 132 | produce the work, or an object code interpreter used to run it. 133 | 134 | The "Corresponding Source" for a work in object code form means all 135 | the source code needed to generate, install, and (for an executable 136 | work) run the object code and to modify the work, including scripts to 137 | control those activities. However, it does not include the work's 138 | System Libraries, or general-purpose tools or generally available free 139 | programs which are used unmodified in performing those activities but 140 | which are not part of the work. For example, Corresponding Source 141 | includes interface definition files associated with source files for 142 | the work, and the source code for shared libraries and dynamically 143 | linked subprograms that the work is specifically designed to require, 144 | such as by intimate data communication or control flow between those 145 | subprograms and other parts of the work. 146 | 147 | The Corresponding Source need not include anything that users 148 | can regenerate automatically from other parts of the Corresponding 149 | Source. 150 | 151 | The Corresponding Source for a work in source code form is that 152 | same work. 153 | 154 | 2. Basic Permissions. 155 | 156 | All rights granted under this License are granted for the term of 157 | copyright on the Program, and are irrevocable provided the stated 158 | conditions are met. This License explicitly affirms your unlimited 159 | permission to run the unmodified Program. The output from running a 160 | covered work is covered by this License only if the output, given its 161 | content, constitutes a covered work. This License acknowledges your 162 | rights of fair use or other equivalent, as provided by copyright law. 163 | 164 | You may make, run and propagate covered works that you do not 165 | convey, without conditions so long as your license otherwise remains 166 | in force. You may convey covered works to others for the sole purpose 167 | of having them make modifications exclusively for you, or provide you 168 | with facilities for running those works, provided that you comply with 169 | the terms of this License in conveying all material for which you do 170 | not control copyright. Those thus making or running the covered works 171 | for you must do so exclusively on your behalf, under your direction 172 | and control, on terms that prohibit them from making any copies of 173 | your copyrighted material outside their relationship with you. 174 | 175 | Conveying under any other circumstances is permitted solely under 176 | the conditions stated below. Sublicensing is not allowed; section 10 177 | makes it unnecessary. 178 | 179 | 3. Protecting Users' Legal Rights From Anti-Circumvention Law. 180 | 181 | No covered work shall be deemed part of an effective technological 182 | measure under any applicable law fulfilling obligations under article 183 | 11 of the WIPO copyright treaty adopted on 20 December 1996, or 184 | similar laws prohibiting or restricting circumvention of such 185 | measures. 186 | 187 | When you convey a covered work, you waive any legal power to forbid 188 | circumvention of technological measures to the extent such circumvention 189 | is effected by exercising rights under this License with respect to 190 | the covered work, and you disclaim any intention to limit operation or 191 | modification of the work as a means of enforcing, against the work's 192 | users, your or third parties' legal rights to forbid circumvention of 193 | technological measures. 194 | 195 | 4. Conveying Verbatim Copies. 196 | 197 | You may convey verbatim copies of the Program's source code as you 198 | receive it, in any medium, provided that you conspicuously and 199 | appropriately publish on each copy an appropriate copyright notice; 200 | keep intact all notices stating that this License and any 201 | non-permissive terms added in accord with section 7 apply to the code; 202 | keep intact all notices of the absence of any warranty; and give all 203 | recipients a copy of this License along with the Program. 204 | 205 | You may charge any price or no price for each copy that you convey, 206 | and you may offer support or warranty protection for a fee. 207 | 208 | 5. Conveying Modified Source Versions. 209 | 210 | You may convey a work based on the Program, or the modifications to 211 | produce it from the Program, in the form of source code under the 212 | terms of section 4, provided that you also meet all of these conditions: 213 | 214 | a) The work must carry prominent notices stating that you modified 215 | it, and giving a relevant date. 216 | 217 | b) The work must carry prominent notices stating that it is 218 | released under this License and any conditions added under section 219 | 7. This requirement modifies the requirement in section 4 to 220 | "keep intact all notices". 221 | 222 | c) You must license the entire work, as a whole, under this 223 | License to anyone who comes into possession of a copy. This 224 | License will therefore apply, along with any applicable section 7 225 | additional terms, to the whole of the work, and all its parts, 226 | regardless of how they are packaged. This License gives no 227 | permission to license the work in any other way, but it does not 228 | invalidate such permission if you have separately received it. 229 | 230 | d) If the work has interactive user interfaces, each must display 231 | Appropriate Legal Notices; however, if the Program has interactive 232 | interfaces that do not display Appropriate Legal Notices, your 233 | work need not make them do so. 234 | 235 | A compilation of a covered work with other separate and independent 236 | works, which are not by their nature extensions of the covered work, 237 | and which are not combined with it such as to form a larger program, 238 | in or on a volume of a storage or distribution medium, is called an 239 | "aggregate" if the compilation and its resulting copyright are not 240 | used to limit the access or legal rights of the compilation's users 241 | beyond what the individual works permit. Inclusion of a covered work 242 | in an aggregate does not cause this License to apply to the other 243 | parts of the aggregate. 244 | 245 | 6. Conveying Non-Source Forms. 246 | 247 | You may convey a covered work in object code form under the terms 248 | of sections 4 and 5, provided that you also convey the 249 | machine-readable Corresponding Source under the terms of this License, 250 | in one of these ways: 251 | 252 | a) Convey the object code in, or embodied in, a physical product 253 | (including a physical distribution medium), accompanied by the 254 | Corresponding Source fixed on a durable physical medium 255 | customarily used for software interchange. 256 | 257 | b) Convey the object code in, or embodied in, a physical product 258 | (including a physical distribution medium), accompanied by a 259 | written offer, valid for at least three years and valid for as 260 | long as you offer spare parts or customer support for that product 261 | model, to give anyone who possesses the object code either (1) a 262 | copy of the Corresponding Source for all the software in the 263 | product that is covered by this License, on a durable physical 264 | medium customarily used for software interchange, for a price no 265 | more than your reasonable cost of physically performing this 266 | conveying of source, or (2) access to copy the 267 | Corresponding Source from a network server at no charge. 268 | 269 | c) Convey individual copies of the object code with a copy of the 270 | written offer to provide the Corresponding Source. This 271 | alternative is allowed only occasionally and noncommercially, and 272 | only if you received the object code with such an offer, in accord 273 | with subsection 6b. 274 | 275 | d) Convey the object code by offering access from a designated 276 | place (gratis or for a charge), and offer equivalent access to the 277 | Corresponding Source in the same way through the same place at no 278 | further charge. You need not require recipients to copy the 279 | Corresponding Source along with the object code. If the place to 280 | copy the object code is a network server, the Corresponding Source 281 | may be on a different server (operated by you or a third party) 282 | that supports equivalent copying facilities, provided you maintain 283 | clear directions next to the object code saying where to find the 284 | Corresponding Source. Regardless of what server hosts the 285 | Corresponding Source, you remain obligated to ensure that it is 286 | available for as long as needed to satisfy these requirements. 287 | 288 | e) Convey the object code using peer-to-peer transmission, provided 289 | you inform other peers where the object code and Corresponding 290 | Source of the work are being offered to the general public at no 291 | charge under subsection 6d. 292 | 293 | A separable portion of the object code, whose source code is excluded 294 | from the Corresponding Source as a System Library, need not be 295 | included in conveying the object code work. 296 | 297 | A "User Product" is either (1) a "consumer product", which means any 298 | tangible personal property which is normally used for personal, family, 299 | or household purposes, or (2) anything designed or sold for incorporation 300 | into a dwelling. In determining whether a product is a consumer product, 301 | doubtful cases shall be resolved in favor of coverage. For a particular 302 | product received by a particular user, "normally used" refers to a 303 | typical or common use of that class of product, regardless of the status 304 | of the particular user or of the way in which the particular user 305 | actually uses, or expects or is expected to use, the product. A product 306 | is a consumer product regardless of whether the product has substantial 307 | commercial, industrial or non-consumer uses, unless such uses represent 308 | the only significant mode of use of the product. 309 | 310 | "Installation Information" for a User Product means any methods, 311 | procedures, authorization keys, or other information required to install 312 | and execute modified versions of a covered work in that User Product from 313 | a modified version of its Corresponding Source. The information must 314 | suffice to ensure that the continued functioning of the modified object 315 | code is in no case prevented or interfered with solely because 316 | modification has been made. 317 | 318 | If you convey an object code work under this section in, or with, or 319 | specifically for use in, a User Product, and the conveying occurs as 320 | part of a transaction in which the right of possession and use of the 321 | User Product is transferred to the recipient in perpetuity or for a 322 | fixed term (regardless of how the transaction is characterized), the 323 | Corresponding Source conveyed under this section must be accompanied 324 | by the Installation Information. But this requirement does not apply 325 | if neither you nor any third party retains the ability to install 326 | modified object code on the User Product (for example, the work has 327 | been installed in ROM). 328 | 329 | The requirement to provide Installation Information does not include a 330 | requirement to continue to provide support service, warranty, or updates 331 | for a work that has been modified or installed by the recipient, or for 332 | the User Product in which it has been modified or installed. Access to a 333 | network may be denied when the modification itself materially and 334 | adversely affects the operation of the network or violates the rules and 335 | protocols for communication across the network. 336 | 337 | Corresponding Source conveyed, and Installation Information provided, 338 | in accord with this section must be in a format that is publicly 339 | documented (and with an implementation available to the public in 340 | source code form), and must require no special password or key for 341 | unpacking, reading or copying. 342 | 343 | 7. Additional Terms. 344 | 345 | "Additional permissions" are terms that supplement the terms of this 346 | License by making exceptions from one or more of its conditions. 347 | Additional permissions that are applicable to the entire Program shall 348 | be treated as though they were included in this License, to the extent 349 | that they are valid under applicable law. If additional permissions 350 | apply only to part of the Program, that part may be used separately 351 | under those permissions, but the entire Program remains governed by 352 | this License without regard to the additional permissions. 353 | 354 | When you convey a copy of a covered work, you may at your option 355 | remove any additional permissions from that copy, or from any part of 356 | it. (Additional permissions may be written to require their own 357 | removal in certain cases when you modify the work.) You may place 358 | additional permissions on material, added by you to a covered work, 359 | for which you have or can give appropriate copyright permission. 360 | 361 | Notwithstanding any other provision of this License, for material you 362 | add to a covered work, you may (if authorized by the copyright holders of 363 | that material) supplement the terms of this License with terms: 364 | 365 | a) Disclaiming warranty or limiting liability differently from the 366 | terms of sections 15 and 16 of this License; or 367 | 368 | b) Requiring preservation of specified reasonable legal notices or 369 | author attributions in that material or in the Appropriate Legal 370 | Notices displayed by works containing it; or 371 | 372 | c) Prohibiting misrepresentation of the origin of that material, or 373 | requiring that modified versions of such material be marked in 374 | reasonable ways as different from the original version; or 375 | 376 | d) Limiting the use for publicity purposes of names of licensors or 377 | authors of the material; or 378 | 379 | e) Declining to grant rights under trademark law for use of some 380 | trade names, trademarks, or service marks; or 381 | 382 | f) Requiring indemnification of licensors and authors of that 383 | material by anyone who conveys the material (or modified versions of 384 | it) with contractual assumptions of liability to the recipient, for 385 | any liability that these contractual assumptions directly impose on 386 | those licensors and authors. 387 | 388 | All other non-permissive additional terms are considered "further 389 | restrictions" within the meaning of section 10. If the Program as you 390 | received it, or any part of it, contains a notice stating that it is 391 | governed by this License along with a term that is a further 392 | restriction, you may remove that term. If a license document contains 393 | a further restriction but permits relicensing or conveying under this 394 | License, you may add to a covered work material governed by the terms 395 | of that license document, provided that the further restriction does 396 | not survive such relicensing or conveying. 397 | 398 | If you add terms to a covered work in accord with this section, you 399 | must place, in the relevant source files, a statement of the 400 | additional terms that apply to those files, or a notice indicating 401 | where to find the applicable terms. 402 | 403 | Additional terms, permissive or non-permissive, may be stated in the 404 | form of a separately written license, or stated as exceptions; 405 | the above requirements apply either way. 406 | 407 | 8. Termination. 408 | 409 | You may not propagate or modify a covered work except as expressly 410 | provided under this License. Any attempt otherwise to propagate or 411 | modify it is void, and will automatically terminate your rights under 412 | this License (including any patent licenses granted under the third 413 | paragraph of section 11). 414 | 415 | However, if you cease all violation of this License, then your 416 | license from a particular copyright holder is reinstated (a) 417 | provisionally, unless and until the copyright holder explicitly and 418 | finally terminates your license, and (b) permanently, if the copyright 419 | holder fails to notify you of the violation by some reasonable means 420 | prior to 60 days after the cessation. 421 | 422 | Moreover, your license from a particular copyright holder is 423 | reinstated permanently if the copyright holder notifies you of the 424 | violation by some reasonable means, this is the first time you have 425 | received notice of violation of this License (for any work) from that 426 | copyright holder, and you cure the violation prior to 30 days after 427 | your receipt of the notice. 428 | 429 | Termination of your rights under this section does not terminate the 430 | licenses of parties who have received copies or rights from you under 431 | this License. If your rights have been terminated and not permanently 432 | reinstated, you do not qualify to receive new licenses for the same 433 | material under section 10. 434 | 435 | 9. Acceptance Not Required for Having Copies. 436 | 437 | You are not required to accept this License in order to receive or 438 | run a copy of the Program. Ancillary propagation of a covered work 439 | occurring solely as a consequence of using peer-to-peer transmission 440 | to receive a copy likewise does not require acceptance. However, 441 | nothing other than this License grants you permission to propagate or 442 | modify any covered work. These actions infringe copyright if you do 443 | not accept this License. Therefore, by modifying or propagating a 444 | covered work, you indicate your acceptance of this License to do so. 445 | 446 | 10. Automatic Licensing of Downstream Recipients. 447 | 448 | Each time you convey a covered work, the recipient automatically 449 | receives a license from the original licensors, to run, modify and 450 | propagate that work, subject to this License. You are not responsible 451 | for enforcing compliance by third parties with this License. 452 | 453 | An "entity transaction" is a transaction transferring control of an 454 | organization, or substantially all assets of one, or subdividing an 455 | organization, or merging organizations. If propagation of a covered 456 | work results from an entity transaction, each party to that 457 | transaction who receives a copy of the work also receives whatever 458 | licenses to the work the party's predecessor in interest had or could 459 | give under the previous paragraph, plus a right to possession of the 460 | Corresponding Source of the work from the predecessor in interest, if 461 | the predecessor has it or can get it with reasonable efforts. 462 | 463 | You may not impose any further restrictions on the exercise of the 464 | rights granted or affirmed under this License. For example, you may 465 | not impose a license fee, royalty, or other charge for exercise of 466 | rights granted under this License, and you may not initiate litigation 467 | (including a cross-claim or counterclaim in a lawsuit) alleging that 468 | any patent claim is infringed by making, using, selling, offering for 469 | sale, or importing the Program or any portion of it. 470 | 471 | 11. Patents. 472 | 473 | A "contributor" is a copyright holder who authorizes use under this 474 | License of the Program or a work on which the Program is based. The 475 | work thus licensed is called the contributor's "contributor version". 476 | 477 | A contributor's "essential patent claims" are all patent claims 478 | owned or controlled by the contributor, whether already acquired or 479 | hereafter acquired, that would be infringed by some manner, permitted 480 | by this License, of making, using, or selling its contributor version, 481 | but do not include claims that would be infringed only as a 482 | consequence of further modification of the contributor version. For 483 | purposes of this definition, "control" includes the right to grant 484 | patent sublicenses in a manner consistent with the requirements of 485 | this License. 486 | 487 | Each contributor grants you a non-exclusive, worldwide, royalty-free 488 | patent license under the contributor's essential patent claims, to 489 | make, use, sell, offer for sale, import and otherwise run, modify and 490 | propagate the contents of its contributor version. 491 | 492 | In the following three paragraphs, a "patent license" is any express 493 | agreement or commitment, however denominated, not to enforce a patent 494 | (such as an express permission to practice a patent or covenant not to 495 | sue for patent infringement). To "grant" such a patent license to a 496 | party means to make such an agreement or commitment not to enforce a 497 | patent against the party. 498 | 499 | If you convey a covered work, knowingly relying on a patent license, 500 | and the Corresponding Source of the work is not available for anyone 501 | to copy, free of charge and under the terms of this License, through a 502 | publicly available network server or other readily accessible means, 503 | then you must either (1) cause the Corresponding Source to be so 504 | available, or (2) arrange to deprive yourself of the benefit of the 505 | patent license for this particular work, or (3) arrange, in a manner 506 | consistent with the requirements of this License, to extend the patent 507 | license to downstream recipients. "Knowingly relying" means you have 508 | actual knowledge that, but for the patent license, your conveying the 509 | covered work in a country, or your recipient's use of the covered work 510 | in a country, would infringe one or more identifiable patents in that 511 | country that you have reason to believe are valid. 512 | 513 | If, pursuant to or in connection with a single transaction or 514 | arrangement, you convey, or propagate by procuring conveyance of, a 515 | covered work, and grant a patent license to some of the parties 516 | receiving the covered work authorizing them to use, propagate, modify 517 | or convey a specific copy of the covered work, then the patent license 518 | you grant is automatically extended to all recipients of the covered 519 | work and works based on it. 520 | 521 | A patent license is "discriminatory" if it does not include within 522 | the scope of its coverage, prohibits the exercise of, or is 523 | conditioned on the non-exercise of one or more of the rights that are 524 | specifically granted under this License. You may not convey a covered 525 | work if you are a party to an arrangement with a third party that is 526 | in the business of distributing software, under which you make payment 527 | to the third party based on the extent of your activity of conveying 528 | the work, and under which the third party grants, to any of the 529 | parties who would receive the covered work from you, a discriminatory 530 | patent license (a) in connection with copies of the covered work 531 | conveyed by you (or copies made from those copies), or (b) primarily 532 | for and in connection with specific products or compilations that 533 | contain the covered work, unless you entered into that arrangement, 534 | or that patent license was granted, prior to 28 March 2007. 535 | 536 | Nothing in this License shall be construed as excluding or limiting 537 | any implied license or other defenses to infringement that may 538 | otherwise be available to you under applicable patent law. 539 | 540 | 12. No Surrender of Others' Freedom. 541 | 542 | If conditions are imposed on you (whether by court order, agreement or 543 | otherwise) that contradict the conditions of this License, they do not 544 | excuse you from the conditions of this License. If you cannot convey a 545 | covered work so as to satisfy simultaneously your obligations under this 546 | License and any other pertinent obligations, then as a consequence you may 547 | not convey it at all. For example, if you agree to terms that obligate you 548 | to collect a royalty for further conveying from those to whom you convey 549 | the Program, the only way you could satisfy both those terms and this 550 | License would be to refrain entirely from conveying the Program. 551 | 552 | 13. Use with the GNU Affero General Public License. 553 | 554 | Notwithstanding any other provision of this License, you have 555 | permission to link or combine any covered work with a work licensed 556 | under version 3 of the GNU Affero General Public License into a single 557 | combined work, and to convey the resulting work. The terms of this 558 | License will continue to apply to the part which is the covered work, 559 | but the special requirements of the GNU Affero General Public License, 560 | section 13, concerning interaction through a network will apply to the 561 | combination as such. 562 | 563 | 14. Revised Versions of this License. 564 | 565 | The Free Software Foundation may publish revised and/or new versions of 566 | the GNU General Public License from time to time. Such new versions will 567 | be similar in spirit to the present version, but may differ in detail to 568 | address new problems or concerns. 569 | 570 | Each version is given a distinguishing version number. If the 571 | Program specifies that a certain numbered version of the GNU General 572 | Public License "or any later version" applies to it, you have the 573 | option of following the terms and conditions either of that numbered 574 | version or of any later version published by the Free Software 575 | Foundation. If the Program does not specify a version number of the 576 | GNU General Public License, you may choose any version ever published 577 | by the Free Software Foundation. 578 | 579 | If the Program specifies that a proxy can decide which future 580 | versions of the GNU General Public License can be used, that proxy's 581 | public statement of acceptance of a version permanently authorizes you 582 | to choose that version for the Program. 583 | 584 | Later license versions may give you additional or different 585 | permissions. However, no additional obligations are imposed on any 586 | author or copyright holder as a result of your choosing to follow a 587 | later version. 588 | 589 | 15. Disclaimer of Warranty. 590 | 591 | THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY 592 | APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT 593 | HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY 594 | OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, 595 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 596 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM 597 | IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF 598 | ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 599 | 600 | 16. Limitation of Liability. 601 | 602 | IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 603 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS 604 | THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY 605 | GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE 606 | USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF 607 | DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD 608 | PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), 609 | EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF 610 | SUCH DAMAGES. 611 | 612 | 17. Interpretation of Sections 15 and 16. 613 | 614 | If the disclaimer of warranty and limitation of liability provided 615 | above cannot be given local legal effect according to their terms, 616 | reviewing courts shall apply local law that most closely approximates 617 | an absolute waiver of all civil liability in connection with the 618 | Program, unless a warranty or assumption of liability accompanies a 619 | copy of the Program in return for a fee. 620 | 621 | END OF TERMS AND CONDITIONS 622 | 623 | How to Apply These Terms to Your New Programs 624 | 625 | If you develop a new program, and you want it to be of the greatest 626 | possible use to the public, the best way to achieve this is to make it 627 | free software which everyone can redistribute and change under these terms. 628 | 629 | To do so, attach the following notices to the program. It is safest 630 | to attach them to the start of each source file to most effectively 631 | state the exclusion of warranty; and each file should have at least 632 | the "copyright" line and a pointer to where the full notice is found. 633 | 634 | 635 | Copyright (C) 636 | 637 | This program is free software: you can redistribute it and/or modify 638 | it under the terms of the GNU General Public License as published by 639 | the Free Software Foundation, either version 3 of the License, or 640 | (at your option) any later version. 641 | 642 | This program is distributed in the hope that it will be useful, 643 | but WITHOUT ANY WARRANTY; without even the implied warranty of 644 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 645 | GNU General Public License for more details. 646 | 647 | You should have received a copy of the GNU General Public License 648 | along with this program. If not, see . 649 | 650 | Also add information on how to contact you by electronic and paper mail. 651 | 652 | If the program does terminal interaction, make it output a short 653 | notice like this when it starts in an interactive mode: 654 | 655 | Copyright (C) 656 | This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 657 | This is free software, and you are welcome to redistribute it 658 | under certain conditions; type `show c' for details. 659 | 660 | The hypothetical commands `show w' and `show c' should show the appropriate 661 | parts of the General Public License. Of course, your program's commands 662 | might be different; for a GUI interface, you would use an "about box". 663 | 664 | You should also get your employer (if you work as a programmer) or school, 665 | if any, to sign a "copyright disclaimer" for the program, if necessary. 666 | For more information on this, and how to apply and follow the GNU GPL, see 667 | . 668 | 669 | The GNU General Public License does not permit incorporating your program 670 | into proprietary programs. If your program is a subroutine library, you 671 | may consider it more useful to permit linking proprietary applications with 672 | the library. If this is what you want to do, use the GNU Lesser General 673 | Public License instead of this License. But first, please read 674 | . 675 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # eth-local 2 | 3 | #### NOTE: This project is still in development, not all components are functional. 4 | 5 | The purpose of eth-local is to offer a standardized way to store your keystore files on your local machine. 6 | 7 | The core functionality of this application is the ability of the cli to safely transmit pre-signed tx to a website without the need of having Metamask installed on the browser. The cli runs a simple HTTP server which allows the npm module to connect to it. 8 | 9 | 10 | 11 | ![Alt Text](https://imgur.com/yPDD97F.png) 12 | 13 | 14 | `./cli` is the CLI as well as an express server that can be run optionally. 15 | 16 | `./web` is a create-react-app and will serve as testing ground for the npm module that will interact with the express server in the CLI. 17 | 18 | `./client` is intended to be a daemon (currently just a node app) that initiates an electron app to prompt the user for their password. 19 | 20 | ## Running 21 | 22 | 1. Start the cli by running `cd cli && npm i && node app.js`. You will prompted with all availible options. In necessary initiate keystore and create a key pair. 23 | 24 | 2. Start the dev web app server by running `cd web && npm i && npm start`. 25 | 26 | 3. Following the instructions in the dev web app will initiate the elctron prompt. 27 | 28 | 29 | ## Features 30 | 31 | - [x] Generate a wallet 32 | - [x] Encrypt a wallet 33 | - [x] Mnemonic support 34 | - [x] Proof of HTTP connection from client <-> cli made 35 | - [ ] Get balance 36 | - [ ] Transfer eth 37 | - [ ] Electron prompt 38 | - [ ] Transaction signing 39 | 40 | ## Details 41 | 42 | ### Cli 43 | - Uses the spawn() library to launch electron prompt (see `cli/utils/spawn.js`) 44 | - stdin/out are supposed to provide data to and from the electron prompt (WIP) 45 | 46 | ### Client 47 | 48 | - `/ui` is the UI for the electron app, standard create-react-app 49 | - `/app` is the deployable part, which includes a production build of `ui/` (TODO: Setup linkage or change structure so we don't have to copy build from `ui/`. 50 | - `app/main.js` is the electron app. This is where you can configure it. 51 | - Launching the electron app on its own may be troublesome, you must run it with electron (eg. `electron main.js`) 52 | 53 | 54 | ### Web 55 | - This is just a front end for testing purposes 56 | 57 | 58 | 59 | Interested in lending a hand? Reach out to `david at chainsafe dot io`:) 60 | -------------------------------------------------------------------------------- /cli/.gitignore: -------------------------------------------------------------------------------- 1 | .idea/ 2 | -------------------------------------------------------------------------------- /cli/README.MD: -------------------------------------------------------------------------------- 1 | # CLI 2 | 3 | #### Setup 4 | - `npm install` 5 | 6 | #### How To Use 7 | - `./app.js ` 8 | 9 | Note: executing `./app.js` will output a helper of all available commands. 10 | 11 | #### Available Arguments: 12 | 13 | 1. `setup` - Creates a directory in the users home directory where private keys will be stored. 14 | 15 | 2. `wallet` - Prompts user for a list of wallet related options. 16 | 17 | 3. `start` - Starts an express server to allow communication with a browser. 18 | 19 | 20 | TODO: 21 | - [x] Use a cli package 22 | - [] Add wallet decryption 23 | - [] Add ability to check balance 24 | - [] Add ability to send pre-signed tx 25 | -------------------------------------------------------------------------------- /cli/app.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | const express = require('express'); 3 | const clear = require('clear'); 4 | const chalk = require('chalk'); 5 | const figlet = require('figlet'); 6 | const program = require('commander'); 7 | const app = express(); 8 | var bodyParser = require('body-parser') 9 | const BN = require('ethereumjs-util').BN 10 | const {log, debug} = require('./utils/logger') 11 | 12 | 13 | 14 | // Relative imports 15 | const Setup = require('./utils/setup'); 16 | const Wallet = require('./utils/wallet'); 17 | const Sign = require('./utils/sign'); 18 | const spawn = require('./utils/spawn') 19 | 20 | 21 | let signedTransactionObject; 22 | 23 | // Constants 24 | const PORT = 3210; 25 | app.use(bodyParser.json()) 26 | 27 | // Clear terminal & show message. 28 | clear(); 29 | console.log( 30 | chalk.yellow( 31 | figlet.textSync('ETH-LOCAL', { horizontalLayout: 'full' }) 32 | ) 33 | ); 34 | 35 | // Flags 36 | program 37 | .version('0.1.0') 38 | .option('-s, --setup', 'Setup the wallet in your local drive.') 39 | .option('-S, --start', 'Start app.') 40 | .option('-w, --wallet', 'Wallet functionality.') 41 | .parse(process.argv); 42 | 43 | // Show helper if no arguments are passed 44 | if (!process.argv.slice(2).length) program.help(); 45 | // Verify the setup 46 | else Setup.Verify(); 47 | 48 | // Execute functions based on arguments 49 | if (program.setup) Setup.Init(); 50 | if (program.start) app.listen(PORT); 51 | if (program.wallet) Wallet.Choose(); 52 | 53 | // Cross Origin middleware 54 | app.use(function(req, res, next) { 55 | res.header("Access-Control-Allow-Origin", "*"); 56 | res.header("Access-Control-Allow-Headers", "Origin, X-Requested-With, Content-Type, Accept"); 57 | next() 58 | }); 59 | 60 | app.get('/', (req, res) => res.send({connected: true})); 61 | 62 | app.get('/getAccounts', (req, res) => { 63 | console.log('Received request'); 64 | }); 65 | 66 | app.get('/req', (req, res) => { 67 | const to = req.query.to 68 | const value = req.query.value 69 | console.log('received ' + to + " " + value ); 70 | }); 71 | 72 | app.get('/wallets', (req, res) => { 73 | res.send(Wallet.getWallets()); 74 | }) 75 | 76 | // used for Web3 tx signing 77 | var node_endpoint = "http://127.0.0.1:8545" 78 | var Web3 = require("web3"); 79 | var web3 = new Web3(new Web3.providers.HttpProvider(node_endpoint)); 80 | var addr1 = "0x781eD7a40BE08584fCd086e3e8337154B20B4e3B"; // test from account 81 | 82 | app.post('/transactionDetails', async(req, res) => { 83 | //const from = req.body.from 84 | //TODO: determine why req.body.from is undefined for me (ed) 85 | debug('req.body.from:', req.body.from) 86 | const from = req.body.from//'0xd9Ccb5FFd474b7830e41a03E1675084b3e27DBd4'; 87 | const to = req.body.to 88 | const value = new BN(req.body.value); 89 | //TODO: Find better way of getting user password 90 | const password = 'password'; 91 | 92 | let realPW = await spawn.start() 93 | 94 | var rawTx = {}; 95 | rawTx.nonce = web3.utils.toHex(web3.eth.getTransactionCount(from)); 96 | rawTx.to = to; 97 | rawTx.gasPrice = web3.utils.toHex(31000000000); 98 | rawTx.gasLimit = web3.utils.toHex(21000); 99 | rawTx.value = web3.utils.toHex(web3.utils.toWei(value, 'ether')); 100 | rawTx.data = ""; 101 | 102 | 103 | Sign.SignTX(rawTx, from, password).then((val) => { 104 | console.log('signed digest: ', val); 105 | signedTransactionObject = val; 106 | }).catch(function(error) { 107 | console.log(error); 108 | }); 109 | 110 | console.log("to: " + to); 111 | console.log("from: " + from); 112 | console.log("value: " + value); 113 | console.log("rawTX: ", rawTx); 114 | }) 115 | 116 | app.get("/getSignedTransaction", (req, res) => { 117 | console.log(signedTransactionObject); 118 | res.send(signedTransactionObject); 119 | }) -------------------------------------------------------------------------------- /cli/err.out: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ChainSafe/eth-local/8a583fbab45c0eb36278925e1f404f2845c25f9c/cli/err.out -------------------------------------------------------------------------------- /cli/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "eth-local-cli", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "main.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "chalk": "^2.4.1", 13 | "clear": "^0.1.0", 14 | "commander": "^2.15.1", 15 | "electron": "^2.0.4", 16 | "ethereumjs-tx": "^1.3.6", 17 | "ethereumjs-util": "^5.2.0", 18 | "ethers": "^3.0.17", 19 | "express": "^4.16.3", 20 | "figlet": "^1.2.0", 21 | "inquirer": "^5.2.0", 22 | "web3": "^1.0.0-beta.34" 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /cli/utils/constants.js: -------------------------------------------------------------------------------- 1 | // Require the users home directory 2 | const HOME_DIR = require('os').homedir(); 3 | const ETH_HOME = '.eth-local'; 4 | const FULL_PATH = require('path').join(HOME_DIR, ETH_HOME); 5 | 6 | module.exports = { HOME_DIR, ETH_HOME, FULL_PATH }; -------------------------------------------------------------------------------- /cli/utils/err.out: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ChainSafe/eth-local/8a583fbab45c0eb36278925e1f404f2845c25f9c/cli/utils/err.out -------------------------------------------------------------------------------- /cli/utils/logger.js: -------------------------------------------------------------------------------- 1 | const debug = (...msgs) => { 2 | if(process.env.DEBUG === 'true'){ 3 | msgs.forEach((msg) => console.log(msg)) 4 | } 5 | } 6 | 7 | const log = (...msgs) => { 8 | msgs.forEach((msg) => console.log(msg)) 9 | } 10 | 11 | module.exports = {log, debug} 12 | 13 | -------------------------------------------------------------------------------- /cli/utils/setup.js: -------------------------------------------------------------------------------- 1 | const inquirer = require('inquirer'); 2 | const fs = require('fs'); 3 | const { HOME_DIR, ETH_HOME, FULL_PATH } = require('./constants'); 4 | 5 | Verify = () => { 6 | console.log(`\nChecking if ${ETH_HOME} exists in ${HOME_DIR}...`); 7 | if (!fs.existsSync(FULL_PATH)) { 8 | console.log('\nDirectory structure not found! Please run setup'); 9 | } else { 10 | console.log(`${ETH_HOME} found in ${HOME_DIR}!`); 11 | } 12 | }; 13 | 14 | const question = [{ 15 | name: 'input', 16 | type: 'confirm', 17 | message: `Create directory ${ETH_HOME} in ${HOME_DIR}?` 18 | }]; 19 | 20 | Init = async () => { 21 | const res = await inquirer.prompt(question); 22 | if (res.input) { 23 | console.log(`Creating directory...`); 24 | fs.mkdir(FULL_PATH, (err, res) => { 25 | if (err) { 26 | console.log('Error creating directory, exiting...'); 27 | console.log(err); 28 | process.exit(1); 29 | } else { 30 | console.log('Succesfully created directory'); 31 | } 32 | }); 33 | } else { 34 | console.log(`\nUser declined setup.`); 35 | console.log('\nExiting...'); 36 | process.exit(1); 37 | } 38 | }; 39 | 40 | module.exports = {Init, Verify}; 41 | -------------------------------------------------------------------------------- /cli/utils/sign.js: -------------------------------------------------------------------------------- 1 | const ethers = require('ethers') 2 | //const inquirer = require('inquirer') 3 | const fs = require('fs') 4 | const {log, debug} = require('./logger') 5 | const { HOME_DIR, ETH_HOME, FULL_PATH } = require('./constants'); 6 | const {getWallets} = require('./wallet') 7 | 8 | 9 | SignTX = async (tx, walletAddress, password) => { 10 | debug('Wallet addr:', walletAddress) 11 | // Update wallet list 12 | let wallets = getWallets() 13 | debug('Loading key from: ', wallets[walletAddress]) 14 | let keyStore = JSON.parse(fs.readFileSync(wallets[walletAddress])) 15 | debug('KeyStore: ', keyStore) 16 | let privateKey = await ethers.Wallet.fromEncryptedWallet(keyStore, password) 17 | debug('Private Key:', privateKey) 18 | let signingKey = new ethers.SigningKey(privateKey.privateKey) 19 | // Encode tx 20 | let txBytes = ethers.utils.toUtf8Bytes(tx); 21 | let txDigest = ethers.utils.keccak256(txBytes); 22 | debug('txDigest:', txDigest) 23 | // Sign tx and return it 24 | return signingKey.signDigest(txDigest) 25 | } 26 | 27 | module.exports = {SignTX} -------------------------------------------------------------------------------- /cli/utils/spawn.js: -------------------------------------------------------------------------------- 1 | const fs = require('fs') 2 | 3 | const { spawn } = require('child_process', { 4 | stdio: [ 5 | 'pipe', // Use parent's stdin for child 6 | 'pipe', // Pipe child's stdout to parent 7 | fs.openSync('err.out', 'w') // Direct child's stderr to a file 8 | ] 9 | }); 10 | 11 | // Open app and pass params 12 | const start = (params) => { 13 | new Promise((resolve, reject) => { 14 | const child = spawn('../client/app/node_modules/electron/dist/electron', ['../client/app', 'david']); 15 | 16 | child.stdout.on('data', (data) => { 17 | console.log(data.toString()); 18 | resolve(data.toString()) 19 | }); 20 | }) 21 | } 22 | 23 | module.exports = {start} 24 | -------------------------------------------------------------------------------- /cli/utils/wallet.js: -------------------------------------------------------------------------------- 1 | const ethers = require('ethers'); 2 | const inquirer = require('inquirer'); 3 | const fs = require('fs'); 4 | const path = require('path'); 5 | const clear = require('clear'); 6 | const { FULL_PATH } = require('./constants'); 7 | const {log, debug} = require('./logger') 8 | 9 | const createQuestions = [{ 10 | name: 'walletName', 11 | type: 'input', 12 | message: `Desired wallet name? (default public address)` 13 | }, 14 | { 15 | name: 'createConfirm', 16 | type: 'confirm', 17 | message: 'Please write down your mnemonic, confirm once written down.' 18 | }, 19 | { 20 | name: 'choose', 21 | type: 'list', 22 | message: 'Please choose a wallet action:', 23 | choices: ['Create Wallet', 'Get Balance'] 24 | }, 25 | { 26 | name: 'password', 27 | type: 'password', 28 | message: 'Please choose a password to encrypt your wallet:' 29 | }, 30 | { 31 | name: 'confirmPassword', 32 | type: 'password', 33 | message: 'Re-type password:' 34 | }, 35 | ]; 36 | 37 | Choose = async () => { 38 | const res = await inquirer.prompt(createQuestions[2]); 39 | switch (res.choose) { 40 | case 'Create Wallet': 41 | CreateWallet(); 42 | break; 43 | case 'Get Balance': 44 | console.log('Not supported yet!'); 45 | process.exit(1); 46 | break; 47 | } 48 | 49 | }; 50 | 51 | CreateWallet = async () => { 52 | const resName = await inquirer.prompt(createQuestions[0]); 53 | const wallet = ethers.Wallet.createRandom(); 54 | const walletName = resName.walletName === "" ? wallet.address : `${resName.walletName} - ${wallet.address}`; 55 | const filePath = path.join(FULL_PATH, walletName); 56 | // Exit if wallet name already exists. 57 | if (fs.existsSync(filePath)) { 58 | console.log('\nWallet with that name already exists...'); 59 | console.log('\nExiting...'); 60 | process.exit(1); 61 | } 62 | console.log(`mnemonic: ${wallet.mnemonic}`); 63 | await inquirer.prompt(createQuestions[1]); 64 | // Get rid of mnemonic 65 | clear(); 66 | const passRes = await inquirer.prompt(createQuestions.slice(3,5)); 67 | if (passRes.password !== passRes.confirmPassword) { 68 | console.log("Passwords do not match!"); 69 | process.exit(1); 70 | } 71 | const encryptedWallet = await wallet.encrypt(passRes.password, percentLoader); 72 | // write to a new file 73 | fs.writeFile(filePath, JSON.stringify(encryptedWallet), (err) => { 74 | // throws an error, you could also catch it here 75 | if (err) { 76 | console.log(err); 77 | process.exit(1); 78 | } 79 | // success case, the file was saved 80 | console.log(`\nSuccessfully created ${walletName} \n at ${filePath}`); 81 | process.exit(1); 82 | }); 83 | }; 84 | 85 | percentLoader = (percent) => { 86 | process.stdout.clearLine(); 87 | process.stdout.cursorTo(0); 88 | process.stdout.write(`Encrypting... ${parseInt(percent * 100)}%`); 89 | }; 90 | 91 | getWallets = () => { 92 | let files = fs.readdirSync(FULL_PATH); 93 | let wallets = {} 94 | files.map((file, i) => { 95 | debug(`Found file: ${file}`) 96 | // Get name from 'name - address' 97 | wallets[file.split('-')[1].trim()] = FULL_PATH + '/' + file 98 | }) 99 | debug('Wallets found:', wallets) 100 | return wallets 101 | } 102 | 103 | module.exports = { Choose, getWallets } ; -------------------------------------------------------------------------------- /client/app/build/asset-manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "main.js": "static/js/main.10e408d1.js", 3 | "main.js.map": "static/js/main.10e408d1.js.map" 4 | } -------------------------------------------------------------------------------- /client/app/build/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ChainSafe/eth-local/8a583fbab45c0eb36278925e1f404f2845c25f9c/client/app/build/favicon.ico -------------------------------------------------------------------------------- /client/app/build/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | Enter Password 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /client/app/build/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "React App", 3 | "name": "Create React App Sample", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | } 10 | ], 11 | "start_url": "./index.html", 12 | "display": "standalone", 13 | "theme_color": "#000000", 14 | "background_color": "#ffffff" 15 | } 16 | -------------------------------------------------------------------------------- /client/app/build/service-worker.js: -------------------------------------------------------------------------------- 1 | "use strict";var precacheConfig=[["/index.html","bc243c2f42f92818ffbc907c256a7b61"],["/static/js/main.10e408d1.js","5780e2227c77e7b7ebc4fe8ab6047e8a"]],cacheName="sw-precache-v3-sw-precache-webpack-plugin-"+(self.registration?self.registration.scope:""),ignoreUrlParametersMatching=[/^utm_/],addDirectoryIndex=function(e,t){var n=new URL(e);return"/"===n.pathname.slice(-1)&&(n.pathname+=t),n.toString()},cleanResponse=function(t){return t.redirected?("body"in t?Promise.resolve(t.body):t.blob()).then(function(e){return new Response(e,{headers:t.headers,status:t.status,statusText:t.statusText})}):Promise.resolve(t)},createCacheKey=function(e,t,n,r){var a=new URL(e);return r&&a.pathname.match(r)||(a.search+=(a.search?"&":"")+encodeURIComponent(t)+"="+encodeURIComponent(n)),a.toString()},isPathWhitelisted=function(e,t){if(0===e.length)return!0;var n=new URL(t).pathname;return e.some(function(e){return n.match(e)})},stripIgnoredUrlParameters=function(e,n){var t=new URL(e);return t.hash="",t.search=t.search.slice(1).split("&").map(function(e){return e.split("=")}).filter(function(t){return n.every(function(e){return!e.test(t[0])})}).map(function(e){return e.join("=")}).join("&"),t.toString()},hashParamName="_sw-precache",urlsToCacheKeys=new Map(precacheConfig.map(function(e){var t=e[0],n=e[1],r=new URL(t,self.location),a=createCacheKey(r,hashParamName,n,/\.\w{8}\./);return[r.toString(),a]}));function setOfCachedUrls(e){return e.keys().then(function(e){return e.map(function(e){return e.url})}).then(function(e){return new Set(e)})}self.addEventListener("install",function(e){e.waitUntil(caches.open(cacheName).then(function(r){return setOfCachedUrls(r).then(function(n){return Promise.all(Array.from(urlsToCacheKeys.values()).map(function(t){if(!n.has(t)){var e=new Request(t,{credentials:"same-origin"});return fetch(e).then(function(e){if(!e.ok)throw new Error("Request for "+t+" returned a response with status "+e.status);return cleanResponse(e).then(function(e){return r.put(t,e)})})}}))})}).then(function(){return self.skipWaiting()}))}),self.addEventListener("activate",function(e){var n=new Set(urlsToCacheKeys.values());e.waitUntil(caches.open(cacheName).then(function(t){return t.keys().then(function(e){return Promise.all(e.map(function(e){if(!n.has(e.url))return t.delete(e)}))})}).then(function(){return self.clients.claim()}))}),self.addEventListener("fetch",function(t){if("GET"===t.request.method){var e,n=stripIgnoredUrlParameters(t.request.url,ignoreUrlParametersMatching),r="index.html";(e=urlsToCacheKeys.has(n))||(n=addDirectoryIndex(n,r),e=urlsToCacheKeys.has(n));var a="/index.html";!e&&"navigate"===t.request.mode&&isPathWhitelisted(["^(?!\\/__).*"],t.request.url)&&(n=new URL(a,self.location).toString(),e=urlsToCacheKeys.has(n)),e&&t.respondWith(caches.open(cacheName).then(function(e){return e.match(urlsToCacheKeys.get(n)).then(function(e){if(e)return e;throw Error("The cached response that was expected is missing.")})}).catch(function(e){return console.warn('Couldn\'t serve response for "%s" from cache: %O',t.request.url,e),fetch(t.request)}))}}); -------------------------------------------------------------------------------- /client/app/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Hello World! 6 | 7 | 8 |

Hello World!

9 | 10 | We are using Node.js , 11 | Chromium , 12 | and Electron . 13 | 14 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /client/app/main.js: -------------------------------------------------------------------------------- 1 | // Modules to control application life and create native browser window 2 | const {app, BrowserWindow} = require('electron') 3 | 4 | // Keep a global reference of the window object, if you don't, the window will 5 | // be closed automatically when the JavaScript object is garbage collected. 6 | let mainWindow 7 | 8 | function createWindow () { 9 | // Create the browser window. 10 | mainWindow = new BrowserWindow({width: 800, height: 300, alwaysOnTop: true}) 11 | 12 | // and load the index.html from the react build folder 13 | mainWindow.loadFile('./build/index.html') 14 | 15 | app.focus() 16 | // Open the DevTools. 17 | // mainWindow.webContents.openDevTools() 18 | 19 | mainWindow.on('close', () => { 20 | let session = mainWindow.webContents.session 21 | // Query all cookies. 22 | session.cookies.get({}, (error, cookies) => { 23 | if(error) { 24 | process.stdout.write(error.toString()) 25 | } 26 | else { 27 | // Write cookies to parent process (use JSON.parse in parent process) 28 | process.stdout.write(JSON.stringify(cookies)) 29 | } 30 | }) 31 | }) 32 | 33 | // Emitted when the window is closed. 34 | mainWindow.on('closed', function () { 35 | 36 | // Dereference the window object, usually you would store windows 37 | // in an array if your app supports multi windows, this is the time 38 | // when you should delete the corresponding element. 39 | mainWindow = null 40 | }) 41 | } 42 | 43 | // This method will be called when Electron has finished 44 | // initialization and is ready to create browser windows. 45 | // Some APIs can only be used after this event occurs. 46 | app.on('ready', createWindow) 47 | 48 | app.on('activate', function () { 49 | // On OS X it's common to re-create a window in the app when the 50 | // dock icon is clicked and there are no other windows open. 51 | if (mainWindow === null) { 52 | createWindow() 53 | } 54 | }) 55 | 56 | process.stdout.write('hello') 57 | 58 | // In this file you can include the rest of your app's specific main process 59 | // code. You can also put them in separate files and require them here. 60 | -------------------------------------------------------------------------------- /client/app/package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "app", 3 | "version": "1.0.0", 4 | "lockfileVersion": 1, 5 | "requires": true, 6 | "dependencies": { 7 | "@types/node": { 8 | "version": "8.10.21", 9 | "resolved": "https://registry.npmjs.org/@types/node/-/node-8.10.21.tgz", 10 | "integrity": "sha512-87XkD9qDXm8fIax+5y7drx84cXsu34ZZqfB7Cial3Q/2lxSoJ/+DRaWckkCbxP41wFSIrrb939VhzaNxj4eY1w==" 11 | }, 12 | "ajv": { 13 | "version": "5.5.2", 14 | "resolved": "https://registry.npmjs.org/ajv/-/ajv-5.5.2.tgz", 15 | "integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=", 16 | "requires": { 17 | "co": "4.6.0", 18 | "fast-deep-equal": "1.1.0", 19 | "fast-json-stable-stringify": "2.0.0", 20 | "json-schema-traverse": "0.3.1" 21 | } 22 | }, 23 | "ansi-regex": { 24 | "version": "2.1.1", 25 | "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", 26 | "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" 27 | }, 28 | "array-find-index": { 29 | "version": "1.0.2", 30 | "resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz", 31 | "integrity": "sha1-3wEKoSh+Fku9pvlyOwqWoexBh6E=" 32 | }, 33 | "asn1": { 34 | "version": "0.2.3", 35 | "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.3.tgz", 36 | "integrity": "sha1-2sh4dxPJlmhJ/IGAd36+nB3fO4Y=" 37 | }, 38 | "assert-plus": { 39 | "version": "1.0.0", 40 | "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", 41 | "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=" 42 | }, 43 | "asynckit": { 44 | "version": "0.4.0", 45 | "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", 46 | "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=" 47 | }, 48 | "aws-sign2": { 49 | "version": "0.7.0", 50 | "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", 51 | "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=" 52 | }, 53 | "aws4": { 54 | "version": "1.7.0", 55 | "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.7.0.tgz", 56 | "integrity": "sha512-32NDda82rhwD9/JBCCkB+MRYDp0oSvlo2IL6rQWA10PQi7tDUM3eqMSltXmY+Oyl/7N3P3qNtAlv7X0d9bI28w==" 57 | }, 58 | "balanced-match": { 59 | "version": "1.0.0", 60 | "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", 61 | "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" 62 | }, 63 | "bcrypt-pbkdf": { 64 | "version": "1.0.2", 65 | "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", 66 | "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", 67 | "optional": true, 68 | "requires": { 69 | "tweetnacl": "0.14.5" 70 | } 71 | }, 72 | "brace-expansion": { 73 | "version": "1.1.11", 74 | "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", 75 | "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", 76 | "requires": { 77 | "balanced-match": "1.0.0", 78 | "concat-map": "0.0.1" 79 | } 80 | }, 81 | "buffer-from": { 82 | "version": "1.1.0", 83 | "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.0.tgz", 84 | "integrity": "sha512-c5mRlguI/Pe2dSZmpER62rSCu0ryKmWddzRYsuXc50U2/g8jMOulc31VZMa4mYx31U5xsmSOpDCgH88Vl9cDGQ==" 85 | }, 86 | "builtin-modules": { 87 | "version": "1.1.1", 88 | "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-1.1.1.tgz", 89 | "integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8=" 90 | }, 91 | "camelcase": { 92 | "version": "2.1.1", 93 | "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-2.1.1.tgz", 94 | "integrity": "sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8=" 95 | }, 96 | "camelcase-keys": { 97 | "version": "2.1.0", 98 | "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-2.1.0.tgz", 99 | "integrity": "sha1-MIvur/3ygRkFHvodkyITyRuPkuc=", 100 | "requires": { 101 | "camelcase": "2.1.1", 102 | "map-obj": "1.0.1" 103 | } 104 | }, 105 | "caseless": { 106 | "version": "0.12.0", 107 | "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", 108 | "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=" 109 | }, 110 | "co": { 111 | "version": "4.6.0", 112 | "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", 113 | "integrity": "sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ=" 114 | }, 115 | "code-point-at": { 116 | "version": "1.1.0", 117 | "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", 118 | "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" 119 | }, 120 | "combined-stream": { 121 | "version": "1.0.6", 122 | "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.6.tgz", 123 | "integrity": "sha1-cj599ugBrFYTETp+RFqbactjKBg=", 124 | "requires": { 125 | "delayed-stream": "1.0.0" 126 | } 127 | }, 128 | "concat-map": { 129 | "version": "0.0.1", 130 | "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", 131 | "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" 132 | }, 133 | "concat-stream": { 134 | "version": "1.6.2", 135 | "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.6.2.tgz", 136 | "integrity": "sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==", 137 | "requires": { 138 | "buffer-from": "1.1.0", 139 | "inherits": "2.0.3", 140 | "readable-stream": "2.3.6", 141 | "typedarray": "0.0.6" 142 | }, 143 | "dependencies": { 144 | "isarray": { 145 | "version": "1.0.0", 146 | "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", 147 | "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" 148 | }, 149 | "readable-stream": { 150 | "version": "2.3.6", 151 | "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", 152 | "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", 153 | "requires": { 154 | "core-util-is": "1.0.2", 155 | "inherits": "2.0.3", 156 | "isarray": "1.0.0", 157 | "process-nextick-args": "2.0.0", 158 | "safe-buffer": "5.1.2", 159 | "string_decoder": "1.1.1", 160 | "util-deprecate": "1.0.2" 161 | } 162 | }, 163 | "string_decoder": { 164 | "version": "1.1.1", 165 | "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", 166 | "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", 167 | "requires": { 168 | "safe-buffer": "5.1.2" 169 | } 170 | } 171 | } 172 | }, 173 | "core-util-is": { 174 | "version": "1.0.2", 175 | "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", 176 | "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" 177 | }, 178 | "currently-unhandled": { 179 | "version": "0.4.1", 180 | "resolved": "https://registry.npmjs.org/currently-unhandled/-/currently-unhandled-0.4.1.tgz", 181 | "integrity": "sha1-mI3zP+qxke95mmE2nddsF635V+o=", 182 | "requires": { 183 | "array-find-index": "1.0.2" 184 | } 185 | }, 186 | "dashdash": { 187 | "version": "1.14.1", 188 | "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", 189 | "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", 190 | "requires": { 191 | "assert-plus": "1.0.0" 192 | } 193 | }, 194 | "debug": { 195 | "version": "2.6.9", 196 | "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", 197 | "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", 198 | "requires": { 199 | "ms": "2.0.0" 200 | } 201 | }, 202 | "decamelize": { 203 | "version": "1.2.0", 204 | "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", 205 | "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" 206 | }, 207 | "deep-extend": { 208 | "version": "0.6.0", 209 | "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", 210 | "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==" 211 | }, 212 | "delayed-stream": { 213 | "version": "1.0.0", 214 | "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", 215 | "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=" 216 | }, 217 | "ecc-jsbn": { 218 | "version": "0.1.1", 219 | "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz", 220 | "integrity": "sha1-D8c6ntXw1Tw4GTOYUj735UN3dQU=", 221 | "optional": true, 222 | "requires": { 223 | "jsbn": "0.1.1" 224 | } 225 | }, 226 | "electron": { 227 | "version": "2.0.4", 228 | "resolved": "https://registry.npmjs.org/electron/-/electron-2.0.4.tgz", 229 | "integrity": "sha512-rtg6aW2IpWfiwMRk9gqr+a/xOrFlch9sgLNg0UJzCmtUUEGTrbaLxqANr3Ahlx+ODmh/V+WfF7IdEpD76bbssA==", 230 | "requires": { 231 | "@types/node": "8.10.21", 232 | "electron-download": "3.3.0", 233 | "extract-zip": "1.6.7" 234 | } 235 | }, 236 | "electron-download": { 237 | "version": "3.3.0", 238 | "resolved": "https://registry.npmjs.org/electron-download/-/electron-download-3.3.0.tgz", 239 | "integrity": "sha1-LP1U1pZsAZxNSa1l++Zcyc3vaMg=", 240 | "requires": { 241 | "debug": "2.6.9", 242 | "fs-extra": "0.30.0", 243 | "home-path": "1.0.6", 244 | "minimist": "1.2.0", 245 | "nugget": "2.0.1", 246 | "path-exists": "2.1.0", 247 | "rc": "1.2.8", 248 | "semver": "5.5.0", 249 | "sumchecker": "1.3.1" 250 | } 251 | }, 252 | "error-ex": { 253 | "version": "1.3.2", 254 | "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", 255 | "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", 256 | "requires": { 257 | "is-arrayish": "0.2.1" 258 | } 259 | }, 260 | "es6-promise": { 261 | "version": "4.2.4", 262 | "resolved": "https://registry.npmjs.org/es6-promise/-/es6-promise-4.2.4.tgz", 263 | "integrity": "sha512-/NdNZVJg+uZgtm9eS3O6lrOLYmQag2DjdEXuPaHlZ6RuVqgqaVZfgYCepEIKsLqwdQArOPtC3XzRLqGGfT8KQQ==" 264 | }, 265 | "extend": { 266 | "version": "3.0.1", 267 | "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", 268 | "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=" 269 | }, 270 | "extract-zip": { 271 | "version": "1.6.7", 272 | "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-1.6.7.tgz", 273 | "integrity": "sha1-qEC0uK9kAyZMjbV/Txp0Mz74H+k=", 274 | "requires": { 275 | "concat-stream": "1.6.2", 276 | "debug": "2.6.9", 277 | "mkdirp": "0.5.1", 278 | "yauzl": "2.4.1" 279 | } 280 | }, 281 | "extsprintf": { 282 | "version": "1.3.0", 283 | "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", 284 | "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=" 285 | }, 286 | "fast-deep-equal": { 287 | "version": "1.1.0", 288 | "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz", 289 | "integrity": "sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ=" 290 | }, 291 | "fast-json-stable-stringify": { 292 | "version": "2.0.0", 293 | "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz", 294 | "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=" 295 | }, 296 | "fd-slicer": { 297 | "version": "1.0.1", 298 | "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.0.1.tgz", 299 | "integrity": "sha1-i1vL2ewyfFBBv5qwI/1nUPEXfmU=", 300 | "requires": { 301 | "pend": "1.2.0" 302 | } 303 | }, 304 | "find-up": { 305 | "version": "1.1.2", 306 | "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", 307 | "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", 308 | "requires": { 309 | "path-exists": "2.1.0", 310 | "pinkie-promise": "2.0.1" 311 | } 312 | }, 313 | "forever-agent": { 314 | "version": "0.6.1", 315 | "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", 316 | "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=" 317 | }, 318 | "form-data": { 319 | "version": "2.3.2", 320 | "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.2.tgz", 321 | "integrity": "sha1-SXBJi+YEwgwAXU9cI67NIda0kJk=", 322 | "requires": { 323 | "asynckit": "0.4.0", 324 | "combined-stream": "1.0.6", 325 | "mime-types": "2.1.18" 326 | } 327 | }, 328 | "fs-extra": { 329 | "version": "0.30.0", 330 | "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-0.30.0.tgz", 331 | "integrity": "sha1-8jP/zAjU2n1DLapEl3aYnbHfk/A=", 332 | "requires": { 333 | "graceful-fs": "4.1.11", 334 | "jsonfile": "2.4.0", 335 | "klaw": "1.3.1", 336 | "path-is-absolute": "1.0.1", 337 | "rimraf": "2.6.2" 338 | } 339 | }, 340 | "fs.realpath": { 341 | "version": "1.0.0", 342 | "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", 343 | "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" 344 | }, 345 | "get-stdin": { 346 | "version": "4.0.1", 347 | "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-4.0.1.tgz", 348 | "integrity": "sha1-uWjGsKBDhDJJAui/Gl3zJXmkUP4=" 349 | }, 350 | "getpass": { 351 | "version": "0.1.7", 352 | "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", 353 | "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", 354 | "requires": { 355 | "assert-plus": "1.0.0" 356 | } 357 | }, 358 | "glob": { 359 | "version": "7.1.2", 360 | "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", 361 | "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", 362 | "requires": { 363 | "fs.realpath": "1.0.0", 364 | "inflight": "1.0.6", 365 | "inherits": "2.0.3", 366 | "minimatch": "3.0.4", 367 | "once": "1.4.0", 368 | "path-is-absolute": "1.0.1" 369 | } 370 | }, 371 | "graceful-fs": { 372 | "version": "4.1.11", 373 | "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz", 374 | "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=" 375 | }, 376 | "har-schema": { 377 | "version": "2.0.0", 378 | "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", 379 | "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=" 380 | }, 381 | "har-validator": { 382 | "version": "5.0.3", 383 | "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.0.3.tgz", 384 | "integrity": "sha1-ukAsJmGU8VlW7xXg/PJCmT9qff0=", 385 | "requires": { 386 | "ajv": "5.5.2", 387 | "har-schema": "2.0.0" 388 | } 389 | }, 390 | "home-path": { 391 | "version": "1.0.6", 392 | "resolved": "https://registry.npmjs.org/home-path/-/home-path-1.0.6.tgz", 393 | "integrity": "sha512-wo+yjrdAtoXt43Vy92a+0IPCYViiyLAHyp0QVS4xL/tfvVz5sXIW1ubLZk3nhVkD92fQpUMKX+fzMjr5F489vw==" 394 | }, 395 | "hosted-git-info": { 396 | "version": "2.7.1", 397 | "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.7.1.tgz", 398 | "integrity": "sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w==" 399 | }, 400 | "http-signature": { 401 | "version": "1.2.0", 402 | "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", 403 | "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", 404 | "requires": { 405 | "assert-plus": "1.0.0", 406 | "jsprim": "1.4.1", 407 | "sshpk": "1.14.2" 408 | } 409 | }, 410 | "indent-string": { 411 | "version": "2.1.0", 412 | "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-2.1.0.tgz", 413 | "integrity": "sha1-ji1INIdCEhtKghi3oTfppSBJ3IA=", 414 | "requires": { 415 | "repeating": "2.0.1" 416 | } 417 | }, 418 | "inflight": { 419 | "version": "1.0.6", 420 | "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", 421 | "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", 422 | "requires": { 423 | "once": "1.4.0", 424 | "wrappy": "1.0.2" 425 | } 426 | }, 427 | "inherits": { 428 | "version": "2.0.3", 429 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", 430 | "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" 431 | }, 432 | "ini": { 433 | "version": "1.3.5", 434 | "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", 435 | "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==" 436 | }, 437 | "is-arrayish": { 438 | "version": "0.2.1", 439 | "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", 440 | "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=" 441 | }, 442 | "is-builtin-module": { 443 | "version": "1.0.0", 444 | "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz", 445 | "integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=", 446 | "requires": { 447 | "builtin-modules": "1.1.1" 448 | } 449 | }, 450 | "is-finite": { 451 | "version": "1.0.2", 452 | "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.0.2.tgz", 453 | "integrity": "sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko=", 454 | "requires": { 455 | "number-is-nan": "1.0.1" 456 | } 457 | }, 458 | "is-fullwidth-code-point": { 459 | "version": "1.0.0", 460 | "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", 461 | "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", 462 | "requires": { 463 | "number-is-nan": "1.0.1" 464 | } 465 | }, 466 | "is-typedarray": { 467 | "version": "1.0.0", 468 | "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", 469 | "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=" 470 | }, 471 | "is-utf8": { 472 | "version": "0.2.1", 473 | "resolved": "https://registry.npmjs.org/is-utf8/-/is-utf8-0.2.1.tgz", 474 | "integrity": "sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI=" 475 | }, 476 | "isarray": { 477 | "version": "0.0.1", 478 | "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", 479 | "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=" 480 | }, 481 | "isstream": { 482 | "version": "0.1.2", 483 | "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", 484 | "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=" 485 | }, 486 | "jsbn": { 487 | "version": "0.1.1", 488 | "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", 489 | "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", 490 | "optional": true 491 | }, 492 | "json-schema": { 493 | "version": "0.2.3", 494 | "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", 495 | "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=" 496 | }, 497 | "json-schema-traverse": { 498 | "version": "0.3.1", 499 | "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz", 500 | "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=" 501 | }, 502 | "json-stringify-safe": { 503 | "version": "5.0.1", 504 | "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", 505 | "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=" 506 | }, 507 | "jsonfile": { 508 | "version": "2.4.0", 509 | "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz", 510 | "integrity": "sha1-NzaitCi4e72gzIO1P6PWM6NcKug=", 511 | "requires": { 512 | "graceful-fs": "4.1.11" 513 | } 514 | }, 515 | "jsprim": { 516 | "version": "1.4.1", 517 | "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", 518 | "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", 519 | "requires": { 520 | "assert-plus": "1.0.0", 521 | "extsprintf": "1.3.0", 522 | "json-schema": "0.2.3", 523 | "verror": "1.10.0" 524 | } 525 | }, 526 | "klaw": { 527 | "version": "1.3.1", 528 | "resolved": "https://registry.npmjs.org/klaw/-/klaw-1.3.1.tgz", 529 | "integrity": "sha1-QIhDO0azsbolnXh4XY6W9zugJDk=", 530 | "requires": { 531 | "graceful-fs": "4.1.11" 532 | } 533 | }, 534 | "load-json-file": { 535 | "version": "1.1.0", 536 | "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", 537 | "integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=", 538 | "requires": { 539 | "graceful-fs": "4.1.11", 540 | "parse-json": "2.2.0", 541 | "pify": "2.3.0", 542 | "pinkie-promise": "2.0.1", 543 | "strip-bom": "2.0.0" 544 | } 545 | }, 546 | "loud-rejection": { 547 | "version": "1.6.0", 548 | "resolved": "https://registry.npmjs.org/loud-rejection/-/loud-rejection-1.6.0.tgz", 549 | "integrity": "sha1-W0b4AUft7leIcPCG0Eghz5mOVR8=", 550 | "requires": { 551 | "currently-unhandled": "0.4.1", 552 | "signal-exit": "3.0.2" 553 | } 554 | }, 555 | "map-obj": { 556 | "version": "1.0.1", 557 | "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz", 558 | "integrity": "sha1-2TPOuSBdgr3PSIb2dCvcK03qFG0=" 559 | }, 560 | "meow": { 561 | "version": "3.7.0", 562 | "resolved": "https://registry.npmjs.org/meow/-/meow-3.7.0.tgz", 563 | "integrity": "sha1-cstmi0JSKCkKu/qFaJJYcwioAfs=", 564 | "requires": { 565 | "camelcase-keys": "2.1.0", 566 | "decamelize": "1.2.0", 567 | "loud-rejection": "1.6.0", 568 | "map-obj": "1.0.1", 569 | "minimist": "1.2.0", 570 | "normalize-package-data": "2.4.0", 571 | "object-assign": "4.1.1", 572 | "read-pkg-up": "1.0.1", 573 | "redent": "1.0.0", 574 | "trim-newlines": "1.0.0" 575 | } 576 | }, 577 | "mime-db": { 578 | "version": "1.33.0", 579 | "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.33.0.tgz", 580 | "integrity": "sha512-BHJ/EKruNIqJf/QahvxwQZXKygOQ256myeN/Ew+THcAa5q+PjyTTMMeNQC4DZw5AwfvelsUrA6B67NKMqXDbzQ==" 581 | }, 582 | "mime-types": { 583 | "version": "2.1.18", 584 | "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.18.tgz", 585 | "integrity": "sha512-lc/aahn+t4/SWV/qcmumYjymLsWfN3ELhpmVuUFjgsORruuZPVSwAQryq+HHGvO/SI2KVX26bx+En+zhM8g8hQ==", 586 | "requires": { 587 | "mime-db": "1.33.0" 588 | } 589 | }, 590 | "minimatch": { 591 | "version": "3.0.4", 592 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", 593 | "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", 594 | "requires": { 595 | "brace-expansion": "1.1.11" 596 | } 597 | }, 598 | "minimist": { 599 | "version": "1.2.0", 600 | "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", 601 | "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" 602 | }, 603 | "mkdirp": { 604 | "version": "0.5.1", 605 | "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", 606 | "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", 607 | "requires": { 608 | "minimist": "0.0.8" 609 | }, 610 | "dependencies": { 611 | "minimist": { 612 | "version": "0.0.8", 613 | "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", 614 | "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" 615 | } 616 | } 617 | }, 618 | "ms": { 619 | "version": "2.0.0", 620 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", 621 | "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" 622 | }, 623 | "normalize-package-data": { 624 | "version": "2.4.0", 625 | "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.4.0.tgz", 626 | "integrity": "sha512-9jjUFbTPfEy3R/ad/2oNbKtW9Hgovl5O1FvFWKkKblNXoN/Oou6+9+KKohPK13Yc3/TyunyWhJp6gvRNR/PPAw==", 627 | "requires": { 628 | "hosted-git-info": "2.7.1", 629 | "is-builtin-module": "1.0.0", 630 | "semver": "5.5.0", 631 | "validate-npm-package-license": "3.0.3" 632 | } 633 | }, 634 | "nugget": { 635 | "version": "2.0.1", 636 | "resolved": "https://registry.npmjs.org/nugget/-/nugget-2.0.1.tgz", 637 | "integrity": "sha1-IBCVpIfhrTYIGzQy+jytpPjQcbA=", 638 | "requires": { 639 | "debug": "2.6.9", 640 | "minimist": "1.2.0", 641 | "pretty-bytes": "1.0.4", 642 | "progress-stream": "1.2.0", 643 | "request": "2.87.0", 644 | "single-line-log": "1.1.2", 645 | "throttleit": "0.0.2" 646 | } 647 | }, 648 | "number-is-nan": { 649 | "version": "1.0.1", 650 | "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", 651 | "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=" 652 | }, 653 | "oauth-sign": { 654 | "version": "0.8.2", 655 | "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.8.2.tgz", 656 | "integrity": "sha1-Rqarfwrq2N6unsBWV4C31O/rnUM=" 657 | }, 658 | "object-assign": { 659 | "version": "4.1.1", 660 | "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", 661 | "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" 662 | }, 663 | "object-keys": { 664 | "version": "0.4.0", 665 | "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-0.4.0.tgz", 666 | "integrity": "sha1-KKaq50KN0sOpLz2V8hM13SBOAzY=" 667 | }, 668 | "once": { 669 | "version": "1.4.0", 670 | "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", 671 | "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", 672 | "requires": { 673 | "wrappy": "1.0.2" 674 | } 675 | }, 676 | "parse-json": { 677 | "version": "2.2.0", 678 | "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-2.2.0.tgz", 679 | "integrity": "sha1-9ID0BDTvgHQfhGkJn43qGPVaTck=", 680 | "requires": { 681 | "error-ex": "1.3.2" 682 | } 683 | }, 684 | "path-exists": { 685 | "version": "2.1.0", 686 | "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", 687 | "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", 688 | "requires": { 689 | "pinkie-promise": "2.0.1" 690 | } 691 | }, 692 | "path-is-absolute": { 693 | "version": "1.0.1", 694 | "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", 695 | "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" 696 | }, 697 | "path-type": { 698 | "version": "1.1.0", 699 | "resolved": "https://registry.npmjs.org/path-type/-/path-type-1.1.0.tgz", 700 | "integrity": "sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE=", 701 | "requires": { 702 | "graceful-fs": "4.1.11", 703 | "pify": "2.3.0", 704 | "pinkie-promise": "2.0.1" 705 | } 706 | }, 707 | "pend": { 708 | "version": "1.2.0", 709 | "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", 710 | "integrity": "sha1-elfrVQpng/kRUzH89GY9XI4AelA=" 711 | }, 712 | "performance-now": { 713 | "version": "2.1.0", 714 | "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", 715 | "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=" 716 | }, 717 | "pify": { 718 | "version": "2.3.0", 719 | "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", 720 | "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=" 721 | }, 722 | "pinkie": { 723 | "version": "2.0.4", 724 | "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-2.0.4.tgz", 725 | "integrity": "sha1-clVrgM+g1IqXToDnckjoDtT3+HA=" 726 | }, 727 | "pinkie-promise": { 728 | "version": "2.0.1", 729 | "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-2.0.1.tgz", 730 | "integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=", 731 | "requires": { 732 | "pinkie": "2.0.4" 733 | } 734 | }, 735 | "pretty-bytes": { 736 | "version": "1.0.4", 737 | "resolved": "https://registry.npmjs.org/pretty-bytes/-/pretty-bytes-1.0.4.tgz", 738 | "integrity": "sha1-CiLoIQYJrTVUL4yNXSFZr/B1HIQ=", 739 | "requires": { 740 | "get-stdin": "4.0.1", 741 | "meow": "3.7.0" 742 | } 743 | }, 744 | "process-nextick-args": { 745 | "version": "2.0.0", 746 | "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", 747 | "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==" 748 | }, 749 | "progress-stream": { 750 | "version": "1.2.0", 751 | "resolved": "https://registry.npmjs.org/progress-stream/-/progress-stream-1.2.0.tgz", 752 | "integrity": "sha1-LNPP6jO6OonJwSHsM0er6asSX3c=", 753 | "requires": { 754 | "speedometer": "0.1.4", 755 | "through2": "0.2.3" 756 | } 757 | }, 758 | "punycode": { 759 | "version": "1.4.1", 760 | "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", 761 | "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=" 762 | }, 763 | "qs": { 764 | "version": "6.5.2", 765 | "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", 766 | "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==" 767 | }, 768 | "rc": { 769 | "version": "1.2.8", 770 | "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", 771 | "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", 772 | "requires": { 773 | "deep-extend": "0.6.0", 774 | "ini": "1.3.5", 775 | "minimist": "1.2.0", 776 | "strip-json-comments": "2.0.1" 777 | } 778 | }, 779 | "read-pkg": { 780 | "version": "1.1.0", 781 | "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-1.1.0.tgz", 782 | "integrity": "sha1-9f+qXs0pyzHAR0vKfXVra7KePyg=", 783 | "requires": { 784 | "load-json-file": "1.1.0", 785 | "normalize-package-data": "2.4.0", 786 | "path-type": "1.1.0" 787 | } 788 | }, 789 | "read-pkg-up": { 790 | "version": "1.0.1", 791 | "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-1.0.1.tgz", 792 | "integrity": "sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI=", 793 | "requires": { 794 | "find-up": "1.1.2", 795 | "read-pkg": "1.1.0" 796 | } 797 | }, 798 | "readable-stream": { 799 | "version": "1.1.14", 800 | "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz", 801 | "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=", 802 | "requires": { 803 | "core-util-is": "1.0.2", 804 | "inherits": "2.0.3", 805 | "isarray": "0.0.1", 806 | "string_decoder": "0.10.31" 807 | } 808 | }, 809 | "redent": { 810 | "version": "1.0.0", 811 | "resolved": "https://registry.npmjs.org/redent/-/redent-1.0.0.tgz", 812 | "integrity": "sha1-z5Fqsf1fHxbfsggi3W7H9zDCr94=", 813 | "requires": { 814 | "indent-string": "2.1.0", 815 | "strip-indent": "1.0.1" 816 | } 817 | }, 818 | "repeating": { 819 | "version": "2.0.1", 820 | "resolved": "https://registry.npmjs.org/repeating/-/repeating-2.0.1.tgz", 821 | "integrity": "sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo=", 822 | "requires": { 823 | "is-finite": "1.0.2" 824 | } 825 | }, 826 | "request": { 827 | "version": "2.87.0", 828 | "resolved": "https://registry.npmjs.org/request/-/request-2.87.0.tgz", 829 | "integrity": "sha512-fcogkm7Az5bsS6Sl0sibkbhcKsnyon/jV1kF3ajGmF0c8HrttdKTPRT9hieOaQHA5HEq6r8OyWOo/o781C1tNw==", 830 | "requires": { 831 | "aws-sign2": "0.7.0", 832 | "aws4": "1.7.0", 833 | "caseless": "0.12.0", 834 | "combined-stream": "1.0.6", 835 | "extend": "3.0.1", 836 | "forever-agent": "0.6.1", 837 | "form-data": "2.3.2", 838 | "har-validator": "5.0.3", 839 | "http-signature": "1.2.0", 840 | "is-typedarray": "1.0.0", 841 | "isstream": "0.1.2", 842 | "json-stringify-safe": "5.0.1", 843 | "mime-types": "2.1.18", 844 | "oauth-sign": "0.8.2", 845 | "performance-now": "2.1.0", 846 | "qs": "6.5.2", 847 | "safe-buffer": "5.1.2", 848 | "tough-cookie": "2.3.4", 849 | "tunnel-agent": "0.6.0", 850 | "uuid": "3.3.2" 851 | } 852 | }, 853 | "rimraf": { 854 | "version": "2.6.2", 855 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.2.tgz", 856 | "integrity": "sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==", 857 | "requires": { 858 | "glob": "7.1.2" 859 | } 860 | }, 861 | "safe-buffer": { 862 | "version": "5.1.2", 863 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 864 | "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" 865 | }, 866 | "safer-buffer": { 867 | "version": "2.1.2", 868 | "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", 869 | "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" 870 | }, 871 | "semver": { 872 | "version": "5.5.0", 873 | "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz", 874 | "integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA==" 875 | }, 876 | "signal-exit": { 877 | "version": "3.0.2", 878 | "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", 879 | "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=" 880 | }, 881 | "single-line-log": { 882 | "version": "1.1.2", 883 | "resolved": "https://registry.npmjs.org/single-line-log/-/single-line-log-1.1.2.tgz", 884 | "integrity": "sha1-wvg/Jzo+GhbtsJlWYdoO1e8DM2Q=", 885 | "requires": { 886 | "string-width": "1.0.2" 887 | } 888 | }, 889 | "spdx-correct": { 890 | "version": "3.0.0", 891 | "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.0.0.tgz", 892 | "integrity": "sha512-N19o9z5cEyc8yQQPukRCZ9EUmb4HUpnrmaL/fxS2pBo2jbfcFRVuFZ/oFC+vZz0MNNk0h80iMn5/S6qGZOL5+g==", 893 | "requires": { 894 | "spdx-expression-parse": "3.0.0", 895 | "spdx-license-ids": "3.0.0" 896 | } 897 | }, 898 | "spdx-exceptions": { 899 | "version": "2.1.0", 900 | "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.1.0.tgz", 901 | "integrity": "sha512-4K1NsmrlCU1JJgUrtgEeTVyfx8VaYea9J9LvARxhbHtVtohPs/gFGG5yy49beySjlIMhhXZ4QqujIZEfS4l6Cg==" 902 | }, 903 | "spdx-expression-parse": { 904 | "version": "3.0.0", 905 | "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz", 906 | "integrity": "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==", 907 | "requires": { 908 | "spdx-exceptions": "2.1.0", 909 | "spdx-license-ids": "3.0.0" 910 | } 911 | }, 912 | "spdx-license-ids": { 913 | "version": "3.0.0", 914 | "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.0.tgz", 915 | "integrity": "sha512-2+EPwgbnmOIl8HjGBXXMd9NAu02vLjOO1nWw4kmeRDFyHn+M/ETfHxQUK0oXg8ctgVnl9t3rosNVsZ1jG61nDA==" 916 | }, 917 | "speedometer": { 918 | "version": "0.1.4", 919 | "resolved": "https://registry.npmjs.org/speedometer/-/speedometer-0.1.4.tgz", 920 | "integrity": "sha1-mHbb0qFp0xFUAtSObqYynIgWpQ0=" 921 | }, 922 | "sshpk": { 923 | "version": "1.14.2", 924 | "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.14.2.tgz", 925 | "integrity": "sha1-xvxhZIo9nE52T9P8306hBeSSupg=", 926 | "requires": { 927 | "asn1": "0.2.3", 928 | "assert-plus": "1.0.0", 929 | "bcrypt-pbkdf": "1.0.2", 930 | "dashdash": "1.14.1", 931 | "ecc-jsbn": "0.1.1", 932 | "getpass": "0.1.7", 933 | "jsbn": "0.1.1", 934 | "safer-buffer": "2.1.2", 935 | "tweetnacl": "0.14.5" 936 | } 937 | }, 938 | "string-width": { 939 | "version": "1.0.2", 940 | "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", 941 | "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", 942 | "requires": { 943 | "code-point-at": "1.1.0", 944 | "is-fullwidth-code-point": "1.0.0", 945 | "strip-ansi": "3.0.1" 946 | } 947 | }, 948 | "string_decoder": { 949 | "version": "0.10.31", 950 | "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", 951 | "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=" 952 | }, 953 | "strip-ansi": { 954 | "version": "3.0.1", 955 | "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", 956 | "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", 957 | "requires": { 958 | "ansi-regex": "2.1.1" 959 | } 960 | }, 961 | "strip-bom": { 962 | "version": "2.0.0", 963 | "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-2.0.0.tgz", 964 | "integrity": "sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4=", 965 | "requires": { 966 | "is-utf8": "0.2.1" 967 | } 968 | }, 969 | "strip-indent": { 970 | "version": "1.0.1", 971 | "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-1.0.1.tgz", 972 | "integrity": "sha1-DHlipq3vp7vUrDZkYKY4VSrhoKI=", 973 | "requires": { 974 | "get-stdin": "4.0.1" 975 | } 976 | }, 977 | "strip-json-comments": { 978 | "version": "2.0.1", 979 | "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", 980 | "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=" 981 | }, 982 | "sumchecker": { 983 | "version": "1.3.1", 984 | "resolved": "https://registry.npmjs.org/sumchecker/-/sumchecker-1.3.1.tgz", 985 | "integrity": "sha1-ebs7RFbdBPGOvbwNcDodHa7FEF0=", 986 | "requires": { 987 | "debug": "2.6.9", 988 | "es6-promise": "4.2.4" 989 | } 990 | }, 991 | "throttleit": { 992 | "version": "0.0.2", 993 | "resolved": "https://registry.npmjs.org/throttleit/-/throttleit-0.0.2.tgz", 994 | "integrity": "sha1-z+34jmDADdlpe2H90qg0OptoDq8=" 995 | }, 996 | "through2": { 997 | "version": "0.2.3", 998 | "resolved": "https://registry.npmjs.org/through2/-/through2-0.2.3.tgz", 999 | "integrity": "sha1-6zKE2k6jEbbMis42U3SKUqvyWj8=", 1000 | "requires": { 1001 | "readable-stream": "1.1.14", 1002 | "xtend": "2.1.2" 1003 | } 1004 | }, 1005 | "tough-cookie": { 1006 | "version": "2.3.4", 1007 | "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.3.4.tgz", 1008 | "integrity": "sha512-TZ6TTfI5NtZnuyy/Kecv+CnoROnyXn2DN97LontgQpCwsX2XyLYCC0ENhYkehSOwAp8rTQKc/NUIF7BkQ5rKLA==", 1009 | "requires": { 1010 | "punycode": "1.4.1" 1011 | } 1012 | }, 1013 | "trim-newlines": { 1014 | "version": "1.0.0", 1015 | "resolved": "https://registry.npmjs.org/trim-newlines/-/trim-newlines-1.0.0.tgz", 1016 | "integrity": "sha1-WIeWa7WCpFA6QetST301ARgVphM=" 1017 | }, 1018 | "tunnel-agent": { 1019 | "version": "0.6.0", 1020 | "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", 1021 | "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", 1022 | "requires": { 1023 | "safe-buffer": "5.1.2" 1024 | } 1025 | }, 1026 | "tweetnacl": { 1027 | "version": "0.14.5", 1028 | "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", 1029 | "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", 1030 | "optional": true 1031 | }, 1032 | "typedarray": { 1033 | "version": "0.0.6", 1034 | "resolved": "https://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz", 1035 | "integrity": "sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=" 1036 | }, 1037 | "util-deprecate": { 1038 | "version": "1.0.2", 1039 | "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", 1040 | "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" 1041 | }, 1042 | "uuid": { 1043 | "version": "3.3.2", 1044 | "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz", 1045 | "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==" 1046 | }, 1047 | "validate-npm-package-license": { 1048 | "version": "3.0.3", 1049 | "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.3.tgz", 1050 | "integrity": "sha512-63ZOUnL4SIXj4L0NixR3L1lcjO38crAbgrTpl28t8jjrfuiOBL5Iygm+60qPs/KsZGzPNg6Smnc/oY16QTjF0g==", 1051 | "requires": { 1052 | "spdx-correct": "3.0.0", 1053 | "spdx-expression-parse": "3.0.0" 1054 | } 1055 | }, 1056 | "verror": { 1057 | "version": "1.10.0", 1058 | "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", 1059 | "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", 1060 | "requires": { 1061 | "assert-plus": "1.0.0", 1062 | "core-util-is": "1.0.2", 1063 | "extsprintf": "1.3.0" 1064 | } 1065 | }, 1066 | "wrappy": { 1067 | "version": "1.0.2", 1068 | "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", 1069 | "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" 1070 | }, 1071 | "xtend": { 1072 | "version": "2.1.2", 1073 | "resolved": "https://registry.npmjs.org/xtend/-/xtend-2.1.2.tgz", 1074 | "integrity": "sha1-bv7MKk2tjmlixJAbM3znuoe10os=", 1075 | "requires": { 1076 | "object-keys": "0.4.0" 1077 | } 1078 | }, 1079 | "yauzl": { 1080 | "version": "2.4.1", 1081 | "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.4.1.tgz", 1082 | "integrity": "sha1-lSj0QtqxsihOWLQ3m7GU4i4MQAU=", 1083 | "requires": { 1084 | "fd-slicer": "1.0.1" 1085 | } 1086 | } 1087 | } 1088 | } 1089 | -------------------------------------------------------------------------------- /client/app/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "app", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "main.js", 6 | "scripts": { 7 | "start": "electron ." 8 | }, 9 | "author": "David Ansermino ", 10 | "license": "ISC", 11 | "dependencies": { 12 | "electron": "^2.0.4" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /client/ui/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/ignore-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | 6 | # testing 7 | /coverage 8 | 9 | # production 10 | /build 11 | 12 | # misc 13 | .DS_Store 14 | .env.local 15 | .env.development.local 16 | .env.test.local 17 | .env.production.local 18 | 19 | npm-debug.log* 20 | yarn-debug.log* 21 | yarn-error.log* 22 | -------------------------------------------------------------------------------- /client/ui/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ui", 3 | "version": "0.1.0", 4 | "private": true, 5 | "dependencies": { 6 | "react": "^16.4.1", 7 | "react-dom": "^16.4.1", 8 | "react-scripts": "1.1.4", 9 | "semantic-ui-react": "^0.82.0", 10 | "styled-components": "^3.3.3" 11 | }, 12 | "scripts": { 13 | "start": "react-scripts start", 14 | "build": "react-scripts build", 15 | "test": "react-scripts test --env=jsdom", 16 | "eject": "react-scripts eject" 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /client/ui/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ChainSafe/eth-local/8a583fbab45c0eb36278925e1f404f2845c25f9c/client/ui/public/favicon.ico -------------------------------------------------------------------------------- /client/ui/public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 12 | 13 | 22 | React App 23 | 24 | 25 | 28 |
29 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /client/ui/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "React App", 3 | "name": "Create React App Sample", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | } 10 | ], 11 | "start_url": "./index.html", 12 | "display": "standalone", 13 | "theme_color": "#000000", 14 | "background_color": "#ffffff" 15 | } 16 | -------------------------------------------------------------------------------- /client/ui/src/App.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import Loading from './components/Loading'; 3 | import MainContainer from './components/MainContainer'; 4 | 5 | class App extends Component { 6 | constructor(props) { 7 | super(props); 8 | this.state = { 9 | data: false 10 | } 11 | } 12 | 13 | componentDidMount = () => { 14 | setTimeout(() => { 15 | this.setState({ data: true }) 16 | }, 2000); 17 | } 18 | 19 | render() { 20 | return ( 21 |
22 |
23 | { 24 | this.state.data ? : 25 | } 26 |
27 |
28 | ); 29 | } 30 | } 31 | 32 | export default App; 33 | 34 | -------------------------------------------------------------------------------- /client/ui/src/components/Loading.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import styled, { keyframes } from 'styled-components'; 3 | 4 | const foregroundCircle = keyframes` 5 | 0% { 6 | ransform: scale(0.3) rotate(0deg); 7 | } 8 | 12.5% { 9 | transform: scale(0.3) rotate(180deg); 10 | } 11 | 25%, 50% { 12 | opacity: 1; 13 | } 14 | 50% { 15 | transform: scale(1) rotate(720deg); 16 | } 17 | 100% { 18 | transform: scale(0.3) rotate(1800deg); 19 | opacity: 0.5; 20 | } 21 | `; 22 | 23 | const backgroundCircle = keyframes` 24 | 12.5% { 25 | transform: scale(0.3); 26 | } 27 | 90%, 100% { 28 | transform: scale(2); 29 | opacity: 0; 30 | } 31 | `; 32 | 33 | const Loader = styled.div` 34 | width: 100px; 35 | height: 100px; 36 | position: relative; 37 | margin: auto; 38 | &:before, 39 | &:after { 40 | content: ''; 41 | position: absolute; 42 | border-radius: 50%; 43 | width: 100%; 44 | height: 100%; 45 | top: 0; 46 | left: 0; 47 | animation-duration: 3s; 48 | animation-timing-function: linear; 49 | animation-iteration-count: infinite; 50 | } 51 | &:before { 52 | top: -2px; 53 | left: -2px; 54 | border-style: solid; 55 | border-width: 3px 3px 3px 0; 56 | border-color: #fff transparent transparent; 57 | transform: scale(0.3) rotate(0deg); 58 | opacity: 0.5; 59 | animation-name: ${foregroundCircle}; 60 | } 61 | &:after { 62 | background: #fff; 63 | opacity: 0.5; 64 | transform: scale(0); 65 | animation-name: ${backgroundCircle}; 66 | } 67 | `; 68 | 69 | const Wrapper = styled.div` 70 | width: 100%; 71 | height: 100%; 72 | display: flex; 73 | flex-direction: column; 74 | align-items: center; 75 | justify-content: center; 76 | position: absolute; 77 | top: 0; 78 | left: 0; 79 | background-image: linear-gradient(to bottom left, #222222 0%, #000000 100%); 80 | `; 81 | 82 | const Loading = () => 83 | 84 | 85 | ; 86 | 87 | export default Loading; -------------------------------------------------------------------------------- /client/ui/src/components/MainContainer.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react' 2 | import { Button, Checkbox, Form } from 'semantic-ui-react' 3 | 4 | const styles = { 5 | text : { 6 | color: 'white' 7 | } 8 | } 9 | 10 | class MainContainer extends Component { 11 | 12 | constructor(props) { 13 | super(props); 14 | this.state = { 15 | password: "" 16 | } 17 | } 18 | 19 | updatePassword(event) { 20 | console.log("Password " + event.target.value); 21 | this.setState({password: event.target.value }) 22 | } 23 | 24 | submitPassword() { 25 | console.log(this.state.password); 26 | } 27 | 28 | 29 | render() { 30 | return ( 31 |
32 |
33 | 34 | 35 | 40 | 41 | 42 |
43 |
44 | ); 45 | } 46 | } 47 | 48 | export default MainContainer; -------------------------------------------------------------------------------- /client/ui/src/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import ReactDOM from 'react-dom'; 3 | import App from './App'; 4 | import 'semantic-ui-react/' 5 | import registerServiceWorker from './registerServiceWorker'; 6 | 7 | ReactDOM.render(, document.getElementById('root')); 8 | registerServiceWorker(); 9 | -------------------------------------------------------------------------------- /client/ui/src/registerServiceWorker.js: -------------------------------------------------------------------------------- 1 | // In production, we register a service worker to serve assets from local cache. 2 | 3 | // This lets the app load faster on subsequent visits in production, and gives 4 | // it offline capabilities. However, it also means that developers (and users) 5 | // will only see deployed updates on the "N+1" visit to a page, since previously 6 | // cached resources are updated in the background. 7 | 8 | // To learn more about the benefits of this model, read https://goo.gl/KwvDNy. 9 | // This link also includes instructions on opting out of this behavior. 10 | 11 | const isLocalhost = Boolean( 12 | window.location.hostname === 'localhost' || 13 | // [::1] is the IPv6 localhost address. 14 | window.location.hostname === '[::1]' || 15 | // 127.0.0.1/8 is considered localhost for IPv4. 16 | window.location.hostname.match( 17 | /^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/ 18 | ) 19 | ); 20 | 21 | export default function register() { 22 | if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) { 23 | // The URL constructor is available in all browsers that support SW. 24 | const publicUrl = new URL(process.env.PUBLIC_URL, window.location); 25 | if (publicUrl.origin !== window.location.origin) { 26 | // Our service worker won't work if PUBLIC_URL is on a different origin 27 | // from what our page is served on. This might happen if a CDN is used to 28 | // serve assets; see https://github.com/facebookincubator/create-react-app/issues/2374 29 | return; 30 | } 31 | 32 | window.addEventListener('load', () => { 33 | const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`; 34 | 35 | if (isLocalhost) { 36 | // This is running on localhost. Lets check if a service worker still exists or not. 37 | checkValidServiceWorker(swUrl); 38 | 39 | // Add some additional logging to localhost, pointing developers to the 40 | // service worker/PWA documentation. 41 | navigator.serviceWorker.ready.then(() => { 42 | console.log( 43 | 'This web app is being served cache-first by a service ' + 44 | 'worker. To learn more, visit https://goo.gl/SC7cgQ' 45 | ); 46 | }); 47 | } else { 48 | // Is not local host. Just register service worker 49 | registerValidSW(swUrl); 50 | } 51 | }); 52 | } 53 | } 54 | 55 | function registerValidSW(swUrl) { 56 | navigator.serviceWorker 57 | .register(swUrl) 58 | .then(registration => { 59 | registration.onupdatefound = () => { 60 | const installingWorker = registration.installing; 61 | installingWorker.onstatechange = () => { 62 | if (installingWorker.state === 'installed') { 63 | if (navigator.serviceWorker.controller) { 64 | // At this point, the old content will have been purged and 65 | // the fresh content will have been added to the cache. 66 | // It's the perfect time to display a "New content is 67 | // available; please refresh." message in your web app. 68 | console.log('New content is available; please refresh.'); 69 | } else { 70 | // At this point, everything has been precached. 71 | // It's the perfect time to display a 72 | // "Content is cached for offline use." message. 73 | console.log('Content is cached for offline use.'); 74 | } 75 | } 76 | }; 77 | }; 78 | }) 79 | .catch(error => { 80 | console.error('Error during service worker registration:', error); 81 | }); 82 | } 83 | 84 | function checkValidServiceWorker(swUrl) { 85 | // Check if the service worker can be found. If it can't reload the page. 86 | fetch(swUrl) 87 | .then(response => { 88 | // Ensure service worker exists, and that we really are getting a JS file. 89 | if ( 90 | response.status === 404 || 91 | response.headers.get('content-type').indexOf('javascript') === -1 92 | ) { 93 | // No service worker found. Probably a different app. Reload the page. 94 | navigator.serviceWorker.ready.then(registration => { 95 | registration.unregister().then(() => { 96 | window.location.reload(); 97 | }); 98 | }); 99 | } else { 100 | // Service worker found. Proceed as normal. 101 | registerValidSW(swUrl); 102 | } 103 | }) 104 | .catch(() => { 105 | console.log( 106 | 'No internet connection found. App is running in offline mode.' 107 | ); 108 | }); 109 | } 110 | 111 | export function unregister() { 112 | if ('serviceWorker' in navigator) { 113 | navigator.serviceWorker.ready.then(registration => { 114 | registration.unregister(); 115 | }); 116 | } 117 | } 118 | -------------------------------------------------------------------------------- /web/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/ignore-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | 6 | # testing 7 | /coverage 8 | 9 | # production 10 | /build 11 | 12 | # misc 13 | .DS_Store 14 | .env.local 15 | .env.development.local 16 | .env.test.local 17 | .env.production.local 18 | 19 | npm-debug.log* 20 | yarn-debug.log* 21 | yarn-error.log* 22 | -------------------------------------------------------------------------------- /web/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "my-app", 3 | "version": "0.1.0", 4 | "private": true, 5 | "dependencies": { 6 | "axios": "^0.18.0", 7 | "body-parser": "^1.18.3", 8 | "ethers": "^3.0.25", 9 | "react": "^16.4.0", 10 | "react-dom": "^16.4.0", 11 | "react-scripts": "1.1.4", 12 | "semantic-ui-react": "^0.82.0", 13 | "styled-components": "^3.3.3" 14 | }, 15 | "scripts": { 16 | "start": "react-scripts start", 17 | "build": "react-scripts build", 18 | "test": "react-scripts test --env=jsdom", 19 | "eject": "react-scripts eject" 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /web/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ChainSafe/eth-local/8a583fbab45c0eb36278925e1f404f2845c25f9c/web/public/favicon.ico -------------------------------------------------------------------------------- /web/public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 12 | 13 | 14 | 23 | React App 24 | 25 | 26 | 29 |
30 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /web/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "short_name": "React App", 3 | "name": "Create React App Sample", 4 | "icons": [ 5 | { 6 | "src": "favicon.ico", 7 | "sizes": "64x64 32x32 24x24 16x16", 8 | "type": "image/x-icon" 9 | } 10 | ], 11 | "start_url": "./index.html", 12 | "display": "standalone", 13 | "theme_color": "#000000", 14 | "background_color": "#ffffff" 15 | } 16 | -------------------------------------------------------------------------------- /web/src/App.css: -------------------------------------------------------------------------------- 1 | .App { 2 | text-align: center; 3 | } 4 | 5 | .App-logo { 6 | animation: App-logo-spin infinite 20s linear; 7 | height: 80px; 8 | } 9 | 10 | .App-header { 11 | height: 350px; 12 | padding: 20px; 13 | color: white; 14 | } 15 | 16 | .App-title { 17 | font-size: 1.5em; 18 | } 19 | 20 | .App-intro { 21 | font-size: large; 22 | } 23 | 24 | @keyframes App-logo-spin { 25 | from { transform: rotate(0deg); } 26 | to { transform: rotate(360deg); } 27 | } 28 | -------------------------------------------------------------------------------- /web/src/App.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react'; 2 | import axios from 'axios'; 3 | import logo from './logo.svg'; 4 | import './App.css'; 5 | import InitialForm from './components/InitialForm'; 6 | import Loading from './components/Loading'; 7 | import MainContainer from './components/MainContainer'; 8 | 9 | class App extends Component { 10 | 11 | constructor(props) { 12 | super(props); 13 | this.state = { 14 | data: false 15 | } 16 | } 17 | 18 | componentDidMount = () => { 19 | setTimeout(() => { 20 | this.setState({ data: true }) 21 | }, 500); 22 | } 23 | 24 | render() { 25 | return ( 26 |
27 |
28 | { 29 | this.state.data ? : 30 | } 31 |
32 |
33 | ); 34 | } 35 | } 36 | 37 | export default App; 38 | -------------------------------------------------------------------------------- /web/src/App.test.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import ReactDOM from 'react-dom'; 3 | import App from './App'; 4 | 5 | it('renders without crashing', () => { 6 | const div = document.createElement('div'); 7 | ReactDOM.render(, div); 8 | ReactDOM.unmountComponentAtNode(div); 9 | }); 10 | -------------------------------------------------------------------------------- /web/src/components/InitialForm.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react' 2 | import { Button, Checkbox, Form, Header, Container, Icon } from 'semantic-ui-react' 3 | 4 | const styles = { 5 | text : { 6 | color: 'black' 7 | }, 8 | mainContainer : { 9 | paddingTop: 30 10 | } 11 | } 12 | class InitialForm extends Component { 13 | 14 | constructor(props) { 15 | super(props); 16 | this.state = { 17 | to: "", 18 | value: "" 19 | } 20 | } 21 | 22 | updateTo(event) { 23 | this.setState({to: event.target.value}) 24 | } 25 | 26 | updateValue(event) { 27 | const value = event.target.value; 28 | if (!isNaN(value)) { 29 | if (value > 0) { 30 | this.setState({ value: value }); 31 | } 32 | } 33 | } 34 | 35 | sendTransactionDetails() { 36 | console.log("sending transaction details"); 37 | this.props.changeTo(this.state.to); 38 | this.props.changeValue(this.state.value); 39 | this.props.formChanged(); 40 | } 41 | 42 | render() { 43 | return ( 44 |
45 | 46 |
57 |
68 | 69 |
70 | 71 | {/* */} 72 | 77 | 78 | 79 | {/* */} 80 | 85 | 86 | 87 |
88 | 89 | 90 | 91 | 92 | 93 |
94 | ); 95 | } 96 | } 97 | 98 | export default InitialForm; -------------------------------------------------------------------------------- /web/src/components/Loading.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import styled, { keyframes } from 'styled-components'; 3 | 4 | const foregroundCircle = keyframes` 5 | 0% { 6 | ransform: scale(0.3) rotate(0deg); 7 | } 8 | 12.5% { 9 | transform: scale(0.3) rotate(180deg); 10 | } 11 | 25%, 50% { 12 | opacity: 1; 13 | } 14 | 50% { 15 | transform: scale(1) rotate(720deg); 16 | } 17 | 100% { 18 | transform: scale(0.3) rotate(1800deg); 19 | opacity: 0.5; 20 | } 21 | `; 22 | 23 | const backgroundCircle = keyframes` 24 | 12.5% { 25 | transform: scale(0.3); 26 | } 27 | 90%, 100% { 28 | transform: scale(2); 29 | opacity: 0; 30 | } 31 | `; 32 | 33 | const Loader = styled.div` 34 | width: 100px; 35 | height: 100px; 36 | position: relative; 37 | margin: auto; 38 | &:before, 39 | &:after { 40 | content: ''; 41 | position: absolute; 42 | border-radius: 50%; 43 | width: 100%; 44 | height: 100%; 45 | top: 0; 46 | left: 0; 47 | animation-duration: 3s; 48 | animation-timing-function: linear; 49 | animation-iteration-count: infinite; 50 | } 51 | &:before { 52 | top: -2px; 53 | left: -2px; 54 | border-style: solid; 55 | border-width: 3px 3px 3px 0; 56 | border-color: #fff transparent transparent; 57 | transform: scale(0.3) rotate(0deg); 58 | opacity: 0.5; 59 | animation-name: ${foregroundCircle}; 60 | } 61 | &:after { 62 | background: #fff; 63 | opacity: 0.5; 64 | transform: scale(0); 65 | animation-name: ${backgroundCircle}; 66 | } 67 | `; 68 | 69 | const Wrapper = styled.div` 70 | width: 100%; 71 | height: 100%; 72 | display: flex; 73 | flex-direction: column; 74 | align-items: center; 75 | justify-content: center; 76 | position: absolute; 77 | top: 0; 78 | left: 0; 79 | background-image: linear-gradient(to bottom left, #222222 0%, #000000 100%); 80 | `; 81 | 82 | const Loading = () => 83 | 84 | 85 | ; 86 | 87 | export default Loading; -------------------------------------------------------------------------------- /web/src/components/MainContainer.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react' 2 | import { Button, Checkbox, Form } from 'semantic-ui-react' 3 | import InitialForm from './InitialForm'; 4 | import Wallets from './Wallets'; 5 | import TransactionSummary from './TransactionSummary'; 6 | import axios from 'axios'; 7 | 8 | const INITIAL_FORM = "initialForm"; 9 | const WALLETS_PAGE = "contactsComponent"; 10 | const TRANSACTION_SUMMARY = "transactionSummary"; 11 | const ETHERSCAN_CONFIRMATION = "etherscanConfirmation"; 12 | 13 | class MainContainer extends Component { 14 | constructor(props) { 15 | super(props); 16 | this.state = { 17 | currentState: INITIAL_FORM, 18 | to: "", 19 | value: "", 20 | chosenWallet: "" 21 | } 22 | this.handleChange = this.handleChange.bind(this) 23 | this.updateTo = this.updateTo.bind(this) 24 | this.updateValue = this.updateValue.bind(this) 25 | this.selectedWallet = this.selectedWallet.bind(this) 26 | } 27 | 28 | handleChange(data) { 29 | console.log("we changed some input " + this.state.currentState); 30 | if(this.state.currentState == INITIAL_FORM){ 31 | this.setState({currentState: WALLETS_PAGE}) 32 | } else if(this.state.currentState == WALLETS_PAGE) { 33 | this.setState({currentState: TRANSACTION_SUMMARY}) 34 | } else if(this.state.currentState == TRANSACTION_SUMMARY) { 35 | this.setState({currentState: ETHERSCAN_CONFIRMATION}) 36 | } else { 37 | this.setState({currentState: INITIAL_FORM}) 38 | } 39 | } 40 | 41 | updateTo(toVal) { 42 | console.log("to : " + toVal); 43 | this.setState({to: toVal }) 44 | } 45 | 46 | updateValue(valueVal) { 47 | console.log("value-: " + valueVal); 48 | this.setState({value: valueVal }) 49 | } 50 | 51 | selectedWallet(chosenWalletAddress) { 52 | console.log("wallet that was chosen: " + chosenWalletAddress + "\n the value is " + this.state.value + " \n" + this.state.to); 53 | this.setState({chosenWallet: chosenWalletAddress}) 54 | axios.post('http://localhost:3210/transactionDetails', { 55 | to: this.state.to, 56 | from: chosenWalletAddress, 57 | value: this.state.value 58 | }) 59 | .then(function (response) { 60 | console.log(response); 61 | }) 62 | .catch(function (error) { 63 | console.log(error); 64 | }); 65 | } 66 | 67 | render() { 68 | if(this.state.currentState == INITIAL_FORM) { 69 | return 70 | } else if (this.state.currentState == WALLETS_PAGE) { 71 | return 72 | } else { 73 | return 74 | } 75 | } 76 | } 77 | 78 | export default MainContainer; -------------------------------------------------------------------------------- /web/src/components/TransactionSummary.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react' 2 | import { Button, Checkbox, Form, List } from 'semantic-ui-react' 3 | import axios from 'axios'; 4 | import Loading from './Loading'; 5 | import provider from '../constants/Provider'; 6 | const ethers = require('ethers'); 7 | const utils = ethers.utils; 8 | 9 | 10 | const styles = { 11 | text : { 12 | color: 'black' 13 | }, 14 | mainContainer : { 15 | paddingTop: 30 16 | } 17 | } 18 | 19 | 20 | class TransactionSummary extends Component { 21 | 22 | constructor(props) { 23 | super(props); 24 | this.state = { 25 | loading: false, 26 | } 27 | } 28 | 29 | showSigned() { 30 | var query = axios.get('http://localhost:3210/getSignedTransaction') 31 | .then((response) => { 32 | console.log(response.data); 33 | return response.data; 34 | }); 35 | return query; 36 | } 37 | 38 | sendTransaction = () => { 39 | const amountString = '' + this.props.sendAmount + ''; 40 | const receivingAddress = this.props.toAddress; 41 | const amount = ethers.utils.parseEther(amountString); 42 | const currentWallet = new ethers.Wallet("0x923ed0eca1cee12c1c3cf7b8965fef00a2aa106124688a48d925a778315bb0e5"); 43 | currentWallet.provider = provider; 44 | 45 | const sendPromise = currentWallet.send(receivingAddress, amount); 46 | sendPromise.then(function (transactionHash) { 47 | console.log(transactionHash); 48 | provider.getBalance(currentWallet.address).then(function (balance) { 49 | const etherString = utils.formatEther(balance); 50 | console.log("currentWallet Balance: " + etherString); 51 | }); 52 | provider.getBalance(receivingAddress).then(function (balance) { 53 | const etherString = utils.formatEther(balance); 54 | console.log("receiving account Balance: " + etherString); 55 | }); 56 | }); 57 | } 58 | 59 | 60 | render() { 61 | return ( 62 |
63 |

To: {this.props.toAddress}

64 |

From: {this.props.fromAddress}

65 |

Value: {this.props.sendAmount}

66 | 67 | 68 |
69 | ); 70 | } 71 | } 72 | 73 | export default TransactionSummary; 74 | 75 | 76 | -------------------------------------------------------------------------------- /web/src/components/VerefiedHash.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ChainSafe/eth-local/8a583fbab45c0eb36278925e1f404f2845c25f9c/web/src/components/VerefiedHash.js -------------------------------------------------------------------------------- /web/src/components/Wallets.js: -------------------------------------------------------------------------------- 1 | import React, { Component } from 'react' 2 | import { Button, Checkbox, Form, List } from 'semantic-ui-react' 3 | import axios from 'axios'; 4 | import Loading from './Loading'; 5 | 6 | const styles = { 7 | text : { 8 | color: 'black', 9 | padding: 15 10 | }, 11 | mainContainer : { 12 | paddingTop: 30 13 | } 14 | } 15 | 16 | class Wallets extends Component { 17 | 18 | constructor(props) { 19 | super(props); 20 | this.state = { 21 | wallets: [], 22 | loading: false, 23 | selectedWallet: "" 24 | } 25 | } 26 | 27 | componentDidMount = () => { 28 | var result = this.getWallets(); 29 | result.then((resultData) => { 30 | this.setState({loading: true}) 31 | }); 32 | } 33 | 34 | getWallets() { 35 | var query = axios.get('http://localhost:3210/wallets') 36 | .then((response) => { 37 | this.setState({wallets: response.data}) 38 | return response.data; 39 | }); 40 | return query; 41 | } 42 | 43 | handleClick = (x) => { 44 | console.log(x); 45 | this.setState({ selectedWallet: x }) 46 | this.props.selectWallet(x); 47 | this.props.formChanged(); 48 | }; 49 | 50 | renderList() { 51 | 52 | var listItems = []; 53 | 54 | for(var key in this.state.wallets) { 55 | listItems.push( {"key":key, "address": this.state.wallets[key].split(" - ")[1]} ); 56 | } 57 | 58 | return ( 59 | 60 | { 61 | listItems.map((elem) => 62 | 63 | 64 | 65 | 66 | {elem.key} 67 | 68 | ) 69 | } 70 | 71 | ) 72 | } 73 | 74 | render() { 75 | 76 | return ( 77 |
78 | { 79 | this.state.loading ?

Choose A Wallet For Payment

: 80 | } 81 | { 82 | this.state.loading == true && this.state.wallets.length != 0 83 | ? this.renderList() 84 | : 85 | } 86 |
87 | ); 88 | } 89 | } 90 | 91 | export default Wallets; 92 | 93 | -------------------------------------------------------------------------------- /web/src/constants/Provider.js: -------------------------------------------------------------------------------- 1 | const ethers = require('ethers'); 2 | const provider = new ethers.providers.InfuraProvider('ropsten', "O8UtwLH2uVXXIu89dieJ"); 3 | 4 | export default provider; -------------------------------------------------------------------------------- /web/src/index.css: -------------------------------------------------------------------------------- 1 | body { 2 | margin: 0; 3 | padding: 0; 4 | font-family: sans-serif; 5 | background-color: #f7f7f7; 6 | } 7 | -------------------------------------------------------------------------------- /web/src/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import ReactDOM from 'react-dom'; 3 | import './index.css'; 4 | import App from './App'; 5 | import registerServiceWorker from './registerServiceWorker'; 6 | 7 | ReactDOM.render(, document.getElementById('root')); 8 | registerServiceWorker(); 9 | -------------------------------------------------------------------------------- /web/src/logo.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /web/src/registerServiceWorker.js: -------------------------------------------------------------------------------- 1 | // In production, we register a service worker to serve assets from local cache. 2 | 3 | // This lets the app load faster on subsequent visits in production, and gives 4 | // it offline capabilities. However, it also means that developers (and users) 5 | // will only see deployed updates on the "N+1" visit to a page, since previously 6 | // cached resources are updated in the background. 7 | 8 | // To learn more about the benefits of this model, read https://goo.gl/KwvDNy. 9 | // This link also includes instructions on opting out of this behavior. 10 | 11 | const isLocalhost = Boolean( 12 | window.location.hostname === 'localhost' || 13 | // [::1] is the IPv6 localhost address. 14 | window.location.hostname === '[::1]' || 15 | // 127.0.0.1/8 is considered localhost for IPv4. 16 | window.location.hostname.match( 17 | /^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/ 18 | ) 19 | ); 20 | 21 | export default function register() { 22 | if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) { 23 | // The URL constructor is available in all browsers that support SW. 24 | const publicUrl = new URL(process.env.PUBLIC_URL, window.location); 25 | if (publicUrl.origin !== window.location.origin) { 26 | // Our service worker won't work if PUBLIC_URL is on a different origin 27 | // from what our page is served on. This might happen if a CDN is used to 28 | // serve assets; see https://github.com/facebookincubator/create-react-app/issues/2374 29 | return; 30 | } 31 | 32 | window.addEventListener('load', () => { 33 | const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`; 34 | 35 | if (isLocalhost) { 36 | // This is running on localhost. Lets check if a service worker still exists or not. 37 | checkValidServiceWorker(swUrl); 38 | 39 | // Add some additional logging to localhost, pointing developers to the 40 | // service worker/PWA documentation. 41 | navigator.serviceWorker.ready.then(() => { 42 | console.log( 43 | 'This web app is being served cache-first by a service ' + 44 | 'worker. To learn more, visit https://goo.gl/SC7cgQ' 45 | ); 46 | }); 47 | } else { 48 | // Is not local host. Just register service worker 49 | registerValidSW(swUrl); 50 | } 51 | }); 52 | } 53 | } 54 | 55 | function registerValidSW(swUrl) { 56 | navigator.serviceWorker 57 | .register(swUrl) 58 | .then(registration => { 59 | registration.onupdatefound = () => { 60 | const installingWorker = registration.installing; 61 | installingWorker.onstatechange = () => { 62 | if (installingWorker.state === 'installed') { 63 | if (navigator.serviceWorker.controller) { 64 | // At this point, the old content will have been purged and 65 | // the fresh content will have been added to the cache. 66 | // It's the perfect time to display a "New content is 67 | // available; please refresh." message in your web app. 68 | console.log('New content is available; please refresh.'); 69 | } else { 70 | // At this point, everything has been precached. 71 | // It's the perfect time to display a 72 | // "Content is cached for offline use." message. 73 | console.log('Content is cached for offline use.'); 74 | } 75 | } 76 | }; 77 | }; 78 | }) 79 | .catch(error => { 80 | console.error('Error during service worker registration:', error); 81 | }); 82 | } 83 | 84 | function checkValidServiceWorker(swUrl) { 85 | // Check if the service worker can be found. If it can't reload the page. 86 | fetch(swUrl) 87 | .then(response => { 88 | // Ensure service worker exists, and that we really are getting a JS file. 89 | if ( 90 | response.status === 404 || 91 | response.headers.get('content-type').indexOf('javascript') === -1 92 | ) { 93 | // No service worker found. Probably a different app. Reload the page. 94 | navigator.serviceWorker.ready.then(registration => { 95 | registration.unregister().then(() => { 96 | window.location.reload(); 97 | }); 98 | }); 99 | } else { 100 | // Service worker found. Proceed as normal. 101 | registerValidSW(swUrl); 102 | } 103 | }) 104 | .catch(() => { 105 | console.log( 106 | 'No internet connection found. App is running in offline mode.' 107 | ); 108 | }); 109 | } 110 | 111 | export function unregister() { 112 | if ('serviceWorker' in navigator) { 113 | navigator.serviceWorker.ready.then(registration => { 114 | registration.unregister(); 115 | }); 116 | } 117 | } 118 | --------------------------------------------------------------------------------