finding a certificate context in the certificate store meeting a search criterion.
- From: "wuhao" <wuhao@xxxxxxxxxxx>
- Date: Wed, 26 Apr 2006 16:56:12 +0800
i use the codes blow to find a certificate .
but i found it can only find the certificates in the personal tab
(ie-tools-option-content-certificate )
the certificates list in others tab ,it can not find,i wonder why
if ( !( hCertStore = CertOpenStore(
CERT_STORE_PROV_SYSTEM,
0,
NULL,
CERT_SYSTEM_STORE_CURRENT_USER,
L"my")))
{
MyHandleError("The MY store could not be opened.");
}
//--------------------------------------------------------------------
// Get the certificate for the signer.
if(!(pSignerCertContext = CertFindCertificateInStore(
hCertStore,
MY_TYPE,
0,
CERT_FIND_SUBJECT_STR,
SIGNER_NAME,
NULL)))
{
MyHandleError("Cert not found.\n");
}
thanks
.
- Follow-Ups:
- Prev by Date: RE: How to enable certificate purpose programmatically?
- Next by Date: Own GINA dll with special requirements
- Previous by thread: Importing a Symmetric Key into the Microsoft Base Smart Card Crypto Provider
- Next by thread: Re: finding a certificate context in the certificate store meeting a search criterion.
- Index(es):
Relevant Pages
|