Open for Voting

SSL Certificate Expiration Date Monitor

Expand this monitor to also include the SSL certificate CN/"Issued To" field in the message of the monitor.

  • I wanted the same so use this -

    HTH

    #Number of days to look for expiring certificates

    $threshold = 90

    #Set deadline date

    $Subject=""

    $Expiry=0

    $deadline = (Get-Date).AddDays($threshold)

    $store=new-object System.Security.Cryptography.X509Certificates.X509Store("\\${IP}\my","LocalMachine")

    $store.open("ReadOnly")

    $store.certificates | % {

        If ($_.NotAfter -lt $deadline) {

            #$_ | Select Subject, NotAfter, @{Label="ExpiresIn"; Expression={($_.NotAfter - (Get-Date)).Days}}

            $Subject = ($_.Subject).Split(",")

            $Subject = ($Subject[0]).Split("=")

            $Expiry = ($_.NotAfter - (Get-Date)).Days

            }

    }

    If ($Expiry -eq 0){$Expiry=1000}

    Write-Host "Statistic:"$Expiry

    Write-Host "Message:"$Subject[1]

  • We did have a Thwack community member post a PowerShell script that does something Similar but SAM 5.0 included the SSL Certificate Expiration Component Monitor which is not dependent on PowerShell. You can download the template posted to Thwack which utilized this component monitor type and assign it to your nodes immediately. No additional configuration should be necessary. 

  • Should have read closer...  But the monitor you speak of still requires powershell (if I have the right one).

  • familyofcrowes, SAM already includes an SSL Certificate Expiration Monitor that doesn't rely on scripts. setorres feature request is to add additional information to this component monitor type, such as the Certificate Name and Issued To field information of the certificate being used by the web server.

  • funny...  Our CIO emailed us because SHE is the one that found out our webmail cert was expired....   talk about embarassing.....

    This is one I would like to see.  There is a powershell script someone created, but we need something that doesn't require powershell and is a bit more simple to use.... (we are not allowed to load powerscript on our 2003 boxes and we have over 200 2003 boxes still)

    We talk about Orion being 'easy' and not requiring alot of support, but with all the PERL scripts and powershell templates, seems like we need to be programmers....