aboutsummaryrefslogtreecommitdiffstats
path: root/docs/hazmat/primitives/key-derivation-functions.rst
diff options
context:
space:
mode:
Diffstat (limited to 'docs/hazmat/primitives/key-derivation-functions.rst')
-rw-r--r--docs/hazmat/primitives/key-derivation-functions.rst10
1 files changed, 5 insertions, 5 deletions
diff --git a/docs/hazmat/primitives/key-derivation-functions.rst b/docs/hazmat/primitives/key-derivation-functions.rst
index 9b76bf64..11fbd4e0 100644
--- a/docs/hazmat/primitives/key-derivation-functions.rst
+++ b/docs/hazmat/primitives/key-derivation-functions.rst
@@ -220,7 +220,7 @@ Different KDFs are suitable for different tasks such as:
raises an exception if they do not match.
-.. class:: HKDFExpandOnly(algorithm, length, info, backend)
+.. class:: HKDFExpand(algorithm, length, info, backend)
.. versionadded:: 0.5
@@ -230,7 +230,7 @@ Different KDFs are suitable for different tasks such as:
.. warning::
- HKDFExpandOnly should only be used if the key material is
+ HKDFExpand should only be used if the key material is
cryptographically strong. You should use
:class:`~cryptography.hazmat.primitives.kdf.hkdf.HKDF` if
you are unsure.
@@ -239,19 +239,19 @@ Different KDFs are suitable for different tasks such as:
>>> import os
>>> from cryptography.hazmat.primitives import hashes
- >>> from cryptography.hazmat.primitives.kdf.hkdf import HKDFExpandOnly
+ >>> from cryptography.hazmat.primitives.kdf.hkdf import HKDFExpand
>>> from cryptography.hazmat.backends import default_backend
>>> backend = default_backend()
>>> info = b"hkdf-example"
>>> key_material = os.urandom(16)
- >>> hkdf = HKDFExpandOnly(
+ >>> hkdf = HKDFExpand(
... algorithm=hashes.SHA256(),
... length=32,
... info=info,
... backend=backend
... )
>>> key = hkdf.derive(key_material)
- >>> hkdf = HKDFExpandOnly(
+ >>> hkdf = HKDFExpand(
... algorithm=hashes.SHA256(),
... length=32,
... info=info,