X-Git-Url: http://git.euphorik.ch/?a=blobdiff_plain;f=src%2FTests.h;h=75f0bdbb36515de78bdf08be285bd5d5e4aee280;hb=5b2785dd710151d81e6f6af4fd6ae48521068e41;hp=4f01ac0593e04042136982a3e6346a0a5c8fd5d8;hpb=fb173a9728e915fc7b3f99bc41f55034757105df;p=crypto_lab3.git diff --git a/src/Tests.h b/src/Tests.h index 4f01ac0..75f0bdb 100644 --- a/src/Tests.h +++ b/src/Tests.h @@ -8,16 +8,32 @@ class Tests public: Tests(uint keySizeBits, uint rsaPublicExponent); - void runTests(); + void runTests(); + void runTestsWithShamirsTrick(); void runTimeMeasures(); + void doAttack(); + void doAttackFixed(); + private: bool rsaStandard(); bool rsaCrt(); + bool rsaCrtWithShamirsTrick(); + /** + * Return the time in [ms] required to sign N times with RSA standard. + * One key pair and a message is generated. + */ int timeSignRsaStd(int N); + + /** + * Return the time in [ms] required to sign N times with RSA CRT. + * One key pair and a message is generated. + */ int timeSignRsaCRT(int N); + int timeSignRsaCRTShamirsTrick(int N); + const uint KEY_SIZE_BITS; const uint RSA_PUBLIC_EXPONENT; };