Fantasy Engine user guide 1.0.0 / AdminCP
Sign-in security
How the site limits sign-in attempts and protects the AdminCP and the member accounts.
Sign-in security#
Last updated: 2026-11-19 · v1.0.0
The site slows down password guessing by itself. Two settings drive it, in AdminCP → Site Settings → General Configuration → Login & Registration:
| Setting | Default | Used for |
|---|---|---|
| Bad login limit | 10 | how many wrong tries are allowed before a lockout: the member login, the AdminCP login and the two-step codes |
| Lockout time (minutes) | 1 | how long the tries are counted and a lockout lasts: the count starts with the first wrong try and ends that many minutes later |
The counts are kept per visitor address and in the site's cache; with the usual cache set-up they start again when the cache is emptied (Clear cache, an update).
Backend (AdminCP)#
- AdminCP login lockout: after Bad login limit wrong passwords for one account from one visitor within Lockout time, the login form shows "Too many login attempts. Please try again in n minute(s)." and refuses that account from that visitor, even with the right password. From all visitors together an account takes three times Bad login limit wrong passwords (30 with the default) before it is locked for everybody. Every spelling of the e-mail that reaches the same account (capitals, accents) counts on that account. A wrong e-mail and a wrong password get the same answer, "Your email or password was incorrect.", so the form tells nobody which addresses are registered.
- How it unlocks: by itself, when Lockout time has passed since the first wrong try (the message says how many minutes are left); there is nothing to reset. A successful login clears the counts of that account. The AdminCP login asks for the password only, so give every admin account a strong password of its own.
- Withdrawals need the permission "Transfer funds": AdminCP → Users → Manage User Roles → Permissions of a role, group eWallet, Transfer funds. The Member role made at the install has it. A member whose role does not have it cannot withdraw: the app offers him no Redeem Credits (no button on the wallet, no row in the menu, a link to the page opens the wallet), and a request sent anyway is refused with "You cannot transfer funds from your wallet." While Only verified profiles can transfer funds is on and profile verification is switched on, a member needs a verified profile as well as the permission (Members and their money).
Frontend (website and apps)#
- Login: more tries than Bad login limit within Lockout time for one e-mail address or user name from one visitor are refused with "Too many failed login attempts." until the time has passed. The same e-mail typed in capitals or look-alike characters counts as the same one. The tries are also counted per account and visitor: typing the user name or e-mail differently (accents, capitals) gives no extra tries, and once they are used up even the right password is refused from that visitor until the time has passed. A visitor at another address still signs in, so a stranger cannot lock the owner out. A successful login clears the counts.
- Forgot password: the member asks for a code, which is mailed to the address. At most 5 codes an hour are mailed to one account, however its address is typed, and one visitor can ask for at most 20 an hour. A code expires after 6 minutes, works once (the new password spends it) and stops working after 5 wrong tries ("Too many wrong codes. Please ask for a new code."). Setting the new password signs the member out on every device. The form answers an address that has no account exactly like one that has: no mail is sent, and nobody can find out which addresses are registered.
- Two-step verification (while Two-factor authentication (2FA) is on and the member set it up in Settings): after the password the Two-factor authentication screen asks for the code (sent by e-mail or SMS, or shown by an authenticator app). Wrong codes are counted per account with Bad login limit and Lockout time, whatever new password login or visitor address comes in between: then "Too many login attempts. Please try again in n minute(s)."; the right code clears the count. A code sent by e-mail or SMS expires after 6 minutes, works once and stops working after 5 wrong tries ("Too many wrong codes. Please ask for a new code."). In the Android and iOS apps the code is typed into its boxes, or pasted with a long press.
- Screens that ask for the current password (signed in: Change Password, Account - e-mail address and username -, Delete Account, setting up or removing two-factor authentication): a wrong password answers "The password is incorrect." and is counted, per account and per visitor address. After 10 wrong passwords on one account within 15 minutes (counted from the first wrong one), or 30 from one visitor address over all accounts, every further try on these screens answers "Too many requests in 1 minute. Try again later." until those 15 minutes have passed - also the right password, whatever the message says about one minute. The right password itself is never counted, so a member who types his password correctly is never locked out. These numbers are fixed (not settings).
- Contact us: at most 5 messages an hour from one visitor and 5 an hour from one sender e-mail.
Social sign-in (Google, Facebook, Apple ...)#
The providers are set up in AdminCP → Site Settings → Manage OpenID (Facebook, Google, Linkedin and
Twitter are there after the install, switched off; Apple is added with the app name Apple). Members see the
active ones under the login and sign-up forms, on the website and in the apps.
- Same browser: a provider sign-in is accepted only in the browser that started it. A sign-in link opened from elsewhere (an e-mail, another site, another device) is refused before the site contacts the provider: the member sees the error page "400 Unable to determine state" and starts again from the login screen. Each started sign-in can come back once.
- Sign in with Apple needs the site on https (its return relies on a secure cookie that lasts 15 minutes).
- Limit: the social sign-in address answers at most 60 requests a minute from one visitor (a sign-in takes two); past that the visitor sees the error page "429 Too Many Attempts." for the rest of the minute.
- An account that already exists: the first sign-in with a provider joins the account that holds the same e-mail address only when both have proved the address: the provider verified it (Google and Apple do; Facebook does not, so a Facebook sign-in never joins an existing account), and the account confirmed it by resetting its password once with Forgot password? (the code is mailed to that address). Until then the member sees "An account with this email already exists. Please log in with your email and password. To also sign in with this provider, confirm the email once by resetting your password (Forgot password? on the login page)."; after one reset the provider sign-in works for that account. Where the provider did not verify the address the member sees "An account with this email already exists. Please log in with your email and password." (a reset does not help then). Nobody else's account is ever joined, and no second account with that address is made. Members who already signed in with a provider keep signing in as before.
- Changing the e-mail address of an account takes the confirmation back: a new reset with the code mailed to the new address confirms it again. Capitals alone do not count as a change.
- A new account made by a provider sign-in takes the provider's e-mail address when the provider verified it (the address then counts as confirmed). Otherwise (Facebook, Twitter, or a provider that sends no address) the account gets no real e-mail address of its own, and its member signs in with that provider.
- Two-step verification after a provider sign-in: a member who set up two-factor authentication is not signed in by the provider alone. The website and the apps of version 1.0.0 then show "Two-factor verification needed"; the member signs in with e-mail, password and code instead (an account made by a provider sign-in sets its password once with Forgot password?).
Every count above is
kept per visitor address. When the site runs behind Cloudflare, another CDN, a load balancer or a reverse proxy, the
developer must tell the site which addresses are that proxy (install guide, .env
keys, TRUSTED_PROXIES and TRUSTED_PROXY_HEADER); otherwise all visitors look like the
proxy and share one count, so one guesser can lock the login of an account for everybody.
The IP address ban (AdminCP → Site Settings → General Configuration → Spam & Banning
Tools) judges the same visitor address: behind a proxy it matches the visitor once these keys are set, and
without them it never matches a visitor (only the proxy). A banned visitor gets "You are not allowed to access this
site."; the AdminCP is never banned. The list takes IPv4 addresses and ranges with *
(203.0.113.8, 198.51.100.*); a visitor on an IPv6 address is matched by none of them.
Change log#
Last updated: 2026-11-19 · v1.0.0
| Date (GMT+7) | Section | What changed |
|---|---|---|
| 2026-10-28 | all | First version, checked against daily-fantasy 7b8ff49; screenshots of the local demo site (AdminCP 1280, web app 1280 / 390, light). |
| 2026-11-16 | all, change-log | This copy of the guide describes version 1.0.0 (a separate copy describes 1.1.0). Internal labels taken out of older rows and the page-source comment; wording only, those Last updated lines stay. |
| 2026-11-19 | sign-in-security (new) | New section Sign-in security, checked against 3bf3581: Bad login limit (10) and Lockout time (1 minute); the AdminCP login lockout (per account and visitor, three times the limit from all visitors, the message with the minutes left, unlocks by itself, the same answer for a wrong e-mail and a wrong password, no second step); the permission Transfer funds needed to withdraw; the member login limits, forgot password (5 codes an hour per account, 20 per visitor, 6 minutes, 5 wrong tries, one use, the same answer for an unknown address), two-step codes counted per account (typed or pasted into the boxes in the apps), the contact form; social sign-in: only in the browser that started it ("400 Unable to determine state"), Apple needs https, 60 requests a minute per visitor ("429 Too Many Attempts."), an existing account joined only when the provider verified the address and the account confirmed it by one password reset (both messages), an e-mail change takes the confirmation back, what a new account gets, "Two-factor verification needed" after a provider sign-in of a member with two-step verification; proxy box. |
| 2026-11-19 | sign-in-security, members-wallet, member-accounts, wallet, profile | Checked against c0645f6. Sign-in security: the screens that ask for the current password (Change Password, Account, Delete Account, two-factor setup and removal) count wrong passwords, 10 per account in 15 minutes and 30 per visitor address, then "Too many requests in 1 minute. Try again later." until the 15 minutes have passed; the right password is never counted. A member without Transfer funds no longer sees Redeem Credits. Proxy box: the IP address ban judges the visitor address behind a proxy, its message and the IPv4-only list. Members and their money: no Redeem Credits for a role without Transfer funds or while fund transfer is off; balances shown and checked at two decimals, rounded down; the member list of Transfer Mass Funds shows names as plain text. Member accounts: the same for the protected accounts picker. Wallet: the same rounding, an entry fee equal to the balance and All current balance accepted; Redeem Credits hidden (button, menu row, link) when the member may not withdraw; a comma followed by one or two digits counts as the decimal point in the amount boxes ("1,000" is refused), the apps open a number pad with a decimal key. Profile: the Enter Password window after 10 wrong passwords; password boxes do not capitalise or correct. No screenshot changed. |
| 2026-11-19 | all | Moved to the documentation site: this page holds the sections sign-in-security of the former single-page user guide. Page frame, headings and links between the pages updated; the text of the sections is unchanged. |