# system_profiler

> Reports system hardware and software configuration.

system_profiler reports on the hardware and software configuration of the system. It can generate plain text reports or XML reports which can be opened with System Information.app

- Page: https://loobins.io/binaries/system_profiler/
- Author: Ethan Nay
- Created: 2023-07-12
- Tactics: Discovery

## Paths

- `/usr/sbin/system_profiler`

## Example Use Cases

### Listing the available datatypes

List all available sub-systems to get information from.

```bash
system_profiler -listDataTypes
```

- Tactics: Discovery
- Tags: bash, zsh

### Print hardware information

Prints an overview of the hardware of the current machine, including its model name and serial number.

```bash
system_profiler SPHardwareDataType
```

- Tactics: Discovery
- Tags: bash, zsh

### Print software information

Prints an overview of the software of the current machine, including the exact macOS version number.

```bash
system_profiler SPSoftwareDataType
```

- Tactics: Discovery
- Tags: bash, zsh

### Print the information of developer tools

Prints the currently active version of the Xcode developer tools and SDK.

```bash
system_profiler SPDeveloperToolsDataType
```

- Tactics: Discovery
- Tags: bash, zsh

### Print power and battery information

Prints power and battery information, including the current AC wattage and battery cycle count.

```bash
system_profiler SPPowerDataType
```

- Tactics: Discovery
- Tags: bash, zsh

## Detections

- [System Information Discovery Using System_Profiler](https://github.com/SigmaHQ/sigma/blob/master/rules/macos/process_creation/proc_creation_macos_system_profiler_discovery.yml)
- [Jamf Protect: Detect system_profiler activity that gathers system information](https://github.com/jamf/jamfprotect/blob/main/custom_analytic_detections/system_profiler_activity)

## Resources

- [macOS/binaries/system_profiler](https://macosbin.com/bin/system_profiler)
- [system_profiler man page](https://ss64.com/osx/system_profiler.html)
