Finalize migration tool.

Retrieve comments by GET and POST
This commit is contained in:
Yax 2015-05-03 18:31:15 +02:00
parent 4c4ee442d3
commit 612fb85fa3
5 changed files with 53 additions and 27 deletions

16
app/helpers/hashing.py Normal file
View file

@ -0,0 +1,16 @@
#!/usr/bin/python
# -*- coding: UTF-8 -*-
import hashlib
import config
def salt(value):
string = '%s%s' % (value, config.SALT)
dk = hashlib.sha256(string.encode())
return dk.hexdigest()
def md5(value):
dk = hashlib.md5(value.encode())
return dk.hexdigest()