Display invalid hosts
This commit is contained in:
parent
2f7bfa95b2
commit
e9ce137e14
1 changed files with 2 additions and 2 deletions
|
@ -67,7 +67,7 @@ class UiRequest(object):
|
||||||
|
|
||||||
# Check if host allowed to do request
|
# Check if host allowed to do request
|
||||||
if not self.isHostAllowed(self.env.get("HTTP_HOST")):
|
if not self.isHostAllowed(self.env.get("HTTP_HOST")):
|
||||||
return self.error403("Invalid host", details=False)
|
return self.error403("Invalid host: %s" % self.env.get("HTTP_HOST"), details=False)
|
||||||
|
|
||||||
path = re.sub("^http://zero[/]+", "/", path) # Remove begining http://zero/ for chrome extension
|
path = re.sub("^http://zero[/]+", "/", path) # Remove begining http://zero/ for chrome extension
|
||||||
path = re.sub("^http://", "/", path) # Remove begining http for chrome extension .bit access
|
path = re.sub("^http://", "/", path) # Remove begining http for chrome extension .bit access
|
||||||
|
@ -622,7 +622,7 @@ class UiRequest(object):
|
||||||
return """
|
return """
|
||||||
<h1>%s</h1>
|
<h1>%s</h1>
|
||||||
<h2>%s</h3>
|
<h2>%s</h3>
|
||||||
""" % (title, message)
|
""" % (title, cgi.escape(message))
|
||||||
|
|
||||||
|
|
||||||
# - Reload for eaiser developing -
|
# - Reload for eaiser developing -
|
||||||
|
|
Loading…
Reference in a new issue