diff options
| author | Eli Collins <elic@assurancetechnologies.com> | 2011-02-16 16:13:52 -0500 |
|---|---|---|
| committer | Eli Collins <elic@assurancetechnologies.com> | 2011-02-16 16:13:52 -0500 |
| commit | 4cfd0bb3647b25ee1a7a3f54d636ef72244f7fcb (patch) | |
| tree | 92c9184188e2cc64e2c80274076ca4bebe70742b /docs | |
| parent | 3eefcd1f31c534cced89139ebf72d36ceafc3a1c (diff) | |
| download | passlib-4cfd0bb3647b25ee1a7a3f54d636ef72244f7fcb.tar.gz | |
large rearrangment of structure
===============================
* moved passlib.hash package to passlib.drivers
* combined some passlib.driver modules together (eg ext_des_crypt merged w/ des_crypt)
* renamed all hash classes to lower case, to match name attrs.
* renamed ext_des_crypt to bsdi_crypt
* added special proxy module "passlib.hash" which lazily loads drivers from correct location
- registry system reworked, has list of locations for builtin drivers,
and capability for apps to add more
- passlib.hash *is* the registry, changes to it affect list
- thanks to this, documentation can remain, pointing to passlib.hash.xxx as location for driver
* moved passlib.utils.handlers to passlib.utils.drivers, renamed classes from XxxHandler -> XxxHash
* combined all driver tests into single passlib/tests/test_drivers.py file
* NOTE: disabled default unicode testing, not ready for that yet
* all driver UTs pass (others not checked)
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/copyright.rst | 4 | ||||
| -rw-r--r-- | docs/install.rst | 2 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.apr_md5_crypt.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.bcrypt.rst | 6 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.des_crypt.rst | 6 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.ext_des_crypt.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.md5_crypt.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.mysql_323.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.mysql_41.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.nthash.rst | 4 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.phpass.rst | 4 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.postgres_md5.rst | 6 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.rst | 34 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.sha1_crypt.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.sha256_crypt.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.sha512_crypt.rst | 6 | ||||
| -rw-r--r-- | docs/lib/passlib.hash.sun_md5_crypt.rst | 12 | ||||
| -rw-r--r-- | docs/lib/passlib.sqldb.rst | 8 | ||||
| -rw-r--r-- | docs/lib/passlib.unix.rst | 38 | ||||
| -rw-r--r-- | docs/lib/passlib.utils.des.rst | 2 | ||||
| -rw-r--r-- | docs/lib/passlib.utils.rst | 2 | ||||
| -rw-r--r-- | docs/password_hash_api.rst | 4 |
22 files changed, 97 insertions, 97 deletions
diff --git a/docs/copyright.rst b/docs/copyright.rst index 354574c..150bbf4 100644 --- a/docs/copyright.rst +++ b/docs/copyright.rst @@ -46,7 +46,7 @@ implementation of OpenBSD's BCrypt algorithm, written by Damien Miller, and released under a BSD license. :mod:`passlib.utils._slow_bcrypt` is a python translation of this code, -which is used as a fallback backend for :mod:`passlib.hash.bCrypt` +which is used as a fallback backend for :mod:`passlib.drivers.bCrypt` when the external python library `py-bcrypt <http://www.mindrot.org/projects/py-bcrypt/>`_ is not installed. @@ -68,7 +68,7 @@ This is the license and copyright for jBCrypt:: MD5-Crypt --------- -The fallback pure-python implementation contained in :mod:`passlib.hash.md5_crypt` +The fallback pure-python implementation contained in :mod:`passlib.drivers.md5_crypt` was derived from the `FreeBSD md5-crypt <http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/lib/libcrypt/crypt.c?rev=1.2>`_, implementation which was released under the following license:: diff --git a/docs/install.rst b/docs/install.rst index f6ba0c6..e6b8fa2 100644 --- a/docs/install.rst +++ b/docs/install.rst @@ -17,7 +17,7 @@ The following libraries are not required, but will be used if found: * If installed, `py-bcrypt <http://www.mindrot.org/projects/py-bcrypt/>`_ will be used instead of PassLib's slower pure-python bcrypt implementation. - (see :mod:`passlib.hash.bcrypt`). + (see :mod:`passlib.drivers.bcrypt`). *This is strongly recommended, as the builtin implementation is VERY slow*. * stdlib ``crypt.crypt()`` will be used if present, and if the underlying diff --git a/docs/lib/passlib.hash.apr_md5_crypt.rst b/docs/lib/passlib.hash.apr_md5_crypt.rst index 017ff31..5173d5e 100644 --- a/docs/lib/passlib.hash.apr_md5_crypt.rst +++ b/docs/lib/passlib.hash.apr_md5_crypt.rst @@ -1,11 +1,11 @@ ================================================================== -:mod:`passlib.hash.apr_md5_crypt` - Apache MD5-Crypt password hash +:mod:`passlib.drivers.apr_md5_crypt` - Apache MD5-Crypt password hash ================================================================== -.. module:: passlib.hash.apr_md5_crypt +.. module:: passlib.drivers.apr_md5_crypt :synopsis: Apache MD5-Crypt variant -This format is a variation of :mod:`~passlib.hash.md5_crypt`, +This format is a variation of :mod:`~passlib.drivers.md5_crypt`, primarily used by the Apache webserver in ``htpasswd`` files. It contains only minor changes to md5-crypt, and should be considered just as strong / weak as md5-crypt itself. @@ -19,7 +19,7 @@ it's internal hash calculation. Thus, hashes generated by this and md5-crypt are in no way compatible with eachother (they will not even have the same checksum for the same salt). -For details about usage & algorithm, see :mod:`~passlib.hash.md5_crypt`. +For details about usage & algorithm, see :mod:`~passlib.drivers.md5_crypt`. References ========== diff --git a/docs/lib/passlib.hash.bcrypt.rst b/docs/lib/passlib.hash.bcrypt.rst index 32842fc..8b7cc5a 100644 --- a/docs/lib/passlib.hash.bcrypt.rst +++ b/docs/lib/passlib.hash.bcrypt.rst @@ -1,11 +1,11 @@ ================================================================== -:mod:`passlib.hash.bcrypt` - BCrypt +:mod:`passlib.drivers.bcrypt` - BCrypt ================================================================== -.. module:: passlib.hash.bcrypt +.. module:: passlib.drivers.bcrypt :synopsis: BCrypt -BCrypt was developed to replace :mod:`~passlib.hash.md5_crypt` for BSD systems. +BCrypt was developed to replace :mod:`~passlib.drivers.md5_crypt` for BSD systems. It uses a modified version of the Blowfish stream cipher. Featuring a large salt and variable number of rounds, it's currently the default password hash for many systems (notably BSD), and has no known weaknesses. diff --git a/docs/lib/passlib.hash.des_crypt.rst b/docs/lib/passlib.hash.des_crypt.rst index c5e0eb3..6447492 100644 --- a/docs/lib/passlib.hash.des_crypt.rst +++ b/docs/lib/passlib.hash.des_crypt.rst @@ -1,8 +1,8 @@ ======================================================================= -:mod:`passlib.hash.des_crypt` - Tradtional Unix (DES) Crypt +:mod:`passlib.drivers.des_crypt` - Tradtional Unix (DES) Crypt ======================================================================= -.. module:: passlib.hash.des_crypt +.. module:: passlib.drivers.des_crypt :synopsis: Traditional Unix (DES) Crypt .. warning:: @@ -20,7 +20,7 @@ Usage ===== This module can be used directly as follows:: - >>> from passlib.hash import des_crypt as dc + >>> from passlib.drivers.import des_crypt as dc >>> dc.encrypt("password") #generate new salt, encrypt password 'JQMuyS6H.AGMo' diff --git a/docs/lib/passlib.hash.ext_des_crypt.rst b/docs/lib/passlib.hash.ext_des_crypt.rst index d0c2676..8e7fbe5 100644 --- a/docs/lib/passlib.hash.ext_des_crypt.rst +++ b/docs/lib/passlib.hash.ext_des_crypt.rst @@ -1,12 +1,12 @@ ================================================================================= -:mod:`passlib.hash.ext_des_crypt` - BSDi (Extended DES) Crypt +:mod:`passlib.drivers.ext_des_crypt` - BSDi (Extended DES) Crypt ================================================================================= -.. module:: passlib.hash.ext_des_crypt +.. module:: passlib.drivers.ext_des_crypt :synopsis: BSDi (Extended DES) Crypt This algorithm was developed by BSDi for their BSD/OS distribution. -It's based on :mod:`~passlib.hash.des_crypt`, and contains a larger +It's based on :mod:`~passlib.drivers.des_crypt`, and contains a larger salt and a variable number of rounds. Nonetheless, since it's based on DES, and still shares many of des-crypt's other flaws, it should not be used in new applications. @@ -14,7 +14,7 @@ it should not be used in new applications. Usage ===== Aside from differences in format and salt size, -ext-des-crypt usage is exactly the same as :mod:`~passlib.hash.des_crypt`. +ext-des-crypt usage is exactly the same as :mod:`~passlib.drivers.des_crypt`. .. todo:: diff --git a/docs/lib/passlib.hash.md5_crypt.rst b/docs/lib/passlib.hash.md5_crypt.rst index e8235a7..6458851 100644 --- a/docs/lib/passlib.hash.md5_crypt.rst +++ b/docs/lib/passlib.hash.md5_crypt.rst @@ -1,8 +1,8 @@ ================================================================== -:mod:`passlib.hash.md5_crypt` - MD5 Crypt +:mod:`passlib.drivers.md5_crypt` - MD5 Crypt ================================================================== -.. module:: passlib.hash.md5_crypt +.. module:: passlib.drivers.md5_crypt :synopsis: MD5 Crypt This algorithm was developed to replace the aging des-crypt. @@ -13,13 +13,13 @@ algorithm which it's based around is considered broken, though pre-image attacks are currently only theoretical. Despite this, MD5-Crypt itself is not considered broken, and is still considered ok to use, though new applications -should use a stronger scheme (eg :mod:`~passlib.hash.sha512_crypt`) if possible. +should use a stronger scheme (eg :mod:`~passlib.drivers.sha512_crypt`) if possible. Usage ===== This module can be used directly as follows:: - >>> from passlib.hash import md5_crypt as mc + >>> from passlib.drivers.import md5_crypt as mc >>> mc.encrypt("password") #generate new salt, encrypt password '$1$3azHgidD$SrJPt7B.9rekpmwJwtON31' diff --git a/docs/lib/passlib.hash.mysql_323.rst b/docs/lib/passlib.hash.mysql_323.rst index b81acf4..962d780 100644 --- a/docs/lib/passlib.hash.mysql_323.rst +++ b/docs/lib/passlib.hash.mysql_323.rst @@ -1,8 +1,8 @@ ======================================================================== -:mod:`passlib.hash.mysql_323` - MySQL 3.2.3 password hash +:mod:`passlib.drivers.mysql_323` - MySQL 3.2.3 password hash ======================================================================== -.. module:: passlib.hash.mysql_323 +.. module:: passlib.drivers.mysql_323 :synopsis: MySQL 3.2.3 password hash .. warning:: @@ -15,7 +15,7 @@ This module implements the first of MySQL's password hash functions, used to store it's user account passwords. Introduced in MySQL 3.2.3 under the function ``PASSWORD()``, this function was renamed to ``OLD_PASSWORD()`` under MySQL 4.1, when a newer password -hash algorithm was introduced (see :mod:`~passlib.hash.mysql_41`). +hash algorithm was introduced (see :mod:`~passlib.drivers.mysql_41`). Lacking any sort of salt, it's simplistic algorithm amounts to little more than a checksum, and should not be used for *any* purpose but verifying existing MySQL 3.2.3 - 4.0 password hashes. @@ -26,7 +26,7 @@ Users will most likely find the frontends provided by :mod:`passlib.sqldb` to be more useful than accessing this module directly. That aside, this module can be used directly as follows:: - >>> from passlib.hash import mysql_323 as mold + >>> from passlib.drivers.import mysql_323 as mold >>> mold.encrypt("password") #encrypt password '5d2e19393cc5ef67' diff --git a/docs/lib/passlib.hash.mysql_41.rst b/docs/lib/passlib.hash.mysql_41.rst index 85a0b71..894a700 100644 --- a/docs/lib/passlib.hash.mysql_41.rst +++ b/docs/lib/passlib.hash.mysql_41.rst @@ -1,8 +1,8 @@ ===================================================================== -:mod:`passlib.hash.mysql_41` - MySQL 4.1 password hash +:mod:`passlib.drivers.mysql_41` - MySQL 4.1 password hash ===================================================================== -.. module:: passlib.hash.mysql_41 +.. module:: passlib.drivers.mysql_41 :synopsis: MySQL 4.1 password hash .. warning:: @@ -14,7 +14,7 @@ This module implements the second of MySQL's password hash functions, used to store it's user account passwords. Introduced in MySQL 4.1.1 under the function ``PASSWORD()``, it replaced the previous -algorithm (:mod:`~passlib.hash.mysql_323`) as the default +algorithm (:mod:`~passlib.drivers.mysql_323`) as the default used by MySQL, and is still in active use under MySQL 5. Lacking any sort of salt, and using only 2 rounds of the common SHA1 message digest, it's not very secure, @@ -26,7 +26,7 @@ Usage Users will most likely find the frontends provided by :mod:`passlib.sqldb` to be more useful than accessing this module directly. That aside, this module can be used directly in the same manner -as :mod:`~passlib.hash.mysql_323`. +as :mod:`~passlib.drivers.mysql_323`. Functions ========= diff --git a/docs/lib/passlib.hash.nthash.rst b/docs/lib/passlib.hash.nthash.rst index bb35415..e346cec 100644 --- a/docs/lib/passlib.hash.nthash.rst +++ b/docs/lib/passlib.hash.nthash.rst @@ -1,8 +1,8 @@ ================================================================== -:mod:`passlib.hash.nthash` - Windows NT-HASH for Unix +:mod:`passlib.drivers.nthash` - Windows NT-HASH for Unix ================================================================== -.. module:: passlib.hash.nthash +.. module:: passlib.drivers.nthash :synopsis: Windows NT-HASH for Unix .. warning:: diff --git a/docs/lib/passlib.hash.phpass.rst b/docs/lib/passlib.hash.phpass.rst index 01e2690..6a8b291 100644 --- a/docs/lib/passlib.hash.phpass.rst +++ b/docs/lib/passlib.hash.phpass.rst @@ -1,8 +1,8 @@ ================================================================== -:mod:`passlib.hash.phpass` - PHPass Portable Hash +:mod:`passlib.drivers.phpass` - PHPass Portable Hash ================================================================== -.. module:: passlib.hash.phpass +.. module:: passlib.drivers.phpass :synopsis: PHPass Portable Hash This algorithm is used primarily by PHP software diff --git a/docs/lib/passlib.hash.postgres_md5.rst b/docs/lib/passlib.hash.postgres_md5.rst index bbb6d9c..f3a80bb 100644 --- a/docs/lib/passlib.hash.postgres_md5.rst +++ b/docs/lib/passlib.hash.postgres_md5.rst @@ -1,8 +1,8 @@ ================================================================== -:mod:`passlib.hash.postgres_md5` - PostgreSQL MD5 password hash +:mod:`passlib.drivers.postgres_md5` - PostgreSQL MD5 password hash ================================================================== -.. module:: passlib.hash.postgres_md5 +.. module:: passlib.drivers.postgres_md5 :synopsis: PostgreSQL MD5 password hash .. warning:: @@ -24,7 +24,7 @@ Users will most likely find the frontend provided by :mod:`passlib.sqldb` to be more useful than accessing this module directly. That aside, this module can be used directly as follows:: - >>> from passlib.hash import postgres_md5 as pm + >>> from passlib.drivers.import postgres_md5 as pm >>> pm.encrypt("password", "username") #encrypt password using specified username 'md55a231fcdb710d73268c4f44283487ba2' diff --git a/docs/lib/passlib.hash.rst b/docs/lib/passlib.hash.rst index 74bc40e..0a78718 100644 --- a/docs/lib/passlib.hash.rst +++ b/docs/lib/passlib.hash.rst @@ -1,5 +1,5 @@ ============================================ -:mod:`passlib.hash` - Password Hash Schemes +:mod:`passlib.drivers. - Password Hash Schemes ============================================ .. module:: passlib.hash @@ -15,7 +15,7 @@ While many applications may find it easier to use a :class:`CryptContext` instance, or retreive handlers via :func:`get_crypt_handler`, they can also be imported and used directly from this package: - >>> from passlib.hash import md5_crypt + >>> from passlib.drivers.import md5_crypt >>> hash = md5_crypt.encrypt("password") Passlib contains the following builtin password algorithms: @@ -29,24 +29,24 @@ the :ref:`modular crypt format <modular-crypt-format>`. .. toctree:: :maxdepth: 1 - passlib.hash.des_crypt - passlib.hash.ext_des_crypt - passlib.hash.md5_crypt - passlib.hash.bcrypt - passlib.hash.sha1_crypt - passlib.hash.sha256_crypt - passlib.hash.sha512_crypt + passlib.drivers.des_crypt + passlib.drivers.ext_des_crypt + passlib.drivers.md5_crypt + passlib.drivers.bcrypt + passlib.drivers.sha1_crypt + passlib.drivers.sha256_crypt + passlib.drivers.sha512_crypt .. toctree:: :hidden: - passlib.hash.sun_md5_crypt + passlib.drivers.sun_md5_crypt .. todo:: These aren't fully implemented / tested yet: - * :mod:`~passlib.hash.sun_md5_crypt` - MD5-based scheme used by Solaris 10 (NOT related to md5-crypt above). + * :mod:`~passlib.drivers.sun_md5_crypt` - MD5-based scheme used by Solaris 10 (NOT related to md5-crypt above). Non-Standard Unix-Compatible Schemes ------------------------------------ @@ -58,9 +58,9 @@ the modular crypt format. .. toctree:: :maxdepth: 1 - passlib.hash.apr_md5_crypt - passlib.hash.phpass - passlib.hash.nthash + passlib.drivers.apr_md5_crypt + passlib.drivers.phpass + passlib.drivers.nthash Other Schemes ------------- @@ -71,6 +71,6 @@ not seen outside those specific contexts: .. toctree:: :maxdepth: 1 - passlib.hash.mysql_323 - passlib.hash.mysql_41 - passlib.hash.postgres_md5 + passlib.drivers.mysql_323 + passlib.drivers.mysql_41 + passlib.drivers.postgres_md5 diff --git a/docs/lib/passlib.hash.sha1_crypt.rst b/docs/lib/passlib.hash.sha1_crypt.rst index e9b01b5..3f753e7 100644 --- a/docs/lib/passlib.hash.sha1_crypt.rst +++ b/docs/lib/passlib.hash.sha1_crypt.rst @@ -1,8 +1,8 @@ =================================================================== -:mod:`passlib.hash.sha1_crypt` - SHA-1 Crypt +:mod:`passlib.drivers.sha1_crypt` - SHA-1 Crypt =================================================================== -.. module:: passlib.hash.sha1_crypt +.. module:: passlib.drivers.sha1_crypt :synopsis: SHA-1 Crypt SHA1-Crypt is a hash algorithm introduced by NetBSD in 2004. @@ -12,7 +12,7 @@ and supports a large salt and variable number of rounds. Usage ===== Supporting a variable sized salt and variable number of rounds, -this scheme is used in exactly the same way as :mod:`~passlib.hash.sha512_crypt`. +this scheme is used in exactly the same way as :mod:`~passlib.drivers.sha512_crypt`. Functions ========= @@ -54,7 +54,7 @@ as well as providing some of the advancements made in PDKDF2). * the checksum is then rendered into hash-64 format using an ordering that roughly corresponds to big-endian - encoding of 24-bit chunks (see :data:`passlib.hash.sha1_crypt._chk_offsets` for exact byte order). + encoding of 24-bit chunks (see :data:`passlib.drivers.sha1_crypt._chk_offsets` for exact byte order). Deviations ========== diff --git a/docs/lib/passlib.hash.sha256_crypt.rst b/docs/lib/passlib.hash.sha256_crypt.rst index d709c84..064d4ff 100644 --- a/docs/lib/passlib.hash.sha256_crypt.rst +++ b/docs/lib/passlib.hash.sha256_crypt.rst @@ -1,11 +1,11 @@ ================================================================== -:mod:`passlib.hash.sha256_crypt` - SHA-256 Crypt +:mod:`passlib.drivers.sha256_crypt` - SHA-256 Crypt ================================================================== -.. module:: passlib.hash.sha526_crypt +.. module:: passlib.drivers.sha526_crypt :synopsis: SHA-256 Crypt -This scheme is identical to :mod:`~passlib.hash.sha512_crypt` in almost every way, +This scheme is identical to :mod:`~passlib.drivers.sha512_crypt` in almost every way, they are defined by the same specification and have the same design and structure, except the following differences: @@ -13,4 +13,4 @@ except the following differences: * it uses SHA-256 as it's internal hash function instead of SHA-512. * it's output hash is correspondingly smaller. -For details about this module, see :mod:`~passlib.hash.sha512_crypt`. +For details about this module, see :mod:`~passlib.drivers.sha512_crypt`. diff --git a/docs/lib/passlib.hash.sha512_crypt.rst b/docs/lib/passlib.hash.sha512_crypt.rst index cdf4e23..eb1b77a 100644 --- a/docs/lib/passlib.hash.sha512_crypt.rst +++ b/docs/lib/passlib.hash.sha512_crypt.rst @@ -1,12 +1,12 @@ =================================================================== -:mod:`passlib.hash.sha512_crypt` - SHA-512 Crypt +:mod:`passlib.drivers.sha512_crypt` - SHA-512 Crypt =================================================================== -.. module:: passlib.hash.sha512_crypt +.. module:: passlib.drivers.sha512_crypt :synopsis: SHA-512 Crypt SHA-512 Crypt and SHA-256 Crypt were developed as a response -to :mod:`~passlib.hash.bcrypt`. They are descendants of :mod:`~passlib.hash.md5_crypt`, +to :mod:`~passlib.drivers.bcrypt`. They are descendants of :mod:`~passlib.drivers.md5_crypt`, and incorporate many changes: replaced MD5 with newer message digest algorithms, some internal cleanups in MD5-Crypt's rounds algorithm, and the introduction of a variable rounds parameter. diff --git a/docs/lib/passlib.hash.sun_md5_crypt.rst b/docs/lib/passlib.hash.sun_md5_crypt.rst index 393c9c2..5703988 100644 --- a/docs/lib/passlib.hash.sun_md5_crypt.rst +++ b/docs/lib/passlib.hash.sun_md5_crypt.rst @@ -1,8 +1,8 @@ =============================================================== -:mod:`passlib.hash.sun_md5_crypt` - Sun MD5 Crypt password hash +:mod:`passlib.drivers.sun_md5_crypt` - Sun MD5 Crypt password hash =============================================================== -.. module:: passlib.hash.sun_md5_crypt +.. module:: passlib.drivers.sun_md5_crypt :synopsis: Sun MD5 Crypt .. warning:: @@ -16,7 +16,7 @@ This algorithm is used by Solaris, as a replacement for the aging des-crypt. It is mainly used on later versions of Solaris, and is not found many other places. While based on the MD5 message digest, it has very little at all -in common with the :mod:`~passlib.hash.md5_crypt` algorithm. It supports +in common with the :mod:`~passlib.drivers.md5_crypt` algorithm. It supports 32 bit variable rounds and an 8 character salt. Due to a theoretic pre-image attacks on the MD5 message digest, this algorithm should probably not be used in new deploys. @@ -25,7 +25,7 @@ Usage ===== This module supports both rounds and salts, and so can be used in the exact same manner -as :mod:`~passlib.hash.sha512_crypt`. +as :mod:`~passlib.drivers.sha512_crypt`. Functions ========= @@ -73,8 +73,8 @@ by one of the creators). Given a password, the number of rounds, and a salt... data string, along with the current iteration number as an ascii string. - if a 0, the same as 1, except that magic constant data is not included. -* The final checksum is then encoded into :mod:`hash64 <~passlib.hash.h64>` using the same - transposed byte order that :mod:`~passlib.hash.md5_crypt` uses. +* The final checksum is then encoded into :mod:`hash64 <~passlib.drivers.h64>` using the same + transposed byte order that :mod:`~passlib.drivers.md5_crypt` uses. The constant data string is referenced above is a 1517 byte ascii string... an excerpt from Hamlet, starting with ``To be, or not to be...`` and ending with ``...all my sins remember'd.\n``, diff --git a/docs/lib/passlib.sqldb.rst b/docs/lib/passlib.sqldb.rst index 0520f30..5422889 100644 --- a/docs/lib/passlib.sqldb.rst +++ b/docs/lib/passlib.sqldb.rst @@ -13,7 +13,7 @@ which should be capable of recognizing passwords in modern postgres systems: .. object:: postgres_context This object should recognize password hashes stores in postgres' pg_shadow table. - it can recognize :mod:`~passlib.hash.postgres_md5` hashes, + it can recognize :mod:`~passlib.drivers.postgres_md5` hashes, as well as plaintext hashes. It defaults to postgres_md5 when generating new hashes. @@ -26,11 +26,11 @@ for handling MySQL user passwords: .. object:: mysql_context - This object should recognize the new :mod:`~passlib.hash.mysql_41` hashes, - as well as any legacy :mod:`~passlib.hash.mysql_323` hashes. + This object should recognize the new :mod:`~passlib.drivers.mysql_41` hashes, + as well as any legacy :mod:`~passlib.drivers.mysql_323` hashes. It defaults to mysql_41 when generating new hashes. .. object:: mysql3_context This object is for use with older MySQL deploys which only recognize - the :mod:`~passlib.hash.mysql_323` hash. + the :mod:`~passlib.drivers.mysql_323` hash. diff --git a/docs/lib/passlib.unix.rst b/docs/lib/passlib.unix.rst index 4e59714..637db43 100644 --- a/docs/lib/passlib.unix.rst +++ b/docs/lib/passlib.unix.rst @@ -13,19 +13,19 @@ tailor to the hashes supported on various unix systems. .. object:: linux_context this should recognize the hashes used on most linux systems: - :mod:`~passlib.hash.des_crypt`, - :mod:`~passlib.hash.md5_crypt`, - :mod:`~passlib.hash.sha256_crypt`, and - :mod:`~passlib.hash.sha512_crypt` (used as the default). + :mod:`~passlib.drivers.des_crypt`, + :mod:`~passlib.drivers.md5_crypt`, + :mod:`~passlib.drivers.sha256_crypt`, and + :mod:`~passlib.drivers.sha512_crypt` (used as the default). .. object:: bsd_context this should recognize the hashes used on most bsd systems: - :mod:`~passlib.hash.des_crypt`, - :mod:`~passlib.hash.ext_des_crypt`, - :mod:`~passlib.hash.nthash`, - :mod:`~passlib.hash.md5_crypt`, - :mod:`~passlib.hash.bcrypt` (used as the default). + :mod:`~passlib.drivers.des_crypt`, + :mod:`~passlib.drivers.ext_des_crypt`, + :mod:`~passlib.drivers.nthash`, + :mod:`~passlib.drivers.md5_crypt`, + :mod:`~passlib.drivers.bcrypt` (used as the default). .. note:: @@ -47,7 +47,7 @@ Usage Modular Crypt Format ==================== A vast majority of the schemes used on unix systems (and supported by this library) -follow the "Modular Crypt Format", introduced around the time :mod:`~passlib.hash.md5_crypt` was developed. +follow the "Modular Crypt Format", introduced around the time :mod:`~passlib.drivers.md5_crypt` was developed. This scheme allows hashes generates by multiple schemes to co-exist within a database, by requiring that all hash string begin with a unique prefix ``$identifier$``; where ``identifier`` is a short alphanumeric string globally identifying @@ -63,7 +63,7 @@ In fact, for the most part they avoid using any characters except this can be violated on some systems if the user intervenes. .. note:: - :mod:`passlib.hash.des_crypt` and :mod:`passlib.hash.ext_des_crypt` + :mod:`passlib.drivers.des_crypt` and :mod:`passlib.drivers.ext_des_crypt` do not follow this protocol, since they predate it by many years. OS Format Support @@ -74,12 +74,12 @@ are known to support which schemes: =================================== =========== =========== =========== =========== Scheme Linux FreeBSD NetBSD OpenBSD =================================== =========== =========== =========== =========== -:mod:`~passlib.hash.nthash` y -:mod:`~passlib.hash.des_crypt` y y y y -:mod:`~passlib.hash.ext_des_crypt` y y -:mod:`~passlib.hash.md5_crypt` y y y y -:mod:`~passlib.hash.bcrypt` y y y -:mod:`~passlib.hash.sha1_crypt` y -:mod:`~passlib.hash.sha256_crypt` y -:mod:`~passlib.hash.sha512_crypt` y +:mod:`~passlib.drivers.nthash` y +:mod:`~passlib.drivers.des_crypt` y y y y +:mod:`~passlib.drivers.ext_des_crypt` y y +:mod:`~passlib.drivers.md5_crypt` y y y y +:mod:`~passlib.drivers.bcrypt` y y y +:mod:`~passlib.drivers.sha1_crypt` y +:mod:`~passlib.drivers.sha256_crypt` y +:mod:`~passlib.drivers.sha512_crypt` y =================================== =========== =========== =========== =========== diff --git a/docs/lib/passlib.utils.des.rst b/docs/lib/passlib.utils.des.rst index 337e4d1..11d6f76 100644 --- a/docs/lib/passlib.utils.des.rst +++ b/docs/lib/passlib.utils.des.rst @@ -15,7 +15,7 @@ This module contains routines for encrypting blocks of data using the DES algori They do not support multi-block operation or decryption, since they are designed for use in password hash algorithms -such as :mod:`~passlib.hash.des_crypt` and :mod:`~passlib.hash.ext_des_crypt`. +such as :mod:`~passlib.drivers.des_crypt` and :mod:`~passlib.drivers.ext_des_crypt`. .. autofunction:: expand_des_key .. autofunction:: des_encrypt_block diff --git a/docs/lib/passlib.utils.rst b/docs/lib/passlib.utils.rst index 5d7d067..0465310 100644 --- a/docs/lib/passlib.utils.rst +++ b/docs/lib/passlib.utils.rst @@ -59,4 +59,4 @@ There are also a few sub modules which provide additional utility functions: document this module... - passlib.utils.handlers + passlib.utils.drivers diff --git a/docs/password_hash_api.rst b/docs/password_hash_api.rst index 3c86b84..084a669 100644 --- a/docs/password_hash_api.rst +++ b/docs/password_hash_api.rst @@ -23,7 +23,7 @@ and other parts have been kept intentionally non-commital, in order to allow flexibility of implementation. All of the schemes built into passlib implement this interface; -most them as modules within the :mod:`passlib.hash` package. +most them as modules within the :mod:`passlib.drivers. package. Overview ======== @@ -66,7 +66,7 @@ Informational Attributes All handlers built into passlib are implemented as modules whose path corresponds to the name, with an underscore replacing the hyphen. - For example, ``des-crypt`` is stored as the module ``passlib.hash.des_crypt``. + For example, ``des-crypt`` is stored as the module ``passlib.drivers.des_crypt``. .. attribute:: setting_kwds |
