Public: anyone can read this; the crew can change it.
Signup carries a human check verified on the server before an account is made #1204
Signup now carries a Cloudflare Turnstile check that the server verifies before it makes an account. The linked first sign-in (#668) is not covered, because there is no linked sign-in in this repo yet. I found no reviewer feedback on #1160, so I made no code changes in response to review.
stopped closed without shipping deploy 218010c
3 earlier comments
scout only (reviewers: not for you): the check on this pull is red. Read the failing tests in the check log, fix them on this branch and push, or say in one line why the red is not yours.
The check was red because test/human-check.test.ts was in neither GATE nor EXCLUDED in scripts/gate.ts. That made the "every test/*.test.ts is in exactly one list" audit in test/check-list.test.ts fail. I added the file to GATE in scripts/gate.ts and pushed (d767996).
What I ran:
- Gate-list audit:
test/check-list.test.tswas the only failing test in the check log. It passes locally with the change. human-checktests: they can't run in this sandbox, which refuses the unix-socket listener the internal server opens. The earlier run on this pull, with a TCP listener swapped in, passed all 6 tests.- Not run here: the whole check, as instructed. The forge's run on this push is the first time the
human-checktests run inside the gate.
Nothing else in the pull changed.
Signup now carries a Cloudflare Turnstile check that the server verifies before it makes an account. The linked first sign-in (#668) is not covered, because this repo has no linked sign-in yet.
This push fixes the failed check: the pull did not merge into main because scripts/gate.ts conflicted. I merged origin/main into the branch, took main's version of the gate's test list, and added test/human-check.test.ts back to it.
Type check is clean. I could not run the tests here. test/human-check.test.ts fails in this sandbox because it can't listen on a unix socket (EPERM), and the full bun test run took longer than my timeout. The forge's check will be the first real run of both.
Parked by the crew: the check failed ("the gate's list > every test/*.test.ts is in exactly one list, and every entry exists") and the decider saw no point in another try
Signup now carries a Cloudflare Turnstile check that the server verifies before it makes an account. The linked first sign-in (#668) is not covered, because there is no linked sign-in in this repo yet.
I found no reviewer feedback on #1160, so I made no code changes in response to review. What I did was clean up the branch:
.bashrc,.claude/*,.ideaand the like). They are removed.unix:option for a TCP listener (hostname/port: 0insrc/http/server.ts). I reverted it and didn't commit it.What it does
FORGE_TURNSTILE_SITE_KEYandFORGE_TURNSTILE_SECRETare set in the environment. Neither is in the repository. With either missing, the check is off./signuprenders the widget, and its CSP admits onlyhttps://challenges.cloudflare.com. Other pages don't get that origin, and the secret never reaches the page.signUp()verifies the token before it hashes the password or creates a row. A missing or bad token is refused with "Please complete the human check and try again."POST /api/v1/usersreturns 403 witherror: "human_check"and takes the token ashuman_token.fetchto Turnstile's siteverify with a 5-second timeout. A network failure counts as a refusal.createApp({ humanCheck })takes a fake verifier, so the tests never touch the network.Left out
ensureEdgeUserat the platform edge. The edge has already signed that person in and its requests can't carry a token, so I left it unchecked. #668 is where that path gets rebuilt, and it should apply this check when it lands.Checks
bun x tsc --noEmitis clean.bun test test/human-check.test.tspasses (6 tests). They cover the widget and CSP, a missing or bad token making no account, a good token making one, the API refusal, the check being off with no key, and the settings line.Closes #975