The X.509 certificate stores and certificates can be accessed on the Cert drive like below.
Get-ChildItem -Path Cert:\LocalMachine\My | Select-Object Subject, NotAfter | Export-Csv -Path C:\Temp\certs.csv
This will export the certificates in the Personal store to a CSV file.
Best Regards,
Ian Xue
If the Answer is helpful, please click "Accept Answer" and upvote it.