Repository navigation
fix: rename the form honeypots so browser autofill leaves them empty - #78
Merged
Merged
Conversation
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Adel2411
approved these changes
Nov 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stops browser autofill from filling the forms' hidden honeypot, which made the server drop real registrations as bots while showing them a success.
The cause: the registration honeypot was named
company. Chrome reads a field's name, id and label to decide what to autofill, recognizes "company" as part of an address, and fills it from the visitor's saved address even withautocomplete="off". The server then returns its fake success and saves nothing. A real applicant's network log showed the decoy filled with their employer.REGISTRATION_HONEYPOT_FIELDis nowmc_trap, a name no autofill field matches. Bots still fill it, since they fill every input.HONEYPOT_FIELD(waswebsite), and its hidden label now reads "Leave this empty" instead of "Website": autofill and password managers read labels too.Not testable automatically (automation cannot open Chrome's autofill menu). Manual check: with a saved Chrome address that has a company, autofill the registration form from a suggestion and check the submission is saved. The
mc_trapfield stays empty in the request.The cleanup of the uploads these drops left behind is in #79.
Closes #72