From 3e7e95559dd76e836d7e2bfa50719ea289b22cc6 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 14 Nov 2013 20:55:33 +0000 Subject: MS_CRYPTO_ENUM_PROVIDERS: service to get list of crypto providers git-svn-id: http://svn.miranda-ng.org/main/trunk@6906 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/modules/crypt/encrypt.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src') diff --git a/src/modules/crypt/encrypt.cpp b/src/modules/crypt/encrypt.cpp index ab73ac5671..4cb096e3ec 100644 --- a/src/modules/crypt/encrypt.cpp +++ b/src/modules/crypt/encrypt.cpp @@ -74,6 +74,15 @@ static INT_PTR srvRegister(WPARAM wParam, LPARAM lParam) return 0; } +static INT_PTR srvEnumProviders(WPARAM wParam, LPARAM lParam) +{ + if (wParam && lParam) { + *(int*)wParam = arProviders.getCount(); + *(CRYPTO_PROVIDER***)lParam = arProviders.getArray(); + } + return 0; +} + ///////////////////////////////////////////////////////////////////////////////////////// int InitCrypt(void) @@ -82,6 +91,7 @@ int InitCrypt(void) CreateServiceFunction(MS_DB_CRYPT_DECODESTRING, DecodeString); CreateServiceFunction(MS_CRYPTO_REGISTER_ENGINE, srvRegister); + CreateServiceFunction(MS_CRYPTO_ENUM_PROVIDERS, srvEnumProviders); return 0; } -- cgit v1.2.3