iOS Simulator PrivacyManager: Supported Privacy Permissions Beyond the Common Set

The PrivacyManager in conorluddy/ios-simulator-skill supports nine additional iOS privacy permissions beyond camera, microphone, and location, including Health, Siri, Motion & Fitness, and Call History access.

The iOS Simulator Skill provides a centralized Python interface for managing privacy permissions during automated testing. The PrivacyManager script (ios-simulator-skill/scripts/privacy_manager.py) exposes a comprehensive set of services through the SUPPORTED_SERVICES mapping, enabling developers to programmatically control access to sensitive device capabilities that extend well beyond the standard permission set.

Complete List of Supported Privacy Permissions

The authoritative source of supported permissions resides in ios-simulator-skill/scripts/privacy_manager.py at lines 22-37. The SUPPORTED_SERVICES dictionary defines the complete capability matrix that the CLI accepts:


# Supported services (privacy_manager.py L22-L37)

SUPPORTED_SERVICES = {
    "camera":      "Camera access",
    "microphone":  "Microphone access",
    "location":    "Location services",
    "contacts":    "Contacts access",
    "photos":      "Photos library access",
    "calendar":    "Calendar access",
    "health":      "Health data access",
    "reminders":   "Reminders access",
    "motion":      "Motion & fitness",
    "keyboard":    "Keyboard access",
    "mediaLibrary":"Media library",
    "calls":       "Call history",
    "siri":        "Siri access",
}

Beyond the common permissions (camera, microphone, location, contacts, photos), the manager specifically supports:

  • calendar – Calendar database access
  • health – HealthKit data streams
  • reminders – Reminders app integration
  • motion – Motion & fitness tracking (Core Motion)
  • keyboard – Third-party keyboard extensions
  • mediaLibrary – Apple Media Library access
  • calls – Call history metadata
  • siri – SiriKit intent handling

How the PrivacyManager Validates Permissions

Every public method—grant_permission(), revoke_permission(), and reset_permission()—validates input against the SUPPORTED_SERVICES keys. If a caller supplies an unrecognized service identifier, the script executes error handling logic at lines 66-69, printing a diagnostic message that enumerates the full set of supported keys.

This strict validation ensures that only valid xcrun simctl privacy service names are passed to the underlying iOS Simulator infrastructure, preventing runtime failures during test automation sequences.

Discovering Available Permissions with the CLI

You can inspect the complete permission catalog without reading source code by using the --list flag. The main() function implements this feature around line 42, printing a formatted table of all 13 supported services:

python scripts/privacy_manager.py --list

This outputs the human-readable descriptions mapped in SUPPORTED_SERVICES, making it easy to identify which extended permissions (like health or motion) are available for your test scenarios.

Granting, Revoking, and Resetting Extended Permissions

All permission-changing operations ultimately invoke xcrun simctl privacy with three required components: the validated service name from SUPPORTED_SERVICES, the target simulator UDID (auto-detected via resolve_udid from common.py), and the target app's bundle identifier.

After each operation, the manager emits an audit entry through _log_audit (lines 74-98) for test-scenario tracking and compliance documentation.

Grant Health Data Access

python scripts/privacy_manager.py \
    --grant health \
    --bundle-id com.example.myapp

Revoke Motion & Fitness Permission

python scripts/privacy_manager.py \
    --revoke motion \
    --bundle-id com.example.myapp \
    --scenario "Onboarding Flow" \
    --step 3

Reset Siri to Default State

python scripts/privacy_manager.py \
    --reset siri \
    --bundle-id com.example.myapp

Batch Grant Multiple Extended Permissions

The CLI accepts comma-separated service names, enabling efficient setup of complex privacy states:

python scripts/privacy_manager.py \
    --grant calendar,reminders,health \
    --bundle-id com.example.myapp

Summary

  • The SUPPORTED_SERVICES mapping in privacy_manager.py (lines 22-37) defines 13 total privacy permissions, extending beyond common services to include health, motion, keyboard, media library, calls, and Siri.
  • Input validation occurs at lines 66-69, ensuring only legitimate iOS privacy services reach the simulator.
  • The --list CLI flag provides self-documenting discovery of all supported permissions without source inspection.
  • Every permission change triggers xcrun simctl privacy and generates audit logs via _log_audit (lines 74-98) for test traceability.

Frequently Asked Questions

What specific privacy permissions does the iOS Simulator Skill support beyond camera and microphone?

According to the source code in conorluddy/ios-simulator-skill, the PrivacyManager supports calendar, health, reminders, motion & fitness, keyboard, media library, call history, and Siri access beyond the standard camera, microphone, location, contacts, and photos permissions. These are defined in the SUPPORTED_SERVICES constant at lines 22-37 of privacy_manager.py.

How do I list all available privacy permissions in the PrivacyManager?

Execute python scripts/privacy_manager.py --list to display the complete table of supported services. This functionality is implemented in the main() function around line 42 and reads directly from the SUPPORTED_SERVICES dictionary.

Can I manage Health and Siri permissions programmatically with this tool?

Yes. The grant_permission(), revoke_permission(), and reset_permission() methods all accept "health" and "siri" as valid service identifiers. These map directly to xcrun simctl privacy commands targeting HealthKit and SiriKit entitlements respectively.

Where does the PrivacyManager log permission changes?

The _log_audit method (lines 74-98 in privacy_manager.py) emits structured audit entries after every grant, revoke, or reset operation. When you provide --scenario and --step arguments, these entries include contextual test metadata for scenario replay and compliance verification.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →