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
Copy file name to clipboardExpand all lines: en/includes/guides/authentication/conditional-auth/configure-conditional-auth.md
+19-1Lines changed: 19 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,12 +25,26 @@ There are two ways to add a conditional authentication script:
25
25
- Write a [new conditional auth script]({{base_path}}/guides/authentication/conditional-auth/write-your-first-script/).
26
26
27
27
## Add a secret to the script
28
-
Secrets securely store values associated with external APIs. These secret values are used in conditional authentication scripts when {{ product_name }} is required to interact with an external API (service endpoint) during the authentication process. You can securely store these secret values on the {{ product_name }} Console and retrieve them whenever required for `callChoreo()` conditional authentication function.
28
+
Secrets securely store values associated with external APIs. These secret values are used in conditional authentication scripts when {{ product_name }} is required to interact with an external API (service endpoint) during the authentication process.
29
+
30
+
{% if product_name == "Asgardeo" or (product_name == "WSO2 Identity Server" and is_version != "7.0.0") %}
31
+
32
+
You can securely store these secret values on the {{ product_name }} Console and retrieve them whenever required for conditional authentication script.
33
+
34
+
{% else %}
35
+
36
+
You can securely store these secret values on the {{ product_name }} Console and retrieve them whenever required for `callChoreo()` conditional authentication function.
37
+
38
+
{% endif %}
39
+
40
+
{% if product_name == "Asgardeo" or (product_name == "WSO2 Identity Server" and is_version != "7.0.0") %}
29
41
30
42
!!! warning "Before you proceed"
31
43
32
44
When working with conditional authentication scripts, <b>never log secrets</b> or sensitive information within your authentication flows.
33
45
46
+
{% endif %}
47
+
34
48
### Create a new secret
35
49
36
50
To add a new secret:
@@ -81,6 +95,8 @@ To add a new secret:
81
95
82
96
6. Click **Finish** to complete the creation.
83
97
98
+
{% if product_name == "Asgardeo" or (product_name == "WSO2 Identity Server" and is_version != "7.0.0") %}
99
+
84
100
### Use secret in the script
85
101
86
102
You may refer to the previously added secrets in your conditional authentication scripts using the `secrets.{secret name}` syntax. For example, to retrieve a secret value, you may use:
@@ -91,6 +107,8 @@ var secretValue = secrets.secretName;
91
107
92
108
This allows you to securely access secret values within your authentication scripts, enhancing the security and flexibility of your authentication process.
0 commit comments