Core/Authserver: Split SRP6 into its own file (PR #25131)

This commit is contained in:
Treeston
2020-07-29 00:07:41 +02:00
committed by GitHub
parent 210f552ac5
commit 7f7fa8b23d
21 changed files with 301 additions and 132 deletions

View File

@@ -27,7 +27,7 @@ BigNumber::BigNumber()
{ }
BigNumber::BigNumber(BigNumber const& bn)
: _bn(BN_dup(bn._bn))
: _bn(BN_dup(bn.BN()))
{ }
BigNumber::~BigNumber()
@@ -35,6 +35,13 @@ BigNumber::~BigNumber()
BN_free(_bn);
}
void BigNumber::SetDword(int32 val)
{
SetDword(uint32(abs(val)));
if (val < 0)
BN_set_negative(_bn, 1);
}
void BigNumber::SetDword(uint32 val)
{
BN_set_word(_bn, val);