Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttributeError: type object 'Compression' has no attribute 'UNKNOWN' #56

Open
zygame110119 opened this issue Sep 21, 2024 · 0 comments
Open

Comments

@zygame110119
Copy link

Last login: Sun Sep 22 00:52:02 on ttys000
aion@192 ~ % autodecrypt -f iBEC.ipad4.RELEASE.im4p -i 12.2 -d iPad4,1
[i] downloading iBEC.ipad4.RELEASE.im4p
[i] grabbing keys for iPad4,1/16E227
[x] iv : ef85b4f05fb629950b48bedeb5ab3e23
[x] key : c293d5ba11663cfeb3f3cd8532e98a07ef30b5f921414d4f18aa6f5cedd1ae96
[i] decrypting iBEC.ipad4.RELEASE.im4p to iBEC.ipad4.RELEASE.bin...
╭───────────────────── Traceback (most recent call last) ──────────────────────╮
│ /Library/Frameworks/Python.framework/Versions/3.12/bin/autodecrypt:5 in │
│ │
│ │
│ 2 # -- coding: utf-8 -- │
│ 3 import re │
│ 4 import sys │
│ ❱ 5 from autodecrypt.main import app │
│ 6 if name == 'main': │
│ 7 │ sys.argv[0] = re.sub(r'(-script.pyw|.exe)?$', '', sys.argv[0]) │
│ 8 │ sys.exit(app()) │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/autodecrypt/main.py:134 in │
│ │
│ 131 │ return 0 │
│ 132 │
│ 133 │
│ ❱ 134 app = typer.run(main) │
│ 135 │
│ 136 # if name == "main": │
│ 137 # typer.run(main) │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/typer/main.py:895 in run │
│ │
│ 892 def run(function: Callable[..., Any]) -> Any: │
│ 893 │ app = Typer() │
│ 894 │ app.command()(function) │
│ ❱ 895 │ app() │
│ 896 │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/typer/main.py:214 in call
│ │
│ 211 │ │ ) │
│ 212 │ │
│ 213 │ def call(self, *args: Any, **kwargs: Any) -> Any: │
│ ❱ 214 │ │ return get_command(self)(*args, **kwargs) │
│ 215 │
│ 216 │
│ 217 def get_group(typer_instance: Typer) -> click.Command: │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/click/core.py:1157 in call
│ │
│ 1154 │ │
│ 1155 │ def call(self, *args: t.Any, **kwargs: t.Any) -> t.Any: │
│ 1156 │ │ """Alias for :meth:main.""" │
│ ❱ 1157 │ │ return self.main(*args, **kwargs) │
│ 1158 │
│ 1159 │
│ 1160 class Command(BaseCommand): │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/click/core.py:1078 in main │
│ │
│ 1075 │ │ try: │
│ 1076 │ │ │ try: │
│ 1077 │ │ │ │ with self.make_context(prog_name, args, **extra) as c │
│ ❱ 1078 │ │ │ │ │ rv = self.invoke(ctx) │
│ 1079 │ │ │ │ │ if not standalone_mode: │
│ 1080 │ │ │ │ │ │ return rv │
│ 1081 │ │ │ │ │ # it's not safe to ctx.exit(rv) here! │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/click/core.py:1434 in invoke │
│ │
│ 1431 │ │ │ echo(style(message, fg="red"), err=True) │
│ 1432 │ │ │
│ 1433 │ │ if self.callback is not None: │
│ ❱ 1434 │ │ │ return ctx.invoke(self.callback, **ctx.params) │
│ 1435 │ │
│ 1436 │ def shell_complete(self, ctx: Context, incomplete: str) -> t.List │
│ 1437 │ │ """Return a list of completions for the incomplete value. Loo │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/click/core.py:783 in invoke │
│ │
│ 780 │ │ │
│ 781 │ │ with augment_usage_errors(__self): │
│ 782 │ │ │ with ctx: │
│ ❱ 783 │ │ │ │ return __callback(*args, **kwargs) │
│ 784 │ │
│ 785 │ def forward( │
│ 786 │ │ __self, __cmd: "Command", *args: t.Any, **kwargs: t.Any # no │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/typer/main.py:532 in wrapper │
│ │
│ 529 │ │ │ │ use_params[k] = v │
│ 530 │ │ if context_param_name: │
│ 531 │ │ │ use_params[context_param_name] = click.get_current_context │
│ ❱ 532 │ │ return callback(**use_params) # type: ignore │
│ 533 │ │
│ 534 │ update_wrapper(wrapper, callback) │
│ 535 │ return wrapper │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/autodecrypt/main.py:129 in main │
│ │
│ 126 │ │ print("[x] iv : %s" % iv) │
│ 127 │ │ print("[x] key : %s" % key) │
│ 128 │ │
│ ❱ 129 │ decrypt_img.decrypt_img(img_file, magic, iv, key) │
│ 130 │ print("[x] done") │
│ 131 │ return 0 │
│ 132 │
│ │
│ /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packa │
│ ges/autodecrypt/decrypt_img.py:26 in decrypt_img │
│ │
│ 23 │ print(f"[i] decrypting {infile} to {outfile}...") │
│ 24 │ │
│ 25 │ im4p.payload.decrypt(Keybag(key=key, iv=iv)) │
│ ❱ 26 │ if im4p.payload.compression not in (Compression.NONE, Compression.U │
│ 27 │ │ print('[i] image4 payload data is compressed, decompressing...' │
│ 28 │ │ im4p.payload.decompress() │
│ 29 │
╰──────────────────────────────────────────────────────────────────────────────╯
AttributeError: type object 'Compression' has no attribute 'UNKNOWN'
aion@192 ~ %

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant