mirror of
https://github.com/rr-/szurubooru.git
synced 2025-07-17 08:26:24 +00:00
server/func/posts: explicity specify MD5 for post security hash
This commit is contained in:
@ -88,7 +88,8 @@ FLAG_MAP = {
|
||||
def get_post_security_hash(id: int) -> str:
|
||||
return hmac.new(
|
||||
config.config['secret'].encode('utf8'),
|
||||
str(id).encode('utf-8')).hexdigest()[0:16]
|
||||
msg=str(id).encode('utf-8'),
|
||||
digestmod='md5').hexdigest()[0:16]
|
||||
|
||||
|
||||
def get_post_content_url(post: model.Post) -> str:
|
||||
|
Reference in New Issue
Block a user