55 for (
i = 0;
i < 20;
i++)
92 TRACE(
"Adding cert with hash %s\n",
95 contextType, &addedType);
113 contextInterface =
NULL;
115 if (contextInterface)
121 WCHAR asciiHash[20 * 2 + 1];
124 TRACE(
"comparing %s\n",
127 if (!
wcscmp(asciiHash, subKeyName))
129 TRACE(
"hash matches, adding\n");
135 TRACE(
"hash doesn't match, ignoring\n");
153 static const WCHAR *
const subKeys[] = {
L"Certificates",
L"CRLs",
L"CTLs" };
177 WCHAR asciiHash[20 * 2 + 1];
242 static const WCHAR *
const subKeys[] = {
L"Certificates",
L"CRLs",
L"CTLs" };
261 WCHAR asciiHash[20 * 2 + 1];
400 TRACE(
"(%p, %p, %08lx)\n", store, pCertContext,
dwFlags);
421 TRACE(
"(%p, %p, %08lx)\n", store, pCrlContext,
dwFlags);
442 TRACE(
"(%p, %p, %08lx)\n", store, pCtlContext,
dwFlags);
449 DWORD dwCtrlType,
void const *pvCtrlPara)
454 TRACE(
"(%p, %08lx, %ld, %p)\n", hCertStore,
dwFlags, dwCtrlType,
475 FIXME(
"CERT_STORE_CTRL_AUTO_RESYNC: stub\n");
478 FIXME(
"CERT_STORE_CTRL_NOTIFY_CHANGE: stub\n");
481 FIXME(
"%lu: stub\n", dwCtrlType);
509 TRACE(
"(%Id, %08lx, %p)\n", hCryptProv,
dwFlags, pvPara);
555 provInfo.
cbSize =
sizeof(provInfo);
568 TRACE(
"returning %p\n", store);
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
static void list_remove(struct list_entry *entry)
static void list_add_tail(struct list_entry *head, struct list_entry *entry)
static void list_init(struct list_entry *head)
#define RegCloseKey(hKey)
LSTATUS WINAPI RegDeleteTreeW(_In_ HKEY, _In_opt_ LPCWSTR)
WINECRYPT_CERTSTORE * CRYPT_ProvCreateStore(DWORD dwFlags, WINECRYPT_CERTSTORE *memStore, const CERT_STORE_PROV_INFO *pProvInfo)
const void * CRYPT_ReadSerializedElement(const BYTE *pbElement, DWORD cbElement, DWORD dwContextTypeFlags, DWORD *pdwContentType)
BOOL WINAPI I_CertUpdateStore(HCERTSTORE store1, HCERTSTORE store2, DWORD unk0, DWORD unk1)
const WINE_CONTEXT_INTERFACE * pCTLInterface
const WINE_CONTEXT_INTERFACE * pCertInterface
static context_t * context_from_ptr(const void *ptr)
const WINE_CONTEXT_INTERFACE * pCRLInterface
LONG WINAPI RegCreateKeyExW(_In_ HKEY hKey, _In_ LPCWSTR lpSubKey, _In_ DWORD Reserved, _In_opt_ LPWSTR lpClass, _In_ DWORD dwOptions, _In_ REGSAM samDesired, _In_opt_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, _Out_ PHKEY phkResult, _Out_opt_ LPDWORD lpdwDisposition)
LONG WINAPI RegOpenKeyExW(HKEY hKey, LPCWSTR lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
LONG WINAPI RegEnumKeyExW(_In_ HKEY hKey, _In_ DWORD dwIndex, _Out_ LPWSTR lpName, _Inout_ LPDWORD lpcbName, _Reserved_ LPDWORD lpReserved, _Out_opt_ LPWSTR lpClass, _Inout_opt_ LPDWORD lpcbClass, _Out_opt_ PFILETIME lpftLastWriteTime)
LONG WINAPI RegSetValueExW(_In_ HKEY hKey, _In_ LPCWSTR lpValueName, _In_ DWORD Reserved, _In_ DWORD dwType, _In_ CONST BYTE *lpData, _In_ DWORD cbData)
LONG WINAPI RegDeleteKeyW(_In_ HKEY hKey, _In_ LPCWSTR lpSubKey)
LONG WINAPI RegQueryValueExW(_In_ HKEY hkeyorg, _In_ LPCWSTR name, _In_ LPDWORD reserved, _In_ LPDWORD type, _In_ LPBYTE data, _In_ LPDWORD count)
BOOL WINAPI CryptReleaseContext(HCRYPTPROV hProv, DWORD dwFlags)
void Context_Release(context_t *context)
LPVOID WINAPI CryptMemAlloc(ULONG cbSize)
VOID WINAPI CryptMemFree(LPVOID pv)
HCERTSTORE WINAPI CertOpenStore(LPCSTR lpszStoreProvider, DWORD dwMsgAndCertEncodingType, HCRYPTPROV_LEGACY hCryptProv, DWORD dwFlags, const void *pvPara)
BOOL WINAPI CertCloseStore(HCERTSTORE hCertStore, DWORD dwFlags)
#define GetCurrentProcess()
#define ERROR_NO_MORE_ITEMS
#define ERROR_ACCESS_DENIED
BOOL WINAPI DuplicateHandle(IN HANDLE hSourceProcessHandle, IN HANDLE hSourceHandle, IN HANDLE hTargetProcessHandle, OUT LPHANDLE lpTargetHandle, IN DWORD dwDesiredAccess, IN BOOL bInheritHandle, IN DWORD dwOptions)
BOOL WINAPI InitializeCriticalSectionEx(OUT LPCRITICAL_SECTION lpCriticalSection, IN DWORD dwSpinCount, IN DWORD flags)
_ACRTIMP int __cdecl wcscmp(const wchar_t *, const wchar_t *)
GLenum GLuint GLenum GLsizei const GLchar * buf
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define ERROR_FILE_NOT_FOUND
_In_ LPWSTR _In_ DWORD _In_ DWORD _In_ DWORD dwFlags
static unsigned __int64 next
static BOOL WINAPI CRYPT_RegDeleteCTL(HCERTSTORE hCertStore, PCCTL_CONTEXT pCtlContext, DWORD dwFlags)
struct _WINE_HASH_TO_DELETE WINE_HASH_TO_DELETE
static BOOL WINAPI CRYPT_RegWriteCert(HCERTSTORE hCertStore, PCCERT_CONTEXT cert, DWORD dwFlags)
static BOOL CRYPT_RegFlushStore(WINE_REGSTOREINFO *store, BOOL force)
void CRYPT_RegReadSerializedFromReg(HKEY key, DWORD contextType, HCERTSTORE store, DWORD disposition)
static BOOL WINAPI CRYPT_RegWriteCRL(HCERTSTORE hCertStore, PCCRL_CONTEXT crl, DWORD dwFlags)
WINECRYPT_CERTSTORE * CRYPT_RegOpenStore(HCRYPTPROV hCryptProv, DWORD dwFlags, const void *pvPara)
static void * regProvFuncs[]
static BOOL WINAPI CRYPT_RegWriteCTL(HCERTSTORE hCertStore, PCCTL_CONTEXT ctl, DWORD dwFlags)
struct _WINE_REGSTOREINFO WINE_REGSTOREINFO
static BOOL CRYPT_RegDeleteContext(WINE_REGSTOREINFO *store, struct list *deleteList, const void *context, const WINE_CONTEXT_INTERFACE *contextInterface)
static void CRYPT_RegReadFromReg(HKEY key, HCERTSTORE store, DWORD disposition)
static BOOL WINAPI CRYPT_RegDeleteCRL(HCERTSTORE hCertStore, PCCRL_CONTEXT pCrlContext, DWORD dwFlags)
static BOOL WINAPI CRYPT_RegControl(HCERTSTORE hCertStore, DWORD dwFlags, DWORD dwCtrlType, void const *pvCtrlPara)
BOOL CRYPT_SerializeContextsToReg(HKEY key, DWORD flags, const WINE_CONTEXT_INTERFACE *contextInterface, HCERTSTORE memStore)
static void WINAPI CRYPT_RegCloseStore(HCERTSTORE hCertStore, DWORD dwFlags)
static BOOL WINAPI CRYPT_RegDeleteCert(HCERTSTORE hCertStore, PCCERT_CONTEXT pCertContext, DWORD dwFlags)
static BOOL CRYPT_WriteSerializedToReg(HKEY key, DWORD flags, const BYTE *hash, const BYTE *buf, DWORD len)
static void CRYPT_HashToStr(const BYTE *hash, LPWSTR asciiHash)
static BOOL CRYPT_RegWriteContext(WINE_REGSTOREINFO *store, const void *context, DWORD dwFlags)
static BOOL CRYPT_RegWriteToReg(WINE_REGSTOREINFO *store)
#define LIST_FOR_EACH_ENTRY_SAFE(cursor, cursor2, list, type, field)
void ** rgpvStoreProvFunc
HCERTSTOREPROV hStoreProv
PRTL_CRITICAL_SECTION_DEBUG DebugInfo
GetContextPropertyFunc getProp
SerializeElementFunc serialize
AddContextToStoreFunc addContextToStore
EnumContextsInStoreFunc enumContextsInStore
struct list certsToDelete
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
void WINAPI DeleteCriticalSection(PCRITICAL_SECTION)
#define CERT_STORE_CTRL_COMMIT_FORCE_FLAG
#define CERT_STORE_ADD_REPLACE_EXISTING
#define CERT_STORE_CREATE_NEW_FLAG
#define CERT_STORE_CTL_CONTEXT_FLAG
#define CERT_STORE_CTRL_RESYNC
#define CERT_STORE_CRL_CONTEXT_FLAG
#define CERT_STORE_PROV_MEMORY
#define CERT_STORE_CTRL_NOTIFY_CHANGE
#define CERT_STORE_CERTIFICATE_CONTEXT
#define CERT_STORE_CTRL_AUTO_RESYNC
#define CERT_STORE_CTL_CONTEXT
#define CERT_HASH_PROP_ID
#define CERT_STORE_ADD_ALWAYS
#define CERT_STORE_PROV_WRITE_ADD_FLAG
#define CERT_STORE_CTRL_COMMIT
#define CERT_STORE_NO_CRYPT_RELEASE_FLAG
#define CERT_STORE_CERTIFICATE_CONTEXT_FLAG
#define CERT_STORE_DELETE_FLAG
#define CERT_STORE_CRL_CONTEXT
#define CERT_STORE_READONLY_FLAG
#define RTL_CRITICAL_SECTION_FLAG_FORCE_DEBUG_INFO
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)