Table of Contents

Class CorsRule

Namespace
Microsoft.WindowsAzure.Storage.Shared.Protocol
Assembly
Microsoft.WindowsAzure.Storage.dll

Class representing the service properties pertaining to CORS.

public sealed class CorsRule
Inheritance
CorsRule
Inherited Members

Constructors

CorsRule()

public CorsRule()

Properties

AllowedHeaders

Gets or sets headers allowed to be part of the CORS request.

public IList<string> AllowedHeaders { get; set; }

Property Value

IList<string>

A collection of strings containing allowed headers, limited to 64 defined headers and two prefixed headers.

AllowedMethods

Gets or sets the HTTP methods permitted to execute for this origin.

public CorsHttpMethods AllowedMethods { get; set; }

Property Value

CorsHttpMethods

The allowed HTTP methods.

AllowedOrigins

Gets or sets domain names allowed via CORS.

public IList<string> AllowedOrigins { get; set; }

Property Value

IList<string>

A collection of strings containing the allowed domain names, limited to 64.

ExposedHeaders

Gets or sets response headers that should be exposed to client via CORS.

public IList<string> ExposedHeaders { get; set; }

Property Value

IList<string>

A collection of strings containing exposed headers, limited to 64 defined headers and two prefixed headers.

MaxAgeInSeconds

Gets or sets the length of time in seconds that a preflight response should be cached by browser.

public int MaxAgeInSeconds { get; set; }

Property Value

int

The maximum number of seconds to cache the response.