def _validate_request(self): check_connect_method(self._request) validate_mandatory_header(self._request, ':protocol', 'websocket') get_mandatory_header(self._request, 'authority')
def _validate_request(self): check_request_line(self._request) validate_mandatory_header(self._request, common.UPGRADE_HEADER, common.WEBSOCKET_UPGRADE_TYPE) self._validate_connection_header() unused_host = get_mandatory_header(self._request, common.HOST_HEADER)