Skip to content

Commit

Permalink
Fix typo from SP 800-180 to SP 800-108
Browse files Browse the repository at this point in the history
  • Loading branch information
Raccoon authored and Legrandin committed Feb 16, 2025
1 parent 942b630 commit f1cefb8
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Doc/src/protocol/dh.rst
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ not password-based. For instance, some reasonable choices are:

* :ref:`hkdf`
* :ref:`shake128` or :ref:`shake256`
* :ref:`sp800-180-counter`
* :ref:`sp800-108-counter`
* :ref:`tuplehash128` or :ref:`tuplehash256`

KDFs are typically fed with multiple inputs,
Expand Down
4 changes: 2 additions & 2 deletions Doc/src/protocol/kdf.rst
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,9 @@ Example, for deriving two AES256 keys::

.. autofunction:: Crypto.Protocol.KDF.HKDF

.. _sp800-180-counter:
.. _sp800-108-counter:

SP 800-180 Counter Mode
SP 800-108 Counter Mode
++++++++++++++++++++++++

A KDF can be generically constructed with a pseudorandom function (PRF).
Expand Down
6 changes: 3 additions & 3 deletions lib/Crypto/SelfTest/Protocol/test_KDF.py
Original file line number Diff line number Diff line change
Expand Up @@ -714,7 +714,7 @@ def load_hash_by_name(hash_name):
return __import__("Crypto.Hash." + hash_name, globals(), locals(), ["new"])


class SP800_180_Counter_Tests(unittest.TestCase):
class SP800_108_Counter_Tests(unittest.TestCase):

def test_negative_zeroes(self):
def prf(s, x):
Expand Down Expand Up @@ -781,7 +781,7 @@ def kdf_test(self, prf=prf, kin=tv.kin, label=tv.label,
setattr(cls, "test_kdf_sp800_108_counter_%d" % idx, kdf_test)


add_tests_sp800_108_counter(SP800_180_Counter_Tests)
add_tests_sp800_108_counter(SP800_108_Counter_Tests)


def get_tests(config={}):
Expand All @@ -799,7 +799,7 @@ def get_tests(config={}):
tests += [TestVectorsHKDFWycheproof(wycheproof_warnings)]
tests += list_test_cases(scrypt_Tests)
tests += list_test_cases(bcrypt_Tests)
tests += list_test_cases(SP800_180_Counter_Tests)
tests += list_test_cases(SP800_108_Counter_Tests)

return tests

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Test vectors for NIST SP-800 180, KDF in Counter mode
# Test vectors for NIST SP-800 108, KDF in Counter mode
# Generated with Botan v2.19.1
#

Expand Down
4 changes: 2 additions & 2 deletions test_vectors/src/sp800_108.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
using namespace std;

/*
* Generate test vectors for SP 800-180 using the Botan library.
* Generate test vectors for SP 800-108 using the Botan library.
*
* Input key: 16 bytes
* PRF: HMAC-256, HMAC-384, HMAC-512
Expand Down Expand Up @@ -74,7 +74,7 @@ int main(void)
unsigned count = 0;

printf("#\n");
printf("# Test vectors for NIST SP-800 180, KDF in Counter mode\n");
printf("# Test vectors for NIST SP-800 108, KDF in Counter mode\n");
printf("# Generated with Botan v%d.%d.%d\n", BOTAN_VERSION_MAJOR, BOTAN_VERSION_MINOR, BOTAN_VERSION_PATCH);
printf("#\n");

Expand Down

0 comments on commit f1cefb8

Please sign in to comment.