Skip to content
Public template

About

GitHub template that runs Maester Microsoft 365 security tests daily, signing in with workload identity federation (no stored secrets).

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

4 Commits

Folders and files

Repository files navigation

Maester-O365

A GitHub template that runs Maester security tests against a Microsoft 365 tenant every day. Copy it into a private repository, run one setup script, and you get a daily report of your Entra ID, Conditional Access and Microsoft 365 security configuration, with no client secret stored anywhere.

What you get

  • A scheduled workflow (.github/workflows/maester.yml) that runs Maester daily at 06:30 UTC and on demand, through the official maester365/maester-action, pinned to a commit.
  • Secretless sign-in. GitHub Actions authenticates to Entra ID with workload identity federation (OIDC). Only the tenant ID and the app's client ID are stored, as repository secrets.
  • Results in the run summary, plus the full HTML report as a downloadable artifact on every run.
  • Optional extras: email or Teams notifications, failing the run when tests fail, and your own tests in custom/.
  • A safety check: the workflow won't run in a public repository, so your tenant's security findings are never published.
  • A setup script (scripts/Initialize-MaesterMonitoring.ps1) that checks prerequisites, then uses Maester's own New-MtMaesterApp to create the Entra app, grant admin consent to its read-only Graph permissions, add the federated credential and set the GitHub secrets.

Requirements

  • A GitHub account and the GitHub CLI (gh auth login)
  • PowerShell 7.2 or later, with the Maester (2.3 or later) and Az.Accounts modules
  • An Entra admin who can create app registrations and grant admin consent (Privileged Role Administrator plus Cloud Application Administrator, or Global Administrator)
Install-Module Maester, Az.Accounts -Scope CurrentUser

Quick start

# 1. Create your own private copy of this template and clone it
gh repo create maester-monitoring --private --template adrian207/Maester-O365 --clone
cd maester-monitoring

# 2. Create the Entra app, federated credential and GitHub secrets, then start the first run
./scripts/Initialize-MaesterMonitoring.ps1

# 3. Watch the run
gh run watch

Add -SendMail to the setup script to also grant Mail.Send for emailed results. To do the setup by hand instead, follow docs/SETUP.md.

Configuration

Optional settings, under Settings → Secrets and variables → Actions in your copy:

Name Type Effect
MAESTER_MAIL_RECIPIENTS Variable Email results to these addresses (needs -SendMail)
MAESTER_MAIL_SENDER_ID Variable Object ID of the user the email is sent as
MAESTER_TEAMS_WEBHOOK Secret Post a results card to a Teams channel
MAESTER_FAIL_ON_FAILED_TESTS Variable true marks the run failed when any test fails

Change the schedule in .github/workflows/maester.yml. Exchange Online and Teams tests are off by default because they need extra permissions; see docs/SETUP.md.

Repository layout

.github/workflows/maester.yml           The scheduled Maester run
.github/workflows/lint.yml              actionlint and PSScriptAnalyzer
scripts/Initialize-MaesterMonitoring.ps1  One-time setup
custom/                                 Your own *.Tests.ps1 files (optional)
docs/SETUP.md                           Manual setup steps
docs/design/                            Design notes for a larger self-hosted platform (not implemented)

Status

The workflow and setup script are new in 0.10.0 and are built on Maester's documented GitHub Actions setup. Earlier versions of this repository contained design documents only; those are kept in docs/design and are clearly marked as unimplemented. See CHANGELOG.md.

License

MIT. See LICENSE. Maester itself is a separate project: maester365/maester.

Author

Adrian Johnson · github.com/adrian207

About

GitHub template that runs Maester Microsoft 365 security tests daily, signing in with workload identity federation (no stored secrets).

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages