1
High availability / Re: HAProxy 4.3 Broken with Cloudflare Origin Cert and OCSP Automatic Update
« on: February 08, 2024, 11:57:27 pm »
I fixed it. Documenting this if anyone comes across this same issue in the future.
TLDR: Import the Cloudflare CA to your Authorities
The haproxy plugin in 4.1 was the bugged version. The updated plugin in 4.1.1 corrected the bug.
The valid syntax for the configuration is to have the [ocsp-update on] in brackets. So the reason my config worked on 4.1 is because the ocsp-update on parameter was invalid and not interpreted by the haproxy engine. 4.1.1 corrected the syntax and highlighted my actual issue which is that I needed to install the Certificate Authority for the Cloudflare Origin Certificate. This was made evident because the error states that, maybe the issuer could not be found. This refers to the .issuer file under the directory, /tmp/haproxy/ssl/, there was no .issuer file here for me.
I went here and downloaded the CA for my cert (ECC in my case)...
https://developers.cloudflare.com/ssl/origin-configuration/origin-ca/#cloudflare-origin-ca-root-certificate
Then I imported into System > Trust > Authorities, applied my haproxy configuration, and I got no error message in the GUI. The .issuer file appeared in the /tmp/haproxy/ssl/ directory.
Now everything works.
Thanks to these two folks, rlebreton and fraenki, for pointing me in the right direction on GH.
https://github.com/haproxy/haproxy/issues/2432#issuecomment-1935042531
TLDR: Import the Cloudflare CA to your Authorities
The haproxy plugin in 4.1 was the bugged version. The updated plugin in 4.1.1 corrected the bug.
The valid syntax for the configuration is to have the [ocsp-update on] in brackets. So the reason my config worked on 4.1 is because the ocsp-update on parameter was invalid and not interpreted by the haproxy engine. 4.1.1 corrected the syntax and highlighted my actual issue which is that I needed to install the Certificate Authority for the Cloudflare Origin Certificate. This was made evident because the error states that, maybe the issuer could not be found. This refers to the .issuer file under the directory, /tmp/haproxy/ssl/, there was no .issuer file here for me.
I went here and downloaded the CA for my cert (ECC in my case)...
https://developers.cloudflare.com/ssl/origin-configuration/origin-ca/#cloudflare-origin-ca-root-certificate
Then I imported into System > Trust > Authorities, applied my haproxy configuration, and I got no error message in the GUI. The .issuer file appeared in the /tmp/haproxy/ssl/ directory.
Now everything works.
Thanks to these two folks, rlebreton and fraenki, for pointing me in the right direction on GH.
https://github.com/haproxy/haproxy/issues/2432#issuecomment-1935042531