@amzn_request_id
def key_or_control_response(self, request, full_url, headers):
    self.method = request.method
    self.path = self._get_path(request)
    self.headers = request.headers
    if ('host' not in self.headers):
        self.headers['host'] = urlparse(full_url).netloc
    response_headers = {}
    try:
        if (isinstance(request, AWSPreparedRequest) and ('s3-control' in request.url)):
            response = self._control_response(request, full_url, headers)
        else:
            response = self._key_response(request, full_url, self.headers)
    except S3ClientError as s3error:
        response = (s3error.code, {}, s3error.description)
    if isinstance(response, str):
        status_code = 200
        response_content = response
    else:
        (status_code, response_headers, response_content) = response
    if ((status_code == 200) and ('range' in request.headers) and (request.headers['range'] != '')):
        try:
            return self._handle_range_header(request, response_headers, response_content)
        except S3ClientError as s3error:
            return (s3error.code, {}, s3error.description)
    return (status_code, response_headers, response_content)
@amzn_request_id
def key_or_control_response(self, request, full_url, headers):
    self.method = request.method
    self.path = self._get_path(request)
    self.headers = request.headers
    if ('host' not in self.headers):
        self.headers['host'] = urlparse(full_url).netloc
    response_headers = {}
    try:
        if (isinstance(request, AWSPreparedRequest) and ('s3-control' in request.url)):
            response = self._control_response(request, full_url, headers)
        else:
            response = self._key_response(request, full_url, self.headers)
    except S3ClientError as s3error:
        response = (s3error.code, {}, s3error.description)
    if isinstance(response, str):
        status_code = 200
        response_content = response
    else:
        (status_code, response_headers, response_content) = response
    if ((status_code == 200) and ('range' in request.headers) and (request.headers['range'] != )):
        try:
            return self._handle_range_header(request, response_headers, response_content)
        except S3ClientError as s3error:
            return (s3error.code, {}, s3error.description)
    return (status_code, response_headers, response_content)