Skip to content

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
FAlbertDev committed Jan 10, 2024
1 parent 8c50cc2 commit d9a3629
Show file tree
Hide file tree
Showing 8 changed files with 3 additions and 58 deletions.
1 change: 0 additions & 1 deletion src/lib/pubkey/classic_mceliece/cmce.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
#include <botan/cmce.h>
#include <botan/rng.h>
#include <botan/internal/bitvector.h>
#include <botan/internal/cmce_debug_utils.h>
#include <botan/internal/cmce_decaps.h>
#include <botan/internal/cmce_encaps.h>
#include <botan/internal/cmce_field_ordering.h>
Expand Down
51 changes: 0 additions & 51 deletions src/lib/pubkey/classic_mceliece/cmce_debug_utils.h

This file was deleted.

1 change: 0 additions & 1 deletion src/lib/pubkey/classic_mceliece/cmce_decaps.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include <botan/cmce.h>
#include <botan/rng.h>
#include <botan/internal/bitvector.h>
#include <botan/internal/cmce_debug_utils.h>
#include <botan/internal/cmce_field_ordering.h>
#include <botan/internal/cmce_keys_internal.h>
#include <botan/internal/cmce_matrix.h>
Expand Down
3 changes: 2 additions & 1 deletion src/lib/pubkey/classic_mceliece/cmce_keys_internal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ Classic_McEliece_PrivateKeyInternal Classic_McEliece_PrivateKeyInternal::from_by
auto g = Classic_McEliece_Minimal_Polynomial::from_bytes(g_bytes, params.poly_f());

auto alpha_control_bits = sk_slicer.take(params.sk_alpha_control_bytes());
auto field_ordering = Classic_McEliece_Field_Ordering::create_from_control_bits(params, alpha_control_bits);
auto field_ordering =
Classic_McEliece_Field_Ordering::create_from_control_bits(params, secure_bitvector(alpha_control_bits));

auto s = sk_slicer.copy_as_secure_vector(params.sk_s_bytes());
BOTAN_ASSERT_NOMSG(sk_slicer.empty());
Expand Down
1 change: 0 additions & 1 deletion src/lib/pubkey/classic_mceliece/cmce_matrix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
* Botan is released under the Simplified BSD License (see license.txt)
**/

#include <botan/internal/cmce_debug_utils.h>
#include <botan/internal/cmce_matrix.h>

namespace {
Expand Down
2 changes: 1 addition & 1 deletion src/lib/pubkey/classic_mceliece/cmce_parameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ class BOTAN_TEST_API Classic_McEliece_Parameters final {
size_t tau() const {
// Section 8.4 of ISO:
// The integer tau is defined as t if n=q; as 2t if q/2<=n<q; as 4t if q/4<=n<q/2; etc
size_t tau_fact = 1 << (m() - floor_log2(n()));
size_t tau_fact = size_t(1) << (m() - floor_log2(n()));
return tau_fact * t();
}

Expand Down
1 change: 0 additions & 1 deletion src/lib/pubkey/classic_mceliece/info.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ cmce_parameters.h
cmce_poly.h
cmce_matrix.h
cmce_gf.h
cmce_debug_utils.h
cmce_field_ordering.h
cmce_encaps.h
cmce_decaps.h
Expand Down
1 change: 0 additions & 1 deletion src/tests/test_cmce.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <botan/hash.h>
#include <botan/pk_algs.h>
#include <botan/pubkey.h>
#include <botan/internal/cmce_debug_utils.h>
#include <botan/internal/cmce_decaps.h>
#include <botan/internal/cmce_encaps.h>
#include <botan/internal/cmce_field_ordering.h>
Expand Down

0 comments on commit d9a3629

Please sign in to comment.