diff --git a/business/auth2/authprovider/mobile/mobile.go b/business/auth2/authprovider/mobile/mobile.go index 5f552c0f0..32aa3d974 100644 --- a/business/auth2/authprovider/mobile/mobile.go +++ b/business/auth2/authprovider/mobile/mobile.go @@ -3,6 +3,7 @@ package mobile import ( "errors" "fmt" + "math/rand" "git.rosy.net.cn/baseapi/utils" "git.rosy.net.cn/jx-callback/business/auth2" @@ -44,7 +45,8 @@ func init() { // 特殊接口 func (a *Auther) SendVerifyCode(mobileNumber string) (verifyCode string, err error) { - verifyCode = a.GenerateVerifyCode(mobileNumber) + verifyCode = fmt.Sprintf("%06d", rand.Intn(1000000)) + // a.GenerateVerifyCode(mobileNumber) smsClient := aliyunsmsclient.New("http://dysmsapi.aliyuncs.com/") response, err := smsClient.Execute(globals.AliKey, globals.AliSecret, mobileNumber, globals.SMSSignName, globals.SMSMobileVerifyTemplate, string(utils.MustMarshal(map[string]interface{}{ "code": verifyCode,