forked from TrueCloudLab/certificates
Rename new fields as per feedback to remove AAD from the name
This commit is contained in:
parent
8b68bedffa
commit
4a10f2c584
2 changed files with 5 additions and 5 deletions
|
@ -90,7 +90,7 @@ type Azure struct {
|
||||||
TenantID string `json:"tenantID"`
|
TenantID string `json:"tenantID"`
|
||||||
ResourceGroups []string `json:"resourceGroups"`
|
ResourceGroups []string `json:"resourceGroups"`
|
||||||
SubscriptionIDs []string `json:"subscriptionIDs"`
|
SubscriptionIDs []string `json:"subscriptionIDs"`
|
||||||
AadObjectIDs []string `json:"aadObjectIDs"`
|
ObjectIDs []string `json:"ObjectIDs"`
|
||||||
Audience string `json:"audience,omitempty"`
|
Audience string `json:"audience,omitempty"`
|
||||||
DisableCustomSANs bool `json:"disableCustomSANs"`
|
DisableCustomSANs bool `json:"disableCustomSANs"`
|
||||||
DisableTrustOnFirstUse bool `json:"disableTrustOnFirstUse"`
|
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
|
// Filter by Azure AD identity object id
|
||||||
if len(p.AadObjectIDs) > 0 {
|
if len(p.ObjectIDs) > 0 {
|
||||||
var found bool
|
var found bool
|
||||||
for _, i := range p.AadObjectIDs {
|
for _, i := range p.ObjectIDs {
|
||||||
if i == identityObjectID {
|
if i == identityObjectID {
|
||||||
found = true
|
found = true
|
||||||
break
|
break
|
||||||
|
|
|
@ -403,7 +403,7 @@ func TestAzure_AuthorizeSign(t *testing.T) {
|
||||||
p7, err := generateAzure()
|
p7, err := generateAzure()
|
||||||
assert.FatalError(t, err)
|
assert.FatalError(t, err)
|
||||||
p7.TenantID = p1.TenantID
|
p7.TenantID = p1.TenantID
|
||||||
p7.AadObjectIDs = []string{"the-oid"}
|
p7.ObjectIDs = []string{"the-oid"}
|
||||||
p7.config = p1.config
|
p7.config = p1.config
|
||||||
p7.oidcConfig = p1.oidcConfig
|
p7.oidcConfig = p1.oidcConfig
|
||||||
p7.keyStore = p1.keyStore
|
p7.keyStore = p1.keyStore
|
||||||
|
@ -411,7 +411,7 @@ func TestAzure_AuthorizeSign(t *testing.T) {
|
||||||
p8, err := generateAzure()
|
p8, err := generateAzure()
|
||||||
assert.FatalError(t, err)
|
assert.FatalError(t, err)
|
||||||
p8.TenantID = p1.TenantID
|
p8.TenantID = p1.TenantID
|
||||||
p8.AadObjectIDs = []string{"foobarzar"}
|
p8.ObjectIDs = []string{"foobarzar"}
|
||||||
p8.config = p1.config
|
p8.config = p1.config
|
||||||
p8.oidcConfig = p1.oidcConfig
|
p8.oidcConfig = p1.oidcConfig
|
||||||
p8.keyStore = p1.keyStore
|
p8.keyStore = p1.keyStore
|
||||||
|
|
Loading…
Reference in a new issue