summaryrefslogtreecommitdiff
path: root/passlib/apache.py
diff options
context:
space:
mode:
authorEli Collins <elic@assurancetechnologies.com>2011-01-28 06:35:56 +0000
committerEli Collins <elic@assurancetechnologies.com>2011-01-28 06:35:56 +0000
commitfea8e73c8e9bef3e9423af50c128cb20e7813b09 (patch)
tree984691ea244b83ff9cbc8d8692f66f00142f62b9 /passlib/apache.py
parentbc738f4c6e35a31c9edd5fb54f13773e15978a09 (diff)
downloadpasslib-fea8e73c8e9bef3e9423af50c128cb20e7813b09.tar.gz
wow. lots of rearranging
======================== * back to 1.2 structure * moved h64 helpers into utils.h64 module * pared down CryptHandler * tightened UTs somewhat
Diffstat (limited to 'passlib/apache.py')
-rw-r--r--passlib/apache.py27
1 files changed, 26 insertions, 1 deletions
diff --git a/passlib/apache.py b/passlib/apache.py
index b12d9d1..6522b47 100644
--- a/passlib/apache.py
+++ b/passlib/apache.py
@@ -2,7 +2,32 @@
apache support
http://httpd.apache.org/docs/2.2/misc/password_encryptions.html
-
+http://httpd.apache.org/docs/2.0/programs/htpasswd.html
NOTE: digest format is md5(user ":" realm ":" passwd).hexdigest()
file is "user:realm:hash"
"""
+#=========================================================
+#imports
+#=========================================================
+from __future__ import with_statement
+#core
+import logging; log = logging.getLogger(__name__)
+#site
+#libs
+from passlib.hash import postgres_md5
+from passlib.context import CryptContext
+#pkg
+#local
+__all__ = [
+ 'postgres_md5',
+ 'postgres_context',
+]
+
+#=========================================================
+#db contexts
+#=========================================================
+postgres_context = CryptContext([postgres_md5])
+
+#=========================================================
+# eof
+#=========================================================