Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7799915
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T00:27:48+00:00 2026-06-02T00:27:48+00:00

to get UUID on mac i can use dwarfdump -u path/to/compile/executable also i can

  • 0

to get UUID on mac i can use

dwarfdump -u path/to/compile/executable

also i can get UUID with simple crash
in ‘Binary Images’ section

Is the way to get UUID without crash on ios device?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T00:27:51+00:00Added an answer on June 2, 2026 at 12:27 am

    An executable’s (mach-o file) UUID is created by the linker ld and is stored in a load command named LC_UUID. You can see all load commands of a mach-o file using otool:

    otool -l path_to_executable
    
    > ...
    > Load command 8
    >      cmd LC_UUID
    >  cmdsize 24
    >     uuid 3AB82BF6-8F53-39A0-BE2D-D5AEA84D8BA6
    > ...
    

    Any process can access its mach-o header using a global symbol named _mh_execute_header. Using this symbol you can iterate over the load commands to search LC_UUID. The payload of the command is the UUID:

    #import <mach-o/ldsyms.h>
    
    NSString *executableUUID()
    {
        const uint8_t *command = (const uint8_t *)(&_mh_execute_header + 1);
        for (uint32_t idx = 0; idx < _mh_execute_header.ncmds; ++idx) {
            if (((const struct load_command *)command)->cmd == LC_UUID) {
                command += sizeof(struct load_command);
                return [NSString stringWithFormat:@"%02X%02X%02X%02X-%02X%02X-%02X%02X-%02X%02X-%02X%02X%02X%02X%02X%02X",
                        command[0], command[1], command[2], command[3],
                        command[4], command[5],
                        command[6], command[7],
                        command[8], command[9],
                        command[10], command[11], command[12], command[13], command[14], command[15]];
            } else {
                command += ((const struct load_command *)command)->cmdsize;
            }
        }
        return nil;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

how can I get 16 bytes binary form of the uuid from its string/canonical
in java we can get UUID from class ie UUID.randomUUID().toString() how to get UUID
I am using couchDB to get a UUID so that I can send a
I can't get Hibernate working with java.util.UUID for PostgreSQL. Here is the mapping using
i get a valid fd object from a caller. How can i find out
Do you know if is possibile to get the uuid, the result of [[UIDevice
I use xml to get label for my website. the xml generated from database
I still can't get the idea that when I create a new Group in
I want to use UUID() to generate primary keys. After some investigation, I thought
I get a UUID mismatch warning at the console when I try to build

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.