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 6113883
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T14:54:36+00:00 2026-05-23T14:54:36+00:00

I have to find a button’s name in a running process memory in Mac

  • 0

I have to find a button’s name in a running process memory in Mac OSX and change it.

Supposing there is a “Test” application where it has a “Hello” button, is there any way to attach to “Test” application and change the “Hello!” button to “Bye!”?

I assume this could be done either using GDB or Xcode. If not, how can I do this?

  • 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-05-23T14:54:36+00:00Added an answer on May 23, 2026 at 2:54 pm

    Edit

    Assuming you are really looking for dynamic data (as opposed to what your sample seemed to suggest :)) you could always just work with the debugger commands. This will require you to have a sense of the possible memory range to scan (or you’ll simply get useless memory violations):

    Use gdb commands, loop constructs and libc functions

    # assume 0x1234 is a likely base address, say for the heap
    (gdb) set $x=0x1234
    (gdb) set $y = strdup("lookforthistext")
    (gdb) while(0!=memcmp($x++, $y, 15) && $x<0x4321)
        >end
    (gdb) p $x
    (gdb) x $x
    

    This example scans the region 0x1234…0x4321 for the first match and prints/examines the output address.

    You can use similar tricks (strncpy…?) to overwrite the memory if you had access to it.
    Of course the program may fail dramatically if you do things like changing the length of a substring.. YMMV).

    Consider saving your concocted commands as a script (turn on logging, use .gdbinit or even create gdb functions; sadly I know little about the latter)

    Original answer:

    You “need to”? I doubt it. Your best bet is to work with the windowing/UI API’s of your operating system to retrieve the actual window that display the text and make it display another text (usually by sending it appropriate control messages). You’ll need plenty of COW powers (think: root) to pull that off.


    To answer the direct question:

    Usually, messages like this are constants (static data) and as such are either

    1. present in the data segment
    2. read (memory mapped pages) from resources

    Both of which are usually (these days at least) in read-only memory segments (think of sharing of memory mapped pages; this gives the kernel opportunity to share mapped regions of shared binary objects between processes – also it serves the obvious security purposes).

    On the upside,

    strings myprogram | grep 'Hello"
    

    will tell you whether you can use sed, a hex editor or any other suitable editor to manipulate the binary even before it starts. There are two drawbacks I can think of here:

    1. it is not dynamic (you can’t have the text change on the fly)
    2. it may break code signing (meaning the executable might get rejected by the OS because it has been modified).
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've heard bits and pieces here and there, but I have yet find a
I have this Jquery: div.find(.CopyIntoNewTownAssociation).button({ icons: { primary: ui-icon-copy, text: false} }); and this
I'm wanting to click a button and have the matching id name show. I
I have this jquery: $(.button).toggle(function() { $(this).find(.button).addClass('disable'); }, function(){ $(this).find(.button).removeClass('disable'); }); My html for
I am evaluating datamining packages. I have find these two so far: RapidMiner Weka
I have to find the IDs of all the contentPlaceHolders in a MasterPage.
I have a Find function in order to find an element from a BST
I have a few models that need to have custom find conditions placed on
I have two Java instances of java.util.Date and I have to find out if
Nowadays most of the Restaurants and other businesses have a Find Locations functionality on

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.