mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 07:37:46 +00:00
LibCrypto: Small fixes in BigInteger & test-crypto
This commit is contained in:
parent
8ad48cca29
commit
d008a38f93
3 changed files with 121 additions and 122 deletions
|
@ -1341,7 +1341,7 @@ void bigint_subtraction()
|
|||
PASS;
|
||||
}
|
||||
{
|
||||
I_TEST((BigInteger | Subtraction Regerssion 1));
|
||||
I_TEST((BigInteger | Subtraction Regression 1));
|
||||
auto num = Crypto::UnsignedBigInteger { 1 }.shift_left(256);
|
||||
if (num.minus(1).words() == Vector<u32> { 4294967295, 4294967295, 4294967295, 4294967295, 4294967295, 4294967295, 4294967295, 4294967295, 0 }) {
|
||||
PASS;
|
||||
|
@ -1354,7 +1354,7 @@ void bigint_subtraction()
|
|||
void bigint_multiplication()
|
||||
{
|
||||
{
|
||||
I_TEST((BigInteger | Simple Multipliction));
|
||||
I_TEST((BigInteger | Simple Multiplication));
|
||||
Crypto::UnsignedBigInteger num1(8);
|
||||
Crypto::UnsignedBigInteger num2(251);
|
||||
Crypto::UnsignedBigInteger result = num1.multiplied_by(num2);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue