Added an option for blocking public non-https requests
This commit is contained in:
+2
-1
@@ -6,7 +6,7 @@ from tornado.options import options
|
||||
from webssh.handler import IndexHandler, WsockHandler, NotFoundHandler
|
||||
from webssh.settings import (
|
||||
get_app_settings, get_host_keys_settings, get_policy_setting,
|
||||
get_ssl_context, get_server_settings
|
||||
get_ssl_context, get_server_settings, detect_is_open_to_public
|
||||
)
|
||||
|
||||
|
||||
@@ -40,6 +40,7 @@ def main():
|
||||
app.listen(options.sslport, options.ssladdress, **server_settings)
|
||||
logging.info('Listening on ssl {}:{}'.format(options.ssladdress,
|
||||
options.sslport))
|
||||
detect_is_open_to_public(options)
|
||||
loop.start()
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user