reprotobuf
reprotobuf copied to clipboard
KeyError: 'sub'
Tried to use your script with Google Play app and got this error
Traceback (most recent call last): File "reprotobuf.py", line 246, in
workspace.structure_packages() File "reprotobuf.py", line 62, in structure_packages for name in self.tree['sub']: KeyError: 'sub'
+1
+1 same error
But next I tryed with another apk And got this error:
reprotobuf.py", line 241, in analyze
assert 'tag' in properties
AssertionError
+1 same error
@dimmduh Which APK did you get this error with?
@mmcloughlin I tried google play 6.9.20, 5.9.12, 4.2.3
I tried this apk. com.android.vending-1.apk.zip
@ifynk In that APK the generated classes are obfuscated. The script currently identifies protobuf classes by looking for classes that extend MessageNano. This base class is actually com.google.protobuf.nano.b in that APK. The root cause of your error is that it's not actually finding any classes.
Even more discouraging is the fact that the message classes themselves have been obfuscated. Reverse engineering is still possible via this method (looking for classes extending b instead), but we'd end up with an obfuscated schema also.
an obfuscated schema is still useful though, since we already know the majority of the schema from older versions, and could re-puzzle what changed in the schema with each update ;-)
Would it be possible to reliably detect what obfucsated base class name matches the MessageNano and finding the extended classes still with the python script?
the proto-interpretation would then be a job for humans.
Let me look into whether I can identify the obfuscated MessageNano class.
Any progress with this? I'm getting the same issue.
+1
+1
Hey! Sorry to bug you, just wondering if there would be an update regarding this issue. Cheers!
+1
Any updates on this?