-3
我想禁用在Wincrypt API中加密的加密。
请给我点建议,如何做到这一点,一般sugestions也欢迎
下面是从EncryptedMessage.cpp代码示例:如何禁用由Wincrypt API完成的加密
CCryptoEngine::CryptProvider CCryptoEngine::
GetCryptoProvider()
throw(CCryptoEngine::Exception)
{
if(! CryptProviderAllocator::IsAllocated(m_RSACryptProvider))
{
if(! CryptAcquireContext(&m_RSACryptProvider, _T("CollabWorx SIM Client"),
MS_ENHANCED_PROV, PROV_RSA_FULL, 0))
if(! CryptAcquireContext(&m_RSACryptProvider, _T("CollabWorx SIM Client"),
MS_ENHANCED_PROV, PROV_RSA_FULL, CRYPT_NEWKEYSET))
if(! CryptAcquireContext(&m_RSACryptProvider, NULL, MS_ENHANCED_PROV,
PROV_RSA_FULL, CRYPT_NEWKEYSET | CRYPT_VERIFYCONTEXT))
throw CCryptoEngine::Exception(
"Your system may lack the required security capabilities.\n"
"Please make sure that Microsoft High Encryption Pack (128-bit strength) "
"is installed in your system.\n\nInformation for the support:\n"
+ GetErrorMessageFromCode(GetLastError()));
g_RSACryptProvider = m_RSACryptProvider;
}
return m_RSACryptProvider;
}
“...禁用在Wincrypt API中加密的加密。” - 你是否说要解密*使用Wincrypt API加密的内容?你的措辞并没有帮助你的问题的清晰。 – WhozCraig
已标记:不明 –
@WhoizCraig:是多数民众赞成在什么我想说 – ojas