Skip to content

Latest commit

 

History

History
49 lines (32 loc) · 3.57 KB

File metadata and controls

49 lines (32 loc) · 3.57 KB

macOS Apple Events

{% hint style="success" %} Learn & practice AWS Hacking:HackTricks Training AWS Red Team Expert (ARTE)
Learn & practice GCP Hacking: HackTricks Training GCP Red Team Expert (GRTE)

Support HackTricks
{% endhint %}

Basic Information

Apple Events are a feature in Apple's macOS that allows applications to communicate with each other. They are part of the Apple Event Manager, which is a component of the macOS operating system responsible for handling interprocess communication. This system enables one application to send a message to another application to request that it perform a particular operation, like opening a file, retrieving data, or executing a command.

The mina daemon is /System/Library/CoreServices/appleeventsd which registers the service com.apple.coreservices.appleevents.

Every application that can receive events will checking with this daemon providing its Apple Event Mach Port. And when an app wants to send an event to to it, the app will request this port from the daemon.

Sandboxed applications requires privileges like allow appleevent-send and (allow mach-lookup (global-name "com.apple.coreservices.appleevents)) in order to be able to send events. Noten that entitlements like com.apple.security.temporary-exception.apple-events could restrict who have access to send events which will need entitlements like com.apple.private.appleevents.

{% hint style="success" %} It's possible to use the env variable AEDebugSends in order to log informtion about the message sent:

AEDebugSends=1 osascript -e 'tell application "iTerm" to activate'

{% endhint %}

{% hint style="success" %} Learn & practice AWS Hacking:HackTricks Training AWS Red Team Expert (ARTE)
Learn & practice GCP Hacking: HackTricks Training GCP Red Team Expert (GRTE)

Support HackTricks
{% endhint %}