Skip to content

Instantly share code, notes, and snippets.

@SMSAgentSoftware
SMSAgentSoftware / Check-SecureBootCerts.ps1
Last active December 24, 2025 02:25
PowerShell script to check whether the SecureBoot databases contain updated certificates
#Requires -RunAsAdministrator
# Function to read Secure Boot databases (db, KEK, PK, dbx) and parse entries
# Thanks to Chat-GPT 5
function Read-SecureBootDatabase {
[CmdletBinding()]
param(
[ValidateSet('db','KEK','PK','dbx')]
[string]$DatabaseName = 'db',