-
Notifications
You must be signed in to change notification settings - Fork 573
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
26 changed files
with
672 additions
and
301 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,4 +20,5 @@ pcurves_id.h | |
pcurves_impl.h | ||
pcurves_util.h | ||
pcurves_wrap.h | ||
pcurves_instance.h | ||
</header:internal> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<defines> | ||
PCURVES_BRAINPOOL256R1 -> 20240608 | ||
</defines> | ||
|
||
<module_info> | ||
name -> "PCurve brainpool256r1" | ||
brief -> "brainpool256r1" | ||
type -> "Internal" | ||
</module_info> |
40 changes: 40 additions & 0 deletions
40
src/lib/math/pcurves/pcurves_brainpool256r1/pcurves_brainpool256r1.cpp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/* | ||
* (C) 2024 Jack Lloyd | ||
* | ||
* Botan is released under the Simplified BSD License (see license.txt) | ||
*/ | ||
|
||
#include <botan/internal/pcurves_instance.h> | ||
|
||
#include <botan/internal/pcurves_wrap.h> | ||
|
||
namespace Botan::PCurve { | ||
|
||
namespace { | ||
|
||
// clang-format off | ||
namespace brainpool256r1 { | ||
|
||
class Params final : public EllipticCurveParameters< | ||
"A9FB57DBA1EEA9BC3E660A909D838D726E3BF623D52620282013481D1F6E5377", | ||
"7D5A0975FC2C3057EEF67530417AFFE7FB8055C126DC5C6CE94A4B44F330B5D9", | ||
"26DC5C6CE94A4B44F330B5D9BBD77CBF958416295CF7E1CE6BCCDC18FF8C07B6", | ||
"A9FB57DBA1EEA9BC3E660A909D838D718C397AA3B561A6F7901E0E82974856A7", | ||
"8BD2AEB9CB7E57CB2C4B482FFC81B7AFB9DE27E1E3BD23C23A4453BD9ACE3262", | ||
"547EF835C3DAC4FD97F8461A14611DC9C27745132DED8E545C1D54C72F046997"> { | ||
}; | ||
|
||
class Curve final : public EllipticCurve<Params> {}; | ||
|
||
} | ||
|
||
// clang-format on | ||
|
||
} // namespace | ||
|
||
std::shared_ptr<const PrimeOrderCurve> PCurveInstance::brainpool256r1() { | ||
static auto g_brainpool256r1 = std::make_shared<const PrimeOrderCurveImpl<brainpool256r1::Curve>>(); | ||
return g_brainpool256r1; | ||
} | ||
|
||
} // namespace Botan::PCurve |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<defines> | ||
PCURVES_BRAINPOOL384R1 -> 20240608 | ||
</defines> | ||
|
||
<module_info> | ||
name -> "PCurve brainpool384r1" | ||
brief -> "brainpool384r1" | ||
type -> "Internal" | ||
</module_info> |
Oops, something went wrong.