Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Base64CaptchaConfig ¶
type Base64CaptchaConfig struct { Id string CaptchaType string VerifyValue string DriverAudio *base64Captcha.DriverAudio DriverString *base64Captcha.DriverString DriverChinese *base64Captcha.DriverChinese DriverMath *DriverMath DriverDigit *base64Captcha.DriverDigit }
configJsonBody json request body.
type Base64CaptchaX ¶
type Base64CaptchaX struct {
Store base64Captcha.Store
}
func NewBase64CaptchaX ¶
func NewBase64CaptchaX(redis *redis.Redis, expiration time.Duration) *Base64CaptchaX
func (*Base64CaptchaX) GenerateBase64Captcha ¶
func (bc *Base64CaptchaX) GenerateBase64Captcha(param Base64CaptchaConfig) (id, b64s string, err error)
base64Captcha create http handler
type DriverMath ¶
type DriverMath struct {
// contains filtered or unexported fields
}
DriverMath captcha config for captcha math
func NewDriverMath ¶
func NewDriverMath(height int, width int, noiseCount int, showLineOptions int, bgColor *color.RGBA, fontsStorage base64Captcha.FontsStorage, fonts []string) *DriverMath
NewDriverMath creates a driver of math
func (*DriverMath) ConvertFonts ¶
func (d *DriverMath) ConvertFonts() *DriverMath
ConvertFonts loads fonts from names
func (*DriverMath) DrawCaptcha ¶
func (d *DriverMath) DrawCaptcha(question string) (item base64Captcha.Item, err error)
DrawCaptcha creates math captcha item
func (*DriverMath) GenerateIdQuestionAnswer ¶
func (d *DriverMath) GenerateIdQuestionAnswer() (id, question, answer string)
GenerateIdQuestionAnswer creates id,captcha content and answer
type SmsCaptchaX ¶
type SmsCaptchaX struct {
// contains filtered or unexported fields
}
func NewSmsCaptchaX ¶
func (*SmsCaptchaX) Send ¶
func (sc *SmsCaptchaX) Send(mobile string) error
Click to show internal directories.
Click to hide internal directories.