private void context_AuthenticateRequest(object sender, EventArgs e) { if (OpenIDAuthenticateDirSettings.GetConfig().PageNeedAuthenticate()) { DoAuthentication(); } }
/// <summary> /// 获取配置认证目录信息 /// </summary> /// <returns></returns> public static OpenIDAuthenticateDirSettings GetConfig() { OpenIDAuthenticateDirSettings settings = (OpenIDAuthenticateDirSettings)ConfigurationBroker.GetSection("openIDAuthenticateDirSettings"); if (settings == null) settings = new OpenIDAuthenticateDirSettings(); return settings; }
/// <summary> /// 获取配置认证目录信息 /// </summary> /// <returns></returns> public static OpenIDAuthenticateDirSettings GetConfig() { OpenIDAuthenticateDirSettings settings = (OpenIDAuthenticateDirSettings)ConfigurationBroker.GetSection("openIDAuthenticateDirSettings"); if (settings == null) { settings = new OpenIDAuthenticateDirSettings(); } return(settings); }