- Nov 23, 2016
-
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
--HG-- branch : stable
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
which doesn't use deprecated inspect.getargspec()
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
modify PrefixWrapper to proxy _salt_is_bytes flag.
-
- Nov 22, 2016
-
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
now stored in public Hash.deprecated attr of returned hashers, instead of monkeypatching Hash.needs_update(). this removes some cruft from a bunch of places.
-
Eli Collins authored
passlib.ext.django ------------------ * everything in .models relocated to the DjangoContextAdapter() class in .utils. all that's left in models is a couple of hooks. This consolidates all the model state into a single object, making it a lot easier to inspect and optimize. * consolidated a bunch of (undocumented) helper functions into DjangoTranslator() class, which now acts as based for DjangoContextAdapter. Translator instances handle converted passlib <-> django hashers, including caching speed-critical bits. * wrapper class now has guards against wrong type of hasher being passed in * wrapper class uses .using() instead of deprecated .hash(**kwds) format. * updated and confirmed passing tests w/ django 1.10.3 passlib.ext.django tests ------------------------ * split test wrapper for django's internal tests (HashersTest) into separate file, test_ext_django_source.py, to make it easier to run independantly. reworked to use patchAttr(wraps=True) rather than less flexible ContextHook() hack * tries to clean up HashersTest - adapts to django settings, fixed code syncing .iteration settings back to passlib hashers, * blocked out some django tests that we can't / won't pass, documented reasons why. other ----- * CryptContext: added temporary hack to access unpatched Hasher.needs_update() method. * PrefixWrapper: now proxies attr writes if it owns the wrapped hasher. * test utils: added wrap=True support to patchAttr(), for wrapping arbitrary functions.
-
Eli Collins authored
* added django_argon2 wrapper & docs * added method for PrefixWrapper to generically preserve custom attrs when creating variants, so .django_name attr is persisted across .using() calls.
-
- Nov 21, 2016
-
-
Eli Collins authored
in reproducible manner. * added TestCase.getRandom() helper, which creates RNG initialized from ${RANDOM_TEST_SEED} or ${PYTHONHASHSEED} when possible, and logs the seed so that exact test can be reproduced in future. * replaced all test references to 'passlib.utils.rng' or other random source with TestCase().getRandom() call. * once remaining bit was all the hash fuzz tests. since these are called over multiple threads, would either have to pass around a per-thread RNG to every call, or refactor fuzz generator into separate class, so we could make a separate instance per thread. latter choice seemed generally cleaner anyways, so... * Refactored fuzz generator methods into FuzzHashGeneator class. - Uses separate RNG per thread, seeded from .getRandom() using thread name. - removed class-scanning magic, now uses explicit lists of verifiers & parameter generation helpers.
-
Eli Collins authored
To resolve issue #82, getrandbytes() UT reworked to use fixed set of random set values. This removes change of errant false positives, but makes sure it still gets checked across a few different inputs.
-
Eli Collins authored
until a default scheme that would be affects is actually used.
-
Eli Collins authored
-
Eli Collins authored
-
- Nov 20, 2016
-
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
* moved a bunch of pages into 'docs/narr' narrative subsection. added placeholder pages in old locations, to minimize inbound link breakage. * split history into separate pages, was getting way too long. removed toplevel CHANGES file, not feasible under new structure. * passlib.ifc split into reference & tutorial portions, tutorial allowed subsuming a bunch of other hash-usage examples. * added standard fragments for warning about insecure hashes, added them to top of a LOT of hash doc pages. * updated references, various layout tweaks
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
-
Eli Collins authored
-
- Nov 19, 2016
-
-
Eli Collins authored
-
Eli Collins authored
UsedTokenError now has a default message.
-
Eli Collins authored
Expanded preset aliases to make it easier to pick desired behavior for htpasswd_context; picks strongest available hash for various different purposes: whether using apache 2.2 / 2.4, and whether output should be host-specific or portable.
-
Eli Collins authored
* moved has_active_backend() from UTs to .registry * moved os_crypt backend support helper from .hosts to .registry
-
Eli Collins authored
-
- Nov 11, 2016
-
-
Eli Collins authored
Issue for a while has been that IDEs such as PyCharm can't detect autocompletion in 'passlib.hash', because the module is replaced w/ a lazy-loading object, that breaks it's source inspection. As workaround, that module now contains a block listing all the imports explicitly. This block is trapped in a "if False:" block so it will do nothing, but that seems sufficient for PyCharm to autocomplete with. Script "admin/regen.py" can be used to autogenerate this list when registry.py changes.
-