summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Collins <elic@assurancetechnologies.com>2020-02-16 10:57:40 -0500
committerEli Collins <elic@assurancetechnologies.com>2020-02-16 10:57:40 -0500
commit75472043288fc88d30098e5e61a4e451e7d2c043 (patch)
tree76c4f0a02c17d323dd30e7c8060d70b76b1f164a
parentc7c4ca4ece10ac0e1090bfa6a3bc41baabcf5ce7 (diff)
downloadpasslib-75472043288fc88d30098e5e61a4e451e7d2c043.tar.gz
docs: various minor updates
-rw-r--r--docs/lib/passlib.hash.argon2.rst9
-rw-r--r--docs/lib/passlib.hash.rst6
-rw-r--r--passlib/context.py8
3 files changed, 12 insertions, 11 deletions
diff --git a/docs/lib/passlib.hash.argon2.rst b/docs/lib/passlib.hash.argon2.rst
index fcc9508..4c1662b 100644
--- a/docs/lib/passlib.hash.argon2.rst
+++ b/docs/lib/passlib.hash.argon2.rst
@@ -56,14 +56,14 @@ Format & Algorithm
==================
The Argon2 hash format is defined by the argon2 reference implementation.
It's compatible with the :ref:`PHC Format <phc-format>` and :ref:`modular-crypt-format`,
-and uses ``$argon2i$`` and ``$argon2d$``
-as it's identifying prefixes for all its strings. An example hash (of ``password``) is:
+and uses ``$argon2i$``, ``$argon2d$``, or ``$argon2id$`` as the identifying prefixes
+for all its strings. An example hash (of ``password``) is:
``$argon2i$v=19$m=512,t=3,p=2$c29tZXNhbHQ$SqlVijFGiPG+935vDSGEsA``
This string has the format :samp:`$argon2{X}$v={V}$m={M},t={T},p={P}${salt}${digest}`, where:
-* :samp:`{X}` is either ``i`` or ``d``, depending on the argon2 variant
+* :samp:`{X}` is either ``i``, ``d``, or ``id``; depending on the argon2 variant
(``i`` in the example).
* :samp:`{V}` is an integer representing the argon2 revision.
@@ -114,9 +114,6 @@ before it. As of the release of Passlib 1.7, it has no known major security iss
Deviations
==========
-* While passlib supports verifying type "d" Argon2 hashes, it does not support generating
- them. This is a deliberate choice, since type "d" is explicitly not designed for password hashing.
-
* This implementation currently encodes all unicode passwords using UTF-8 before hashing,
other implementations may vary, or offer a configurable encoding; though UTF-8 is assumed
to be the default.
diff --git a/docs/lib/passlib.hash.rst b/docs/lib/passlib.hash.rst
index 94580e8..aaf7e60 100644
--- a/docs/lib/passlib.hash.rst
+++ b/docs/lib/passlib.hash.rst
@@ -38,7 +38,7 @@ Aside from "archaic" schemes such as :class:`!des_crypt`,
most of the password hashes supported by modern Unix flavors
adhere to the :ref:`modular crypt format <modular-crypt-format>`,
allowing them to be easily distinguished when used within the same file.
-The basic of format :samp:`${scheme}${hash}` has also been adopted for use
+Variants of this format's basic :samp:`${scheme}${salt}${digest}` structure have also been adopted for use
by other applications and password hash schemes.
.. _standard-unix-hashes:
@@ -114,8 +114,8 @@ of application-specific hash algorithms:
Active Hashes
-------------
-While most of these schemes generally require an application-specific
-implementation, natively used by any Unix flavor to store user passwords,
+While most of these schemes are generally application-specific,
+and are not natively supported by any Unix OS,
they can be used compatibly along side other modular crypt format hashes:
.. toctree::
diff --git a/passlib/context.py b/passlib/context.py
index fa700f7..e6d3ea5 100644
--- a/passlib/context.py
+++ b/passlib/context.py
@@ -1528,8 +1528,12 @@ class CryptContext(object):
:type encoding: str
:param encoding:
- Encoding to use when decode bytes from string.
- Defaults to ``"utf-8"``. Ignoring when loading from a dictionary.
+ Encoding to use when **source** is bytes.
+ Defaults to ``"utf-8"``. Ignored when loading from a dictionary.
+
+ .. deprecated:: 1.8
+
+ This keyword, and support for bytes input, will be dropped in Passlib 2.0
:raises TypeError:
* If the source cannot be identified.