Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
e94ce8a0
Commit
e94ce8a0
authored
Nov 01, 2007
by
Juan Lang
Committed by
Alexandre Julliard
Nov 02, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32: Fix leaked chains creating the root store.
parent
fc14728e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
13 deletions
+15
-13
rootstore.c
dlls/crypt32/rootstore.c
+15
-13
No files found.
dlls/crypt32/rootstore.c
View file @
e94ce8a0
...
...
@@ -232,21 +232,22 @@ static const char *get_cert_common_name(PCCERT_CONTEXT cert)
static
void
check_and_store_certs
(
HCERTSTORE
from
,
HCERTSTORE
to
)
{
PCCERT_CONTEXT
cert
=
NULL
;
DWORD
root_count
=
0
;
CERT_CHAIN_ENGINE_CONFIG
chainEngineConfig
=
{
sizeof
(
chainEngineConfig
),
0
};
HCERTCHAINENGINE
engine
;
TRACE
(
"
\n
"
);
do
{
cert
=
CertEnumCertificatesInStore
(
from
,
cert
);
if
(
cert
)
{
CERT_CHAIN_ENGINE_CONFIG
chainEngineConfig
=
{
sizeof
(
chainEngineConfig
),
0
};
HCERTCHAINENGINE
engine
=
CRYPT_CreateChainEngine
(
to
,
&
chainEngineConfig
);
CertDuplicateStore
(
to
);
engine
=
CRYPT_CreateChainEngine
(
to
,
&
chainEngineConfig
);
if
(
engine
)
{
PCCERT_CONTEXT
cert
=
NULL
;
if
(
engine
)
do
{
cert
=
CertEnumCertificatesInStore
(
from
,
cert
);
if
(
cert
)
{
CERT_CHAIN_PARA
chainPara
=
{
sizeof
(
chainPara
),
{
0
}
};
PCCERT_CHAIN_CONTEXT
chain
;
...
...
@@ -275,11 +276,12 @@ static void check_and_store_certs(HCERTSTORE from, HCERTSTORE to)
CERT_STORE_ADD_NEW
,
NULL
))
root_count
++
;
}
CertFreeCertificateChain
(
chain
);
}
CertFreeCertificateChainEngine
(
engine
);
}
}
}
while
(
cert
);
}
while
(
cert
);
CertFreeCertificateChainEngine
(
engine
);
}
TRACE
(
"Added %d root certificates
\n
"
,
root_count
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment