Captcha Server writte in go
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Andreas Peters 6fcb75c9de
change font
1 month ago
api change font 1 month ago
font change font 1 month ago
types first commit 3 months ago
.gitignore first commit 3 months ago
Dockerfile change font 1 month ago
LICENSE first commit 3 months ago
README.md change font 1 month ago
app.go change font 1 month ago
init.go first commit 3 months ago

README.md

Go-Captcha API

Server to generate and check captcha

This Captcha Generation is using “Inter Font© SIL OpenFontLicense 1.1”

Requirements

  • Redis Server

How to Use

As example, you can start the go-captcha API like that:

export API_PORT=10888
export API_BIND=0.0.0.0
export LOGLEVEL=debug
export REDIS_SERVER=localhost:6379

go run init.go app.go

If you want to generate a captcha:

curl -X GET localhost:10888/api/captcha/v0

It will give you as result a PNG File and in the HTTP Response Header a “sessiontoken”. This token you have to add to your CaptchaCheck Request:

curl -H 'sessiontoken: <token>' -X POST localhost:10888/api/captcha/v0/<token>

Thats it! Pretty easy.