MobileDevice Library

MobileDevice Library is used by iTunes to transfer data between iPhone and computer over both USB and WiFi connections.

Windows: iTunesMobileDevice.dll

 * Location:  (  on 64-bit)
 * Supporting CoreFoundation.dll (used for CFStringRef, CFPropertyListRef management) is located in the same dir (when using iTunes prior 9.0).
 * For iTunes 9.0, the location of CoreFoundation.dll is stored in InstallDir registry value under HKLM\SOFTWARE\Apple Inc.\Apple Application Support registry key.

Mac OS X: MobileDevice.framework

 * Location: /System/Library/PrivateFrameworks/MobileDevice.framework
 * Export command:

Library Interfaces

 * libimobiledevice (provides the same functionality on GNU/Linux)
 * mobiledevice (command line utility for interacting with MobileDevice Framework)
 * SDMMobileDevice (OS X framework written in C that can be used interchangeably with Apple's private framework MobileDevice.framework)
 * MobileDeviceAccess (similar to above, but written in Objective-C)
 * MobileDevice.h (old reverse engineered header for interfacing with MobileDevice library)

Obtaining address
In order to obtain the address of a usable private function in MobileDevice, you will have to be able to understand x86-64 assembly to reverse engineer it. These methods differ slightly based on platform due to how dynamically linked libraries handle position independent code.

Mac OS X (MobileDevice.framework)
A private function is not marked as exported in the mach-o symbol table. This means it cannot be called by simply linking against the library. To call unexported functions, the mach-o symbol table must be stepped through manually to find the offset of a particular function call. Calls can be verified by checking against the offset of the name inside the name table.

Windows (MobileDevice.dll)
Unlike OS X's dynamically linkable libraries, Windows dynamic libraries do not support position independent code in the same manner. A private function will not have its name in the exported symbol table, so in a debugger, like GDB, it will show up as part of another function. However, you will know that it is a separate function as a new stack frame is set up.

Known Error Codes
For the latest error codes you can look at the pseudo-code of AMDErrorString.

MobileDeviceUpdater


Since at least macOS High Sierra (possibly as early as the introduction of System Integrity Protection in OS X El Capitan), MobileDevice handles its own updates. When a device unknown to the currently installed build of MobileDevice is connected, MobileDeviceUpdater.app prompts the user to install a software update. Previously, MobileDevice would only be updated by installing a full iTunes or Xcode update.

Due to System Integrity Protection, AMDS is installed to, which is symbolically linked to from. Apps that use MobileDevice will use the new build upon next launch.

Additionally, extra bundles may be installed to  and , registering icons for new devices unknown to the current base operating system. This includes Mac devices.