Skip to content

Add 61 macOS forensic plugins (195 functions)#1717

Draft
MrJayTechie wants to merge 1 commit intofox-it:mainfrom
MrJayTechie:macos-forensic-plugins
Draft

Add 61 macOS forensic plugins (195 functions)#1717
MrJayTechie wants to merge 1 commit intofox-it:mainfrom
MrJayTechie:macos-forensic-plugins

Conversation

@MrJayTechie
Copy link
Copy Markdown

Summary

I've been working on macOS forensic plugins for dissect and built 61 plugins covering 195 functions across all major macOS artifacts. Right now dissect.target only has 3 macOS plugins (user, network, _os) — this would bring macOS coverage much closer to what's available for Windows and Linux.

What's included

Category Plugins Functions
Browsers safari, chromium, firefox, cookies 21
User Activity knowledgec, biome, screentime, interactions, spotlight, launchpad 54
Communications imessage, callhistory, facetime, addressbook, notifications, notes 15
Persistence autostart, kext, execpolicy, applications 16
Security tcc, firewall, keychain, profiles 15
Logs logs, crashreporter, powerlogs 16
File System fsevents, dsstore, docrevisions, trash, quicklook 8
Network wifiintelligence, ssh, ard, msrdc, screensharing 9
System/Other preferences, osinfo, users, accounts, icloud, wallet, and more 41

Key points

  • macOS 13, 14, 15 compatible (including Sequoia path changes)
  • All SQLite plugins handle WAL/SHM sidecars
  • Handles Velociraptor %2E filename encoding
  • Ruff clean, type hints and docstrings on all exports
  • Tested with 0 errors across multiple collections

Testing

Tested against real macOS collections — 135/195 functions return data on a typical Mac. Remaining are legitimate empties (app not installed, feature disabled). Happy to add pytest tests based on your framework.

Comprehensive macOS artifact parsing covering:

Browsers: Safari, Chrome/Edge/Brave (Chromium), Firefox
  - history, downloads, searches, bookmarks, cookies, logins

User Activity: KnowledgeC (12 functions), Biome (35 functions),
  ScreenTime, Interactions, Spotlight, Launchpad

Communications: iMessage, FaceTime, CallHistory, Contacts,
  Notifications, Apple Notes

Persistence: LaunchAgents/Daemons, kernel/system extensions,
  cron jobs, periodic scripts, startup files

Security: TCC access grants, firewall (PF + ALF), keychain,
  Gatekeeper/ExecPolicy, MDM profiles

File System: FSEvents, DS_Store, Document Revisions, Trash,
  QuickLook thumbnails

Logs: system/install logs, ASL binary databases, power management,
  crash reports, audit configuration

Network: WiFi intelligence, DHCP leases, SSH, Screen Sharing,
  Apple Remote Desktop, Microsoft Remote Desktop

System: preferences, OS info, local users, timezone, hosts,
  sudoers, share points, DHCP, accounts

Other: Apple Wallet/Pay, Office MRU, shell history, print jobs,
  install history, software updates, iCloud, iOS backups,
  saved application state

All plugins:
- Tested on macOS 13 (Ventura), 14 (Sonoma), 15 (Sequoia)
- 0 errors across multiple test machines
- Handle SQLite WAL/SHM sidecars for data completeness
- Handle Velociraptor %2E filename encoding
- Support both live systems and forensic images
@Schamper
Copy link
Copy Markdown
Member

Thanks for the incredible contribution! It’s too large to review as one PR though, would you mind splitting it up in logical chunks, keeping in mind the following:

  • All contributions must have test data + unit tests
  • If test data is tricky to produce, please include steps on how to reproduce your test data
  • All tests and linting must pass

Thanks!

MrJayTechie pushed a commit to MrJayTechie/dissect.target that referenced this pull request Apr 12, 2026
Add a dedicated osinfo plugin that exposes two exports:
  - osinfo.version: parsed SystemVersion.plist (product_name,
    product_version, build_version, source).
  - osinfo.install_date: the mtime of .AppleSetupDone as a UTC
    datetime, used as a proxy for the initial OS install/setup
    date.

Includes unit tests using the existing target_macos and fs_macos
fixtures, plus hand-crafted test data (SystemVersion.plist and an
empty AppleSetupDone) under tests/_data/.

First plugin split out of PR fox-it#1717 as a proof-of-pattern for the
requested per-plugin test + fixture contribution style.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@MrJayTechie
Copy link
Copy Markdown
Author

Hi @Schamper, thanks for the review! Fully agree the single-PR scope is too large. Here's the proposed split:

To validate the test/fixture/lint pattern before I multiply it 60×, I've prepared a proof-of-pattern branch with just one plugin — osinfo — refactored, fully typed, ruff-clean under your strict config, and with committed test fixtures + unit tests:

https://github.com/MrJayTechie/dissect.target/tree/macos-osinfo

Proposed split into 10 PRs (ordered simplest → most complex):

  1. System metadata — osinfo, localtime, users, softwareupdate, profiles, preferences, sharepoints, etcfiles
  2. Auth & accounts — accounts, icloud, sudoers, sudolastrun, ssh
  3. Network & connectivity — dhcp, hosts, firewall, screensharing, ard
  4. Persistence & autostart — autostart, launchpad, kext, execpolicy
  5. Application metadata — applications, installhistory, printjobs, crashreporter, spotlightshortcuts, savedstate
  6. Shell & terminal — shellhistory, terminalstate, utmpx, logs
  7. File system artifacts — trash, fsevents, dsstore, quicklook, sharedfilelist
  8. Browsers — safari, chromium, firefox, cookies
  9. Communication & iOS — imessage, facetime, callhistory, addressbook, notes, idevicebackup, msrdc
  10. Advanced SQLite forensics — knowledgec, biome, tcc, powerlogs, screentime, notifications, interactions, keychain, wallet, spotlight, docrevisions, officemru, wifiintelligence

Before I start on the rest, could you glance at the osinfo branch and confirm the shape (tests, fixtures, docstring/type conventions, record naming) matches what you want? Once you bless the pattern I'll open PR 1 and the rest sequentially.

Happy to convert this PR to draft or close it entirely once the first split-PR is in review — whichever you prefer.

MrJayTechie pushed a commit to MrJayTechie/dissect.target that referenced this pull request Apr 12, 2026
Add a dedicated osinfo plugin that exposes two exports:
  - osinfo.version: parsed SystemVersion.plist (product_name,
    product_version, build_version, source).
  - osinfo.install_date: the mtime of .AppleSetupDone as a UTC
    datetime, used as a proxy for the initial OS install/setup
    date.

Includes unit tests using the existing target_macos and fs_macos
fixtures, plus hand-crafted test data (SystemVersion.plist and an
empty AppleSetupDone) under tests/_data/.

First plugin split out of PR fox-it#1717 as a proof-of-pattern for the
requested per-plugin test + fixture contribution style.
@Schamper
Copy link
Copy Markdown
Member

Unfortunately the changes in the osinfo branch conflict with existing conventions. There exists already something called osinfo and install_date, and they're not structured like this. Furthermore, briefly looking through some of the changes in this PR, I see a lot of duplication with existing Dissect helper functions.

If you could, please start with making small, targeted changes that you have initially reviewed the generated code of yourself and compare it with existing Dissect functionality and conventions.

Especially when it comes to unit tests, in a framework like Dissect, LLM generated test data is not welcome. It's likely to generate test data that will work with it's own (sometimes hallucinated) implementation.

@MrJayTechie
Copy link
Copy Markdown
Author

Hi @Schamper — understood on all three points. I've opened #1719 as the pilot split: a single macOS plugin (installhistory) implemented to match upstream conventions, using macos/user.py as the structural reference. Verified no name or path collision with existing plugins before starting. Real test data (Apple-system-only entries from an actual InstallHistory.plist), ruff-clean, all tests passing.

Converting this PR to draft while I rebuild the rest of the macOS plugins the same way. Once the pattern is approved I'll open small targeted PRs one at a time.

@MrJayTechie MrJayTechie marked this pull request as draft April 13, 2026 09:07
@DissectBot
Copy link
Copy Markdown

@MrJayTechie thank you for your contribution! As this is your first code contribution, please read the following Contributor License Agreement (CLA). If you agree with the CLA, please reply with the following information:

@DissectBot agree [company="{your company}"]

Options:

  • (default - no company specified) I have sole ownership of intellectual property rights to my Submissions and I am not making Submissions in the course of work for my employer.
  • (when company given) I am making Submissions in the course of work for my employer (or my employer has intellectual property rights in my Submissions by contract or applicable law). I have permission from my employer to make Submissions and enter into this Agreement on behalf of my employer. By signing below, the defined term “You” includes me and my employer.
Contributor License Agreement

Contribution License Agreement

This Contribution License Agreement ("Agreement") governs your Contribution(s) (as defined below) and conveys certain license rights to Fox-IT B.V. ("Fox-IT") for your Contribution(s) to Fox-IT"s open source Dissect project. This Agreement covers any and all Contributions that you ("You" or "Your"), now or in the future, Submit (as defined below) to this project. This Agreement is between Fox-IT B.V. and You and takes effect when you click an “I Accept” button, check box presented with these terms, otherwise accept these terms or, if earlier, when You Submit a Contribution.

  1. Definitions.
    "Contribution" means any original work of authorship, including any modifications or additions to an existing work, that is intentionally submitted by You to Fox-IT for inclusion in, or documentation of, any of the software products owned or managed by, or on behalf of, Fox-IT as part of the Project (the "Work").
    "Project" means any of the projects owned or managed by Fox-IT and offered under a license approved by the Open Source Initiative (www.opensource.org).
    "Submit" means any form of electronic, verbal, or written communication sent to Fox-IT or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, Fox-IT for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by You as "Not a Contribution."

  2. Grant of Copyright License. Subject to the terms and conditions of this Agreement, You hereby grant to Fox-IT and to recipients of software distributed by Fox-IT a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, sublicense, and distribute Your Contributions and such derivative works.

  3. Grant of Patent License. Subject to the terms and conditions of this Agreement, You hereby grant to Fox-IT and to recipients of software distributed by Fox-IT a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, maintain, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by You that are necessarily infringed by Your Contribution(s) alone or by combination of Your Contribution(s) with the Work to which such Contribution(s) was submitted. If any entity institutes patent litigation against You or any other entity (including a cross-claim or counterclaim in a lawsuit) alleging that your Contribution, or the Work to which you have contributed, constitutes direct or contributory patent infringement, then any patent licenses granted to that entity under this Agreement for that Contribution or Work shall terminate as of the date such litigation is filed.

  4. Representations. You represent that:

    • You are legally entitled to grant the above license.
    • each of Your Contributions is Your original creation (see section 8 for submissions on behalf of others).
    • Your Contribution submissions include complete details of any third-party license or other restriction (including, but not limited to, related patents and trademarks) of which you are personally aware and which are associated with any part of Your Contributions.
  5. Employer. If Your Contribution is made in the course of Your work for an employer or Your employer has intellectual property rights in Your Submission by contract or applicable law, You must secure permission from Your employer to make the Contribution before signing this Agreement. In that case, the term "You" in this Agreement will refer to You and the employer collectively. If You change employers in the future and desire to Submit additional Contribution for the new employer, then You agree to sign a new Agreement and secure permission from the new employer before Submitting those Contributions.

  6. Support. You are not expected to provide support for Your Contribution, unless You choose to do so. Any such support provided to the Project is provided free of charge.

  7. Warranty. Unless required by applicable law or agreed to in writing, You provide Your Contributions on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE.

  8. Third party material. Should You wish to submit work that is not Your original creation, You may only submit it to Fox-IT separately from any Contribution, identifying the complete details of its source and of any license or other restriction (including, but not limited to, related patents, trademarks, and license agreements) of which You are personally aware, and conspicuously marking the work as "Submitted on behalf of a third-party: [named here]".

  9. Notify. You agree to notify Fox-IT of any facts or circumstances of which You become aware that would make the above representations inaccurate in any respect.

  10. Governing law / competent court. This Agreement is governed by the laws of the Netherlands. Any disputes that may arise are resolved by arbitration in accordance with the Arbitration Regulations of the Foundation for the Settlement of Automation Disputes (Stichting Geschillenoplossing Automatisering – SGOA – (www.sgoa.eu), this without prejudice to either party"s right to request preliminary relief in preliminary relief proceedings or arbitral preliminary relief proceedings. Arbitration proceedings take place in Amsterdam, or in any other place designated in the Arbitration Regulations. Arbitration shall take place in English.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants