BUG/MINOR: acme: restrict the permissions of the generated account key
When no ACME account key exists yet, haproxy generates one and writes it
through a plain BIO_new_file(), so the file is created with the process'
umask applied. With the common 022 umask the unencrypted private key ends
up on disk as 0644, readable by every local user.
Whoever reads that key can authenticate to the CA as this haproxy ACME
account, and from there deactivate it or manipulate the orders and
revocations for the domains it has validated.
Let's restrict the file to 0600 right after creating it and before writing
anything into it.
This was introduced in 3.2 by commit
856b6042d ("MEDIUM: acme: generate
the account file when not found"). It must be backported to 3.2.
Reported-by: Claude (ANT-2026-2TZ0NDHX)