Hello, this library is pretty impressive!
We've been using Crypto++ 4.1 with MSVC6/7 successfully. We'd like to go to version 5.1 (with patch) on Visual Studio .NET 2003 (VC7.1).
I see that class VerifierFilter is now gone and is replaced with a typedef:
typedef SignatureVerificationFilter VerifierFilter;
What construct should be used to replace old calls to PutSignature()? For reference, here is the code we're using:
{
CryptoPP::StringSource ssPublicKey(szKey, true, new CryptoPP::HexDecoder);
CryptoPP::RSASSA_PKCS1v15_SHA_Verifier pub(ssPublicKey);CryptoPP::StringSource ssSignature(&m_Signature[0], m_Signature.size(), true, new CryptoPP::HexDecoder);
if (ssSignature.MaxRetrievable() == pub.SignatureLength())
{
CryptoPP::SecByteBlock sig(pub.SignatureLength());
ssSignature.Get(sig, sig.size());CryptoPP::VerifierFilter *verifier = new CryptoPP::VerifierFilter(pub);
verifier->PutSignature(sig);
CryptoPP::StringSource ssBody(&m_Body[0], m_Body.size(), true, verifier);byte result = 0;
ssBody.Get(result);
return result == 1;
}
}
Should the call be replaced by something like:
PutMaybeModifiable( sig, sig.size(), 1, true, false); // ?
Thanks for your help!
David Grigsby
Do you Yahoo!?
Free online calendar with sync to Outlook(TM).
