Blasta/blasta/utilities/cryptography.py

13 lines
270 B
Python
Raw Normal View History

#!/usr/bin/python
# -*- coding: utf-8 -*-
import hashlib
class UtilitiesCryptography:
def hash_url_to_md5(url):
url_encoded = url.encode()
url_hashed = hashlib.md5(url_encoded)
url_digest = url_hashed.hexdigest()
return url_digest