From 4a10f2c584837ed28f7bdba2918b0a9e3b161b74 Mon Sep 17 00:00:00 2001 From: vijayjt <2975049+vijayjt@users.noreply.github.com> Date: Thu, 24 Feb 2022 09:26:45 +0000 Subject: [PATCH] Rename new fields as per feedback to remove AAD from the name --- authority/provisioner/azure.go | 6 +++--- authority/provisioner/azure_test.go | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/authority/provisioner/azure.go b/authority/provisioner/azure.go index 453af2c5..14e94410 100644 --- a/authority/provisioner/azure.go +++ b/authority/provisioner/azure.go @@ -90,7 +90,7 @@ type Azure struct { TenantID string `json:"tenantID"` ResourceGroups []string `json:"resourceGroups"` SubscriptionIDs []string `json:"subscriptionIDs"` - AadObjectIDs []string `json:"aadObjectIDs"` + ObjectIDs []string `json:"ObjectIDs"` Audience string `json:"audience,omitempty"` DisableCustomSANs bool `json:"disableCustomSANs"` DisableTrustOnFirstUse bool `json:"disableTrustOnFirstUse"` @@ -308,9 +308,9 @@ func (p *Azure) AuthorizeSign(ctx context.Context, token string) ([]SignOption, } // Filter by Azure AD identity object id - if len(p.AadObjectIDs) > 0 { + if len(p.ObjectIDs) > 0 { var found bool - for _, i := range p.AadObjectIDs { + for _, i := range p.ObjectIDs { if i == identityObjectID { found = true break diff --git a/authority/provisioner/azure_test.go b/authority/provisioner/azure_test.go index 8a2126a9..4ab734d5 100644 --- a/authority/provisioner/azure_test.go +++ b/authority/provisioner/azure_test.go @@ -403,7 +403,7 @@ func TestAzure_AuthorizeSign(t *testing.T) { p7, err := generateAzure() assert.FatalError(t, err) p7.TenantID = p1.TenantID - p7.AadObjectIDs = []string{"the-oid"} + p7.ObjectIDs = []string{"the-oid"} p7.config = p1.config p7.oidcConfig = p1.oidcConfig p7.keyStore = p1.keyStore @@ -411,7 +411,7 @@ func TestAzure_AuthorizeSign(t *testing.T) { p8, err := generateAzure() assert.FatalError(t, err) p8.TenantID = p1.TenantID - p8.AadObjectIDs = []string{"foobarzar"} + p8.ObjectIDs = []string{"foobarzar"} p8.config = p1.config p8.oidcConfig = p1.oidcConfig p8.keyStore = p1.keyStore