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

Generated ghidra python script errors #194

Open
Martmists-GH opened this issue Nov 16, 2021 · 1 comment
Open

Generated ghidra python script errors #194

Martmists-GH opened this issue Nov 16, 2021 · 1 comment
Labels

Comments

@Martmists-GH
Copy link

Error:

il2cpp.py> Running...
Generated script file by Il2CppInspector - http://www.djkaty.com - https://github.com/djkaty
Processing method definitions
Processing constructed generic methods
Processing custom attributes generators
Processing Method.Invoke thunks
Processing string literals
Processing Il2CppClass (TypeInfo) pointers
Processing Il2CppType (TypeRef) pointers
Processing MethodInfo pointers
Processing function boundaries
Processing IL2CPP type metadata
Traceback (most recent call last):
  File "/home/mart/Downloads/Il2CppInspector/Il2CppInspector.CLI/il2cpp.py", line 220, in <module>
    ProcessJSON(jsonData)
  File "/home/mart/Downloads/Il2CppInspector/Il2CppInspector.CLI/il2cpp.py", line 197, in ProcessJSON
    DefineField(d['virtualAddress'], d['name'], d['type'])
  File "/home/mart/Downloads/Il2CppInspector/Il2CppInspector.CLI/il2cpp.py", line 119, in DefineField
    SetType(addr, AsUTF8(type))
  File "/home/mart/Downloads/Il2CppInspector/Il2CppInspector.CLI/il2cpp.py", line 60, in SetType
    createData(addr, t)
	at ghidra.program.database.code.CodeManager.checkValidAddressRange(CodeManager.java:1941)
	at ghidra.program.database.code.CodeManager.createCodeUnit(CodeManager.java:2055)
	at ghidra.program.database.ListingDB.createData(ListingDB.java:422)
	at ghidra.program.flatapi.FlatProgramAPI.createData(FlatProgramAPI.java:1646)
	at jdk.internal.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
ghidra.program.model.util.CodeUnitInsertionException: ghidra.program.model.util.CodeUnitInsertionException: Insufficent memory at address 04aa3ac0 (length: 136 bytes)

Sadly I cannot provide the main binary and metadata as this would put my account at risk and I'm not willing to take any chances when it comes to Nintendo. It does not seem like there is any meaningful data at 04aa3ac0 though.

@ilpescerosso
Copy link

ilpescerosso commented Jan 4, 2023

I know this is quite old, but did you get it working? I'm having the same problem in SetType(), just different address (mine doesn't even get past the string literals part)

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

No branches or pull requests

2 participants