Jump to content

Unity Il2cppdumper for Hopper Disassembler on macOS


Rook

9 posts in this topic

Recommended Posts

il2cppdumper Hopper Disassembler

 

Thanks to @Ted2 & il2cppdumper online, we can easily import il2cpp dumps (script.json) into Hopper Dissassembler just like we do in IDA using the following Python code:

# -*- coding: utf-8 -*-
import json

class LoadIl2cppDumperScript:
    def __init__(self):
        self.document = Document.getCurrentDocument()
        segments = self.document.getSegmentsList()
        self.starting_address = segments[0].getStartingAddress()
        
    def get_address(self, addr):
        return self.starting_address + addr
        
    def process_script(self, script_path):
        with open(script_path, 'r', encoding='utf-8') as file:
            data = json.load(file)

        if "ScriptMethod" in data:
            self.process_script_methods(data["ScriptMethod"])

        if "ScriptString" in data:
            self.process_script_strings(data["ScriptString"])

        if "ScriptMetadata" in data:
            self.process_script_metadata(data["ScriptMetadata"])

        if "ScriptMetadataMethod" in data:
            self.process_script_metadata_methods(data["ScriptMetadataMethod"])

        print("Script finished!")

    def replace_null_characters(self, string):
        return string.replace("\x00", "")

    def process_script_methods(self, script_methods):
        for script_method in script_methods:
            address = self.get_address(script_method["Address"])
            current_method_name = self.document.getNameAtAddress(address)
            self.document.setNameAtAddress(address, script_method["Name"])
            print(f"Renamed {current_method_name} at {address} to {script_method['Name']}")

    def process_script_strings(self, script_strings):
        for index, script_string in enumerate(script_strings, start=1):
            address = self.get_address(script_string["Address"])

            current_string_name = self.document.getNameAtAddress(address)
            new_string_name = f"StringLiteral_{index}"
            
            self.document.setNameAtAddress(address, new_string_name)
            print(f"Renamed {current_string_name} at {address} to {new_string_name}")

            segment = self.document.getSegmentAtAddress(address)
            if segment:
                inline_comment = self.replace_null_characters(script_string["Value"])
                segment.setInlineCommentAtAddress(address, inline_comment)
                print(f"Set inline comment at address {address} to {inline_comment}")

    def process_script_metadata(self, script_metadata):
        for meta in script_metadata:
            address = self.get_address(meta["Address"])
            self.document.setNameAtAddress(address, meta["Name"])
            print(f"Set name at address {address} to {meta['Name']}")

            segment = self.document.getSegmentAtAddress(address)
            if segment:
                inline_comment = self.replace_null_characters(meta["Name"])
                segment.setInlineCommentAtAddress(address, inline_comment)
                print(f"Set inline comment at address {address} to {inline_comment}")

    def process_script_metadata_methods(self, script_metadata_methods):
        for meta_method in script_metadata_methods:
            address = self.get_address(meta_method["Address"])
            self.document.setNameAtAddress(address, meta_method["Name"])
            print(f"Set name at address {address} to {meta_method['Name']}")

            # Set inline comments
            segment = self.document.getSegmentAtAddress(address)
            if segment:
                inline_comment = self.replace_null_characters(meta_method["Name"])
                segment.setInlineCommentAtAddress(address, inline_comment)
                print(f"Set inline comment at address {address} to {inline_comment}")

                inline_comment_method_address = '{0:X}'.format(self.get_address(meta_method["MethodAddress"]))
                segment.setInlineCommentAtAddress(address, inline_comment_method_address)
                print(f"Set inline comment at address {address} to {inline_comment_method_address}")

    def run(self):
        script_path = self.document.askFile("Choose the script.json from Il2cppdumper", "false", None)

        if not script_path:
            raise Exception("No file selected")
        
        self.process_script(script_path)


LoadIl2cppDumperScript().run()

 

 

Usage
Use il2cppdumper online to dump your Unity app.

PRO TIP You can drag and drop the Decrypted App Store IPA link into il2cppdumper online.

Download the resulting il2cppdumper archive and extract it so the script.json is available. Next open Hopper Disassembler with your executable loaded and go to Scripts > Open Script Editor... > + > Add the Python script above & Run. You can also rename () the newly created "New Script.py" to something like "Il2cppdumper Hopper.py" as it will be saved and appear in Hopper's Scripts menu anytime you need to use it.

Next you simply run the script you just created and select the script.json from il2cppdumper online when asked. 

That's it!

 

Thanks again to @Ted2 for the Hopper version of the il2cppdumper script! We'll be updating il2cppdumper online to include the Hopper version of the script inside the dump archive!

Updated by Rook
  • Like 1
  • Winner 2
  • Thanks 1
  • Haha 1
Link to comment
Share on other sites

1 minute ago, Puddin said:

Is hopper better than IDA? 

IDA for free is not available on M1/M2/M3 macOS so Hopper is the only option unless you run Windows IDA through Parallels or Crossover.

They're both similar from what I can see.

Link to comment
Share on other sites

2 minutes ago, Rook said:

IDA for free is not available on M1/M2/M3 macOS so Hopper is the only option unless you run Windows IDA through Parallels or Crossover.

They're both similar from what I can see.

Yeah I’ll just stick with Parallels and IDA. Thanks though! Plus it’s not keeping my hacking sh!t separate from my Mac xD 

  • Like 1
Link to comment
Share on other sites

My girlfriend stopped letting me use her Mac once she found out what I was doing with it lol but I do have ida pro crack for windows if anyone would need it. Nice post btw this would be useful once I steal her Mac again and use it at work 

Link to comment
Share on other sites

  • Rook changed the title to Unity Il2cppdumper for Hopper Disassembler on macOS

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below. For more information, please read our Posting Guidelines.
Reply to this topic... Posting Guidelines

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Our picks

    • [iOS 17/18 Support] Plants vs. Zombies™ 2 v11.5.1 +3 Jailed Cheats [Unlimited Currencies]
      Modded/Hacked App: Plants vs. Zombies™ 2 By PopCap
      Bundle ID: com.popcap.ios.PvZ2
      iTunes Store Link: https://itunes.apple.com/us/app/plants-vs-zombies-2/id597986893
       

      Mod Requirements:
      - Non-Jailbroken/Jailed or Jailbroken iPhone/iPad/iPod Touch.
      - Cydia Impactor.
      - A Computer Running Windows/Mac/Linux.


      Hack Features:
      - Unlimited Coins
      - Unlimited Gems
      - Unlimited Mints
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 3,477 replies
    • Plants vs. Zombies™ 2 (All Versions) +4 Cheats [Unlimited Currencies]
      Modded/Hacked App: Plants vs. Zombies™ 2 By PopCap
      Bundle ID: com.popcap.ios.PvZ2
      iTunes Store Link: https://itunes.apple.com/us/app/plants-vs-zombies-2/id597986893

       

      Mod Requirements:
      - Jailbroken iPhone/iPad/iPod Touch.
      - iFile / Filza / iFunBox / iTools or any other file managers for iOS.
      - Cydia Substrate (from Cydia).
      - PreferenceLoader (from Cydia).


      Hack Features:
      - Unlimited Coins
      - Unlimited Gems
      - Unlimited Mints
      - Unlimited Sun - Will increase instead of decrease.
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 4,010 replies
    • Jurassic World Alive v3.7.32 - [ Dino Don't Move & More ]
      Modded/Hacked App: Jurassic World Alive By Ludia
      Bundle ID: com.ludia.jw2
      iTunes Store Link: https://apps.apple.com/us/app/jurassic-world-alive/id1231085864

      Hack Features:
      - Dino Don't Move
      - Inf.Battery
      - VIP Enabled

      This hack works on the latest x64 or ARM64 iDevices: iPhone 5s, 6, 6 Plus, 6s, 6s Plus, 7, 7 Plus, 8, 8 Plus, X, Xr, Xs, Xs Max, SE, iPod Touch 6G, iPad Air, Air 2, Pro & iPad Mini 2, 3, 4 and later.


      Jailbreak required hack(s): https://iosgods.com/topic/103431-jurassic-world-alive-v1829-dino-dont-move-more/?tab=comments#comment-3107135
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 1,579 replies
    • Jurassic World Alive v3.7.32 - [ Dino Don't Move & More ]
      Modded/Hacked App: Jurassic World Alive By Ludia
      Bundle ID: com.ludia.jw2
      iTunes Store Link: https://apps.apple.com/us/app/jurassic-world-alive/id1231085864


      Hack Features:
      - Dino Don't Move
      - Inf. Battery
      - VIP Enabled

      This hack is an In-Game Mod Menu (iGMM). In order to activate the Mod Menu, tap on the iOSGods button found inside the app. This hack works on the latest x64 or ARM64 iDevices: iPhone 5s, 6, 6 Plus, 6s, 6s Plus, 7, 7 Plus, 8, 8 Plus, X, Xr, Xs, Xs Max, SE, iPod Touch 6G, iPad Air, Air 2, Pro & iPad Mini 2, 3, 4 and later.
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 1,495 replies
    • Modded/Hacked App: Kritika: The White Knights by GAMEVIL Inc.
      Bundle ID: com.gamevil.kritikam.ios.apple.global.normal
      iTunes Store Link: https://apps.apple.com/us/app/kritika-the-white-knights/id865958296

      Hack Features:
      - Infinite Potions (Increase instead of decrease)
      - Infinite Mana
      - No Potion Cooldown
      - Instant EX Gauge Fill
      - God Mode / Never Die
      - No Stage Timer -> Added upon request.

      This hack works on the latest x64 or ARM64 & ARM64e iDevices: iPhone 5s, 6, 6 Plus, 6s, 6s Plus, 7, 7 Plus, 8, 8 Plus, X, Xr, Xs, Xs Max, 11, 11 Pro, 11 Pro Max, 12, 12 Pro, 12 Pro Max, 12 Mini, 13, 13 Pro, 13 Pro Max, 13 Mini, 14, 14 Plus, 14 Pro, 14 Pro Max, SE, iPod Touch 6G, 7G, iPad Air, Air 2, iPad Pro & iPad Mini 2, 3, 4, 5, 6 and later.
      Jailbroken version of this hack: https://iosgods.com/topic/44092-vip-exclusive-kritika-the-white-knights-v2412-15-cheats/
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 1,330 replies
    • Kritika: The White Knights v5.5.2 +3 [God Mode & Set Damage Multiplier]
      Modded/Hacked App: Kritika: The White Knights By GAMEVIL Inc.
      Bundle ID: com.gamevil.kritikam.ios.apple.global.normal
      iTunes Store Link: https://itunes.apple.com/us/app/kritika-the-white-knights/id865958296
       

      Mod Requirements:
      - Jailbroken iPhone/iPad/iPod Touch.
      - iFile / Filza / iFunBox / iTools or any other file managers for iOS.
      - Cydia Substrate or Substitute.
      - PreferenceLoader (from Cydia or Sileo).


      Hack Features:
      - God Mode Works Everywhere
      - Set Damage Multiplier - Do not set it too high, you will get kicked out if you do.
      - No Skill Cooldown 

      All features are unlinked!
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 1,860 replies
    • Bullet Force v1.100.7 +3 Jailed Cheats [Radar Hack]
      Modded/Hacked App: Bullet Force by Blayze Games, L.L.C.
      Bundle ID: com.blayzegames.iosfps
      iTunes Store Link: https://itunes.apple.com/us/app/bullet-force/id1009134067

      Mod Requirements:
      - Non-Jailbroken/Jailed or Jailbroken iPhone/iPad/iPod Touch.
      - Cydia Impactor.
      - A Computer Running Windows/Mac/Linux.


      Hack Features:
      - Radar Hack - Shows all enemies on the radar.
      - Instant Reload
      - Anti-Flash - Flashbangs have no effect.
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 524 replies
    • [FREE] Bullet Force v1.100.7 +10 Cheats [Shoot Through Walls]
      Modded/Hacked App: Bullet Force By Blayze Games, L.L.C.
      Bundle ID: com.blayzegames.iosfps
      iTunes Store Link: https://itunes.apple.com/us/app/bullet-force/id1009134067


      Mod Requirements:
      - Jailbroken iPhone/iPad/iPod Touch.
      - iFile / Filza / iFunBox / iTools or any other file managers for iOS.
      - Cydia Substrate (from Cydia).
      - PreferenceLoader (from Cydia).


      Hack Features:
      - Unlimited Ammo + Increased Fire Rate - Both are linked. I can't unlink them, sorry.
      - Shoot Through Walls - Doesn't work for all walls.
      - ESP - Shows enemies nametags through walls.
      - Radar Hack - Shows all enemies on the radar.
      - Unlock All Perks
      - Instant Reload
      - Anti-Flash - Flashbangs have no effect.
      - Unlimited Throwables - Will not decrease. Works online, kinda.
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 3,695 replies
    • [ViP-Exclusive] Kritika: The White Knights v5.5.2 +10 Cheats
      Hacked App: Kritika: The White Knights By GAMEVIL Inc.
      iTunes Link: https://itunes.apple.com/us/app/kritika-the-white-knights/id865958296
      Bundle ID: com.gamevil.kritikam.ios.apple.global.normal


      Hack Features
      - Infinite Potions (Increase instead of decrease)
      - Infinite Mana
      - No Potion Cooldown
      - Instant EX Gauge Fill
      - God Mode in Stage Mode
      - God Mode in Tower & Monster Wave
      - God Mode in Arena & PvP (Untested)
      - Timer Hack*
      - Mao Support Always Active
      - 1 Hit Kill in Monster -> One Hit Kill was Replaced with "Monster Level 1"
      - Enemy Doesn't Attack
      - Boss Doesn't Attack
      - Enemy Doesn't Move
      - Boss Doesn't Move
      - Monster Level 1 -> Easy kills
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 3,043 replies
    • DRAGON BALL LEGENDS v5.5.1- [ Enemies Don't Attack & More ]
      Modded/Hacked App: DRAGON BALL LEGENDS By BANDAI NAMCO Entertainment Inc.
      Bundle ID: jp.co.bandainamcoent.BNEI0334
      iTunes Store Link: https://itunes.apple.com/us/app/dragon-ball-legends/id1358222641


      Mod Requirements:
      - Jailbroken or Non-Jailbroken iPhone/iPad/iPod Touch.
      - Cydia Impactor.
      - A Computer Running Windows/Mac/Linux.


      Hack Features:
      - Enemies Don't Attack
      - No Ki Cost
      - Unlimited Ki
      - Tutorial Bypassed - No Need To Play Tutorial
      - No Character Swap CoolDown
      - No Vanish CoolDown
      - Auto Complete All Challenges - Currency/Chrono Crystals Hack! 
      - Always Critical
      - All Cards Give DragonBall 
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 2,508 replies
    • DRAGON BALL LEGENDS v5.5.1 +3 Jailed Cheats [No Ki Cost + More]
      Modded/Hacked App: DRAGON BALL LEGENDS By BANDAI NAMCO Entertainment Inc.
      Bundle ID: jp.co.bandainamcoent.BNEI0334
      iTunes Store Link: https://itunes.apple.com/us/app/dragon-ball-legends/id1358222641


      Mod Requirements:
      - Jailbroken or Non-Jailbroken iPhone/iPad/iPod Touch.
      - Cydia Impactor.
      - A Computer Running Windows/Mac/Linux.


      Hack Features:
      - No Ki Cost
      - No Character Swap Cooldown
      - No Vanish Cooldown
      - Tutorial Bypassed
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 4,880 replies
    • DRAGON BALL LEGENDS v5.5.1 +7 FREE Cheats
      Modded/Hacked App: DRAGON BALL LEGENDS by BANDAI NAMCO Entertainment Inc.
      Bundle ID: jp.co.bandainamcoent.BNEI0334
      iTunes Store Link: https://apps.apple.com/us/app/dragon-ball-legends/id1358222641


      Hack Features:
      - No Swap Cooldown
      - No Vanish Cooldown
      - No KI Cost
      -  Auto Complete all Challenges
      - Always Critical
      - Tutorial Bypassed
      - Enemies don't Attack


      Non-Jailbroken & No Jailbreak required hack(s): https://iosgods.com/topic/70408-ios-13-support-dragon-ball-legends-v2110-3-jailed-cheats-no-ki-cost-more/
      Japanese Version: https://iosgods.com/topic/75598-dbl-%E3%83%89%E3%83%A9%E3%82%B4%E3%83%B3%E3%83%9C%E3%83%BC%E3%83%AB-%E3%83%AC%E3%82%B8%E3%82%A7%E3%83%B3%E3%82%BA-by-bandai-namco-entertainment-inc-v2100-instant-win-more/?
      For more fun, check out the Club(s): https://iosgods.com/clubs/
        • Informative
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 3,049 replies
×
  • Create New...

Important Information

We would like to place cookies on your device to help make this website better. The website cannot give you the best user experience without cookies. You can accept or decline our cookies. You may also adjust your cookie settings. Privacy Policy - Guidelines