1 implementation of IEnableCorsAttribute
Microsoft.AspNetCore.Cors (1)
EnableCorsAttribute.cs (1)
13public class EnableCorsAttribute : Attribute, IEnableCorsAttribute
10 references to IEnableCorsAttribute
Microsoft.AspNetCore.Cors (1)
Infrastructure\CorsMiddleware.cs (1)
139else if (corsMetadata is IEnableCorsAttribute enableCorsAttribute &&
Microsoft.AspNetCore.Cors.Test (4)
CorsEndpointConventionBuilderExtensionsTests.cs (4)
27var metadata = endpoint.Metadata.GetMetadata<IEnableCorsAttribute>(); 70var metadata = endpoint.Metadata.GetMetadata<IEnableCorsAttribute>();
Microsoft.AspNetCore.Http.Connections.Tests (2)
MapConnectionHandlerTests.cs (2)
373Assert.NotNull(endpoint.Metadata.GetMetadata<IEnableCorsAttribute>()); 378Assert.NotNull(endpoint.Metadata.GetMetadata<IEnableCorsAttribute>());
Microsoft.AspNetCore.Mvc.Cors (3)
CorsApplicationModelProvider.cs (3)
47var enableCors = controllerModel.Attributes.OfType<IEnableCorsAttribute>().FirstOrDefault(); 63enableCors = actionModel.Attributes.OfType<IEnableCorsAttribute>().FirstOrDefault();