diff options
| author | Michael Merickel <michael@merickel.org> | 2024-01-28 23:17:29 -0700 |
|---|---|---|
| committer | Michael Merickel <michael@merickel.org> | 2024-01-28 23:17:29 -0700 |
| commit | 43e66c6415d6397b0ee93d64dc80c742072f3ada (patch) | |
| tree | f08894d9c026f3c30c25e7aefc7a2c74e48086ac /src | |
| parent | 3d640f43403d7ed8b796d4c825886f591afee5a1 (diff) | |
| download | pyramid-43e66c6415d6397b0ee93d64dc80c742072f3ada.tar.gz pyramid-43e66c6415d6397b0ee93d64dc80c742072f3ada.tar.bz2 pyramid-43e66c6415d6397b0ee93d64dc80c742072f3ada.zip | |
upgrade phash implementation from md5 to sha256
Diffstat (limited to 'src')
| -rw-r--r-- | src/pyramid/config/predicates.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/pyramid/config/predicates.py b/src/pyramid/config/predicates.py index db5df0347..15d990b95 100644 --- a/src/pyramid/config/predicates.py +++ b/src/pyramid/config/predicates.py @@ -1,4 +1,4 @@ -from hashlib import md5 +from hashlib import sha256 from webob.acceptparse import Accept from pyramid.exceptions import ConfigurationError @@ -8,7 +8,7 @@ from pyramid.registry import predvalseq from pyramid.util import TopologicalSorter, bytes_, is_nonstr_iter MAX_ORDER = 1 << 30 -DEFAULT_PHASH = md5().hexdigest() +DEFAULT_PHASH = sha256().hexdigest() class PredicateConfiguratorMixin: @@ -137,7 +137,7 @@ class PredicateList: # phash) that can be used by a caller to identify identical predicate # lists. ordered = self.sorter.sorted() - phash = md5() + phash = sha256() weights = [] preds = [] info = PredicateInfo( |
