Documentation
      ¶
    
    
  
    
  
    Index ¶
Constants ¶
      View Source
      
  
const Audience = "api-token-auth.chainloop"
    Variables ¶
      View Source
      
  
var SigningMethod = jwt.SigningMethodHS256
    Functions ¶
This section is empty.
Types ¶
type Builder ¶
type Builder struct {
	// contains filtered or unexported fields
}
    func NewBuilder ¶
NewBuilder creates a new APIToken JWT builder It supports expiration and revocation Currently we use a simple hmac encryption method meant to be continuously rotated TODO: additional/alternative encryption method, i.e DSE asymmetric, see CAS robot account for reference
func (*Builder) GenerateJWT ¶
func (ra *Builder) GenerateJWT(opts *GenerateJWTOptions) (string, error)
GenerateJWT creates a new JWT token for the given organization and keyID
type CustomClaims ¶
type GenerateJWTOptions ¶ added in v1.12.0
 Click to show internal directories. 
   Click to hide internal directories.