The reason for the 520 is that the request crashes the apache server on the origin server with a Segmentation Fault.
But accessing the origin server directly using Safari also returns the desired result.
This means putting Cloudflare in the pipeline changes something that makes the origin server crash.
The problem only happens when the URL reaches a certain length.
I have some URLs that show this but am not allowed to post them here by the Cloudflare Community forum. I also can’t post screenshots of them. How am I supposed to get support here?
URL 1 works in Safari and Chrome
URL 2 works in Chrome but crashes the server in Safari
The difference between those two URls is just a “1” at the end.
Both work in Safari and Chrome if I send them directly to the origin server and don’t crash the origin server. (I don’t want to expose that URL here)
Also, there is a Page Rule in Cloudflare that sets the Cache Level for apps.boinx.com to “ByPass” so the request and response shouldn’t be modified by Cloudflare at all as far as I understand it.