예제 #1
0
 /// <summary>
 /// 初始化配置信息
 /// </summary>
 internal SecurityConfig(SecurityConfig parent)
 {
     if(parent != null)
     {
         ApplicationName = parent.ApplicationName;
         BusinessUnit = parent.BusinessUnit;
         MaxInvalidPasswordAttempts = parent.MaxInvalidPasswordAttempts;
         PasswordEffectiveDays = parent.PasswordEffectiveDays;
         MinRequiredPasswordLength = parent.MinRequiredPasswordLength;
         MinNonAlphaChar = parent.MinNonAlphaChar;
         MinAlphaChar = parent.MinAlphaChar;
         MinNumChar = parent.MinNumChar;
         PasswordReusePreventionCount = parent.PasswordReusePreventionCount;
         InitialLogonChangePassword = parent.InitialLogonChangePassword;
     }
 }
예제 #2
0
 object IConfigurationSectionHandler.Create(object parent, object configContext, XmlNode section)
 {
     SecurityConfig config = new SecurityConfig((SecurityConfig)parent);
     config.LoadValuesFromConfigurationXml(section);
     return config;
 }
예제 #3
0
 /// <summary>
 /// 获取Web.config中的数据引擎配置信息
 /// </summary>
 /// <returns>返回Web.config中的数据引擎配置信息对象,类型:DataConfig</returns>
 internal static SecurityConfig GetConfigData()
 {
     if (config == null)
     {
         config = (SecurityConfig)ConfigurationManager.GetSection(SecurityConfig.GetConfigSection());
     }
     return config;
 }