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

ktool open error on macos #53

Open
U5KUN opened this issue Oct 29, 2023 · 1 comment
Open

ktool open error on macos #53

U5KUN opened this issue Oct 29, 2023 · 1 comment

Comments

@U5KUN
Copy link

U5KUN commented Oct 29, 2023

Hard fault in GUI due to uncaught exception: Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.11/bin/ktool", line 8, in <module> sys.exit(main()) ^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/ktool_script.py", line 409, in main args.func(args) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/ktool_script.py", line 489, in _open raise ex File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/ktool_script.py", line 481, in _open screen.load_file(args.filename, MMAP_ENABLED) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/window.py", line 2230, in load_file raise ex File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/window.py", line 2214, in load_file for item in KToolMachOLoader.contents_for_file(fd, self.update_load_status, mmap): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/window.py", line 1605, in contents_for_file raise ex File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/window.py", line 1603, in contents_for_file items.append(cls.slice_item(macho_slice, callback)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/window.py", line 1610, in slice_item loaded_image = MachOImageLoader.load(macho_slice) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/loader.py", line 58, in load MachOImageLoader._parse_load_commands(image, load_symtab, load_imports, load_exports) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/loader.py", line 80, in _parse_load_commands image.vm.add_segment(segment) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/image.py", line 51, in add_segment self.map_pages(segment.file_address, segment.vm_address, segment.size) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ktool/image.py", line 86, in map_pages raise MachOAlignmentError(f'Tried to map {hex(virtual_addr)}+{hex(size)} to {hex(physical_addr)}') ktool.exceptions.MachOAlignmentError: Tried to map 0xe0000+0xe000 to 0xe0000

My env

macOS Sonoma 14.0
Apple M1

@0cyn
Copy link
Owner

0cyn commented Nov 1, 2023

This looks like an issue specific to a file, are you able to share the one that caused it here?

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

2 participants