slightly stronger email protection
This commit is contained in:
parent
9ff45581d9
commit
a87eb14ebc
1 changed files with 6 additions and 2 deletions
|
@ -14,6 +14,8 @@ from modules import Set
|
|||
from modules import markdown
|
||||
from modules.Common import *
|
||||
|
||||
KnownCookies = []
|
||||
|
||||
def guess_type(path):
|
||||
|
||||
if "/json/" in path or ".json" in path:
|
||||
|
@ -37,7 +39,9 @@ def headers(server, code):
|
|||
server.send_header("Content-type", guess_type(server.path))
|
||||
|
||||
if not server.cookie:
|
||||
server.send_header("Set-Cookie", "temp_id="+RandString())
|
||||
cookie = RandString()
|
||||
KnownCookies.append(cookie)
|
||||
server.send_header("Set-Cookie", "temp_id="+cookie)
|
||||
|
||||
server.end_headers()
|
||||
|
||||
|
@ -691,7 +695,7 @@ def AccountPage(server, account):
|
|||
html = html + '</center>'
|
||||
|
||||
# Protecting emails and stuff from scrubbers
|
||||
if len(str(server.cookie)) == 50:
|
||||
if server.cookie in KnownCookies:
|
||||
|
||||
# Website
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue