Auditing AD and O365
Synopsis: Notes on quickly generating Audit reports for Active Directory and O365
Published June 24th, 2026
Last Modified: September 23rd, 2026
Intro: I've generated many reports in my lifetime and will do many more. This process should help me do so in bulk, and will be designed to be ran in bulk and export things I might need - regardless of project goals.
Published June 24th, 2026
Last Modified: September 23rd, 2026
Intro: I've generated many reports in my lifetime and will do many more. This process should help me do so in bulk, and will be designed to be ran in bulk and export things I might need - regardless of project goals.
Quick Run Down
-
1.)Register MS Graph
2.)Entra AD Reports
3.)Active Directory Reports
4.)File Server Reports
4.)Print Server Reports
4.)Troubleshooting
MS Graph
-
Register a MS GRAPH Application with the following permissions for use in the next scripts:
- User.Read.All
- Directory.Read.All
- Organization.Read.All
Creating a GRAPH API application for use with PowerShell
Required Application permissions:
Entra AD
-
Run this script while on a domain controller to generate multiple reports:
PLACE HOLDER
Active Directory
-
Run this script while on a domain controller.
Export of Home Directories &
Export of Dist Groups & Mail Enabled Security Groups &
Export of Groups w/ Members &
Export of All Users / Emails & Alias': GitHub Script
Export of Login BAT files: GitHub Script
File Server
-
Run these script from a file server, if possible.
Export of Top Level folders &
Export of Permissions: File Server Audit Script
Print Server
-
Run this script from a print server
Export of Printers, Ips, & ShareNames : Printer Audit Script
Troubleshooting Tips
- None. You're on your own, Buddy.