Versions in this module Expand all Collapse all v0 v0.1.0 Jun 17, 2020 Changes in this version + var ErrCaptchaExpired = errors.New("captcha is expired") + var ErrCaptchaIncorrect = errors.New("captcha is incorrect") + type Captcha interface + Answer func() string + EncodeToString func() string + HTMLField func(fieldName string) template.HTML + ID func() string + type Driver interface + Generate func() (Captcha, error) + type Manager struct + func New(store Store, driver Driver, opts ...Option) *Manager + func (m *Manager) Generate(ctx context.Context) (Captcha, error) + func (m *Manager) Get(ctx context.Context, id string, clear bool) (string, error) + func (m *Manager) Verify(ctx context.Context, id, actual string, clear bool) error + type Option func(*Manager) + func CaseSensitive(v bool) Option + type Store interface + Get func(ctx context.Context, id string, clear bool) (string, error) + Set func(ctx context.Context, id, answer string) error