# jamf/jamfprotect architecture

> Architecture diagram of the GitHub repository jamf/jamfprotect, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-03-23). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/jamf/jamfprotect
- Repository: https://github.com/jamf/jamfprotect

## Overview

##### Main Components
- Custom Analytics (custom_analytic_detections): This folder contains YAML files defining behavioral detection rules. Represent this as a module that “feeds” analytic rules into Jamf Protect.
- Device Controls (device_controls): Contains configurations to manage and restrict endpoint behaviors (e.g., mobile device syncing). Treat this as a device management/control module.
- Helper Tools (helper_tools): Includes diagnostic scripts, event analysis, audit re-enabling scripts, and even sample apps. Highlight these as utility modules that support testing, diagnostics, and maintenance.
- Jamf Pro Extension Attributes (jamf_pro_extension_attributes): These are scripts and templates used to extend Jamf Pro inventory reporting related to Jamf Protect. Represent this as the custom reporting or attributes component.
- JSON Samples and Schemas (json_samples_and_schemas): A repository of JSON event samples, telemetry, and web protection schemas. This acts as the data-contract or schema specification module.
- SOAR Playbooks (soar_playbooks): Automation playbooks that integrate Jamf Protect with Jamf Pro for remediation workflows. Include these as orchestration and automation components.
- Telemetry (telemetry): Contains scripts and examples for log file collection and telemetry data gathering.
- Third Party Integrations (third_party_integrations): Scripts and workflows to integrate with external systems such as Microsoft Sentinel, ZTNA solutions, and alerts management. These should be represented as connectors or integration modules.
- Unified Log Filters (unified_log_filters): YAML files that define logging filters to streamline data before passing to SIEMs or third-party data stores.

##### Relationships and Interactions
- Central Hub (Jamf Protect) – Connect most of the components (Custom Analytics, API Scripts, Telemetry) into the central Jamf Protect platform.
- Extension Attributes and API Scripts – The extension attributes module feeds into Jamf Pro, which in turn acts upon or supplies data to Jamf Protect.
- Data Flow – JSON Samples/Schemas act as reference materials ensuring that other modules like Telemetry and Unified Log Filters produce standardized data exchange formats.
- Helper Tools – These are supporting scripts that might diagnose or test outputs from any of the other modules (e.g., API Tools and Telemetry).

##### Architectural Patterns/Design Principles
- Modularity: The repository is designed in a modular fashion; each directory group represents an independent, yet connected module.
- Separation of Concerns: There’s a clear separation between analytics, device controls, API operations, automation, and integrations.
- Integration Layer: The API scripts and third-party integrations indicate a well-thought-out integration model using standard interfaces (GraphQL API, JSON schemas).
- Extensibility: The inclusion of SOAR playbooks, custom attributes, and extensible log filters emphasize design flexibility and extensibility.

##### Relevant Technologies/Frameworks
- YAML and JSON for configuration and schema definitions.
- Scripting languages: Bash, Python, and shell scripts are used for API integrations and helper tools.
- Jamf Protect and Jamf Pro APIs and extension attributes as central technologies.
- SIEM and third-party integration points (as referenced in JSON samples and unified log filters).

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Nodes
    JamfProtect["Jamf Protect Core Integration"]:::core
    JamfPro["Jamf Pro"]:::core
    ExternalSIEM["SIEM/External Systems"]:::integration

    CustomAnalytics["Custom Analytic Detections (YAML rules)"]:::config
    DeviceControls["Device Controls (Endpoint Configurations)"]:::config
    HelperTools["Helper Tools (Diagnostics & Utilities)"]:::script
    JamfProExt["Jamf Pro Extension Attributes (Custom Reporting)"]:::script
    JamfProtectAPIScripts["Jamf Protect API Scripts (Automated Tasks)"]:::script
    JSONSamples["JSON Samples & Schemas (Data Contracts)"]:::config
    SOARPlaybooks["SOAR Playbooks (Automation & Orchestration)"]:::automation
    Telemetry["Telemetry (Log & Telemetry Collection)"]:::script
    ThirdParty["Third Party Integrations (External Connectors)"]:::integration
    UnifiedLogFilters["Unified Log Filters (Log Standardization)"]:::config

    %% Relationships to Jamf Protect Core Integration
    CustomAnalytics -->|"rules"| JamfProtect
    DeviceControls -->|"configs"| JamfProtect
    JamfProtectAPIScripts -->|"APIcalls"| JamfProtect
    Telemetry -->|"telemetry"| JamfProtect
    HelperTools -->|"support"| JamfProtect

    %% Relationships involving Jamf Pro
    JamfProExt -->|"inventory"| JamfPro
    SOARPlaybooks -->|"remediation"| JamfProtect
    SOARPlaybooks -->|"remediation"| JamfPro

    %% External integration paths
    UnifiedLogFilters -->|"filters"| ExternalSIEM
    ThirdParty -->|"externalAPIs"| ExternalSIEM

    %% Data contract flows
    JSONSamples -->|"standards"| Telemetry
    JSONSamples -->|"standards"| UnifiedLogFilters
    JSONSamples -->|"schemas"| JamfProtectAPIScripts
    HelperTools -->|"testing"| JamfProtectAPIScripts

    %% Styles
    classDef core fill:#FFD700,stroke:#333,stroke-width:2px;
    classDef config fill:#ADD8E6,stroke:#333,stroke-width:1px;
    classDef script fill:#90EE90,stroke:#333,stroke-width:1px;
    classDef automation fill:#FFB6C1,stroke:#333,stroke-width:1px;
    classDef integration fill:#DDA0DD,stroke:#333,stroke-width:1px;

    %% Click Events
    click CustomAnalytics "https://github.com/jamf/jamfprotect/tree/main/custom_analytic_detections"
    click DeviceControls "https://github.com/jamf/jamfprotect/tree/main/device_controls"
    click HelperTools "https://github.com/jamf/jamfprotect/tree/main/helper_tools"
    click JamfProExt "https://github.com/jamf/jamfprotect/tree/main/jamf_pro_extension_attributes"
    click JamfProtectAPIScripts "https://github.com/jamf/jamfprotect/tree/main/jamf_protect_api"
    click JSONSamples "https://github.com/jamf/jamfprotect/tree/main/json_samples_and_schemas"
    click SOARPlaybooks "https://github.com/jamf/jamfprotect/tree/main/soar_playbooks"
    click Telemetry "https://github.com/jamf/jamfprotect/tree/main/telemetry"
    click ThirdParty "https://github.com/jamf/jamfprotect/tree/main/third_party_integrations"
    click UnifiedLogFilters "https://github.com/jamf/jamfprotect/tree/main/unified_log_filters"
```
