jtool -e __DATA.__objc_classrefs output weird chars

Used for discussing the various tools in the book as well as encouraging members to share tools

jtool -e __DATA.__objc_classrefs output weird chars

Postby Wingzero » Wed May 30, 2018 9:12 am

UnityAdsExample.zip
just unzip, it's the binary
(23.5 KiB) Downloaded 16 times
Hi J,

Just to report jtool -e __DATA.__objc_classrefs UnityAdsExample gives weird chars like:

^@^@^@^@^@^@^@^@`<db>^@^@^A^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@ ^@^@^@^@^@^@^@^@^@^@^@^@^@

The test binary is just compile from UnityAdsExample.

version:
This is jtool v1.0 - with bug fixes for @stek29's Malformed Mach-Os (thanks) and full support for dyld shared caches branch pools, compiled on Feb 4 2018 18:07:27
Wingzero
 
Posts: 53
Joined: Thu Jul 27, 2017 2:35 am

Re: jtool -e __DATA.__objc_classrefs output weird chars

Postby morpheus » Wed May 30, 2018 7:40 pm

That is correct behavior! -e extract a segment. What you MEANT to do was "-v -d objc"

And btw recent version of jtool is much newer than that :-) And jtool2 coming soon!
Attachments
Screen Shot 2018-05-30 at 3.24.41 PM.png
Screen Shot 2018-05-30 at 3.24.41 PM.png (203.87 KiB) Viewed 238 times
morpheus
Site Admin
 
Posts: 665
Joined: Thu Apr 11, 2013 6:24 pm

Re: jtool -e __DATA.__objc_classrefs output weird chars

Postby Wingzero » Thu May 31, 2018 1:36 am

morpheus wrote:That is correct behavior! -e extract a segment. What you MEANT to do was "-v -d objc"

And btw recent version of jtool is much newer than that :-) And jtool2 coming soon!


Actually, -v -d objc does not give classrefs section.

but otool -o will give not only classrefs:
Code: Select all
Contents of (__DATA,__objc_classrefs) section
000000010000daa8 0x0 _OBJC_CLASS_$_NSBundle
000000010000dab0 0x10000db60
000000010000dab8 0x0 _OBJC_CLASS_$_UnityAds
000000010000dac0 0x0 _OBJC_CLASS_$_NSUserDefaults
000000010000dac8 0x0 _OBJC_CLASS_$_UIColor
000000010000dad0 0x0 _OBJC_CLASS_$_UADSPlayerMetaData
000000010000dad8 0x0 _OBJC_CLASS_$_UADSMediationMetaData
000000010000dae0 0x0 _OBJC_CLASS_$_UADSMetaData
000000010000dae8 0x0 _OBJC_CLASS_$_NSNumber
000000010000daf0 0x0 _OBJC_CLASS_$_UIAlertController
000000010000daf8 0x0 _OBJC_CLASS_$_NSString
000000010000db00 0x0 _OBJC_CLASS_$_UIAlertAction
Contents of (__DATA,__objc_superrefs) section
000000010000db08 0x10000db88
Contents of (__DATA,__objc_protolist) section
000000010000c630 0x10000dc28
000000010000c638 0x10000dc88
000000010000c640 0x10000dcf0
000000010000c648 0x10000dd50
Contents of (__DATA,__objc_imageinfo) section
  version 0
    flags 0x40


What I am looking for is classrefs. The problem is this UnityAdsExample has a dynamic framework UnityAds. So UnityAds' classes remain as symbol.

can jtool print meaningful classrefs?
Wingzero
 
Posts: 53
Joined: Thu Jul 27, 2017 2:35 am


Return to Tools

Who is online

Users browsing this forum: No registered users and 1 guest