Bug 1385485 - 404 ends in \n instead of \r\n, causing errors in some libraries
Summary: 404 ends in \n instead of \r\n, causing errors in some libraries
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Ceph Storage
Classification: Red Hat Storage
Component: RGW
Version: 2.1
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: rc
: 2.2
Assignee: Marcus Watts
QA Contact: shilpa
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-10-17 07:44 UTC by JuanJose Galvez
Modified: 2022-02-21 18:17 UTC (History)
13 users (show)

Fixed In Version: RHEL: ceph-10.2.5-13.el7cp Ubuntu: ceph_10.2.5-7redhat1xenial
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-03-14 15:45:50 UTC
Embargoed:


Attachments (Terms of Use)
Wireshark showing \n instead of \r\n at end of 404 response (289.36 KB, image/png)
2016-10-17 07:44 UTC, JuanJose Galvez
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Ceph Project Bug Tracker 18473 0 None None None 2017-03-22 20:43:26 UTC
Red Hat Product Errata RHBA-2017:0514 0 normal SHIPPED_LIVE Red Hat Ceph Storage 2.2 bug fix and enhancement update 2017-03-21 07:24:26 UTC

Description JuanJose Galvez 2016-10-17 07:44:57 UTC
Created attachment 1211237 [details]
Wireshark showing \n instead of \r\n at end of 404 response

Description of problem:

The Go (1.7.1) language net.http library is strict and is throwing an error when an extra \n is returned by the radosgw. We can find the extra \n at the end of a 404. Please see the attached image.

Steps to Reproduce:
1. Access a 404 response from the radosgw
2. See the extra \n at the end of the response.

Actual results:

\n is an invalid ending, causing an error in strict language libraries. In Go's net.http library the following error is seen:

Unsolicited response received on idle HTTP channel starting with "\n"; err=<nil>

Expected results:

\r\n would be considered valid.

Comment 15 Matt Benjamin (redhat) 2017-01-26 20:20:32 UTC
Fix merged to upstream as 

commit 5f229d6a33eae4906f22cdb90941835e47ee9f02
Author: Marcus Watts <mwatts>
Date:   Wed Jan 11 00:06:15 2017 -0500

    radosgw/swift: clean up flush / newline behavior.

Scheduled for jewel backport.

Comment 26 shilpa 2017-02-22 09:05:25 UTC
Verified on 10.2.5-27

Comment 28 errata-xmlrpc 2017-03-14 15:45:50 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2017-0514.html


Note You need to log in before you can comment on or make changes to this bug.