Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CaptchaRedisStore ¶
type CaptchaRedisStore struct {
// contains filtered or unexported fields
}
CaptchaRedisStore implements captcha.Store interface using redis v9 client
func NewCaptchaRedisStore ¶
func NewCaptchaRedisStore(cli *redis.Client, expiration time.Duration, prefix string) *CaptchaRedisStore
NewCaptchaRedisStore creates a new CaptchaRedisStore instance
func (*CaptchaRedisStore) Get ¶
func (s *CaptchaRedisStore) Get(id string, clear bool) []byte
Get retrieves the captcha digits from redis and optionally deletes it
func (*CaptchaRedisStore) Set ¶
func (s *CaptchaRedisStore) Set(id string, digits []byte)
Set stores the captcha id and digits in redis
Click to show internal directories.
Click to hide internal directories.