
An in-depth look into Mac OS X and iOS kernels Powering Macs, iPhones, iPads and more, OS X and iOS are becoming ubiquitous. When it comes to documentation, however, much of them are shrouded in mystery. Cocoa and Carbon, the application frameworks, are neatly described, but system programmers find the rest lacking. This indispensable guide illuminates the darkest corners of those systems, starting with an architectural overview, then drilling all the way to the core. • Provides you with a top down view of OS X and iOS • Walks you through the phases of system startup—both Mac (EFi) and mobile (iBoot) • Explains how processes, threads, virtual memory, and filesystems are maintained • Covers the security architecture • Reviews the internal Apis used by the system—BSD and Mach • Dissects the kernel, XNU, into its sub components: Mach, the BSD Layer, and I/o kit, and explains each in detail • Explains the inner workings of device drivers From architecture to implementation, this book is essential reading if you want to get serious about the internal workings of Mac OS X and iOS.
You can start by reading the Mac OS X Internals, followed by Mac OS X and iOS Internals: To the Apple's Core.
Then hop over to Apple's archive, https://developer.apple.com/library/archive/navigation/
Also many BSD syscalls have been deprecated along the years, including POSIX features like networking stack, now replaced by Objective-C APIs.
I would advise spending some time reading "Mac OS X Internals: A Systems Approach" and "Mac OS X and iOS Internals" books, to learn that having everything on kernel space alone, doesn't rewrite the original microkernel code into a huge monolith.
"On top of Mach, but still an inseparable part of XNU, is the BSD layer. This layer presents a solid and more modern API that provides the POSIX compatibility discussed earlier. The BSD layer provides higher-level abstractions, including, among others:
‰ The UNIX Process model
‰ The POSIX threading model (Pthread) and its related synchronization primitives
‰ UNIX Users and Groups
‰ The Network stack (BSD Socket API)
‰ File system access
‰ Device access (through the /dev directory)
XNU’s BSD implementation is largely compatible with FreeBSD’s, but does have some noteworthy changes. After covering Mach, this book turns to BSD, focusing on the implementations of the BSD core, and providing specific detail about the virtual file system switch and the networking stack in dedicated chapters."
I don't disagree with Apple providing funding, however the BSD license doesn't require it. Many of the original Windows userland network utilities came directly from BSD, as well.
Technically it is kind of the same, but with different set of configured features.
Already a bit oldie,
"Mac OS X and iOS Internals: To the Apple's Core"
https://www.amazon.com/Mac-OS-iOS-Internals-Apples/dp/111805...
They are an updated and much expanded version of "Mac OS X and iOS Internals: To the Apple′s Core" by the same author.
Which in turn was an updated version of "MAC OS X Internals: A Systems Approach" by Amit Singh.
Or having been a former Microsoft or Apple employee working on kernel stuff, then I could eventually value the opinion how fake they happen to be.
Yet somehow I get the feeling, from both of us, only I have delved into such internals.