You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ms.custom: template-how-to-pattern #Required; leave this attribute/value as-is.
10
10
---
11
11
# Use CORS for resource sharing in Azure Data Manager for Energy Preview
12
+
This document is to help you as user of Azure Data Manager for Energy preview to set up CORS policies.
12
13
13
14
## What is CORS?
14
15
@@ -20,11 +21,11 @@ You can set CORS rules for each Azure Data Manager for Energy Preview instance.
20
21
21
22
1. Create an **Azure Data Manager for Energy Preview** instance.
22
23
2. Select the **Resource Sharing(CORS)** tab.
23
-
[](media/how-to-enable-cors/enable-cors-1.png#lightbox)
24
+
[](media/how-to-enable-cors/enable-cors-1.png#lightbox)
24
25
25
26
3. In the Resource Sharing(CORS) tab, select **Allowed Origins**.
26
27
4. There can be upto 5 **Allowed Origins** added for a given instance.
27
-
[](media/how-to-enable-cors/enable-cors-2.png#lightbox)
28
+
[](media/how-to-enable-cors/enable-cors-2.png#lightbox)
28
29
5. If you explicitly want to have ***(Wildcard)**, then in the allowed origin * can be added.
29
30
6. If no setting is enabled on CORS page it's defaulted to Wildcard*, allow all.
30
31
7. The other values of CORS policy like **Allowed Methods**, **Allowed Headers**, **Exposed Headers**, **Max age in seconds** are set with default values displayed on the screen.
@@ -33,13 +34,12 @@ You can set CORS rules for each Azure Data Manager for Energy Preview instance.
33
34
9. An **Azure Data Manager for Energy Preview** instance is created with CORS policy.
34
35
10. Next, once the instance is created the CORS policy set can be viewed in instance **overview** page.
35
36
11. You can navigate to **Resource Sharing(CORS)** and see that CORS is enabled with required **Allowed Origins**.
36
-
37
-
[](media/how-to-enable-cors/enable-cors-3.png#lightbox)
37
+
[](media/how-to-enable-cors/enable-cors-3.png#lightbox)
38
38
39
39
## How are CORS rules evaluated?
40
40
CORS rules are evaluated as follows:
41
-
- First, the origin domain of the request is checked against the domains listed for the AllowedOrigins element.
42
-
- If the origin domain is included in the list, or all domains are allowed with the wildcard character '*', then rules evaluation proceeds. If the origin domain isn't included, then the request fails.
41
+
1. First, the origin domain of the request is checked against the domains listed for the AllowedOrigins element.
42
+
2. If the origin domain is included in the list, or all domains are allowed with the wildcard character '*', then rules evaluation proceeds. If the origin domain isn't included, then the request fails.
0 commit comments