Bot Challenge on the Login Pages#
SynergyCP can ask for a Cloudflare Turnstile check on the administrator and client login pages. It stops automated password guessing that is spread over many addresses and accounts, which rate limiting alone does not catch. Most people never see more than a checkmark.
It is off by default, and it can be turned on for the administrator login, the client login, or both. The forgot password page of a panel follows the same setting as its login page.
Turnstile is free and does not require your panels to be proxied through Cloudflare.
Before you turn it on#
- Scripts that sign in with a username and password stop working for the account type you turn it on for. Give them an API key instead. Integrations such as the WHMCS modules already use API keys and are not affected.
- Clients who are signed in by an Integration (for example the Manage button of a billing system) or by an administrator are not asked.
- Everyone who signs in needs to be able to reach
challenges.cloudflare.com, and so does the SynergyCP master host. - If Cloudflare cannot confirm a check, the login is refused. Keep the command that turns it off at hand.
Set it up#
- In your Cloudflare account, open Turnstile and add a widget.
- Under hostnames, add the hostnames of both your admin panel and your client panel.
- Widget mode: Managed.
- Copy the widget’s Site Key and Secret Key.
- In the SynergyCP admin panel, go to System > Settings > Site and fill in Turnstile site key and Turnstile secret key. Save.
- Check Turnstile on the client login, Turnstile on the administrator login, or both. Save.
- Before you sign out, open the login page in a private browser window and sign in there. If that works, you are done.
A checkbox only takes effect once both keys are saved.
We recommend turning it on for the client login first, and for the administrator login once you have seen it work.
If nobody can sign in#
This happens when the keys are wrong, when a panel hostname is missing from the widget’s hostname list, or when the master host cannot reach Cloudflare.
Log in as the root user on the SynergyCP master host and run:
/scp/bin/scp-exec php_s php artisan turnstile:disable
This unchecks both checkboxes. The keys are kept, so you can correct them and turn it on again.
What the activity log shows#
A login or password reset request that is refused over the check leaves an entry in the log:
| Entry | Meaning |
|---|---|
| Challenge not completed | The request came without a check. Typical for scripts and bots. |
| Challenge not passed | Cloudflare did not confirm the check. |
| Challenge not verified | Cloudflare gave no answer, or does not accept the secret key. The entry’s details say which. |
These requests do not count towards locking the account they name.