Versions in this module Expand all Collapse all v1 v1.0.2 Mar 14, 2024 v1.0.1 Mar 14, 2024 Changes in this version + type Captcha struct + CachePrefix string + ChallengeNums int + Expiration time.Duration + FieldCaptchaName string + FieldIDName string + StdHeight int + StdWidth int + URLPrefix string + func NewCaptcha(urlPrefix string, store Storage) *Captcha + func NewWithFilter(urlPrefix string, store Storage) *Captcha + func (c *Captcha) CreateCaptcha() (string, error) + func (c *Captcha) CreateCaptchaHTML() template.HTML + func (c *Captcha) Handler(ctx *context.Context) + func (c *Captcha) Verify(id string, challenge string) (success bool) + func (c *Captcha) VerifyReq(req *http.Request) bool + type Image struct + func NewImage(digits []byte, width, height int) *Image + func (m *Image) WriteTo(w io.Writer) (int64, error) + type Storage interface + Delete func(ctx context2.Context, key string) error + Get func(ctx context2.Context, key string) (interface{}, error) + Put func(ctx context2.Context, key string, val interface{}, timeout time.Duration) error