question

DucheminDominique-7551 avatar image
0 Votes"
DucheminDominique-7551 asked AllenLiu-MSFT commented

How to get the expiration date after a certificate deployment?

Hello,

I am looking for a process in Configuration Manager to get the expiration date on a certificate.
I just deployed a certificate and it is placed in an application folder as CA.cer.

Powershell?

Thanks,
Dom

windows-server-powershellmem-cm-general
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

May we know the current status of the problem?

0 Votes 0 ·
LuisRodriguez-MSFT avatar image
1 Vote"
LuisRodriguez-MSFT answered

Hi @DucheminDominique-7551

Welcome to Microsoft Q&A Platform.

Can you try using the cmdlet "Get-ChildItem"?, for example:

 Get-ChildItem -path cert:\LocalMachine\My | Select-Object NotAfter, Subject

For reference: https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.security/about/about_certificate_provider?view=powershell-7.2


I hope this helps!


Please don’t forget to "Accept the answer" and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

AllenLiu-MSFT avatar image
1 Vote"
AllenLiu-MSFT answered

Hi, @DucheminDominique-7551

Thank you for posting in Microsoft Q&A forum.

ConfigMgr doesn't collect any information about certificate by default.
You may start for adding this follow this article:
http://www.sccm-tools.com/tools/vbscript/vbscript-certificates.html
(Please Note: Since the website is not hosted by Microsoft, just for your reference.)



If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

LimitlessTechnology-2700 avatar image
1 Vote"
LimitlessTechnology-2700 answered

Hello @DucheminDominique-7551

Not sure I understand your question. System Center is not the right tool to monitor certificate expiration dates, but they need to be controlled from the CA role in Windows or using powershell.

I can recommend the next official guide to obtain different information from the certificates installed in your environment and even export to a CSV to keep it documented.

https://devblogs.microsoft.com/scripting/get-certificate-info-into-a-csv-by-using-powershell/

If you query is different than this, please add more details and specifics of what has been done, and what you are are trying to achieve.

Hope this helps with your query,


--If the reply is helpful, please Upvote and Accept as answer--

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.