FederatedAuthentication.FederationConfiguration 属性
定义
获取 HTTP 模块在该 Web 应用程序使用的单独 FederationConfiguration 实例。Gets the singleton FederationConfiguration instance used by the HTTP modules in this web application.
public:
static property System::IdentityModel::Services::Configuration::FederationConfiguration ^ FederationConfiguration { System::IdentityModel::Services::Configuration::FederationConfiguration ^ get(); };
public static System.IdentityModel.Services.Configuration.FederationConfiguration FederationConfiguration { get; }
member this.FederationConfiguration : System.IdentityModel.Services.Configuration.FederationConfiguration
Public Shared ReadOnly Property FederationConfiguration As FederationConfiguration
属性值
联合配置实例。The federation configuration instance.
例外
FederationConfiguration 属性将由 FederationConfigurationCreated 事件的事件处理程序设置为 null。The FederationConfiguration property is set to null by an event handler for the FederationConfigurationCreated event.
注解
FederationConfiguration第一次访问此属性时,将从配置文件中的 < federationConfiguration > 元素创建和初始化一个对象。A FederationConfiguration object is created and initialized from the <federationConfiguration> element in the configuration file the first time this property is accessed by one of the HTTP modules. 在初始化配置对象后,将 FederationConfigurationCreated 引发事件,以便为开发人员提供一个机会来修改新创建的配置对象,然后将其用于初始化任何已配置的 HTTP 模块。Just after the configuration object has been initialized, the FederationConfigurationCreated event is raised to provide a developer with an opportunity to modify the newly created configuration object before it is used to initialize any of the configured HTTP modules. 它可以从 FederationConfigurationCreatedEventArgs.FederationConfiguration 事件处理程序中的属性访问。It can be accessed from the FederationConfigurationCreatedEventArgs.FederationConfiguration property in an event handler.
在后续访问时,将返回相同的配置实例。On subsequent accesses, the same configuration instance is returned.
根据特定模块是否存在,将在初始化过程中从以下方法中访问属性: ClaimsAuthorizationModule.InitializePropertiesFromConfiguration 、 SessionAuthenticationModule.InitializePropertiesFromConfiguration 和 WSFederationAuthenticationModule.InitializePropertiesFromConfiguration 。Depending on whether specific modules are present, the property is accessed from within the following methods during initialization: ClaimsAuthorizationModule.InitializePropertiesFromConfiguration, SessionAuthenticationModule.InitializePropertiesFromConfiguration, and WSFederationAuthenticationModule.InitializePropertiesFromConfiguration.
重要
声明授权管理器 (ClaimsAuthorizationManager) ,用于在使用类时评估基于声明的访问检查, ClaimsPrincipalPermission 或 ClaimsPrincipalPermissionAttribute 在 IdentityConfiguration 通过属性引用的联合身份验证配置对象上设置的对象上配置类 FederatedAuthentication.FederationConfiguration 。The claims authorization manager (ClaimsAuthorizationManager) that is used to evaluate claims based access checks when using the ClaimsPrincipalPermission class or the ClaimsPrincipalPermissionAttribute class is configured on the IdentityConfiguration object that is set on the federation configuration object referenced through the FederatedAuthentication.FederationConfiguration property. 无论应用程序是否 ASP.NET 应用程序都是如此。This is true for all applications whether they are ASP.NET applications or not.