To retrieve all certificates registered in IIS, run this command in PowerShell Administrator mode (source)
import-module WebAdministration
get-childitem iis:SslBindings
To retrieve the bindings (i.e. http and https properties) of IIS sites, run (source)
import-module WebAdministration
get-website | select name,id,state, physicalpath,
@{n="Bindings"; e= { ($_.bindings | select -expa collection) -join ';' }}
I used the last code snippet to find the IIS sites without https / SSL certificate:
import-module WebAdministration
get-website | where {$_.State -eq "Started"} |
select name,
@{n="Bindings"; e= { ($_.bindings | select -expa collection) -join ';' }} |
where {$_.Bindings -notmatch "ssl" }
There is also a nice script finding IIS certificates and whether they are used in an IIS site or not.