Skip to content

Instantly share code, notes, and snippets.

View seanjoo's full-sized avatar

Sean Joo seanjoo

  • LatticeWorks, Inc
View GitHub Profile
AWSTemplateFormatVersion: '2010-09-09'
Description: AU-5 evidence — EC2 audit alerts for disk capacity and auditd failures
Parameters:
AlertEmail:
Type: String
Description: Email address to receive audit alerts (SNS subscription)
InstanceId:
Type: String
Description: EC2 InstanceId that emits CWAgent metrics (disk_used_percent)
# Set private IP (You can also get it dynamically if you want)
$privateIp = (Get-NetIPAddress -AddressFamily IPv4 | Where-Object {$_.InterfaceAlias -notlike "vEthernet*"}).IPAddress
Write-Host "Checking IIS Site Bindings..." -ForegroundColor Cyan
try {
Import-Module WebAdministration
Get-WebBinding | Select-Object protocol, bindingInformation
} catch {
Write-Host "IIS not installed or unable to load WebAdministration module." -ForegroundColor Yellow
}