List installed personal certificates in batch
I use a few secure websites that require me to install a PFX certificate to access them. I have multiple computers I do this from, and I need a quick way of determining which ones in which I still need to install the certificate.
Is there a way I can list all the certificates in the Personal store using batch commands? I can run the command remotely, but I'm not aware of any method to list them.
"How can I get a list of installed certificates on Windows?" is a similar question but I'm looking for a solution specific to command line. The answers there all involve using the GUI or Powershell.
windows-7 batch ssl certificate
|
show 4 more comments
I use a few secure websites that require me to install a PFX certificate to access them. I have multiple computers I do this from, and I need a quick way of determining which ones in which I still need to install the certificate.
Is there a way I can list all the certificates in the Personal store using batch commands? I can run the command remotely, but I'm not aware of any method to list them.
"How can I get a list of installed certificates on Windows?" is a similar question but I'm looking for a solution specific to command line. The answers there all involve using the GUI or Powershell.
windows-7 batch ssl certificate
What OS are you using?
– EBGreen
Dec 19 '13 at 18:43
I'm using Windows 7
– Moses
Dec 19 '13 at 18:57
3
@Moses What's your particular aversion to PowerShell? It's not like you're looking to do this on XP or Server 2003, where PowerShell isn't built-in on a standard install. Also, PowerShell allows you to run some commands remotely (if the systems are properly configured for it) which would allow you to easily gather all data on all your systems from across the network in one script.
– Iszi
Dec 19 '13 at 20:40
1
@Iszi In fact, for a large number of systems, using PowerShell to do the entire task (determine whether the cert needs to be installed, and then install it if not) is entirely plausible -- assuming they're all on the same LAN, you could sit at your own workstation and do this for ALL the PCs under your purview using the remote feature of PS. I would rather think he'd be trying to implement his solution in PS, rather than avoiding it!
– allquixotic
Dec 19 '13 at 20:55
1
@allquixotic I will confess though, that more than once I asked a question like this myself. It was perhaps almost as much out of fear of adapting to PowerShell (vs. writing the batch scripts I understood) as it was a need to support XP/2003. I've learned a bit since then, though. Now I can't stand being limited to batch.
– Iszi
Dec 19 '13 at 20:58
|
show 4 more comments
I use a few secure websites that require me to install a PFX certificate to access them. I have multiple computers I do this from, and I need a quick way of determining which ones in which I still need to install the certificate.
Is there a way I can list all the certificates in the Personal store using batch commands? I can run the command remotely, but I'm not aware of any method to list them.
"How can I get a list of installed certificates on Windows?" is a similar question but I'm looking for a solution specific to command line. The answers there all involve using the GUI or Powershell.
windows-7 batch ssl certificate
I use a few secure websites that require me to install a PFX certificate to access them. I have multiple computers I do this from, and I need a quick way of determining which ones in which I still need to install the certificate.
Is there a way I can list all the certificates in the Personal store using batch commands? I can run the command remotely, but I'm not aware of any method to list them.
"How can I get a list of installed certificates on Windows?" is a similar question but I'm looking for a solution specific to command line. The answers there all involve using the GUI or Powershell.
windows-7 batch ssl certificate
windows-7 batch ssl certificate
edited Jan 17 at 15:44
Moses
asked Dec 19 '13 at 18:38
MosesMoses
9,1262159107
9,1262159107
What OS are you using?
– EBGreen
Dec 19 '13 at 18:43
I'm using Windows 7
– Moses
Dec 19 '13 at 18:57
3
@Moses What's your particular aversion to PowerShell? It's not like you're looking to do this on XP or Server 2003, where PowerShell isn't built-in on a standard install. Also, PowerShell allows you to run some commands remotely (if the systems are properly configured for it) which would allow you to easily gather all data on all your systems from across the network in one script.
– Iszi
Dec 19 '13 at 20:40
1
@Iszi In fact, for a large number of systems, using PowerShell to do the entire task (determine whether the cert needs to be installed, and then install it if not) is entirely plausible -- assuming they're all on the same LAN, you could sit at your own workstation and do this for ALL the PCs under your purview using the remote feature of PS. I would rather think he'd be trying to implement his solution in PS, rather than avoiding it!
– allquixotic
Dec 19 '13 at 20:55
1
@allquixotic I will confess though, that more than once I asked a question like this myself. It was perhaps almost as much out of fear of adapting to PowerShell (vs. writing the batch scripts I understood) as it was a need to support XP/2003. I've learned a bit since then, though. Now I can't stand being limited to batch.
– Iszi
Dec 19 '13 at 20:58
|
show 4 more comments
What OS are you using?
– EBGreen
Dec 19 '13 at 18:43
I'm using Windows 7
– Moses
Dec 19 '13 at 18:57
3
@Moses What's your particular aversion to PowerShell? It's not like you're looking to do this on XP or Server 2003, where PowerShell isn't built-in on a standard install. Also, PowerShell allows you to run some commands remotely (if the systems are properly configured for it) which would allow you to easily gather all data on all your systems from across the network in one script.
– Iszi
Dec 19 '13 at 20:40
1
@Iszi In fact, for a large number of systems, using PowerShell to do the entire task (determine whether the cert needs to be installed, and then install it if not) is entirely plausible -- assuming they're all on the same LAN, you could sit at your own workstation and do this for ALL the PCs under your purview using the remote feature of PS. I would rather think he'd be trying to implement his solution in PS, rather than avoiding it!
– allquixotic
Dec 19 '13 at 20:55
1
@allquixotic I will confess though, that more than once I asked a question like this myself. It was perhaps almost as much out of fear of adapting to PowerShell (vs. writing the batch scripts I understood) as it was a need to support XP/2003. I've learned a bit since then, though. Now I can't stand being limited to batch.
– Iszi
Dec 19 '13 at 20:58
What OS are you using?
– EBGreen
Dec 19 '13 at 18:43
What OS are you using?
– EBGreen
Dec 19 '13 at 18:43
I'm using Windows 7
– Moses
Dec 19 '13 at 18:57
I'm using Windows 7
– Moses
Dec 19 '13 at 18:57
3
3
@Moses What's your particular aversion to PowerShell? It's not like you're looking to do this on XP or Server 2003, where PowerShell isn't built-in on a standard install. Also, PowerShell allows you to run some commands remotely (if the systems are properly configured for it) which would allow you to easily gather all data on all your systems from across the network in one script.
– Iszi
Dec 19 '13 at 20:40
@Moses What's your particular aversion to PowerShell? It's not like you're looking to do this on XP or Server 2003, where PowerShell isn't built-in on a standard install. Also, PowerShell allows you to run some commands remotely (if the systems are properly configured for it) which would allow you to easily gather all data on all your systems from across the network in one script.
– Iszi
Dec 19 '13 at 20:40
1
1
@Iszi In fact, for a large number of systems, using PowerShell to do the entire task (determine whether the cert needs to be installed, and then install it if not) is entirely plausible -- assuming they're all on the same LAN, you could sit at your own workstation and do this for ALL the PCs under your purview using the remote feature of PS. I would rather think he'd be trying to implement his solution in PS, rather than avoiding it!
– allquixotic
Dec 19 '13 at 20:55
@Iszi In fact, for a large number of systems, using PowerShell to do the entire task (determine whether the cert needs to be installed, and then install it if not) is entirely plausible -- assuming they're all on the same LAN, you could sit at your own workstation and do this for ALL the PCs under your purview using the remote feature of PS. I would rather think he'd be trying to implement his solution in PS, rather than avoiding it!
– allquixotic
Dec 19 '13 at 20:55
1
1
@allquixotic I will confess though, that more than once I asked a question like this myself. It was perhaps almost as much out of fear of adapting to PowerShell (vs. writing the batch scripts I understood) as it was a need to support XP/2003. I've learned a bit since then, though. Now I can't stand being limited to batch.
– Iszi
Dec 19 '13 at 20:58
@allquixotic I will confess though, that more than once I asked a question like this myself. It was perhaps almost as much out of fear of adapting to PowerShell (vs. writing the batch scripts I understood) as it was a need to support XP/2003. I've learned a bit since then, though. Now I can't stand being limited to batch.
– Iszi
Dec 19 '13 at 20:58
|
show 4 more comments
2 Answers
2
active
oldest
votes
Here's how to do it from a cmd.exe
shell on Windows 7, without first starting PowerShell:
C:> powershell -Command Get-ChildItem -Recurse Cert:
You can then pipe the output to other commands (which commands? well, your question isn't about that, so I won't go into detail) or to a file. From there you can isolate whether the specific cert you're looking for is installed.
Since you said you're on Windows 7, I assume that PowerShell is installed. To not have PowerShell, it would explicitly have to be uninstalled, and you didn't mention in your question that PowerShell was uninstalled or not available, or that the solution has to work on pre-Vista Windows where PowerShell didn't exist.
I know how to pipe the output, so that shouldn't be an issue. My main reason for avoiding Powershell is that I use a couple different management applications that work really well with batch. This will work fine, though. Thanks
– Moses
Dec 20 '13 at 17:28
Looks like thePersonal -> Certificates
of interest to you show up under theName : My
section from the powershell output.
– jxramos
Feb 9 '17 at 20:35
add a comment |
No Powershell necessary.
Also the proposed solution dumps raw data not just the Personal store requested by the OP.
N.B. The following was run in an Administrator command prompt shell
C:windowssystem32>systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
OS Name: Microsoft Windows 7 Enterprise
OS Version: 6.1.7601 Service Pack 1 Build 7601
C:windowssystem32>certutil -store My
My <<< Certificate Store Name
================ Certificate 0 ================
Serial Number: **************************** *<<< asterisks = mask for post. You will see cert info*
Issuer: ****************************
NotBefore: ****************************
NotAfter: ****************************
Subject: CN=****************************
Non-root Certificate
Template: ****************************
Cert Hash(sha1): ****************************
Simple container name: ****************************
Provider = Microsoft RSA SChannel Cryptographic Provider
Private key is NOT exportable
Encryption test passed
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f690763%2flist-installed-personal-certificates-in-batch%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
Here's how to do it from a cmd.exe
shell on Windows 7, without first starting PowerShell:
C:> powershell -Command Get-ChildItem -Recurse Cert:
You can then pipe the output to other commands (which commands? well, your question isn't about that, so I won't go into detail) or to a file. From there you can isolate whether the specific cert you're looking for is installed.
Since you said you're on Windows 7, I assume that PowerShell is installed. To not have PowerShell, it would explicitly have to be uninstalled, and you didn't mention in your question that PowerShell was uninstalled or not available, or that the solution has to work on pre-Vista Windows where PowerShell didn't exist.
I know how to pipe the output, so that shouldn't be an issue. My main reason for avoiding Powershell is that I use a couple different management applications that work really well with batch. This will work fine, though. Thanks
– Moses
Dec 20 '13 at 17:28
Looks like thePersonal -> Certificates
of interest to you show up under theName : My
section from the powershell output.
– jxramos
Feb 9 '17 at 20:35
add a comment |
Here's how to do it from a cmd.exe
shell on Windows 7, without first starting PowerShell:
C:> powershell -Command Get-ChildItem -Recurse Cert:
You can then pipe the output to other commands (which commands? well, your question isn't about that, so I won't go into detail) or to a file. From there you can isolate whether the specific cert you're looking for is installed.
Since you said you're on Windows 7, I assume that PowerShell is installed. To not have PowerShell, it would explicitly have to be uninstalled, and you didn't mention in your question that PowerShell was uninstalled or not available, or that the solution has to work on pre-Vista Windows where PowerShell didn't exist.
I know how to pipe the output, so that shouldn't be an issue. My main reason for avoiding Powershell is that I use a couple different management applications that work really well with batch. This will work fine, though. Thanks
– Moses
Dec 20 '13 at 17:28
Looks like thePersonal -> Certificates
of interest to you show up under theName : My
section from the powershell output.
– jxramos
Feb 9 '17 at 20:35
add a comment |
Here's how to do it from a cmd.exe
shell on Windows 7, without first starting PowerShell:
C:> powershell -Command Get-ChildItem -Recurse Cert:
You can then pipe the output to other commands (which commands? well, your question isn't about that, so I won't go into detail) or to a file. From there you can isolate whether the specific cert you're looking for is installed.
Since you said you're on Windows 7, I assume that PowerShell is installed. To not have PowerShell, it would explicitly have to be uninstalled, and you didn't mention in your question that PowerShell was uninstalled or not available, or that the solution has to work on pre-Vista Windows where PowerShell didn't exist.
Here's how to do it from a cmd.exe
shell on Windows 7, without first starting PowerShell:
C:> powershell -Command Get-ChildItem -Recurse Cert:
You can then pipe the output to other commands (which commands? well, your question isn't about that, so I won't go into detail) or to a file. From there you can isolate whether the specific cert you're looking for is installed.
Since you said you're on Windows 7, I assume that PowerShell is installed. To not have PowerShell, it would explicitly have to be uninstalled, and you didn't mention in your question that PowerShell was uninstalled or not available, or that the solution has to work on pre-Vista Windows where PowerShell didn't exist.
answered Dec 19 '13 at 20:27
allquixoticallquixotic
30.8k695127
30.8k695127
I know how to pipe the output, so that shouldn't be an issue. My main reason for avoiding Powershell is that I use a couple different management applications that work really well with batch. This will work fine, though. Thanks
– Moses
Dec 20 '13 at 17:28
Looks like thePersonal -> Certificates
of interest to you show up under theName : My
section from the powershell output.
– jxramos
Feb 9 '17 at 20:35
add a comment |
I know how to pipe the output, so that shouldn't be an issue. My main reason for avoiding Powershell is that I use a couple different management applications that work really well with batch. This will work fine, though. Thanks
– Moses
Dec 20 '13 at 17:28
Looks like thePersonal -> Certificates
of interest to you show up under theName : My
section from the powershell output.
– jxramos
Feb 9 '17 at 20:35
I know how to pipe the output, so that shouldn't be an issue. My main reason for avoiding Powershell is that I use a couple different management applications that work really well with batch. This will work fine, though. Thanks
– Moses
Dec 20 '13 at 17:28
I know how to pipe the output, so that shouldn't be an issue. My main reason for avoiding Powershell is that I use a couple different management applications that work really well with batch. This will work fine, though. Thanks
– Moses
Dec 20 '13 at 17:28
Looks like the
Personal -> Certificates
of interest to you show up under the Name : My
section from the powershell output.– jxramos
Feb 9 '17 at 20:35
Looks like the
Personal -> Certificates
of interest to you show up under the Name : My
section from the powershell output.– jxramos
Feb 9 '17 at 20:35
add a comment |
No Powershell necessary.
Also the proposed solution dumps raw data not just the Personal store requested by the OP.
N.B. The following was run in an Administrator command prompt shell
C:windowssystem32>systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
OS Name: Microsoft Windows 7 Enterprise
OS Version: 6.1.7601 Service Pack 1 Build 7601
C:windowssystem32>certutil -store My
My <<< Certificate Store Name
================ Certificate 0 ================
Serial Number: **************************** *<<< asterisks = mask for post. You will see cert info*
Issuer: ****************************
NotBefore: ****************************
NotAfter: ****************************
Subject: CN=****************************
Non-root Certificate
Template: ****************************
Cert Hash(sha1): ****************************
Simple container name: ****************************
Provider = Microsoft RSA SChannel Cryptographic Provider
Private key is NOT exportable
Encryption test passed
add a comment |
No Powershell necessary.
Also the proposed solution dumps raw data not just the Personal store requested by the OP.
N.B. The following was run in an Administrator command prompt shell
C:windowssystem32>systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
OS Name: Microsoft Windows 7 Enterprise
OS Version: 6.1.7601 Service Pack 1 Build 7601
C:windowssystem32>certutil -store My
My <<< Certificate Store Name
================ Certificate 0 ================
Serial Number: **************************** *<<< asterisks = mask for post. You will see cert info*
Issuer: ****************************
NotBefore: ****************************
NotAfter: ****************************
Subject: CN=****************************
Non-root Certificate
Template: ****************************
Cert Hash(sha1): ****************************
Simple container name: ****************************
Provider = Microsoft RSA SChannel Cryptographic Provider
Private key is NOT exportable
Encryption test passed
add a comment |
No Powershell necessary.
Also the proposed solution dumps raw data not just the Personal store requested by the OP.
N.B. The following was run in an Administrator command prompt shell
C:windowssystem32>systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
OS Name: Microsoft Windows 7 Enterprise
OS Version: 6.1.7601 Service Pack 1 Build 7601
C:windowssystem32>certutil -store My
My <<< Certificate Store Name
================ Certificate 0 ================
Serial Number: **************************** *<<< asterisks = mask for post. You will see cert info*
Issuer: ****************************
NotBefore: ****************************
NotAfter: ****************************
Subject: CN=****************************
Non-root Certificate
Template: ****************************
Cert Hash(sha1): ****************************
Simple container name: ****************************
Provider = Microsoft RSA SChannel Cryptographic Provider
Private key is NOT exportable
Encryption test passed
No Powershell necessary.
Also the proposed solution dumps raw data not just the Personal store requested by the OP.
N.B. The following was run in an Administrator command prompt shell
C:windowssystem32>systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
OS Name: Microsoft Windows 7 Enterprise
OS Version: 6.1.7601 Service Pack 1 Build 7601
C:windowssystem32>certutil -store My
My <<< Certificate Store Name
================ Certificate 0 ================
Serial Number: **************************** *<<< asterisks = mask for post. You will see cert info*
Issuer: ****************************
NotBefore: ****************************
NotAfter: ****************************
Subject: CN=****************************
Non-root Certificate
Template: ****************************
Cert Hash(sha1): ****************************
Simple container name: ****************************
Provider = Microsoft RSA SChannel Cryptographic Provider
Private key is NOT exportable
Encryption test passed
answered Aug 9 '17 at 12:44
NetScr1beNetScr1be
961
961
add a comment |
add a comment |
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f690763%2flist-installed-personal-certificates-in-batch%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
What OS are you using?
– EBGreen
Dec 19 '13 at 18:43
I'm using Windows 7
– Moses
Dec 19 '13 at 18:57
3
@Moses What's your particular aversion to PowerShell? It's not like you're looking to do this on XP or Server 2003, where PowerShell isn't built-in on a standard install. Also, PowerShell allows you to run some commands remotely (if the systems are properly configured for it) which would allow you to easily gather all data on all your systems from across the network in one script.
– Iszi
Dec 19 '13 at 20:40
1
@Iszi In fact, for a large number of systems, using PowerShell to do the entire task (determine whether the cert needs to be installed, and then install it if not) is entirely plausible -- assuming they're all on the same LAN, you could sit at your own workstation and do this for ALL the PCs under your purview using the remote feature of PS. I would rather think he'd be trying to implement his solution in PS, rather than avoiding it!
– allquixotic
Dec 19 '13 at 20:55
1
@allquixotic I will confess though, that more than once I asked a question like this myself. It was perhaps almost as much out of fear of adapting to PowerShell (vs. writing the batch scripts I understood) as it was a need to support XP/2003. I've learned a bit since then, though. Now I can't stand being limited to batch.
– Iszi
Dec 19 '13 at 20:58