Questions tagged [mach]

Mach is the name of the foundational component of the XNU kernel, common to macOS, iOS, tvOS and watchOS. Originally developed by CMU, it was adopted by NeXTSTEP, and integrated into macOS (formally known as Mac OS X) when the former merged with Apple. Though largely undocumented, Mach APIs make up the core of XNU's IPC, scheduling and memory management, supplementing the more widely known POSIX APIs offered in Darwin.

159 questions
0
votes
1 answer

Mac hook function

I used to be able to use mach_override to hook any exported function on Mac OS including Catalina. However, now the target app crashed every time and I check the Console and find the following error: CODE SIGNING: 30911[app] vm_map_protect can't…
ken
  • 63
  • 1
  • 4
0
votes
1 answer

IOLockWakeup and IOLockSleep

I am curious about the event parameter that gets passed to IOLockWakeup and IOLockSleep{Deadline}. i understand that the event is an address that gets passed to both functions. i am assuming this address is used to essentially notify the thread. so…
gagan
  • 115
  • 9
0
votes
1 answer

Attempt to call global "Sicherheitskreis" (a nil value ) stack traceback

I'm trying to secure the doors of my CNC with switchs that send a Signal to my Laptop (I got Mach 4 on it). I created this Code that should make the Spindle stay still if the doors aren't locked, but I always get an error that says : [string""]1576…
Alucalex
  • 3
  • 2
0
votes
0 answers

Equivalent of `objcopy -O binary .bin` for Mach-O object files on macOS?

Equivalent of objcopy -O binary .bin for Mach-O object files in macOS? I want to dump the executable code in the __TEXT segment to a flat binary file on macOS. This can be accomplished on Linux as follows: objcopy -O binary
Shuzheng
  • 11,288
  • 20
  • 88
  • 186
0
votes
0 answers

iOS Catch Debugger Trap (BKPT 3)

I have an iOS application I am analyzing/reverse engineering. There is a function I want to intercept with Frida. Normally, this wouldn't be a problem but the function is called at or soon after the app is launched so there is no time for Frida to…
genghiskhan
  • 1,095
  • 12
  • 21
0
votes
1 answer

why is this pointer Typedef'd to a struct

I've been looking through the code for various IPC systems and I happen to come across these lines in Mach(xnu-123.5/osfmk/ipc/ipc_port.h) typedef port_name_t mach_port_name_t; typedef mach_port_name_t *mach_port_name_array_t; where the…
Emacs Fan
  • 3
  • 1
0
votes
1 answer

iOS project won't compile because of missing OpenCV file

I'm compiling from the Pods workspace. Using OpenCv-ios 3.0.2. It's compiled fine before I changed the bundle name. Tried cleaning and building to no avail. Thank you for any and all suggestions!
Nick
  • 51
  • 2
0
votes
1 answer

Getting Apple Mach-O Linker (Id) Error on iOS app with ar6unity

I have the exact same issue as this; Apple Mach-O Linker (Id) Error on ar6unity iOS Unfortunately the link to the accepted answer in that post is broken. I've been trying all sorts of other Mach-O linker error solutions; Clean & Rebuild Deleted…
seltar
  • 1
  • 3
0
votes
0 answers

Error about 32 bit address in 64 bit mode for global data

I'm trying to write a simple x64 assembly program on mac using nasm. Here is my program: global start section .text start: mov r10, 3; Store 3 to r10 mov r9, 4; Store 4 to r9 mov rax, r10; Move 3 to rax because multiply needs an arg in…
Drew
  • 12,578
  • 11
  • 58
  • 98
0
votes
1 answer

In `/usr/include/mach-o/loader.h`, what's the mach filetype `mh_dylib_stub` for?

I'm reading mach-o/loader.h and noticed this file type and it's description: #define MH_DYLIB_STUB 0x9 /* shared library stub for static */ /* linking only, no section contents */ This sounds almost like an…
lanza
  • 1,512
  • 2
  • 13
  • 26
0
votes
1 answer

Mac assembly: segfault with libc exit

I am diving into x86_64 assembly on macOS 10.12. I am trying to call libc exit() function: .section __TEXT,__text .globl _main _main: pushq %rbp movq %rsp, %rbp movl $5, %edi callq _exit And compile it with: as exit2.s -o exit2.o ld…
CorellianAle
  • 645
  • 8
  • 16
0
votes
1 answer

Mach vs Spring Operating Systems

I have to write a paper on an operating system topic. I decided to get some information about Mach and Spring (being both microkernel and object-oriented operating systems). I'd like the paper to be a comparison between some specific aspects about…
0
votes
1 answer

Different result from match search and check directly cell()

For the below problem I mistakenly asked for a review in C.R., but they told me not to be the right place, so I extend to you the same question. I cannot find answers alone. this very simple code return 2 different results, why ?!?! I'll be…
Fabrizio
  • 662
  • 1
  • 7
  • 23
0
votes
1 answer

Catch system calls on Mac OS X

I'm trying to catch all systems-calls called by a given PID with a self-made program (I cant use any of strace, dtruss, gdb...). So i used the function kern_return_t task_set_emulation(task_t target_port, vm_address_t routine_entry_pt, int…
limaconoob
  • 53
  • 1
  • 7
0
votes
1 answer

Xcode 8 beta 5 : The operation couldn't be completed

I'm working on Xcode 8 beta 5. While running app on iPhone SE simulator I'm getting an error that The operation couldn't be completed. (Mach error - 308 - (pic/mig) server died). I tried clean build, restart Xcode but didn't worked. Any fix?
Jayprakash Dubey
  • 35,723
  • 18
  • 170
  • 177