Cloudflare is changing text in the page (+ display html as plain text)

So i have setup a traefik middleware for my error pages and when the error page is though Cloudflare it just display the page as plain text. I did a compare on both CF proxied and not proxied, and some text where changed inside the response body.
No description
16 Replies
Ibaraki Douji
Ibaraki DoujiOP4mo ago
left is non proxy, right is proxied
No description
No description
Ibaraki Douji
Ibaraki DoujiOP4mo ago
also to test i disabled the cache but no
No description
Ibaraki Douji
Ibaraki DoujiOP4mo ago
adding a html response header fix the problem
No description
Ibaraki Douji
Ibaraki DoujiOP4mo ago
but WHY does this happen ? and is there something else than editing the CF response headers ? (also if you ask, no in the non-proxied page i don't have any content-type and it works) looking for more elements your x-content-type-options header is the cause is there a way to remove it (other than rules) ? if no i will stick on rules but if there is an option to remove it globally that would be perfect
Chaika
Chaika4mo ago
oh so you're not returning the content-type and you have nosniff set that header isn't on by default, you enabled something to add it Enabling the Managed Transform Add Security Headers (Rules -> Transform Rules -> Managed Transform -> Add Security Headers) would add it, for example
Ibaraki Douji
Ibaraki DoujiOP4mo ago
this is disabled (everything in managed is disabled) maybe in other security things
Ibaraki Douji
Ibaraki DoujiOP4mo ago
Security > Settings
No description
Chaika
Chaika4mo ago
You could throw the url through trace under account https://dash.cloudflare.com/?to=/:account/trace/search and see all it hits
Ibaraki Douji
Ibaraki DoujiOP4mo ago
oh that a cool thing, let me try it
Ibaraki Douji
Ibaraki DoujiOP4mo ago
on what i see it hits the default ruleset and my test rule (for the cache i'm in dev mode so it should not count)
No description
Chaika
Chaika4mo ago
you don't see this response header being returned from your origin at all?
Ibaraki Douji
Ibaraki DoujiOP4mo ago
on the trace page no i just see the response code (200)
Chaika
Chaika4mo ago
yea it doesn't show you headers/make an origin request I mean if you bypass the proxy and see the request headers
Ibaraki Douji
Ibaraki DoujiOP4mo ago
when i bypass this is the response headers
No description
Ibaraki Douji
Ibaraki DoujiOP4mo ago
and request headers (i just hidded the :authority:)
No description
Ibaraki Douji
Ibaraki DoujiOP4mo ago
and if you want proxied response headers here you go
No description
Want results from more Discord servers?
Add your server