tracker issue : CF-3198173

select a category, or use search below
(searches all categories and all time range)

cfhttp fails to dezip requests that are gzipped

| View in Tracker

Status/Resolution/Reason: Closed/Withdrawn/CannotReproduce

Reporter/Name(from Bugbase): Raymond Camden / Raymond Camden (Raymond Camden)

Created: 05/24/2012

Components: Net Protocols, HTTP

Versions: 10.0

Failure Type: Data Corruption

Found In Build/Fixed In Build: Final / 282554

Priority/Frequency: Critical / Some users will encounter

Locale/System: English / Windows 7 64-bit

Vote Count: 1

That title is probably wrong, but here goes...

Check out this blog entry:

It describes a workaround for cffeed and gzipped RSS resources. I made use of the workaround only (ie, not try/catch) at CFBloggers and it worked fine.

However - in CF10 I can confirm it fails. When CFHTTP hits the url and stores the results, it is NOT unzipping it. So you end up with junk that can't be parsed. 

I can work around this for CFB, but obviously it could be a bad issue for cfhttp.

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3198173

External Customer Info:
External Company:  
External Customer Name: cfjedimaster
External Customer Email:  
External Test Config: My Hardware and Environment details:



it is still broken in 10.0.1 you still see exception running <cftry> <cfhttp url="" path="#tempDir#" file="#tempFileName#"> <cfhttpparam type="header" name="Accept-Encoding" value="compress,gzip,deflate"> </cfhttp> <cffeed action="read" source="#tempFile#" name="feedInStruct" > <cfdump var="#feedInStruct#"> <cfcatch> <cfdump var="#cfcatch#"> </cfcatch> </cftry> it worked in CF9
Comment by External U.
19221 | September 07, 2012 01:26:37 PM GMT
You can NOT just use the example script in the blog entry to check. The problem is NOT in <CFFEED> now, it is <CFHTTP> if just run the example in the blog entry, it will never in cfcatch.
Comment by External U.
19222 | September 07, 2012 01:29:22 PM GMT
I'm not able to reproduce this. Here's the same code: <cfset tempDir = GetTempDirectory()> <cfset tempFile = GetTempFile(tempDir, "myfeed")> <cfset tempFileName = GetFileInfo(tempFile).name> cftry> <cfhttp url="" path="#tempDir#" file="#tempFileName#"> <cfhttpparam type="header" name="Accept-Encoding" value="compress,gzip,deflate"> </cfhttp> <cffeed action="read" source="#tempFile#" name="feedInStruct"> <cfdump var="#feedInStruct#"> <cfcatch> <cfdump var="#cfcatch#"> </cfcatch> </cftry> Can you check this again? (Comment added from ex-user id:sagarg)
Comment by Adobe D.
19223 | September 11, 2012 04:28:52 AM GMT
I'm using AWeng's code and I get an error still. <cftry> <cfhttp url=""> <cfhttpparam type="header" name="Accept-Encoding" value="compress,gzip,deflate"> </cfhttp> <cfdump var="#cfhttp#"> <cfcatch> <cfdump var="#cfcatch#"> </cfcatch> </cftry> Wait - to be clear - I do not get an Exception. But FileContent isn't screwed up. It isn't plain text.
Comment by External U.
19224 | September 11, 2012 05:49:28 AM GMT
Also, your code Sagar throws an error for me as well. When I output the contents it is also still in binary.
Comment by External U.
19225 | September 11, 2012 05:52:04 AM GMT
This is still an issue with 10 update 2, cfhttp, and <cfhttpparam TYPE="CGI" NAME="accept-encoding" VALUE="gzip" />. Content is not de-zipped.
Vote by External U.
19228 | October 08, 2012 12:28:35 PM GMT
akhila, could you plz check if this is still an isssue?
Comment by Rupesh K.
19226 | November 13, 2014 09:13:59 AM GMT
This is not an issue now, the http response(file content) is plain text. hence closing the bug.
Comment by Akhila K.
19227 | December 05, 2014 02:15:36 AM GMT