-
Notifications
You must be signed in to change notification settings - Fork 40
/
config.go
55 lines (45 loc) · 2.59 KB
/
config.go
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
// Copyright (c) HashiCorp Inc. All rights reserved.
// Licensed under the MPL-2.0 License. See NOTICE.txt in the project root for license information.
package auth
import (
"github.com/hashicorp/go-azure-sdk/sdk/environments"
)
// Credentials sets up NewAuthorizer to return an Authorizer based on the provided credentails.
type Credentials struct {
// Specifies the national cloud environment to use
Environment environments.Environment
// AuxiliaryTenantIDs specifies the Auxiliary Tenant IDs for which to obtain tokens in a multi-tenant scenario.
AuxiliaryTenantIDs []string
// ClientID specifies the Client ID for the application used to authenticate the connection
ClientID string
// TenantID specifies the Azure Active Directory Tenant to connect to, which must be a valid UUID.
TenantID string
// EnableAuthenticatingUsingAzureCLI specifies whether Azure CLI authentication should be checked.
EnableAuthenticatingUsingAzureCLI bool
// EnableAuthenticatingUsingClientCertificate specifies whether Client Certificate authentication should be checked.
EnableAuthenticatingUsingClientCertificate bool
// ClientCertificateData specifies the contents of a Client Certificate PKCS#12 bundle.
ClientCertificateData []byte
// ClientCertificatePath specifies the path to a Client Certificate PKCS#12 bundle (.pfx file)
ClientCertificatePath string
// ClientCertificatePassword specifies the encryption password to unlock a Client Certificate.
ClientCertificatePassword string
// EnableAuthenticatingUsingClientSecret specifies whether Client Secret authentication should be used.
EnableAuthenticatingUsingClientSecret bool
// ClientSecret specifies the Secret used authenticate using Client Secret authentication.
ClientSecret string
// EnableAuthenticatingUsingManagedIdentity specifies whether Managed Identity authentication should be checked.
EnableAuthenticatingUsingManagedIdentity bool
// CustomManagedIdentityEndpoint specifies a custom endpoint which should be used for Managed Identity.
CustomManagedIdentityEndpoint string
// Enables OIDC authentication (federated client credentials).
EnableAuthenticationUsingOIDC bool
// OIDCAssertionToken specifies the OIDC Assertion Token to authenticate using Client Credentials.
OIDCAssertionToken string
// EnableAuthenticationUsingGitHubOIDC specifies whether GitHub OIDC
EnableAuthenticationUsingGitHubOIDC bool
// GitHubOIDCTokenRequestURL specifies the URL for GitHub's OIDC provider
GitHubOIDCTokenRequestURL string
// GitHubOIDCTokenRequestToken specifies the bearer token for the request to GitHub's OIDC provider
GitHubOIDCTokenRequestToken string
}