##// END OF EJS Templates
don't use Origin header to determine ws_url
MinRK -
Show More
@@ -144,10 +144,11 b' class AuthenticatedHandler(web.RequestHandler):'
144 def ws_url(self):
144 def ws_url(self):
145 """websocket url matching the current request
145 """websocket url matching the current request
146
146
147 turns http[s]://host[:port]/foo/bar into
147 turns http[s]://host[:port] into
148 ws[s]://host[:port]/foo/bar
148 ws[s]://host[:port]
149 """
149 """
150 return self.request.headers.get('Origin').replace('http', 'ws', 1)
150 proto = self.request.protocol.replace('http', 'ws')
151 return "%s://%s" % (proto, self.request.host)
151
152
152
153
153 class ProjectDashboardHandler(AuthenticatedHandler):
154 class ProjectDashboardHandler(AuthenticatedHandler):
General Comments 0
You need to be logged in to leave comments. Login now