Currently, I’m seeing an issue where Cloudflare replaces the contents of PDF files on my server with 34-character code.
Example: https://fccid.io/pdf.php?id=2303213
Trying to load this file in any browser will result in a code similar to:
ec6a90e2-397b-4c80-b10c-273def9a2ae6
The code will always be different despite the returned header of:
CF-Cache-Status: HIT
Attempting to download the file via curl or wget returns the proper file.
The end of my PHP script creating the file appears as so:
header("Reported-Size: ".strlen($data));
header("Content-length: ".strlen($data));
print $data;
You can see the Reported-Size header is much larger than the content of the document (as the real content is lost somewhere in Cloudflare)
Here’s a direct link to a PDF file which loads fine in chrome, but will give the strange 36 byte code when you view-source:https://fccid.io/hello-world.pdf