Fixed "signed/unsigned" conversion warning when "-DDEBUG" defined
parent
f61577af9d
commit
e507a4136e
20
esign.cpp
20
esign.cpp
|
|
@ -75,8 +75,8 @@ void ESIGNFunction::AssignFrom(const NameValuePairs &source)
|
||||||
|
|
||||||
void InvertibleESIGNFunction::GenerateRandom(RandomNumberGenerator &rng, const NameValuePairs ¶m)
|
void InvertibleESIGNFunction::GenerateRandom(RandomNumberGenerator &rng, const NameValuePairs ¶m)
|
||||||
{
|
{
|
||||||
int modulusSize = 1023*2;
|
unsigned int modulusSize = 1023*2;
|
||||||
param.GetIntValue("ModulusSize", modulusSize) || param.GetIntValue("KeySize", modulusSize);
|
param.GetAsUIntValue("ModulusSize", modulusSize) || param.GetAsUIntValue("KeySize", modulusSize);
|
||||||
|
|
||||||
if (modulusSize < 24)
|
if (modulusSize < 24)
|
||||||
throw InvalidArgument("InvertibleESIGNFunction: specified modulus size is too small");
|
throw InvalidArgument("InvertibleESIGNFunction: specified modulus size is too small");
|
||||||
|
|
@ -167,14 +167,14 @@ Integer InvertibleESIGNFunction::CalculateRandomizedInverse(RandomNumberGenerato
|
||||||
CRYPTOPP_ASSERT(s < m_n);
|
CRYPTOPP_ASSERT(s < m_n);
|
||||||
/*
|
/*
|
||||||
using namespace std;
|
using namespace std;
|
||||||
cout << "f = " << x << endl;
|
std::cout << "f = " << x << std::endl;
|
||||||
cout << "r = " << r << endl;
|
std::cout << "r = " << r << std::endl;
|
||||||
cout << "z = " << z << endl;
|
std::cout << "z = " << z << std::endl;
|
||||||
cout << "a = " << a << endl;
|
std::cout << "a = " << a << std::endl;
|
||||||
cout << "w0 = " << w0 << endl;
|
std::cout << "w0 = " << w0 << std::endl;
|
||||||
cout << "w1 = " << w1 << endl;
|
std::cout << "w1 = " << w1 << std::endl;
|
||||||
cout << "t = " << t << endl;
|
std::cout << "t = " << t << std::endl;
|
||||||
cout << "s = " << s << endl;
|
std::cout << "s = " << s << std::endl;
|
||||||
*/
|
*/
|
||||||
return s;
|
return s;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
2
ida.cpp
2
ida.cpp
|
|
@ -151,7 +151,7 @@ void RawIDA::AddOutputChannel(word32 channelId)
|
||||||
|
|
||||||
void RawIDA::PrepareInterpolation()
|
void RawIDA::PrepareInterpolation()
|
||||||
{
|
{
|
||||||
CRYPTOPP_ASSERT(m_inputChannelIds.size() == m_threshold);
|
CRYPTOPP_ASSERT(m_inputChannelIds.size() == (unsigned int)m_threshold);
|
||||||
PrepareBulkPolynomialInterpolation(field, m_w.begin(), &(m_inputChannelIds[0]), m_threshold);
|
PrepareBulkPolynomialInterpolation(field, m_w.begin(), &(m_inputChannelIds[0]), m_threshold);
|
||||||
for (unsigned int i=0; i<m_outputChannelIds.size(); i++)
|
for (unsigned int i=0; i<m_outputChannelIds.size(); i++)
|
||||||
ComputeV(i);
|
ComputeV(i);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue