modular Flask webapp capable of serving CAPTCHA challenges
the project uses flask installed within a venv.
$ ./setup.sh
should create the venv and install all dependencies once you're in it, then you can use
(venv) $ ./run.sh
once in the venv to run it.
$ . venv/bin/activate
should drop you into a venv shell any time after the setup.
designed so that it emulates a real environment without replication (e.g. the use of tokens handled userside is better for us when we're writing solver suites than the usual session values)
- non-standard header
X-Researchshould be set for all responses /captchasreturns a list of the avaliable CAPTCHA types- served CAPTCHA decided by
/captcha/name?modifiers=a,b,cused for the obvious- e.g.
/an5char?modifiers=distort,obstructserves a 5-character alphanumeric CAPTCHA that has distorting and obstructive effects applied to it - all valid CAPTCHA responses should be JSON with two attributes
challenge, which is the challenge stored as a data URItoken, which stores a randomly generated token- this is used as a naive session tracker
- solutions should be POSTed to
/solutionswith the given token value and the answer,200means correct and401means incorrect- good responses come with the
passport_tokenin a JSON object
- good responses come with the
- challenge information, including the generated token, is kept in an internal queue
after a certain size (20 perhaps) old values can be knocked off- invalid after 60 seconds
- CAPTCHA types are treated as separate modules and loaded during initialization
- a similar system is used for storing and authentication of 'passports'