Esempio n. 1
0
        private void ck_weakpwd(HttpContext context)
        {
            string pwd = AppRequest.GetQueryString("pwd");//密码

            if (string.IsNullOrEmpty(pwd))
            {
                context.Response.Write(JsonHelper.ObjectToJSON(new { succeess = false, msg = "弱密码" }));
                return;
            }
            try
            {
                if (pwd.Contains("123456"))
                {
                    context.Response.Write(JsonHelper.ObjectToJSON(new { succeess = false, msg = "弱密码" }));
                    return;
                }
                if (pwd.Length != 32)
                {
                    string ckStatus = Utils.HttpGetUtf("http://monitor.qianniusoft.com/api/userWeakpwd/ckUserWeakPwd?password="******"succeess"];
                        string msg     = dicCK["msg"].ToString();
                        if (!succuss)
                        {
                            context.Response.Write(JsonHelper.ObjectToJSON(new { succeess = false, msg = msg }));
                            return;
                        }
                    }
                    else
                    {
                        context.Response.Write(JsonHelper.ObjectToJSON(new { succeess = false, msg = "弱密码" }));
                        return;
                    }
                }
                else
                {
                    if (LimitPhoneHelper.GetWeakPwdList().Contains(pwd))
                    {
                        context.Response.Write(JsonHelper.ObjectToJSON(new { succeess = false, msg = "弱密码" }));
                        return;
                    }
                }
            }
            catch (Exception ex)
            {
            }
            context.Response.Write(JsonHelper.ObjectToJSON(new { succeess = true, msg = "正常密码" }));
            return;
        }