diff --git a/dlls/crypt32/crypt32_En.rc b/dlls/crypt32/crypt32_En.rc index 08bf3854403..38e3b2e91f9 100644 --- a/dlls/crypt32/crypt32_En.rc +++ b/dlls/crypt32/crypt32_En.rc @@ -164,3 +164,11 @@ STRINGTABLE DISCARDABLE IDS_LIFETIME_SIGNING "Lifetime Signing" IDS_ANY_CERT_POLICY "All issuance policies" } + +STRINGTABLE DISCARDABLE +{ + IDS_LOCALIZEDNAME_ROOT "Trusted Root Certification Authorities" + IDS_LOCALIZEDNAME_MY "Personal" + IDS_LOCALIZEDNAME_CA "Intermediate Certification Authorities" + IDS_LOCALIZEDNAME_ADDRESSBOOK "Other People" +} diff --git a/dlls/crypt32/crypt32_No.rc b/dlls/crypt32/crypt32_No.rc index 6d5bb8261fe..18de84b8c4b 100644 --- a/dlls/crypt32/crypt32_No.rc +++ b/dlls/crypt32/crypt32_No.rc @@ -164,3 +164,11 @@ STRINGTABLE DISCARDABLE IDS_LIFETIME_SIGNING "Livstidsignering" IDS_ANY_CERT_POLICY "Alle framgangsmåter for utsteding" } + +STRINGTABLE DISCARDABLE +{ + IDS_LOCALIZEDNAME_ROOT "Klarerte rotsertifiseringsinstanser" + IDS_LOCALIZEDNAME_MY "Personlig" + IDS_LOCALIZEDNAME_CA "Mellomliggende sertifiseringsinstanser" + IDS_LOCALIZEDNAME_ADDRESSBOOK "Andre personer" +} diff --git a/dlls/crypt32/cryptres.h b/dlls/crypt32/cryptres.h index 1f0a95ea43d..32c81690e2c 100644 --- a/dlls/crypt32/cryptres.h +++ b/dlls/crypt32/cryptres.h @@ -160,4 +160,9 @@ #define IDS_LIFETIME_SIGNING 1139 #define IDS_ANY_CERT_POLICY 1140 +#define IDS_LOCALIZEDNAME_ROOT 1141 +#define IDS_LOCALIZEDNAME_MY 1142 +#define IDS_LOCALIZEDNAME_CA 1143 +#define IDS_LOCALIZEDNAME_ADDRESSBOOK 1144 + #endif /* ndef __WINE_CRYPTRES_H__ */ diff --git a/dlls/crypt32/oid.c b/dlls/crypt32/oid.c index c35554f8c83..5d1799738d1 100644 --- a/dlls/crypt32/oid.c +++ b/dlls/crypt32/oid.c @@ -77,6 +77,13 @@ struct OIDFunction struct list next; }; +static const WCHAR ROOT[] = {'R','O','O','T',0}; +static const WCHAR MY[] = {'M','Y',0}; +static const WCHAR CA[] = {'C','A',0}; +static const WCHAR ADDRESSBOOK[] = {'A','D','D','R','E','S','S','B','O','O','K',0}; +static const LPCWSTR LocalizedKeys[] = {ROOT,MY,CA,ADDRESSBOOK}; +static WCHAR LocalizedNames[4][256]; + static void free_function_sets(void) { struct OIDFunctionSet *setCursor, *setNext; @@ -987,12 +994,32 @@ BOOL WINAPI CryptUnregisterDefaultOIDFunction(DWORD dwEncodingType, return ret; } +static void oid_init_localizednames(HINSTANCE hInstance) +{ + int i; + + for(i = 0; i < sizeof(LocalizedKeys)/sizeof(LPCWSTR); i++) + { + LoadStringW(hInstance, IDS_LOCALIZEDNAME_ROOT+i, LocalizedNames[i], 256); + } +} + /******************************************************************** * CryptFindLocalizedName (CRYPT32.@) */ LPCWSTR WINAPI CryptFindLocalizedName(LPCWSTR pwszCryptName) { - FIXME(" %s - stub\n",debugstr_w(pwszCryptName)); + int i; + + for(i = 0; i < sizeof(LocalizedKeys)/sizeof(LPCWSTR); i++) + { + if(!lstrcmpiW(LocalizedKeys[i], pwszCryptName)) + { + return LocalizedNames[i]; + } + } + + FIXME("No name for: %s - stub\n",debugstr_w(pwszCryptName)); return NULL; } @@ -1345,6 +1372,7 @@ static void init_oid_info(HINSTANCE hinst) { DWORD i; + oid_init_localizednames(hinst); for (i = 0; i < sizeof(oidInfoConstructors) / sizeof(oidInfoConstructors[0]); i++) {