├── .github
└── workflows
│ └── pythonpackage.yml
├── .gitignore
├── LICENSE.txt
├── Pipfile
├── Pipfile.lock
├── README.md
├── iospytools
├── __init__.py
├── __main__.py
├── archive.py
├── bundle.py
├── diff.py
├── foreman.py
├── img3.py
├── img4.py
├── iphonewiki.py
├── ipswme.py
├── manifest.py
├── remote.py
├── template.py
├── tss.py
├── usb.py
└── utils.py
├── setup.py
└── test_module.py
/.github/workflows/pythonpackage.yml:
--------------------------------------------------------------------------------
1 | # This workflow will install Python dependencies, run tests and lint with a variety of Python versions
2 | # For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
3 |
4 | name: Python package
5 |
6 | on:
7 | push:
8 | branches: [ master ]
9 | pull_request:
10 | branches: [ master ]
11 |
12 | jobs:
13 | build:
14 |
15 | runs-on: ubuntu-latest
16 | strategy:
17 | matrix:
18 | python-version: [3.6, 3.7, 3.8, 3.9]
19 |
20 | steps:
21 | - uses: actions/checkout@v2
22 | - name: Set up Python ${{ matrix.python-version }}
23 | uses: actions/setup-python@v1
24 | with:
25 | python-version: ${{ matrix.python-version }}
26 | - name: Install dependencies
27 | run: |
28 | python -m pip install --upgrade pip
29 | pip install flake8 pytest
30 | if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
31 | - name: Lint with flake8
32 | run: |
33 | # stop the build if there are Python syntax errors or undefined names
34 | flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
35 | # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
36 | flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
37 | - name: Test with pytest
38 | run: |
39 | pytest
40 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | __pycache__
3 | venv
4 | .vscode
5 | *shsh
6 | *.plist
7 | *.code-workspace
8 | IPSW
9 | *.ipsw
10 | *.pyc
11 | *.patched
12 | *.egg-info
13 | dist
14 | build
15 | *.zip
16 | *.toml
17 |
--------------------------------------------------------------------------------
/LICENSE.txt:
--------------------------------------------------------------------------------
1 | GNU GENERAL PUBLIC LICENSE
2 | Version 3, 29 June 2007
3 |
4 | Copyright (C) 2007 Free Software Foundation, Inc.
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 |
--------------------------------------------------------------------------------
/Pipfile:
--------------------------------------------------------------------------------
1 | [[source]]
2 | url = "https://pypi.org/simple"
3 | verify_ssl = true
4 | name = "pypi"
5 |
6 | [packages]
7 | remotezip = "*"
8 | progressbar = "*"
9 | aiohttp = "*"
10 | enquiries = "*"
11 | autopep8 = "*"
12 | flake8 = "*"
13 |
14 | [dev-packages]
15 |
16 | [requires]
17 | python_version = "3.9"
18 |
--------------------------------------------------------------------------------
/Pipfile.lock:
--------------------------------------------------------------------------------
1 | {
2 | "_meta": {
3 | "hash": {
4 | "sha256": "8c131b11517b8cf9dbf0800133972ce2104b6c5109f444bd056a2740e66d5c41"
5 | },
6 | "pipfile-spec": 6,
7 | "requires": {
8 | "python_version": "3.9"
9 | },
10 | "sources": [
11 | {
12 | "name": "pypi",
13 | "url": "https://pypi.org/simple",
14 | "verify_ssl": true
15 | }
16 | ]
17 | },
18 | "default": {
19 | "aiohttp": {
20 | "hashes": [
21 | "sha256:01d7bdb774a9acc838e6b8f1d114f45303841b89b95984cbb7d80ea41172a9e3",
22 | "sha256:03a6d5349c9ee8f79ab3ff3694d6ce1cfc3ced1c9d36200cb8f08ba06bd3b782",
23 | "sha256:04d48b8ce6ab3cf2097b1855e1505181bdd05586ca275f2505514a6e274e8e75",
24 | "sha256:0770e2806a30e744b4e21c9d73b7bee18a1cfa3c47991ee2e5a65b887c49d5cf",
25 | "sha256:07b05cd3305e8a73112103c834e91cd27ce5b4bd07850c4b4dbd1877d3f45be7",
26 | "sha256:086f92daf51a032d062ec5f58af5ca6a44d082c35299c96376a41cbb33034675",
27 | "sha256:099ebd2c37ac74cce10a3527d2b49af80243e2a4fa39e7bce41617fbc35fa3c1",
28 | "sha256:0c7ebbbde809ff4e970824b2b6cb7e4222be6b95a296e46c03cf050878fc1785",
29 | "sha256:102e487eeb82afac440581e5d7f8f44560b36cf0bdd11abc51a46c1cd88914d4",
30 | "sha256:11691cf4dc5b94236ccc609b70fec991234e7ef8d4c02dd0c9668d1e486f5abf",
31 | "sha256:11a67c0d562e07067c4e86bffc1553f2cf5b664d6111c894671b2b8712f3aba5",
32 | "sha256:12de6add4038df8f72fac606dff775791a60f113a725c960f2bab01d8b8e6b15",
33 | "sha256:13487abd2f761d4be7c8ff9080de2671e53fff69711d46de703c310c4c9317ca",
34 | "sha256:15b09b06dae900777833fe7fc4b4aa426556ce95847a3e8d7548e2d19e34edb8",
35 | "sha256:1c182cb873bc91b411e184dab7a2b664d4fea2743df0e4d57402f7f3fa644bac",
36 | "sha256:1ed0b6477896559f17b9eaeb6d38e07f7f9ffe40b9f0f9627ae8b9926ae260a8",
37 | "sha256:28d490af82bc6b7ce53ff31337a18a10498303fe66f701ab65ef27e143c3b0ef",
38 | "sha256:2e5d962cf7e1d426aa0e528a7e198658cdc8aa4fe87f781d039ad75dcd52c516",
39 | "sha256:2ed076098b171573161eb146afcb9129b5ff63308960aeca4b676d9d3c35e700",
40 | "sha256:2f2f69dca064926e79997f45b2f34e202b320fd3782f17a91941f7eb85502ee2",
41 | "sha256:31560d268ff62143e92423ef183680b9829b1b482c011713ae941997921eebc8",
42 | "sha256:31d1e1c0dbf19ebccbfd62eff461518dcb1e307b195e93bba60c965a4dcf1ba0",
43 | "sha256:37951ad2f4a6df6506750a23f7cbabad24c73c65f23f72e95897bb2cecbae676",
44 | "sha256:3af642b43ce56c24d063325dd2cf20ee012d2b9ba4c3c008755a301aaea720ad",
45 | "sha256:44db35a9e15d6fe5c40d74952e803b1d96e964f683b5a78c3cc64eb177878155",
46 | "sha256:473d93d4450880fe278696549f2e7aed8cd23708c3c1997981464475f32137db",
47 | "sha256:477c3ea0ba410b2b56b7efb072c36fa91b1e6fc331761798fa3f28bb224830dd",
48 | "sha256:4a4a4e30bf1edcad13fb0804300557aedd07a92cabc74382fdd0ba6ca2661091",
49 | "sha256:4aed991a28ea3ce320dc8ce655875e1e00a11bdd29fe9444dd4f88c30d558602",
50 | "sha256:51467000f3647d519272392f484126aa716f747859794ac9924a7aafa86cd411",
51 | "sha256:55c3d1072704d27401c92339144d199d9de7b52627f724a949fc7d5fc56d8b93",
52 | "sha256:589c72667a5febd36f1315aa6e5f56dd4aa4862df295cb51c769d16142ddd7cd",
53 | "sha256:5bfde62d1d2641a1f5173b8c8c2d96ceb4854f54a44c23102e2ccc7e02f003ec",
54 | "sha256:5c23b1ad869653bc818e972b7a3a79852d0e494e9ab7e1a701a3decc49c20d51",
55 | "sha256:61bfc23df345d8c9716d03717c2ed5e27374e0fe6f659ea64edcd27b4b044cf7",
56 | "sha256:6ae828d3a003f03ae31915c31fa684b9890ea44c9c989056fea96e3d12a9fa17",
57 | "sha256:6c7cefb4b0640703eb1069835c02486669312bf2f12b48a748e0a7756d0de33d",
58 | "sha256:6d69f36d445c45cda7b3b26afef2fc34ef5ac0cdc75584a87ef307ee3c8c6d00",
59 | "sha256:6f0d5f33feb5f69ddd57a4a4bd3d56c719a141080b445cbf18f238973c5c9923",
60 | "sha256:6f8b01295e26c68b3a1b90efb7a89029110d3a4139270b24fda961893216c440",
61 | "sha256:713ac174a629d39b7c6a3aa757b337599798da4c1157114a314e4e391cd28e32",
62 | "sha256:718626a174e7e467f0558954f94af117b7d4695d48eb980146016afa4b580b2e",
63 | "sha256:7187a76598bdb895af0adbd2fb7474d7f6025d170bc0a1130242da817ce9e7d1",
64 | "sha256:71927042ed6365a09a98a6377501af5c9f0a4d38083652bcd2281a06a5976724",
65 | "sha256:7d08744e9bae2ca9c382581f7dce1273fe3c9bae94ff572c3626e8da5b193c6a",
66 | "sha256:7dadf3c307b31e0e61689cbf9e06be7a867c563d5a63ce9dca578f956609abf8",
67 | "sha256:81e3d8c34c623ca4e36c46524a3530e99c0bc95ed068fd6e9b55cb721d408fb2",
68 | "sha256:844a9b460871ee0a0b0b68a64890dae9c415e513db0f4a7e3cab41a0f2fedf33",
69 | "sha256:8b7ef7cbd4fec9a1e811a5de813311ed4f7ac7d93e0fda233c9b3e1428f7dd7b",
70 | "sha256:97ef77eb6b044134c0b3a96e16abcb05ecce892965a2124c566af0fd60f717e2",
71 | "sha256:99b5eeae8e019e7aad8af8bb314fb908dd2e028b3cdaad87ec05095394cce632",
72 | "sha256:a25fa703a527158aaf10dafd956f7d42ac6d30ec80e9a70846253dd13e2f067b",
73 | "sha256:a2f635ce61a89c5732537a7896b6319a8fcfa23ba09bec36e1b1ac0ab31270d2",
74 | "sha256:a79004bb58748f31ae1cbe9fa891054baaa46fb106c2dc7af9f8e3304dc30316",
75 | "sha256:a996d01ca39b8dfe77440f3cd600825d05841088fd6bc0144cc6c2ec14cc5f74",
76 | "sha256:b0e20cddbd676ab8a64c774fefa0ad787cc506afd844de95da56060348021e96",
77 | "sha256:b6613280ccedf24354406caf785db748bebbddcf31408b20c0b48cb86af76866",
78 | "sha256:b9d00268fcb9f66fbcc7cd9fe423741d90c75ee029a1d15c09b22d23253c0a44",
79 | "sha256:bb01ba6b0d3f6c68b89fce7305080145d4877ad3acaed424bae4d4ee75faa950",
80 | "sha256:c2aef4703f1f2ddc6df17519885dbfa3514929149d3ff900b73f45998f2532fa",
81 | "sha256:c34dc4958b232ef6188c4318cb7b2c2d80521c9a56c52449f8f93ab7bc2a8a1c",
82 | "sha256:c3630c3ef435c0a7c549ba170a0633a56e92629aeed0e707fec832dee313fb7a",
83 | "sha256:c3d6a4d0619e09dcd61021debf7059955c2004fa29f48788a3dfaf9c9901a7cd",
84 | "sha256:d15367ce87c8e9e09b0f989bfd72dc641bcd04ba091c68cd305312d00962addd",
85 | "sha256:d2f9b69293c33aaa53d923032fe227feac867f81682f002ce33ffae978f0a9a9",
86 | "sha256:e999f2d0e12eea01caeecb17b653f3713d758f6dcc770417cf29ef08d3931421",
87 | "sha256:ea302f34477fda3f85560a06d9ebdc7fa41e82420e892fc50b577e35fc6a50b2",
88 | "sha256:eaba923151d9deea315be1f3e2b31cc39a6d1d2f682f942905951f4e40200922",
89 | "sha256:ef9612483cb35171d51d9173647eed5d0069eaa2ee812793a75373447d487aa4",
90 | "sha256:f5315a2eb0239185af1bddb1abf472d877fede3cc8d143c6cddad37678293237",
91 | "sha256:fa0ffcace9b3aa34d205d8130f7873fcfefcb6a4dd3dd705b0dab69af6712642",
92 | "sha256:fc5471e1a54de15ef71c1bc6ebe80d4dc681ea600e68bfd1cbce40427f0b7578"
93 | ],
94 | "index": "pypi",
95 | "version": "==3.8.1"
96 | },
97 | "aiosignal": {
98 | "hashes": [
99 | "sha256:54cd96e15e1649b75d6c87526a6ff0b6c1b0dd3459f43d9ca11d48c339b68cfc",
100 | "sha256:f8376fb07dd1e86a584e4fcdec80b36b7f81aac666ebc724e2c090300dd83b17"
101 | ],
102 | "markers": "python_version >= '3.7'",
103 | "version": "==1.3.1"
104 | },
105 | "async-timeout": {
106 | "hashes": [
107 | "sha256:2163e1640ddb52b7a8c80d0a67a08587e5d245cc9c553a74a847056bc2976b15",
108 | "sha256:8ca1e4fcf50d07413d66d1a5e416e42cfdf5851c981d679a09851a6853383b3c"
109 | ],
110 | "markers": "python_version >= '3.6'",
111 | "version": "==4.0.2"
112 | },
113 | "attrs": {
114 | "hashes": [
115 | "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6",
116 | "sha256:86efa402f67bf2df34f51a335487cf46b1ec130d02b8d39fd248abfd30da551c"
117 | ],
118 | "markers": "python_version >= '3.5'",
119 | "version": "==22.1.0"
120 | },
121 | "autopep8": {
122 | "hashes": [
123 | "sha256:44f0932855039d2c15c4510d6df665e4730f2b8582704fa48f9c55bd3e17d979",
124 | "sha256:ed77137193bbac52d029a52c59bec1b0629b5a186c495f1eb21b126ac466083f"
125 | ],
126 | "index": "pypi",
127 | "version": "==1.6.0"
128 | },
129 | "blessed": {
130 | "hashes": [
131 | "sha256:63b8554ae2e0e7f43749b6715c734cc8f3883010a809bf16790102563e6cf25b",
132 | "sha256:9a0d099695bf621d4680dd6c73f6ad547f6a3442fbdbe80c4b1daa1edbc492fc"
133 | ],
134 | "markers": "python_version >= '2.7'",
135 | "version": "==1.19.1"
136 | },
137 | "certifi": {
138 | "hashes": [
139 | "sha256:35824b4c3a97115964b408844d64aa14db1cc518f6562e8d7261699d1350a9e3",
140 | "sha256:4ad3232f5e926d6718ec31cfc1fcadfde020920e278684144551c91769c7bc18"
141 | ],
142 | "index": "pypi",
143 | "version": "==2022.12.7"
144 | },
145 | "charset-normalizer": {
146 | "hashes": [
147 | "sha256:5a3d016c7c547f69d6f81fb0db9449ce888b418b5b9952cc5e6e66843e9dd845",
148 | "sha256:83e9a75d1911279afd89352c68b45348559d1fc0506b054b346651b5e7fee29f"
149 | ],
150 | "markers": "python_version >= '3.6'",
151 | "version": "==2.1.1"
152 | },
153 | "curtsies": {
154 | "hashes": [
155 | "sha256:62d10f349c553845306556a7f2663ce96b098d8c5bbc40daec7a6eedde1622b0"
156 | ],
157 | "markers": "python_version >= '3.7'",
158 | "version": "==0.4.1"
159 | },
160 | "cwcwidth": {
161 | "hashes": [
162 | "sha256:02a2e8a7cf1aaa590c1c56624cf87b793b1ecb84850b9a965df78766843439a1",
163 | "sha256:058162c84ca54362f8af99a57feba5abe76075e16c7fe8a290f99f63a9b40bd9",
164 | "sha256:0dbb6c6faa5899f71a3064843c528e9ed31881a2b0c83e33ee5109a71a1389cf",
165 | "sha256:1a5256190f2fa081e9ce0a4e3031992e7c8b98868fc77e4c00bc9563b1fc3017",
166 | "sha256:1cb4768ff9f6dcebcfb9e3bcc06b2de4f7d24ab423b01b94740f6ac5c72eede6",
167 | "sha256:1e156b9fa6068d32b14984fef9281cedfda114616d6f40cc21202756c04045fd",
168 | "sha256:26875ee1ac234e4bd73e6b55c0d8e1f61ae51736f4b712a4f9dd147e559fb17f",
169 | "sha256:275d89f102a966755e7b8482b96ad2efd8399853481b2a91d662da48fbcb8539",
170 | "sha256:3a5c9c9f6ee425d6d1bf5d09227304e10178755576b103d83457cc9884c7513f",
171 | "sha256:3e99cd2433ab37e35061057b6fddfd714d34e214bd2f2d9f708e422fe6c4eeb6",
172 | "sha256:4dc6b7a86893cb8615f3ff9a29132e21e292d47a30ccb33f1e024d745f30f1f9",
173 | "sha256:577a9394cba36339d41e633c9d82da0c67d26a3392ca64ac33e8379492206041",
174 | "sha256:5adc034b7c90e6a8586bd046bcbf6004e35e16b0d7e31de395513a50d729bbf6",
175 | "sha256:5c75d262d3bbb7fda982b0b8ce234d8a9e6bec0920f20c7daad93f7a631b1396",
176 | "sha256:5de08f1f55c255f9fdf6957bf4852d274f70f6cc39f2eff62c7be9342c6e8c6a",
177 | "sha256:62d4a203782b9eb677e5645517c6f2bfb033f07f9d3d112e994e37c1ac0d411c",
178 | "sha256:63ea84c5c3ac3f146ef091cded6a96cb9d421c28d8c4b40902adb1e28aeba52a",
179 | "sha256:6569c91d787adb312d8d30608e83def6689d0756d39edc4e1d9f85a0512abeee",
180 | "sha256:6858884314f58532e6c431564dae5fdf6e4f1aa6e461b421a1e431cbd6b40340",
181 | "sha256:6f5130eabcab72efdf1eee614a9ed00d0f8da9f6d7e6f81537ce010cecaf3427",
182 | "sha256:6f6b6abf1c375f394b2b1ed67237395082db9b3afd6fcb830bd7808ea36878d4",
183 | "sha256:70f3dd71d935780657e91047389161188e2d121e01c4356746263d280e294fa9",
184 | "sha256:72aed59f8cdb7a6b0fe3717be766bbdc41c8ac9ad43deb4b61e96e1c8a6f7f1b",
185 | "sha256:79fea2acf7418f7b6398d43f47195b993fcefd4adf4c9a851d93b50914b0eceb",
186 | "sha256:87a53489a715416b1c0e2b6a498061d9d395747ad4e05af34e4b6efdb68566b7",
187 | "sha256:9abc6c4616359c21862f3ba42630556102577897f474a9d00bb9cdfa5cb53757",
188 | "sha256:a56f65342c9878bf243849ed9d4f262544de1590eb0d429821e30fed3f7333c4",
189 | "sha256:ab47a6010833b017bca750ac4c0ccf3c0478c290d70fb6384f33c4ed238cc4b5",
190 | "sha256:add82ab289c8a9d98af50e711199da1784abbac25a17979dea05ba4e862694de",
191 | "sha256:af597541e0c7af9db76f6189ebaae085b4a2649e91e87d0e8e93bf7b822f5a86",
192 | "sha256:b85483ca46e7715b1d8c3e64a45d15413e33f2a7d5760022fe745135373dad7c",
193 | "sha256:c699a2a526b031b62dce4023194b99b0d7649ef042cfb1e18cca76b4a5e714f7",
194 | "sha256:d89448dfe4b9bde74b4a43fd359c892797262f3c77579027409fb4099f88670f",
195 | "sha256:d8acab21c0485d18779fc05b55903dc40a66ce66d0c018edfec01a0ed0a5c469",
196 | "sha256:eaaea46c6895ed5dc2f6ff67a3d13400d8a5f5d0f4f243f487879c358b902099",
197 | "sha256:f83b063b93ac8581f11c6a1ebd9adc1c74942fb2f2d5dfd027f81d5217038cf2"
198 | ],
199 | "markers": "python_version >= '3.7'",
200 | "version": "==0.1.8"
201 | },
202 | "enquiries": {
203 | "hashes": [
204 | "sha256:11227e0ff167384bc6494c61e5c5ed045603af2d605230f7cac710898a31785f"
205 | ],
206 | "index": "pypi",
207 | "version": "==0.1.0"
208 | },
209 | "flake8": {
210 | "hashes": [
211 | "sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d",
212 | "sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d"
213 | ],
214 | "index": "pypi",
215 | "version": "==4.0.1"
216 | },
217 | "frozenlist": {
218 | "hashes": [
219 | "sha256:008a054b75d77c995ea26629ab3a0c0d7281341f2fa7e1e85fa6153ae29ae99c",
220 | "sha256:02c9ac843e3390826a265e331105efeab489ffaf4dd86384595ee8ce6d35ae7f",
221 | "sha256:034a5c08d36649591be1cbb10e09da9f531034acfe29275fc5454a3b101ce41a",
222 | "sha256:05cdb16d09a0832eedf770cb7bd1fe57d8cf4eaf5aced29c4e41e3f20b30a784",
223 | "sha256:0693c609e9742c66ba4870bcee1ad5ff35462d5ffec18710b4ac89337ff16e27",
224 | "sha256:0771aed7f596c7d73444c847a1c16288937ef988dc04fb9f7be4b2aa91db609d",
225 | "sha256:0af2e7c87d35b38732e810befb9d797a99279cbb85374d42ea61c1e9d23094b3",
226 | "sha256:14143ae966a6229350021384870458e4777d1eae4c28d1a7aa47f24d030e6678",
227 | "sha256:180c00c66bde6146a860cbb81b54ee0df350d2daf13ca85b275123bbf85de18a",
228 | "sha256:1841e200fdafc3d51f974d9d377c079a0694a8f06de2e67b48150328d66d5483",
229 | "sha256:23d16d9f477bb55b6154654e0e74557040575d9d19fe78a161bd33d7d76808e8",
230 | "sha256:2b07ae0c1edaa0a36339ec6cce700f51b14a3fc6545fdd32930d2c83917332cf",
231 | "sha256:2c926450857408e42f0bbc295e84395722ce74bae69a3b2aa2a65fe22cb14b99",
232 | "sha256:2e24900aa13212e75e5b366cb9065e78bbf3893d4baab6052d1aca10d46d944c",
233 | "sha256:303e04d422e9b911a09ad499b0368dc551e8c3cd15293c99160c7f1f07b59a48",
234 | "sha256:352bd4c8c72d508778cf05ab491f6ef36149f4d0cb3c56b1b4302852255d05d5",
235 | "sha256:3843f84a6c465a36559161e6c59dce2f2ac10943040c2fd021cfb70d58c4ad56",
236 | "sha256:394c9c242113bfb4b9aa36e2b80a05ffa163a30691c7b5a29eba82e937895d5e",
237 | "sha256:3bbdf44855ed8f0fbcd102ef05ec3012d6a4fd7c7562403f76ce6a52aeffb2b1",
238 | "sha256:40de71985e9042ca00b7953c4f41eabc3dc514a2d1ff534027f091bc74416401",
239 | "sha256:41fe21dc74ad3a779c3d73a2786bdf622ea81234bdd4faf90b8b03cad0c2c0b4",
240 | "sha256:47df36a9fe24054b950bbc2db630d508cca3aa27ed0566c0baf661225e52c18e",
241 | "sha256:4ea42116ceb6bb16dbb7d526e242cb6747b08b7710d9782aa3d6732bd8d27649",
242 | "sha256:58bcc55721e8a90b88332d6cd441261ebb22342e238296bb330968952fbb3a6a",
243 | "sha256:5c11e43016b9024240212d2a65043b70ed8dfd3b52678a1271972702d990ac6d",
244 | "sha256:5cf820485f1b4c91e0417ea0afd41ce5cf5965011b3c22c400f6d144296ccbc0",
245 | "sha256:5d8860749e813a6f65bad8285a0520607c9500caa23fea6ee407e63debcdbef6",
246 | "sha256:6327eb8e419f7d9c38f333cde41b9ae348bec26d840927332f17e887a8dcb70d",
247 | "sha256:65a5e4d3aa679610ac6e3569e865425b23b372277f89b5ef06cf2cdaf1ebf22b",
248 | "sha256:66080ec69883597e4d026f2f71a231a1ee9887835902dbe6b6467d5a89216cf6",
249 | "sha256:783263a4eaad7c49983fe4b2e7b53fa9770c136c270d2d4bbb6d2192bf4d9caf",
250 | "sha256:7f44e24fa70f6fbc74aeec3e971f60a14dde85da364aa87f15d1be94ae75aeef",
251 | "sha256:7fdfc24dcfce5b48109867c13b4cb15e4660e7bd7661741a391f821f23dfdca7",
252 | "sha256:810860bb4bdce7557bc0febb84bbd88198b9dbc2022d8eebe5b3590b2ad6c842",
253 | "sha256:841ea19b43d438a80b4de62ac6ab21cfe6827bb8a9dc62b896acc88eaf9cecba",
254 | "sha256:84610c1502b2461255b4c9b7d5e9c48052601a8957cd0aea6ec7a7a1e1fb9420",
255 | "sha256:899c5e1928eec13fd6f6d8dc51be23f0d09c5281e40d9cf4273d188d9feeaf9b",
256 | "sha256:8bae29d60768bfa8fb92244b74502b18fae55a80eac13c88eb0b496d4268fd2d",
257 | "sha256:8df3de3a9ab8325f94f646609a66cbeeede263910c5c0de0101079ad541af332",
258 | "sha256:8fa3c6e3305aa1146b59a09b32b2e04074945ffcfb2f0931836d103a2c38f936",
259 | "sha256:924620eef691990dfb56dc4709f280f40baee568c794b5c1885800c3ecc69816",
260 | "sha256:9309869032abb23d196cb4e4db574232abe8b8be1339026f489eeb34a4acfd91",
261 | "sha256:9545a33965d0d377b0bc823dcabf26980e77f1b6a7caa368a365a9497fb09420",
262 | "sha256:9ac5995f2b408017b0be26d4a1d7c61bce106ff3d9e3324374d66b5964325448",
263 | "sha256:9bbbcedd75acdfecf2159663b87f1bb5cfc80e7cd99f7ddd9d66eb98b14a8411",
264 | "sha256:a4ae8135b11652b08a8baf07631d3ebfe65a4c87909dbef5fa0cdde440444ee4",
265 | "sha256:a6394d7dadd3cfe3f4b3b186e54d5d8504d44f2d58dcc89d693698e8b7132b32",
266 | "sha256:a97b4fe50b5890d36300820abd305694cb865ddb7885049587a5678215782a6b",
267 | "sha256:ae4dc05c465a08a866b7a1baf360747078b362e6a6dbeb0c57f234db0ef88ae0",
268 | "sha256:b1c63e8d377d039ac769cd0926558bb7068a1f7abb0f003e3717ee003ad85530",
269 | "sha256:b1e2c1185858d7e10ff045c496bbf90ae752c28b365fef2c09cf0fa309291669",
270 | "sha256:b4395e2f8d83fbe0c627b2b696acce67868793d7d9750e90e39592b3626691b7",
271 | "sha256:b756072364347cb6aa5b60f9bc18e94b2f79632de3b0190253ad770c5df17db1",
272 | "sha256:ba64dc2b3b7b158c6660d49cdb1d872d1d0bf4e42043ad8d5006099479a194e5",
273 | "sha256:bed331fe18f58d844d39ceb398b77d6ac0b010d571cba8267c2e7165806b00ce",
274 | "sha256:c188512b43542b1e91cadc3c6c915a82a5eb95929134faf7fd109f14f9892ce4",
275 | "sha256:c21b9aa40e08e4f63a2f92ff3748e6b6c84d717d033c7b3438dd3123ee18f70e",
276 | "sha256:ca713d4af15bae6e5d79b15c10c8522859a9a89d3b361a50b817c98c2fb402a2",
277 | "sha256:cd4210baef299717db0a600d7a3cac81d46ef0e007f88c9335db79f8979c0d3d",
278 | "sha256:cfe33efc9cb900a4c46f91a5ceba26d6df370ffddd9ca386eb1d4f0ad97b9ea9",
279 | "sha256:d5cd3ab21acbdb414bb6c31958d7b06b85eeb40f66463c264a9b343a4e238642",
280 | "sha256:dfbac4c2dfcc082fcf8d942d1e49b6aa0766c19d3358bd86e2000bf0fa4a9cf0",
281 | "sha256:e235688f42b36be2b6b06fc37ac2126a73b75fb8d6bc66dd632aa35286238703",
282 | "sha256:eb82dbba47a8318e75f679690190c10a5e1f447fbf9df41cbc4c3afd726d88cb",
283 | "sha256:ebb86518203e12e96af765ee89034a1dbb0c3c65052d1b0c19bbbd6af8a145e1",
284 | "sha256:ee78feb9d293c323b59a6f2dd441b63339a30edf35abcb51187d2fc26e696d13",
285 | "sha256:eedab4c310c0299961ac285591acd53dc6723a1ebd90a57207c71f6e0c2153ab",
286 | "sha256:efa568b885bca461f7c7b9e032655c0c143d305bf01c30caf6db2854a4532b38",
287 | "sha256:efce6ae830831ab6a22b9b4091d411698145cb9b8fc869e1397ccf4b4b6455cb",
288 | "sha256:f163d2fd041c630fed01bc48d28c3ed4a3b003c00acd396900e11ee5316b56bb",
289 | "sha256:f20380df709d91525e4bee04746ba612a4df0972c1b8f8e1e8af997e678c7b81",
290 | "sha256:f30f1928162e189091cf4d9da2eac617bfe78ef907a761614ff577ef4edfb3c8",
291 | "sha256:f470c92737afa7d4c3aacc001e335062d582053d4dbe73cda126f2d7031068dd",
292 | "sha256:ff8bf625fe85e119553b5383ba0fb6aa3d0ec2ae980295aaefa552374926b3f4"
293 | ],
294 | "markers": "python_version >= '3.7'",
295 | "version": "==1.3.3"
296 | },
297 | "idna": {
298 | "hashes": [
299 | "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4",
300 | "sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2"
301 | ],
302 | "markers": "python_version >= '3.5'",
303 | "version": "==3.4"
304 | },
305 | "mccabe": {
306 | "hashes": [
307 | "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42",
308 | "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"
309 | ],
310 | "version": "==0.6.1"
311 | },
312 | "multidict": {
313 | "hashes": [
314 | "sha256:018c8e3be7f161a12b3e41741b6721f9baeb2210f4ab25a6359b7d76c1017dce",
315 | "sha256:01b456046a05ff7cceefb0e1d2a9d32f05efcb1c7e0d152446304e11557639ce",
316 | "sha256:114a4ab3e5cfbc56c4b6697686ecb92376c7e8c56893ef20547921552f8bdf57",
317 | "sha256:12e0d396faa6dc55ff5379eee54d1df3b508243ff15bfc8295a6ec7a4483a335",
318 | "sha256:190626ced82d4cc567a09e7346340d380154a493bac6905e0095d8158cdf1e38",
319 | "sha256:1f5d5129a937af4e3c4a1d6c139f4051b7d17d43276cefdd8d442a7031f7eef2",
320 | "sha256:21e1ce0b187c4e93112304dcde2aa18922fdbe8fb4f13d8aa72a5657bce0563a",
321 | "sha256:24e8d513bfcaadc1f8b0ebece3ff50961951c54b07d5a775008a882966102418",
322 | "sha256:2523a29006c034687eccd3ee70093a697129a3ffe8732535d3b2df6a4ecc279d",
323 | "sha256:26fbbe17f8a7211b623502d2bf41022a51da3025142401417c765bf9a56fed4c",
324 | "sha256:2b66d61966b12e6bba500e5cbb2c721a35e119c30ee02495c5629bd0e91eea30",
325 | "sha256:2cf5d19e12eff855aa198259c0b02fd3f5d07e1291fbd20279c37b3b0e6c9852",
326 | "sha256:2cfda34b7cb99eacada2072e0f69c0ad3285cb6f8e480b11f2b6d6c1c6f92718",
327 | "sha256:3541882266247c7cd3dba78d6ef28dbe704774df60c9e4231edaa4493522e614",
328 | "sha256:36df958b15639e40472adaa4f0c2c7828fe680f894a6b48c4ce229f59a6a798b",
329 | "sha256:38d394814b39be1c36ac709006d39d50d72a884f9551acd9c8cc1ffae3fc8c4e",
330 | "sha256:4159fc1ec9ede8ab93382e0d6ba9b1b3d23c72da39a834db7a116986605c7ab4",
331 | "sha256:445c0851a1cbc1f2ec3b40bc22f9c4a235edb3c9a0906122a9df6ea8d51f886c",
332 | "sha256:47defc0218682281a52fb1f6346ebb8b68b17538163a89ea24dfe4da37a8a9a3",
333 | "sha256:4cc5c8cd205a9810d16a5cd428cd81bac554ad1477cb87f4ad722b10992e794d",
334 | "sha256:4ccf55f28066b4f08666764a957c2b7c241c7547b0921d69c7ceab5f74fe1a45",
335 | "sha256:4fb3fe591956d8841882c463f934c9f7485cfd5f763a08c0d467b513dc18ef89",
336 | "sha256:526f8397fc124674b8f39748680a0ff673bd6a715fecb4866716d36e380f015f",
337 | "sha256:578bfcb16f4b8675ef71b960c00f174b0426e0eeb796bab6737389d8288eb827",
338 | "sha256:5b51969503709415a35754954c2763f536a70b8bf7360322b2edb0c0a44391f6",
339 | "sha256:5e58ec0375803526d395f6f7e730ecc45d06e15f68f7b9cdbf644a2918324e51",
340 | "sha256:62db44727d0befea68e8ad2881bb87a9cfb6b87d45dd78609009627167f37b69",
341 | "sha256:67090b17a0a5be5704fd109f231ee73cefb1b3802d41288d6378b5df46ae89ba",
342 | "sha256:6cd14e61f0da2a2cfb9fe05bfced2a1ed7063ce46a7a8cd473be4973de9a7f91",
343 | "sha256:70740c2bc9ab1c99f7cdcb104f27d16c63860c56d51c5bf0ef82fc1d892a2131",
344 | "sha256:73009ea04205966d47e16d98686ac5c438af23a1bb30b48a2c5da3423ec9ce37",
345 | "sha256:791458a1f7d1b4ab3bd9e93e0dcd1d59ef7ee9aa051dcd1ea030e62e49b923fd",
346 | "sha256:7f9511e48bde6b995825e8d35e434fc96296cf07a25f4aae24ff9162be7eaa46",
347 | "sha256:81c3d597591b0940e04949e4e4f79359b2d2e542a686ba0da5e25de33fec13e0",
348 | "sha256:8230a39bae6c2e8a09e4da6bace5064693b00590a4a213e38f9a9366da10e7dd",
349 | "sha256:8b92a9f3ab904397a33b193000dc4de7318ea175c4c460a1e154c415f9008e3d",
350 | "sha256:94cbe5535ef150546b8321aebea22862a3284da51e7b55f6f95b7d73e96d90ee",
351 | "sha256:960ce1b790952916e682093788696ef7e33ac6a97482f9b983abdc293091b531",
352 | "sha256:99341ca1f1db9e7f47914cb2461305665a662383765ced6f843712564766956d",
353 | "sha256:9aac6881454a750554ed4b280a839dcf9e2133a9d12ab4d417d673fb102289b7",
354 | "sha256:9d359b0a962e052b713647ac1f13eabf2263167b149ed1e27d5c579f5c8c7d2c",
355 | "sha256:9dbab2a7e9c073bc9538824a01f5ed689194db7f55f2b8102766873e906a6c1a",
356 | "sha256:a27b029caa3b555a4f3da54bc1e718eb55fcf1a11fda8bf0132147b476cf4c08",
357 | "sha256:a8b817d4ed68fd568ec5e45dd75ddf30cc72a47a6b41b74d5bb211374c296f5e",
358 | "sha256:ad7d66422b9cc51125509229693d27e18c08f2dea3ac9de408d821932b1b3759",
359 | "sha256:b46e79a9f4db53897d17bc64a39d1c7c2be3e3d4f8dba6d6730a2b13ddf0f986",
360 | "sha256:baa96a3418e27d723064854143b2f414a422c84cc87285a71558722049bebc5a",
361 | "sha256:beeca903e4270b4afcd114f371a9602240dc143f9e944edfea00f8d4ad56c40d",
362 | "sha256:c2a1168e5aa7c72499fb03c850e0f03f624fa4a5c8d2e215c518d0a73872eb64",
363 | "sha256:c5790cc603456b6dcf8a9a4765f666895a6afddc88b3d3ba7b53dea2b6e23116",
364 | "sha256:cb4a08f0aaaa869f189ffea0e17b86ad0237b51116d494da15ef7991ee6ad2d7",
365 | "sha256:cd5771e8ea325f85cbb361ddbdeb9ae424a68e5dfb6eea786afdcd22e68a7d5d",
366 | "sha256:ce8e51774eb03844588d3c279adb94efcd0edeccd2f97516623292445bcc01f9",
367 | "sha256:d09daf5c6ce7fc6ed444c9339bbde5ea84e2534d1ca1cd37b60f365c77f00dea",
368 | "sha256:d0e798b072cf2aab9daceb43d97c9c527a0c7593e67a7846ad4cc6051de1e303",
369 | "sha256:d325d61cac602976a5d47b19eaa7d04e3daf4efce2164c630219885087234102",
370 | "sha256:d408172519049e36fb6d29672f060dc8461fc7174eba9883c7026041ef9bfb38",
371 | "sha256:d52442e7c951e4c9ee591d6047706e66923d248d83958bbf99b8b19515fffaef",
372 | "sha256:dc4cfef5d899f5f1a15f3d2ac49f71107a01a5a2745b4dd53fa0cede1419385a",
373 | "sha256:df7b4cee3ff31b3335aba602f8d70dbc641e5b7164b1e9565570c9d3c536a438",
374 | "sha256:e068dfeadbce63072b2d8096486713d04db4946aad0a0f849bd4fc300799d0d3",
375 | "sha256:e07c24018986fb00d6e7eafca8fcd6e05095649e17fcf0e33a592caaa62a78b9",
376 | "sha256:e0bce9f7c30e7e3a9e683f670314c0144e8d34be6b7019e40604763bd278d84f",
377 | "sha256:e1925f78a543b94c3d46274c66a366fee8a263747060220ed0188e5f3eeea1c0",
378 | "sha256:e322c94596054352f5a02771eec71563c018b15699b961aba14d6dd943367022",
379 | "sha256:e4a095e18847c12ec20e55326ab8782d9c2d599400a3a2f174fab4796875d0e2",
380 | "sha256:e5a811aab1b4aea0b4be669363c19847a8c547510f0e18fb632956369fdbdf67",
381 | "sha256:eddf604a3de2ace3d9a4e4d491be7562a1ac095a0a1c95a9ec5781ef0273ef11",
382 | "sha256:ee9b1cae9a6c5d023e5a150f6f6b9dbb3c3bbc7887d6ee07d4c0ecb49a473734",
383 | "sha256:f1650ea41c408755da5eed52ac6ccbc8938ccc3e698d81e6f6a1be02ff2a0945",
384 | "sha256:f2c0957b3e8c66c10d27272709a5299ab3670a0f187c9428f3b90d267119aedb",
385 | "sha256:f76109387e1ec8d8e2137c94c437b89fe002f29e0881aae8ae45529bdff92000",
386 | "sha256:f8a728511c977df6f3d8af388fcb157e49f11db4a6637dd60131b8b6e40b0253",
387 | "sha256:fb6c3dc3d65014d2c782f5acf0b3ba14e639c6c33d3ed8932ead76b9080b3544"
388 | ],
389 | "markers": "python_version >= '3.7'",
390 | "version": "==6.0.3"
391 | },
392 | "progressbar": {
393 | "hashes": [
394 | "sha256:5d81cb529da2e223b53962afd6c8ca0f05c6670e40309a7219eacc36af9b6c63"
395 | ],
396 | "index": "pypi",
397 | "version": "==2.5"
398 | },
399 | "pycodestyle": {
400 | "hashes": [
401 | "sha256:720f8b39dde8b293825e7ff02c475f3077124006db4f440dcbc9a20b76548a20",
402 | "sha256:eddd5847ef438ea1c7870ca7eb78a9d47ce0cdb4851a5523949f2601d0cbbe7f"
403 | ],
404 | "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'",
405 | "version": "==2.8.0"
406 | },
407 | "pyflakes": {
408 | "hashes": [
409 | "sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c",
410 | "sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e"
411 | ],
412 | "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
413 | "version": "==2.4.0"
414 | },
415 | "remotezip": {
416 | "hashes": [
417 | "sha256:8bed7d1fd3f096c15e480d05492d84537ac401b473ba109e0b30611452ac8e57"
418 | ],
419 | "index": "pypi",
420 | "version": "==0.9.4"
421 | },
422 | "requests": {
423 | "hashes": [
424 | "sha256:7c5599b102feddaa661c826c56ab4fee28bfd17f5abca1ebbe3e7f19d7c97983",
425 | "sha256:8fefa2a1a1365bf5520aac41836fbee479da67864514bdb821f31ce07ce65349"
426 | ],
427 | "markers": "python_version >= '3.7' and python_version < '4'",
428 | "version": "==2.28.1"
429 | },
430 | "six": {
431 | "hashes": [
432 | "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926",
433 | "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"
434 | ],
435 | "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
436 | "version": "==1.16.0"
437 | },
438 | "tabulate": {
439 | "hashes": [
440 | "sha256:0095b12bf5966de529c0feb1fa08671671b3368eec77d7ef7ab114be2c068b3c",
441 | "sha256:024ca478df22e9340661486f85298cff5f6dcdba14f3813e8830015b9ed1948f"
442 | ],
443 | "markers": "python_version >= '3.7'",
444 | "version": "==0.9.0"
445 | },
446 | "toml": {
447 | "hashes": [
448 | "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b",
449 | "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"
450 | ],
451 | "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'",
452 | "version": "==0.10.2"
453 | },
454 | "urllib3": {
455 | "hashes": [
456 | "sha256:47cc05d99aaa09c9e72ed5809b60e7ba354e64b59c9c173ac3018642d8bb41fc",
457 | "sha256:c083dd0dce68dbfbe1129d5271cb90f9447dea7d52097c6e0126120c521ddea8"
458 | ],
459 | "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5'",
460 | "version": "==1.26.13"
461 | },
462 | "wcwidth": {
463 | "hashes": [
464 | "sha256:beb4802a9cebb9144e99086eff703a642a13d6a0052920003a230f3294bbe784",
465 | "sha256:c4d647b99872929fdb7bdcaa4fbe7f01413ed3d98077df798530e5b04f116c83"
466 | ],
467 | "version": "==0.2.5"
468 | },
469 | "yarl": {
470 | "hashes": [
471 | "sha256:009a028127e0a1755c38b03244c0bea9d5565630db9c4cf9572496e947137a87",
472 | "sha256:0414fd91ce0b763d4eadb4456795b307a71524dbacd015c657bb2a39db2eab89",
473 | "sha256:0978f29222e649c351b173da2b9b4665ad1feb8d1daa9d971eb90df08702668a",
474 | "sha256:0ef8fb25e52663a1c85d608f6dd72e19bd390e2ecaf29c17fb08f730226e3a08",
475 | "sha256:10b08293cda921157f1e7c2790999d903b3fd28cd5c208cf8826b3b508026996",
476 | "sha256:1684a9bd9077e922300ecd48003ddae7a7474e0412bea38d4631443a91d61077",
477 | "sha256:1b372aad2b5f81db66ee7ec085cbad72c4da660d994e8e590c997e9b01e44901",
478 | "sha256:1e21fb44e1eff06dd6ef971d4bdc611807d6bd3691223d9c01a18cec3677939e",
479 | "sha256:2305517e332a862ef75be8fad3606ea10108662bc6fe08509d5ca99503ac2aee",
480 | "sha256:24ad1d10c9db1953291f56b5fe76203977f1ed05f82d09ec97acb623a7976574",
481 | "sha256:272b4f1599f1b621bf2aabe4e5b54f39a933971f4e7c9aa311d6d7dc06965165",
482 | "sha256:2a1fca9588f360036242f379bfea2b8b44cae2721859b1c56d033adfd5893634",
483 | "sha256:2b4fa2606adf392051d990c3b3877d768771adc3faf2e117b9de7eb977741229",
484 | "sha256:3150078118f62371375e1e69b13b48288e44f6691c1069340081c3fd12c94d5b",
485 | "sha256:326dd1d3caf910cd26a26ccbfb84c03b608ba32499b5d6eeb09252c920bcbe4f",
486 | "sha256:34c09b43bd538bf6c4b891ecce94b6fa4f1f10663a8d4ca589a079a5018f6ed7",
487 | "sha256:388a45dc77198b2460eac0aca1efd6a7c09e976ee768b0d5109173e521a19daf",
488 | "sha256:3adeef150d528ded2a8e734ebf9ae2e658f4c49bf413f5f157a470e17a4a2e89",
489 | "sha256:3edac5d74bb3209c418805bda77f973117836e1de7c000e9755e572c1f7850d0",
490 | "sha256:3f6b4aca43b602ba0f1459de647af954769919c4714706be36af670a5f44c9c1",
491 | "sha256:3fc056e35fa6fba63248d93ff6e672c096f95f7836938241ebc8260e062832fe",
492 | "sha256:418857f837347e8aaef682679f41e36c24250097f9e2f315d39bae3a99a34cbf",
493 | "sha256:42430ff511571940d51e75cf42f1e4dbdded477e71c1b7a17f4da76c1da8ea76",
494 | "sha256:44ceac0450e648de86da8e42674f9b7077d763ea80c8ceb9d1c3e41f0f0a9951",
495 | "sha256:47d49ac96156f0928f002e2424299b2c91d9db73e08c4cd6742923a086f1c863",
496 | "sha256:48dd18adcf98ea9cd721a25313aef49d70d413a999d7d89df44f469edfb38a06",
497 | "sha256:49d43402c6e3013ad0978602bf6bf5328535c48d192304b91b97a3c6790b1562",
498 | "sha256:4d04acba75c72e6eb90745447d69f84e6c9056390f7a9724605ca9c56b4afcc6",
499 | "sha256:57a7c87927a468e5a1dc60c17caf9597161d66457a34273ab1760219953f7f4c",
500 | "sha256:58a3c13d1c3005dbbac5c9f0d3210b60220a65a999b1833aa46bd6677c69b08e",
501 | "sha256:5df5e3d04101c1e5c3b1d69710b0574171cc02fddc4b23d1b2813e75f35a30b1",
502 | "sha256:63243b21c6e28ec2375f932a10ce7eda65139b5b854c0f6b82ed945ba526bff3",
503 | "sha256:64dd68a92cab699a233641f5929a40f02a4ede8c009068ca8aa1fe87b8c20ae3",
504 | "sha256:6604711362f2dbf7160df21c416f81fac0de6dbcf0b5445a2ef25478ecc4c778",
505 | "sha256:6c4fcfa71e2c6a3cb568cf81aadc12768b9995323186a10827beccf5fa23d4f8",
506 | "sha256:6d88056a04860a98341a0cf53e950e3ac9f4e51d1b6f61a53b0609df342cc8b2",
507 | "sha256:705227dccbe96ab02c7cb2c43e1228e2826e7ead880bb19ec94ef279e9555b5b",
508 | "sha256:728be34f70a190566d20aa13dc1f01dc44b6aa74580e10a3fb159691bc76909d",
509 | "sha256:74dece2bfc60f0f70907c34b857ee98f2c6dd0f75185db133770cd67300d505f",
510 | "sha256:75c16b2a900b3536dfc7014905a128a2bea8fb01f9ee26d2d7d8db0a08e7cb2c",
511 | "sha256:77e913b846a6b9c5f767b14dc1e759e5aff05502fe73079f6f4176359d832581",
512 | "sha256:7a66c506ec67eb3159eea5096acd05f5e788ceec7b96087d30c7d2865a243918",
513 | "sha256:8c46d3d89902c393a1d1e243ac847e0442d0196bbd81aecc94fcebbc2fd5857c",
514 | "sha256:93202666046d9edadfe9f2e7bf5e0782ea0d497b6d63da322e541665d65a044e",
515 | "sha256:97209cc91189b48e7cfe777237c04af8e7cc51eb369004e061809bcdf4e55220",
516 | "sha256:a48f4f7fea9a51098b02209d90297ac324241bf37ff6be6d2b0149ab2bd51b37",
517 | "sha256:a783cd344113cb88c5ff7ca32f1f16532a6f2142185147822187913eb989f739",
518 | "sha256:ae0eec05ab49e91a78700761777f284c2df119376e391db42c38ab46fd662b77",
519 | "sha256:ae4d7ff1049f36accde9e1ef7301912a751e5bae0a9d142459646114c70ecba6",
520 | "sha256:b05df9ea7496df11b710081bd90ecc3a3db6adb4fee36f6a411e7bc91a18aa42",
521 | "sha256:baf211dcad448a87a0d9047dc8282d7de59473ade7d7fdf22150b1d23859f946",
522 | "sha256:bb81f753c815f6b8e2ddd2eef3c855cf7da193b82396ac013c661aaa6cc6b0a5",
523 | "sha256:bcd7bb1e5c45274af9a1dd7494d3c52b2be5e6bd8d7e49c612705fd45420b12d",
524 | "sha256:bf071f797aec5b96abfc735ab97da9fd8f8768b43ce2abd85356a3127909d146",
525 | "sha256:c15163b6125db87c8f53c98baa5e785782078fbd2dbeaa04c6141935eb6dab7a",
526 | "sha256:cb6d48d80a41f68de41212f3dfd1a9d9898d7841c8f7ce6696cf2fd9cb57ef83",
527 | "sha256:ceff9722e0df2e0a9e8a79c610842004fa54e5b309fe6d218e47cd52f791d7ef",
528 | "sha256:cfa2bbca929aa742b5084fd4663dd4b87c191c844326fcb21c3afd2d11497f80",
529 | "sha256:d617c241c8c3ad5c4e78a08429fa49e4b04bedfc507b34b4d8dceb83b4af3588",
530 | "sha256:d881d152ae0007809c2c02e22aa534e702f12071e6b285e90945aa3c376463c5",
531 | "sha256:da65c3f263729e47351261351b8679c6429151ef9649bba08ef2528ff2c423b2",
532 | "sha256:de986979bbd87272fe557e0a8fcb66fd40ae2ddfe28a8b1ce4eae22681728fef",
533 | "sha256:df60a94d332158b444301c7f569659c926168e4d4aad2cfbf4bce0e8fb8be826",
534 | "sha256:dfef7350ee369197106805e193d420b75467b6cceac646ea5ed3049fcc950a05",
535 | "sha256:e59399dda559688461762800d7fb34d9e8a6a7444fd76ec33220a926c8be1516",
536 | "sha256:e6f3515aafe0209dd17fb9bdd3b4e892963370b3de781f53e1746a521fb39fc0",
537 | "sha256:e7fd20d6576c10306dea2d6a5765f46f0ac5d6f53436217913e952d19237efc4",
538 | "sha256:ebb78745273e51b9832ef90c0898501006670d6e059f2cdb0e999494eb1450c2",
539 | "sha256:efff27bd8cbe1f9bd127e7894942ccc20c857aa8b5a0327874f30201e5ce83d0",
540 | "sha256:f37db05c6051eff17bc832914fe46869f8849de5b92dc4a3466cd63095d23dfd",
541 | "sha256:f8ca8ad414c85bbc50f49c0a106f951613dfa5f948ab69c10ce9b128d368baf8",
542 | "sha256:fb742dcdd5eec9f26b61224c23baea46c9055cf16f62475e11b9b15dfd5c117b",
543 | "sha256:fc77086ce244453e074e445104f0ecb27530d6fd3a46698e33f6c38951d5a0f1",
544 | "sha256:ff205b58dc2929191f68162633d5e10e8044398d7a45265f90a0f1d51f85f72c"
545 | ],
546 | "markers": "python_version >= '3.7'",
547 | "version": "==1.8.2"
548 | }
549 | },
550 | "develop": {}
551 | }
552 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | This project was inspired by Matteyeux with his ios-tools repo, this will be a similar project but for my own practice. Also, in native Python 3 code :D
2 |
3 | ### Prerequisites
4 |
5 | Python >= 3.9
6 |
7 | ## How to install
8 |
9 | 1. python3 -m venv venv
10 | 2. source venv/bin/activate
11 | 3. pip install pipenv
12 | 4. pipenv install
13 |
14 | After this, running "iospytools" will print the help menu,
15 | also by entering "iospytools -h" or "iospytools --help".
16 |
17 | Use the help menu to dictate which commands are necessary to use one of the features.
18 |
19 | ### Features
20 |
21 | s0n
22 |
23 | ### TODO
24 |
25 | https://trello.com/b/2zGlkvUb/ios-python-tools
26 |
27 | ### Credits
28 |
29 | Matteyeux @matteyeux: inspiration
30 | mcg29 @mcg29_: Helping me when needed
31 | wxblank @wxblank2: TSS code
32 |
--------------------------------------------------------------------------------
/iospytools/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Merculous/ios-python-tools/ce935e2c47d98b68c60ba88e1790e77672a159a1/iospytools/__init__.py
--------------------------------------------------------------------------------
/iospytools/__main__.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3
2 | # -*- coding: utf-8 -*-
3 |
4 | import aiohttp
5 | import asyncio
6 | import sys
7 |
8 | from argparse import ArgumentParser
9 |
10 | from .ipswme import IPSWAPI
11 |
12 |
13 | def printUsage() -> None:
14 | print('Usage: iospytools []')
15 | sys.exit(1)
16 |
17 |
18 | async def main(args: tuple) -> None:
19 | argc = len(args)
20 |
21 | parser = ArgumentParser()
22 | parser.add_argument('-a', help='all', action='store_true')
23 | parser.add_argument('-b', help='buildid', nargs='?', const=True)
24 | parser.add_argument('-d', help='device', nargs='?', const=True)
25 | parser.add_argument('-i', help='info', action='store_true')
26 | parser.add_argument('-s', help='signed', action='store_true')
27 | parser.add_argument('-o', help='ota', action='store_true')
28 | parser.add_argument('-v', help='version', nargs='?', const=True)
29 | parser.add_argument('-w', help='wiki', action='store_true')
30 | pargs = parser.parse_args()
31 |
32 | if argc == 1:
33 | printUsage()
34 |
35 | if pargs.d: # -d
36 | async with aiohttp.ClientSession() as session:
37 | api = IPSWAPI(session)
38 | if pargs.a and not pargs.i: # -d -a
39 | devices = await api.getAllDevices()
40 | for device in devices:
41 | name = device['name']
42 | ident = device['identifier']
43 | board = device['boardconfig']
44 | print(f'{name}: {ident}, {board}')
45 | elif pargs.i: # -d -i
46 | api.device = pargs.d
47 | info = await api.getDeviceInfo()
48 | if pargs.a: # -d -i -a
49 | firmwares = info['firmwares']
50 | for firmware in firmwares:
51 | iOS = firmware['version']
52 | buildid = firmware['buildid']
53 | url = firmware['url']
54 | filesize = firmware['filesize']
55 | hash = firmware['sha256sum']
56 | signed = firmware['signed']
57 | print(f'iOS: {iOS}')
58 | print(f'BuildID: {buildid}')
59 | print(f'URL: {url}')
60 | print(f'Filesize: {filesize}')
61 | print(f'SHA256: {hash}')
62 | print(f'Signed: {signed}')
63 | print('\n')
64 | elif pargs.v: # -d -i -v
65 | api.device = pargs.d
66 | api.version = pargs.v
67 | firmware = await api.getDeviceFirmware()
68 | iOS = firmware['version']
69 | buildid = firmware['buildid']
70 | url = firmware['url']
71 | filesize = firmware['filesize']
72 | hash = firmware['sha256sum']
73 | signed = firmware['signed']
74 | print(f'iOS: {iOS}')
75 | print(f'BuildID: {buildid}')
76 | print(f'URL: {url}')
77 | print(f'Filesize: {filesize}')
78 | print(f'SHA256: {hash}')
79 | print(f'Signed: {signed}')
80 |
81 |
82 | asyncio.run(main(tuple(sys.argv)))
83 |
--------------------------------------------------------------------------------
/iospytools/archive.py:
--------------------------------------------------------------------------------
1 |
2 | from hashlib import sha256
3 | from zipfile import ZipFile
4 |
5 | class Archive:
6 | def __init__(self, path: str) -> None:
7 | self.path = path
8 |
9 | def getSHA256(self):
10 | with open(self.path, 'rb') as f:
11 | return sha256(f.read()).hexdigest()
12 |
13 | def listContents(self):
14 | with ZipFile(self.path) as f:
15 | contents = f.filelist
16 | for content in contents:
17 | print(content.filename)
18 |
19 | def createArchive(self, contents):
20 | pass
21 |
22 |
23 | def extract(self, member=None, out_path=None):
24 | if member:
25 | with ZipFile(self.path) as f:
26 | if out_path:
27 | f.extract(member, out_path)
28 | else:
29 | f.extract(member)
30 | else:
31 | with ZipFile(self.path) as f:
32 | if out_path:
33 | f.extractall(out_path)
34 | else:
35 | f.extractall()
36 |
--------------------------------------------------------------------------------
/iospytools/bundle.py:
--------------------------------------------------------------------------------
1 | import os
2 | import plistlib
3 |
4 |
5 | class Bundle:
6 | def __init__(self, bundle=None):
7 | if not os.path.exists('FirmwareBundles'):
8 | os.mkdir('FirmwareBundles')
9 |
10 | try:
11 | os.path.isdir(bundle)
12 | except IOError:
13 | print(f'{bundle} must be a directory!')
14 | raise
15 | else:
16 | self.bundle = bundle
17 |
18 | try:
19 | os.path.exists(f'{self.bundle}/Info.plist')
20 | except FileNotFoundError:
21 | print(f'Info.plist does not exist in {self.bundle}!')
22 | raise
23 |
24 | def getInfo(self):
25 | # Making my own so we don't have to rely on plist tags
26 | # and whatnot. Don't want to deal with it.
27 | info = {
28 | 'IPSWName': str,
29 | 'IPSWHash': str,
30 | 'RemoveManifest': bool,
31 | 'Jailbroken': bool,
32 | 'RootFS': {
33 | 'RootFSFilename': str,
34 | 'RootFSSize': int,
35 | 'RootFSKey': str,
36 | 'RootFSMountName': str,
37 | 'Patches': []
38 | },
39 | 'Firmware': [],
40 | 'Ramdisk': []
41 | }
42 |
43 | with open(f'{self.bundle}/Info.plist', 'rb') as f:
44 | data = plistlib.load(f)
45 |
46 | # Add our info from the plist to my dict cause easier reading
47 |
48 | if 'org.saurik.cydia' in data['PreInstalledPackages']:
49 | info['Jailbroken'] = True
50 | else:
51 | info['Jailbroken'] = False
52 |
53 | info['RemoveManifest'] = data['DeleteBuildManifest']
54 | info['IPSWHash'] = data['SHA1']
55 | info['IPSWName'] = data['Filename']
56 |
57 | info['RootFS']['RootFSFilename'] = data['RootFilesystem']
58 | info['RootFS']['RootFSSize'] = data['RootFilesystemSize']
59 | info['RootFS']['RootFSKey'] = data['RootFilesystemKey']
60 | info['RootFS']['RootFSMountName'] = data['RootFilesystemMountVolume']
61 |
62 | for stuff in data['FilesystemPatches'].items():
63 | info['RootFS']['Patches'].append(stuff[1])
64 |
65 | for stuff in data['FirmwarePatches'].items():
66 | info['Firmware'].append(stuff[1])
67 |
68 | for stuff in data['RamdiskPatches'].items():
69 | info['Ramdisk'].append(stuff[1])
70 |
71 | return info
72 |
73 | def checkForBundle(self, device, version, buildid):
74 | path = f'{device}_{version}_{buildid}.bundle'
75 | if path in os.listdir('FirmwareBundles'):
76 | if os.listdir('FirmwareBundles'):
77 | print(f'{path} exists!')
78 | else:
79 | print(f'{path} exists but is empty!')
80 | else:
81 | print(f'{path} does not exist!')
82 |
--------------------------------------------------------------------------------
/iospytools/diff.py:
--------------------------------------------------------------------------------
1 |
2 | import itertools
3 |
4 | class DIFF:
5 | def __init__(self, file1, file2):
6 | self.file1 = file1
7 | self.file2 = file2
8 |
9 | def diff(self):
10 | differences = {}
11 |
12 | with open(self.file1, 'rb') as f:
13 | data1 = f.read()
14 |
15 | with open(self.file2, 'rb') as ff:
16 | data2 = ff.read()
17 |
18 | x = 0
19 |
20 | for i, ii in itertools.zip_longest(data1, data2):
21 | if i is None:
22 | i = 0
23 |
24 | if ii is None:
25 | ii = 0
26 |
27 | i = hex(i)
28 | ii = hex(ii)
29 |
30 | if i != ii:
31 | differences[hex(x)] = (i, ii)
32 |
33 | x += 1
34 |
35 | return differences
36 |
37 | def patch(self):
38 | pass
39 |
--------------------------------------------------------------------------------
/iospytools/foreman.py:
--------------------------------------------------------------------------------
1 | class Foreman:
2 | def __init__(self):
3 | pass
4 |
--------------------------------------------------------------------------------
/iospytools/img3.py:
--------------------------------------------------------------------------------
1 | import struct
2 |
3 | '''
4 |
5 | typedef struct img3File {
6 | uint32_t magic; // ASCII_LE("Img3")
7 | uint32_t fullSize; // full size of fw image
8 | uint32_t sizeNoPack; // size of fw image without header
9 | uint32_t sigCheckArea;// although that is just my name for it, this is the
10 | // size of the start of the data section (the code) up to
11 | // the start of the RSA signature (SHSH section)
12 | uint32_t ident; // identifier of image, used when bootrom is parsing images
13 | // list to find LLB (illb), LLB parsing it to find iBoot (ibot),
14 | // etc.
15 | img3Tag tags[]; // continues until end of file
16 | };
17 | typedef struct img3Tag {
18 | uint32_t magic; // see below
19 | uint32_t totalLength; // length of tag including "magic" and these two length values
20 | uint32_t dataLength; // length of tag data
21 | uint8_t data[dataLength];
22 | uint8_t pad[totalLength - dataLength - 12]; // Typically padded to 4 byte multiple
23 | };
24 |
25 | '''
26 |
27 | '''
28 |
29 | VERS: iBoot version of the image
30 | SEPO: Security Epoch
31 | SDOM: Security Domain
32 | PROD: Production Mode
33 | CHIP: Chip to be used with. example: 0x8900 for S5L8900.
34 | BORD: Board to be used with
35 | KBAG: Contains the IV and key required to decrypt; encrypted with the GID Key
36 | SHSH: RSA encrypted SHA1 hash of the file
37 | CERT: Certificate
38 | ECID: Exclusive Chip ID unique to every device
39 | TYPE: Type of image, should contain the same string as the header's ident
40 | DATA: Real content of the file
41 | NONC: Nonce used when file was signed.
42 | CEPO: Chip epoch
43 | OVRD: For demoting -axi0mX
44 | RAND:
45 | SALT: For flavor -axi0mX (lmao)
46 |
47 | '''
48 |
49 | '''
50 |
51 | Decryption is done using the modulus at cert + 0xA15
52 | 0xC to SHSH is SHAed
53 |
54 | '''
55 |
56 |
57 | class IMG3:
58 | def __init__(self, file):
59 | with open(file, 'rb') as f:
60 | self.data = f.read()
61 | self.info = {
62 | 'magic': struct.unpack('4s', self.data[0:4])[0][::-1].decode(),
63 | 'size': struct.unpack('I', self.data[4:8])[0],
64 | 'unpacksize': struct.unpack('I', self.data[8:12])[0],
65 | 'sigcheckarea': struct.unpack('I', self.data[12:16])[0],
66 | 'ident': struct.unpack('4s', self.data[16:20])[0][::-1].decode(),
67 | 'tags': None,
68 | 'kbag': None,
69 | 'version': None
70 | }
71 |
72 | # Add tag values
73 |
74 | tags = []
75 |
76 | i = 20
77 |
78 | while i < 20 + self.info['unpacksize']:
79 | self.tag_info = {
80 | 'magic': struct.unpack('4s', self.data[i:i+4])[0][::-1].decode(),
81 | 'totalsize': struct.unpack('I', self.data[i+4:i+8])[0],
82 | 'datasize': struct.unpack('I', self.data[i+8:i+12])[0],
83 | 'data': None
84 | }
85 |
86 | tag_size = self.tag_info['totalsize']
87 | self.tag_info['data'] = self.data[i+12:i+tag_size]
88 |
89 | tags.append(self.tag_info)
90 | self.info['tags'] = tags
91 |
92 | # Done with tag, move on to next
93 |
94 | i += tag_size
95 |
96 | # Add iBoot version string, if iBoot, of course
97 |
98 | for version in self.info['tags']:
99 | if version['magic'] == 'VERS':
100 | version_info = {
101 | 'stringsize': struct.unpack('I', version['data'][:4])[0],
102 | 'string': None
103 | }
104 | size = version_info['stringsize']
105 | version_info['string'] = struct.unpack(
106 | f'{size}s', version['data'][4:4+size])[0].decode()
107 | self.info['version'] = version_info
108 |
109 | # Add kbag values
110 |
111 | kbags = []
112 | for kbag in self.info['tags']:
113 | if kbag['magic'] == 'KBAG':
114 | kbag_info = {
115 | 'type': struct.unpack('I', kbag['data'][:4])[0],
116 | 'aes_type': struct.unpack('I', kbag['data'][4:8])[0],
117 | 'kbag': kbag['data'][8:56].hex()
118 | }
119 | kbags.append(kbag_info)
120 | self.info['kbag'] = kbags
121 |
122 | # Add SHSH values
123 |
124 | for blob in self.info['tags']:
125 | if blob['magic'] == 'SHSH':
126 | pass
127 |
128 | # Add CERT values
129 |
130 | for cert in self.info['tags']:
131 | if cert['magic'] == 'CERT':
132 | pass
133 |
134 | def printInfo(self):
135 | return self.info
136 |
137 | def printTags(self):
138 | return self.info['tags']
139 |
140 | def getKBAGS(self):
141 | return self.info['kbag']
142 |
--------------------------------------------------------------------------------
/iospytools/img4.py:
--------------------------------------------------------------------------------
1 | class IMG4:
2 | def __init__(self, file: str):
3 | self.file = file
4 |
5 | """
6 |
7 | Class to parse and interact with Apple's img4 formatted files.
8 |
9 | """
10 |
11 | def printTags(self):
12 | """
13 | Print the tags of an img3 file
14 | """
15 |
16 | with open(self.file, 'rb') as f:
17 | data = f.read()
18 |
19 | if b'IM4P' in data:
20 | print('I see a IM4P tag at index:', hex(data.find(b'IM4P')))
21 |
22 | f.close()
23 |
--------------------------------------------------------------------------------
/iospytools/iphonewiki.py:
--------------------------------------------------------------------------------
1 |
2 | import asyncio
3 |
4 | from .remote import getURLData
5 |
6 | class WIKI:
7 | base_url = 'https://www.theiphonewiki.com'
8 |
9 | def __init__(self, session, codename, buildid, identifier):
10 | self.session = session
11 | self.codename = codename
12 | self.buildid = buildid
13 | self.identifier = identifier
14 |
15 |
16 | async def readFirmwareKeysPage(self):
17 | url = self.base_url + f'/w/index.php?title={self.codename}_{self.buildid}_({self.identifier})&action=raw'
18 | data = await getURLData(self.session, url)
19 | return data
20 |
21 |
22 | async def parseTemplate(self):
23 | data = await self.readFirmwareKeysPage()
24 | data = data.splitlines()
25 |
26 | info = {}
27 |
28 | for line in data:
29 | if line.startswith(' | '):
30 | line = line.replace(' | ', '').split('=')
31 | key = line[0].strip()
32 | value = line[1].strip()
33 |
34 | info[key] = value
35 |
36 | return info
37 |
--------------------------------------------------------------------------------
/iospytools/ipswme.py:
--------------------------------------------------------------------------------
1 |
2 | import json
3 |
4 | from remotezip import RemoteZip
5 |
6 | from .iphonewiki import WIKI
7 | from .manifest import parseManifest
8 | from .remote import downloadFile, getURLData
9 | from .utils import choose
10 |
11 |
12 | class IPSWAPI:
13 | base_url = 'https://api.ipsw.me/v4/'
14 |
15 | def __init__(self, session, device=None, version=None, restore_type=None):
16 | self.session = session
17 | self.device = device
18 | self.version = version
19 | self.restore_type = restore_type
20 |
21 | async def getAllDevices(self):
22 | url = self.base_url + 'devices'
23 | return json.loads(await getURLData(self.session, url))
24 |
25 | async def getDeviceInfo(self):
26 | if self.device:
27 | if self.restore_type == 'ota' or self.restore_type == 'ipsw':
28 | url = self.base_url + 'device/' + self.device + f'?type={self.restore_type}'
29 | return json.loads(await getURLData(self.session, url))
30 | else:
31 | raise ValueError('No restore type was passed!')
32 | else:
33 | raise ValueError('No device was passed!')
34 |
35 |
36 | async def iOSToBuildid(self):
37 | if self.version:
38 | self.restore_type = 'ipsw'
39 | ipsw_firmwares = await self.getDeviceInfo()
40 | self.restore_type = 'ota'
41 | ota_firmwares = await self.getDeviceInfo()
42 | self.restore_type = None
43 |
44 | firmwares = {'ipsw': {}, 'ota': {}}
45 |
46 | for data in ipsw_firmwares['firmwares']:
47 | ipsw_version = data['version']
48 | ipsw_buildid = data['buildid']
49 |
50 | if ipsw_version not in firmwares['ipsw']:
51 | firmwares['ipsw'][ipsw_version] = []
52 |
53 | if ipsw_buildid not in firmwares['ipsw'][ipsw_version]:
54 | firmwares['ipsw'][ipsw_version].append(ipsw_buildid)
55 |
56 | for data in ota_firmwares['firmwares']:
57 | ota_version = data['version']
58 | ota_buildid = data['buildid']
59 |
60 | if ota_version not in firmwares['ota']:
61 | firmwares['ota'][ota_version] = []
62 |
63 | if ota_buildid not in firmwares['ota'][ota_version]:
64 | firmwares['ota'][ota_version].append(ota_buildid)
65 |
66 | buildids = []
67 |
68 | if self.version in firmwares['ipsw']:
69 | buildid = firmwares['ipsw'][self.version]
70 | if buildid not in buildids:
71 | buildids.append(buildid)
72 |
73 | if self.version in firmwares['ota']:
74 | buildid = firmwares['ota'][self.version]
75 | if buildid not in buildids:
76 | buildids.append(buildid)
77 |
78 | if buildids:
79 | if len(buildids) == 1:
80 | if len(buildids[0]) == 1: # 1 ipsw value
81 | return buildids[0][0]
82 | else: # 2 ipsw values
83 | choice = await choose('Please select a buildid...\n', buildids[0])
84 | print(f'User selected: {choice}')
85 | return choice
86 | elif len(buildids) == 2: # ipsw and ota values
87 | restore_types = ('ipsw', 'ota')
88 | selected_type = await choose('Please selected a restore type...\n', restore_types)
89 | print(f'User selected: {selected_type}')
90 | if selected_type == restore_types[0]: # ipsw
91 | values = buildids[0]
92 | if len(values) == 1:
93 | return (values[0], restore_types[0])
94 | else:
95 | choice = await choose('Please select a buildid...\n', values)
96 | print(f'User selcted: {choice}')
97 | return (choice, restore_types[0])
98 | elif selected_type == restore_types[1]: # ota
99 | values = buildids[1]
100 | if len(values) == 1:
101 | return (values[0], restore_types[1])
102 | else:
103 | choice = await choose('Please select a buildid...\n', values)
104 | print(f'User selected: {choice}')
105 | return (choice, restore_types[1])
106 | else:
107 | print('Somehow we got here???')
108 |
109 | else:
110 | ValueError('Something went wrong grabbing buildids!')
111 | else:
112 | raise ValueError('No version was passed!')
113 |
114 | async def getArchiveURL(self):
115 | buildid = await self.iOSToBuildid()
116 |
117 | if isinstance(buildid, str):
118 | build = buildid
119 | self.restore_type = 'ipsw'
120 | data = await self.getDeviceInfo()
121 |
122 | elif isinstance(buildid, tuple):
123 | build = buildid[0]
124 | self.restore_type = buildid[1]
125 | data = await self.getDeviceInfo()
126 |
127 |
128 | for value in data['firmwares']:
129 | if value['buildid'] == build:
130 | return value['url']
131 |
132 |
133 | async def getSignedVersionsForDevice(self):
134 | if self.device:
135 | signed = {'ipsw': {}, 'ota': {}}
136 |
137 | self.restore_type = 'ipsw'
138 | ipsw_data = await self.getDeviceInfo()
139 | self.restore_type = 'ota'
140 | ota_data = await self.getDeviceInfo()
141 | self.restore_type = None
142 |
143 | for data in ipsw_data['firmwares']:
144 | version = data['version']
145 | buildid = data['buildid']
146 | is_signed = data['signed']
147 |
148 | if is_signed:
149 | signed['ipsw'][version] = buildid
150 |
151 | for data in ota_data['firmwares']:
152 | version = data['version']
153 | buildid = data['buildid']
154 | is_signed = data['signed']
155 |
156 | if is_signed:
157 | signed['ota'][version] = buildid
158 |
159 | return signed
160 |
161 | else:
162 | raise ValueError('No device was passed!')
163 |
164 |
165 | async def getAllSignedVersions(self):
166 | devices = await self.getAllDevices()
167 | signed = {}
168 | for device in devices:
169 | identifier = device['identifier']
170 | self.device = identifier
171 | signed_versions = await self.getSignedVersionsForDevice()
172 | signed[identifier] = signed_versions
173 |
174 | return signed
175 |
176 | async def downloadArchive(self):
177 | url = await self.getArchiveURL()
178 | await downloadFile(self.session, url)
179 |
180 | async def listArchiveContents(self):
181 | url = await self.getArchiveURL()
182 | with RemoteZip(url) as f:
183 | return (url, f.filelist)
184 |
185 | async def readFromArchive(self, path):
186 | url = await self.getArchiveURL()
187 | if url:
188 | with RemoteZip(url) as f:
189 | data = f.read(path)
190 | return data
191 | else:
192 | raise ValueError('No url was found!')
193 |
194 | async def readFromBuildManifest(self):
195 | contents = await self.listArchiveContents()
196 | for line in contents[1]:
197 | if 'BuildManifest.plist' in line.filename:
198 | with RemoteZip(contents[0]) as f:
199 | data = f.read(line.filename)
200 | return data
201 |
202 | async def getBoardConfig(self):
203 | data = await self.getDeviceInfo()
204 | return data['boardconfig']
205 |
206 | async def getChipID(self):
207 | data = await self.getDeviceInfo()
208 | return hex(data['cpid'])
209 |
210 | async def getCodename(self):
211 | data = await self.readFromBuildManifest()
212 | info = await parseManifest(data, await self.getChipID(), await self.getBoardConfig())
213 | return info['codename']
214 |
215 | async def getKeysFromWiki(self):
216 | info = await parseManifest(await self.readFromBuildManifest(), await self.getChipID(), await self.getBoardConfig())
217 | w = WIKI(self.session, info['codename'], info['buildid'], self.device)
218 | keys = await w.parseTemplate()
219 | return keys
220 |
--------------------------------------------------------------------------------
/iospytools/manifest.py:
--------------------------------------------------------------------------------
1 |
2 | import asyncio
3 | import plistlib
4 | import re
5 |
6 | from .utils import getDeviceType, getMajorDeviceRevision, getMinorDeviceRevision, fastTokenHex
7 |
8 | async def parseManifest(data: bytes, chipid: str, boardconfig: str) -> dict:
9 | info = {}
10 | data = plistlib.loads(data)
11 |
12 | info['version'] = data['ProductVersion']
13 | info['buildid'] = data['ProductBuildVersion']
14 |
15 | for thing in data['BuildIdentities']:
16 | if thing['ApChipID'] == chipid:
17 | if re.match(boardconfig.lower(), thing['Info']['DeviceClass']):
18 | info['codename'] = thing['Info']['BuildTrain']
19 | info['restore_type'] = thing['Info']['RestoreBehavior']
20 | info['Paths'] = {}
21 |
22 | for filename in thing['Manifest']:
23 | info['Paths'][filename] = thing['Manifest'][filename]['Info']['Path']
24 |
25 | break
26 |
27 | return info
28 |
29 | class TSSManifest:
30 | # Thanks tihmstar! http://blog.tihmstar.net/2017/01/basebandgoldcertid-not-found-please.html
31 | # https://github.com/tihmstar/tsschecker/blob/master/tsschecker/tsschecker.c#L110
32 |
33 | # Returns BbGoldCertId, BbSNUM length
34 |
35 | def getBbConfigurationForDevice(self, device: str):
36 | if getDeviceType(device) == 'iPhone':
37 | if getMajorDeviceRevision(device) == 1 \
38 | or getMajorDeviceRevision(device) == 2:
39 | return []
40 |
41 | if getMajorDeviceRevision(device) == 3:
42 | if getMinorDeviceRevision(device) <= 2:
43 | return [257, 12]
44 | else:
45 | return [2, 4]
46 |
47 | if getMajorDeviceRevision(device) == 4:
48 | return [2, 4]
49 |
50 | if getMajorDeviceRevision(device) == 5:
51 | if getMinorDeviceRevision(device) <= 2:
52 | return [3255536192, 4]
53 | else:
54 | return [3554301762, 4]
55 |
56 | if getMajorDeviceRevision(device) == 6:
57 | return [3554301762, 4]
58 |
59 | if getMajorDeviceRevision(device) == 7:
60 | return [3840149528, 4]
61 |
62 | if getMajorDeviceRevision(device) == 8:
63 | return [3840149528, 4]
64 |
65 | if getMajorDeviceRevision(device) == 9:
66 | if getMinorDeviceRevision(device) <= 2:
67 | return [2315222105, 4]
68 | else:
69 | return [1421084145, 12]
70 |
71 | if getMajorDeviceRevision(device) == 10:
72 | if getMinorDeviceRevision(device) <= 3:
73 | return [2315222105, 4]
74 | else:
75 | return [524245983, 12]
76 |
77 | if getMajorDeviceRevision(device) == 11:
78 | return [165673526, 12]
79 |
80 | if getMajorDeviceRevision(device) == 12:
81 | return [524245983, 12]
82 |
83 | if getDeviceType(device) == 'iPad':
84 | if getMajorDeviceRevision(device) == 1:
85 | return []
86 |
87 | if getMajorDeviceRevision(device) == 2:
88 | if getMinorDeviceRevision(device) >= 2 \
89 | and getMinorDeviceRevision(device) <= 3:
90 | return [257, 12]
91 |
92 | if getMinorDeviceRevision(device) >= 6 \
93 | and getMinorDeviceRevision(device) <= 7:
94 | return [3255536192, 4]
95 |
96 | if getMajorDeviceRevision(device) == 3:
97 | if getMinorDeviceRevision(device) >= 2 \
98 | and getMinorDeviceRevision(device) <= 3:
99 | return [4, 4]
100 |
101 | if getMinorDeviceRevision(device) >= 5:
102 | return [3255536192, 4]
103 |
104 | if getMajorDeviceRevision(device) == 4:
105 | if (getMinorDeviceRevision(device) >= 2
106 | and getMinorDeviceRevision(device) <= 3) \
107 | \
108 | or (getMinorDeviceRevision(device) >= 5
109 | and getMinorDeviceRevision(device) <= 6) \
110 | \
111 | or (getMinorDeviceRevision(device) >= 8
112 | and getMinorDeviceRevision(device) <= 9):
113 | return [3554301762, 4]
114 |
115 | if getMajorDeviceRevision(device) == 5:
116 | if getMinorDeviceRevision(device) == 2 \
117 | or getMinorDeviceRevision(device) == 4:
118 | return [3840149528, 4]
119 |
120 | if getMajorDeviceRevision(device) == 6:
121 | if getMinorDeviceRevision(device) == 4 \
122 | or getMinorDeviceRevision(device) == 8 \
123 | or getMinorDeviceRevision(device) == 11:
124 | return [3840149528, 4]
125 |
126 | if getMajorDeviceRevision(device) == 7:
127 | if getMinorDeviceRevision(device) == 2 \
128 | or getMinorDeviceRevision(device) == 4:
129 | return [2315222105, 4]
130 |
131 | if getMinorDeviceRevision(device) == 6:
132 | return [3840149528, 4]
133 |
134 | if getMinorDeviceRevision(device) == 12:
135 | return [524245983, 12]
136 |
137 | if getMajorDeviceRevision(device) == 8:
138 | if (getMinorDeviceRevision(device) >= 3
139 | and getMinorDeviceRevision(device) <= 4) \
140 | \
141 | or (getMinorDeviceRevision(device) >= 7
142 | and getMinorDeviceRevision(device) <= 8):
143 | return [165673526, 12]
144 |
145 | if getMajorDeviceRevision(device) == 11:
146 | if getMinorDeviceRevision(device) == 2 \
147 | or getMinorDeviceRevision(device) == 4:
148 | return [165673526, 12]
149 |
150 | return []
151 |
152 | # See 'Notes' in https://www.theiphonewiki.com/wiki/SHSH_Protocol#Communication
153 | def createTSSTestVersionManifest(self, path: str):
154 | testVersionManifest = {'ApSecurityDomain': 1}
155 |
156 | with open(path, 'w') as v:
157 | plistlib.dump(testVersionManifest, v)
158 |
159 | # See 'Sending data (request)' in https://www.theiphonewiki.com/wiki/SHSH_Protocol#Communication
160 | def initFromBuildManifest(self, device: str, tss_manifest_path: str, build_manifest_path: str, ecid: str, apnonce='', sepnonce='', bbsnum=''):
161 | with open(build_manifest_path, 'rb+') as f:
162 | data = plistlib.load(f, fmt=plistlib.FMT_XML)
163 |
164 | has_baseband = False
165 | found_erase_identity = False
166 |
167 | # Set TSS manifest to the Erase preset
168 | for identity in data['BuildIdentities']:
169 | if 'Erase' in identity['Info']['Variant']:
170 | for component in identity['Info']['VariantContents']:
171 | if component == 'SEP': # Set SepNonce now
172 | if sepnonce == '':
173 | sepnonce = fastTokenHex(20)
174 |
175 | identity['SepNonce'] = int(
176 | sepnonce, 16).to_bytes(20, 'big')
177 |
178 | elif component == 'BasebandFirmware': # Enable Baseband-related keys later
179 | has_baseband = True
180 |
181 | # This will clash with the root key labeled 'Info'
182 | del identity['Info']
183 |
184 | data = identity
185 | found_erase_identity = True
186 | break
187 |
188 | if not found_erase_identity:
189 | print('No \'Erase\' BuildIdentity was found in the BuildManifest')
190 | exit(1)
191 |
192 | for key in ('Info', 'ProductMarketingVersion'): # Remove unnecessary root keys
193 | if key in data:
194 | del data[key]
195 |
196 | # production_mode = False
197 | # security_mode = False
198 |
199 | for component in data['Manifest']:
200 | content = data['Manifest'][component]
201 |
202 | # This is messy; fix later
203 |
204 | if 'RestoreRequestRules' in content['Info']:
205 | for rule in content['Info']['RestoreRequestRules']:
206 | if 'EPRO' in rule['Actions']:
207 | content['EPRO'] = True
208 | if 'ApRequiresImage4' in rule['Conditions']:
209 | if rule['Conditions']['ApRequiresImage4']:
210 | data['@ApImg4Ticket'] = True
211 |
212 | elif 'ESEC' in rule['Actions']:
213 | content['ESEC'] = True
214 |
215 | if 'Trusted' in content and 'Digest' not in content:
216 | content['Digest'] = bytes()
217 |
218 | del content['Info']
219 |
220 | data[component] = content # Move keys to root
221 |
222 | if '@ApImg4Ticket' not in data:
223 | data['@APTicket'] = True # Old IMG3 ticket
224 |
225 | del data['Manifest']
226 |
227 | # These are hardcoded for now; will change later
228 |
229 | data['ApProductionMode'] = True
230 | data['ApSecurityMode'] = True
231 |
232 | if has_baseband:
233 | bb_config = self.getBbConfigurationForDevice(device)
234 | if bb_config != [] and bbsnum:
235 | if 'BbChipID' in data:
236 | data['BbChipID'] = int(data['BbChipID'], 16)
237 |
238 | data['@BBTicket'] = True
239 | data['BbGoldCertId'] = bb_config[0]
240 |
241 | if len(bbsnum) != bb_config[1]:
242 | print('Provided BbSNUM length is', len(bbsnum),
243 | 'while the max for', device, 'is', bb_config[1])
244 | exit(1)
245 |
246 | data['BbSNUM'] = int(bbsnum, 16).to_bytes(
247 | bb_config[1], 'big')
248 | else:
249 | print(
250 | device, 'either does not have a known BbGoldCertId and/or you have not supplied a BbSNUM. Skipping BBTicket...')
251 | for key in list(data):
252 | if key == 'BasebandFirmware' or key[0:2] == 'Bb':
253 | del data[key]
254 |
255 | if len(ecid) == 13 or len(ecid) == 11:
256 | try:
257 | data['ApECID'] = int(ecid, 16) # Hex ECID
258 | except:
259 | data['ApECID'] = int(ecid) # Decimal ECID
260 | else:
261 | data['ApECID'] = int(ecid) # Decimal ECID
262 |
263 | if apnonce == '':
264 | apnonce = fastTokenHex(20)
265 |
266 | data['ApNonce'] = int(apnonce, 16).to_bytes(20, 'big')
267 |
268 | with open(tss_manifest_path, 'wb+') as p:
269 | plistlib.dump(data, p, fmt=plistlib.FMT_XML)
270 |
271 | return {
272 | 'apnonce': apnonce,
273 | 'sepnonce': sepnonce
274 | }
275 |
--------------------------------------------------------------------------------
/iospytools/remote.py:
--------------------------------------------------------------------------------
1 |
2 | import asyncio
3 |
4 | async def getURLData(session, url: str) -> str:
5 | async with session.get(url) as r:
6 | if r.status == 404:
7 | print('Server returned no response...')
8 | elif r.status == 429: # We shouldn't hit this, but for sanity...
9 | print('Server is asking us to slow down...')
10 | wait = int(r.headers['Retry-After'])
11 | print(f'Waiting {wait} seconds...')
12 | asyncio.sleep(wait)
13 | getURLData(session, url)
14 | elif r.status == 200:
15 | return await r.text()
16 | else:
17 | print(f'Server error: {r.code}')
18 |
19 |
20 | async def downloadFile(session, url: str):
21 | filename = url.split('/')[-1:][0]
22 | async with session.get(url) as r:
23 | if r.status == 200:
24 | print(f'Downloading {filename}...')
25 | with open(filename, 'wb') as f:
26 | f.write(await r.read())
27 |
--------------------------------------------------------------------------------
/iospytools/template.py:
--------------------------------------------------------------------------------
1 | class Template:
2 | def __init__(self, template: str) -> None:
3 | self.template = template
4 |
5 | def parse(self) -> list:
6 | data = self.template.split('{{keys')[1].split('}}')[0].splitlines()
7 | new_list = filter(None, data) # Remove all ''
8 | info = []
9 | for stuff in new_list:
10 | new_str = stuff.replace('|', '').replace('=', '').split()
11 | info.append({new_str[0]: new_str[1]})
12 |
13 | return info
14 |
--------------------------------------------------------------------------------
/iospytools/tss.py:
--------------------------------------------------------------------------------
1 | import os
2 | import plistlib
3 | import shutil
4 | from urllib.request import Request, urlopen
5 |
6 | from .ipswapi import API
7 | from .manifest import TSSManifest
8 |
9 | tss_url = 'https://gs.apple.com/TSS/controller?action=2'
10 |
11 | # See https://www.theiphonewiki.com/wiki/SHSH_Protocol#Communication
12 | tss_headers = {
13 | 'User-Agent': 'InetURL/1.0',
14 | 'Proxy-Connection': 'Keep-Alive',
15 | 'Pragma': 'no-cache',
16 | 'Content-type': 'text/xml; charset="utf-8"'
17 | }
18 |
19 | # TODO Add support for OTA saving
20 |
21 |
22 | class TSS:
23 | def __init__(self, device: str, ecid: str, apnonce='', sepnonce='', bbsnum='', shsh_path='shsh'):
24 | self.device = device
25 | self.ecid = ecid
26 | self.apnonce = apnonce
27 | self.sepnonce = sepnonce
28 | self.bbsnum = bbsnum
29 | self.shsh_path = shsh_path
30 |
31 | def makeTSSRequest(self, data: bytes):
32 | request = Request(tss_url, headers=tss_headers, data=data)
33 | response = urlopen(request, timeout=5.0)
34 | response_text = response.read().decode('utf-8')
35 |
36 | if 'STATUS=0' not in response_text:
37 | if response.headers['Content-Length'] == '0':
38 | print('Server returned no response... are you blacklisted?')
39 | else:
40 | print(f'Server error: {response_text}')
41 | else:
42 | # Remove TSS response header
43 | return response_text[response_text.find('=3.9',
24 | install_requires=dependencies
25 | )
26 |
--------------------------------------------------------------------------------
/test_module.py:
--------------------------------------------------------------------------------
1 | # FFS, I'll just make a random test thingy
2 |
3 | def something(x: int):
4 | return x + 1
5 |
6 |
7 | def test():
8 | return something(1)
9 |
--------------------------------------------------------------------------------