mirror of https://github.com/scrapy/scrapy.git
bandit: ignore md5 usage for download slot names
This commit is contained in:
parent
2bfd9a2257
commit
31cbbb5758
|
|
@ -20,7 +20,7 @@ def _path_safe(text):
|
|||
pathable_slot = "".join([c if c.isalnum() or c in "-._" else "_" for c in text])
|
||||
# as we replace some letters we can get collision for different slots
|
||||
# add we add unique part
|
||||
unique_slot = hashlib.md5(text.encode("utf8")).hexdigest()
|
||||
unique_slot = hashlib.md5(text.encode("utf8")).hexdigest() # nosec
|
||||
return "-".join([pathable_slot, unique_slot])
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue