From a1f54921d2bd301b5aea2813d3ed60d354825169 Mon Sep 17 00:00:00 2001 From: Mariano Cano Date: Wed, 3 Aug 2022 12:07:45 -0700 Subject: [PATCH] Rename internal field --- authority/provisioner/jwk.go | 8 ++++---- authority/provisioner/x5c.go | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/authority/provisioner/jwk.go b/authority/provisioner/jwk.go index 966fa155..5cfb0409 100644 --- a/authority/provisioner/jwk.go +++ b/authority/provisioner/jwk.go @@ -23,8 +23,8 @@ type jwtPayload struct { } type stepPayload struct { - SSH *SignSSHOptions `json:"ssh,omitempty"` - RAInfo *RAInfo `json:"ra,omitempty"` + SSH *SignSSHOptions `json:"ssh,omitempty"` + RA *RAInfo `json:"ra,omitempty"` } // JWK is the default provisioner, an entity that can sign tokens necessary for @@ -175,10 +175,10 @@ func (p *JWK) AuthorizeSign(ctx context.Context, token string) ([]SignOption, er // Wrap provisioner if the token is an RA token. var self Interface = p - if claims.Step != nil && claims.Step.RAInfo != nil { + if claims.Step != nil && claims.Step.RA != nil { self = &raProvisioner{ Interface: p, - raInfo: claims.Step.RAInfo, + raInfo: claims.Step.RA, } } diff --git a/authority/provisioner/x5c.go b/authority/provisioner/x5c.go index 183d40ea..9f9a0e4e 100644 --- a/authority/provisioner/x5c.go +++ b/authority/provisioner/x5c.go @@ -223,10 +223,10 @@ func (p *X5C) AuthorizeSign(ctx context.Context, token string) ([]SignOption, er // Wrap provisioner if the token is an RA token. var self Interface = p - if claims.Step != nil && claims.Step.RAInfo != nil { + if claims.Step != nil && claims.Step.RA != nil { self = &raProvisioner{ Interface: p, - raInfo: claims.Step.RAInfo, + raInfo: claims.Step.RA, } }