mirror of
https://github.com/evennia/evennia.git
synced 2026-03-27 18:26:32 +01:00
Printing traces to the user is usually bad.
This could, in theory, expose more information about how the server works than would be advised, benefiting potential attackers.
This commit is contained in:
parent
f890c8bddb
commit
acdf2573b0
3 changed files with 4 additions and 8 deletions
|
|
@ -140,8 +140,7 @@ class CmdUnconnectedConnect(MuxCommand):
|
|||
# We are in the middle between logged in and -not, so we have
|
||||
# to handle tracebacks ourselves at this point. If we don't,
|
||||
# we won't see any errors at all.
|
||||
string = "%s\nThis is a bug. Please e-mail an admin if the problem persists."
|
||||
session.msg(string % (traceback.format_exc()))
|
||||
session.msg("An error occurred. Please e-mail an admin if the problem persists.")
|
||||
logger.log_errmsg(traceback.format_exc())
|
||||
finally:
|
||||
return
|
||||
|
|
@ -287,8 +286,7 @@ class CmdUnconnectedCreate(MuxCommand):
|
|||
# We are in the middle between logged in and -not, so we have
|
||||
# to handle tracebacks ourselves at this point. If we don't,
|
||||
# we won't see any errors at all.
|
||||
string = "%s\nThis is a bug. Please e-mail an admin if the problem persists."
|
||||
session.msg(string % (traceback.format_exc()))
|
||||
session.msg("An error occurred. Please e-mail an admin if the problem persists.")
|
||||
logger.log_errmsg(traceback.format_exc())
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -257,8 +257,7 @@ its and @/./+/-/_ only.") # this echoes the restrictions made by django's auth m
|
|||
# We are in the middle between logged in and -not, so we have
|
||||
# to handle tracebacks ourselves at this point. If we don't,
|
||||
# we won't see any errors at all.
|
||||
string = "%s\nThis is a bug. Please e-mail an admin if the problem persists."
|
||||
session.msg(string % (traceback.format_exc()))
|
||||
session.msg("An error occurred. Please e-mail an admin if the problem persists.")
|
||||
logger.log_errmsg(traceback.format_exc())
|
||||
|
||||
class CmdUnconnectedQuit(MuxCommand):
|
||||
|
|
|
|||
|
|
@ -235,8 +235,7 @@ class CmdPasswordCreate(Command):
|
|||
# We are in the middle between logged in and -not, so we have
|
||||
# to handle tracebacks ourselves at this point. If we don't, we
|
||||
# won't see any errors at all.
|
||||
string = "%s\nThis is a bug. Please e-mail an admin if the problem persists."
|
||||
self.caller.msg(string % (traceback.format_exc()))
|
||||
self.caller.msg("An error occurred. Please e-mail an admin if the problem persists."
|
||||
logger.log_errmsg(traceback.format_exc())
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue