Quantcast
Channel: Public Key Infrastructure PowerShell module
Viewing all articles
Browse latest Browse all 729

New Post: Certificate recieving ends after 30 minutes with "The handle is invalid"

$
0
0
I'm already using 2 queries. I think there are some misunderstanding. My plan is:
  1. Valid issued certificates -> Issued folder
  2. Lapsed issued certificates -> Lapsed folder with removing from Issued folder
  3. Valid revoked certificates -> Revoked folder with removing from Issued folder
  4. Valid suspended certificates -> Suspended folder
  5. Lapsed revoked certificates -> Lapsed folder with removing from Revoked & Suspended folders
  6. Renewed certificates -> Issued folder with removing from Revoked & Suspended folders
I'm talking about point 6.
I'm doing it using this code:
Get-ChildItem $pathCertSuspendedValidExport -Name|ForEach-Object -Process {$SN=$_ -replace ".cer"; Connect-CertificationAuthority -ComputerName $CN|Get-IssuedRequest -Filter "Disposition -eq 20","NotAfter -ge $DT","SerialNumber -eq $SN" -Property "RawCertificate"| %{[IO.File]::WriteAllText("$pathCertIssuedExport\$($_.SerialNumber).cer", $_.RawCertificate)}}
but it causes many calls (number equals to files in Suspended folder quantity. I've asked about how to avoid using many calls in this situation.

Viewing all articles
Browse latest Browse all 729

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>