crypt32: Implement CryptFindLocalizedName.
This commit is contained in:
parent
29b8c35bbf
commit
a3a165fcdb
|
@ -164,3 +164,11 @@ STRINGTABLE DISCARDABLE
|
||||||
IDS_LIFETIME_SIGNING "Lifetime Signing"
|
IDS_LIFETIME_SIGNING "Lifetime Signing"
|
||||||
IDS_ANY_CERT_POLICY "All issuance policies"
|
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"
|
||||||
|
}
|
||||||
|
|
|
@ -164,3 +164,11 @@ STRINGTABLE DISCARDABLE
|
||||||
IDS_LIFETIME_SIGNING "Livstidsignering"
|
IDS_LIFETIME_SIGNING "Livstidsignering"
|
||||||
IDS_ANY_CERT_POLICY "Alle framgangsmåter for utsteding"
|
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"
|
||||||
|
}
|
||||||
|
|
|
@ -160,4 +160,9 @@
|
||||||
#define IDS_LIFETIME_SIGNING 1139
|
#define IDS_LIFETIME_SIGNING 1139
|
||||||
#define IDS_ANY_CERT_POLICY 1140
|
#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__ */
|
#endif /* ndef __WINE_CRYPTRES_H__ */
|
||||||
|
|
|
@ -77,6 +77,13 @@ struct OIDFunction
|
||||||
struct list next;
|
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)
|
static void free_function_sets(void)
|
||||||
{
|
{
|
||||||
struct OIDFunctionSet *setCursor, *setNext;
|
struct OIDFunctionSet *setCursor, *setNext;
|
||||||
|
@ -987,12 +994,32 @@ BOOL WINAPI CryptUnregisterDefaultOIDFunction(DWORD dwEncodingType,
|
||||||
return ret;
|
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.@)
|
* CryptFindLocalizedName (CRYPT32.@)
|
||||||
*/
|
*/
|
||||||
LPCWSTR WINAPI CryptFindLocalizedName(LPCWSTR pwszCryptName)
|
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;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1345,6 +1372,7 @@ static void init_oid_info(HINSTANCE hinst)
|
||||||
{
|
{
|
||||||
DWORD i;
|
DWORD i;
|
||||||
|
|
||||||
|
oid_init_localizednames(hinst);
|
||||||
for (i = 0; i < sizeof(oidInfoConstructors) /
|
for (i = 0; i < sizeof(oidInfoConstructors) /
|
||||||
sizeof(oidInfoConstructors[0]); i++)
|
sizeof(oidInfoConstructors[0]); i++)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue