鄂尔多斯-招源科技

RegexHelper.cs 452B

12345678910111213141516171819
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Text.RegularExpressions;
  6. using System.Threading.Tasks;
  7. namespace CallCenterApi.Common
  8. {
  9. public class RegexHelper
  10. {
  11. public static readonly string Reg_Pwd = @"^(?=.*\d)(?=.*[a-z])(?=.*[A-Z]).{6,16}$";
  12. public static bool RegexPwd(string password)
  13. {
  14. return Regex.IsMatch(password, Reg_Pwd);
  15. }
  16. }
  17. }