-
Notifications
You must be signed in to change notification settings - Fork 17
Expand file tree
/
Copy pathEnvVars.cs
More file actions
62 lines (51 loc) · 2.55 KB
/
EnvVars.cs
File metadata and controls
62 lines (51 loc) · 2.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
namespace Microsoft.Authentication.AzureAuth
{
/// <summary>
/// A static class to hold env var names.
/// </summary>
public static class EnvVars
{
/// <summary>Env var indicating we are in Cloud Build.</summary>
public const string CloudBuild = "QBUILD_DISTRIBUTED";
/// <summary>
/// Holds the name of the env var to get an application insights ingestion token.
/// </summary>
public static readonly string ApplicationInsightsIngestionTokenEnvVar = $"{EnvVarPrefix}_APPLICATION_INSIGHTS_INGESTION_TOKEN";
/// <summary>
/// Holds the path of the registry key to get an application insights ingestion token.
/// </summary>
public static readonly string ApplicationInsightsIngestionTokenRegKeyPath = @"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\AzureAuth";
/// <summary>
/// Holds the name of the registry key to get an application insights ingestion token.
/// </summary>
public static readonly string ApplicationInsightsIngestionTokenRegKeyName = "ApplicationInsightsIngestionToken";
/// <summary>
/// Holds the name of the env var to get a config file from.
/// </summary>
public static readonly string Config = $"{EnvVarPrefix}_CONFIG";
/// <summary>
/// Name of the env var used to disable Public Client Authentication.
/// </summary>
public static readonly string NoUser = $"{EnvVarPrefix}_NO_USER";
/// <summary>
/// Name of the env var for the Azure DevOps pipelines default personal access token.
/// </summary>
public static readonly string SystemAccessToken = "SYSTEM_ACCESSTOKEN";
/// <summary>
/// Name of the env var to check for an Azure DevOps personal access token.
/// </summary>
public static readonly string AdoPat = $"{EnvVarPrefix}_ADO_PAT";
/// <summary>
/// Name of the env var to get the Auth Mode.
/// </summary>
public static readonly string AuthMode = $"{EnvVarPrefix}_MODE";
/// <summary>
/// Name of the env var used to disable user based authentication modes.
/// NOTE: This is a private variable and it is recommended to not rely on this variable.
/// </summary>
internal static readonly string CorextNonInteractive = $"Corext_NonInteractive";
private const string EnvVarPrefix = "AZUREAUTH";
}
}