Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CaptchaVerify ¶
base64Captcha verify http handler
func GenerateCaptcha ¶
func GenerateCaptcha(param *CaptchaParam) (string, string, error)
base64Captcha create http handler
func InitCaptcha ¶
func InitCaptcha()
Types ¶
type CaptchaParam ¶
type CaptchaParam struct { CaptchaType string //audio、string、math、chinese、digit Length int //Length random string length. //audio Language string // Language possible values for lang are "en", "ja", "ru", "zh". //string Height int // Height png height in pixel. Width int // Width Captcha png width in pixel. NoiseCount int //NoiseCount text noise count. ShowLineOptions int // OptionShowHollowLine=2 | OptionShowSlimeLine=4 | OptionShowSineLine=8 . Source string //Source is a unicode which is the rand string from. BgColor *color.RGBA //BgColor captcha image background color (optional) // Digit MaxSkew float64 // MaxSkew max absolute skew factor of a single digit. DotCount int // DotCount Number of background circles. }
configJsonBody json request body.
type JoyCaptchaStore ¶
func (*JoyCaptchaStore) Set ¶
func (store *JoyCaptchaStore) Set(id string, value string)
Click to show internal directories.
Click to hide internal directories.