Documentation
¶
Index ¶
- func EnrootImageFormat(dockerImage string) (enrootImage string, err error)
- func IsNotExpired(expiresAt time.Time, margin time.Duration, required bool) bool
- func VerifyExpiresAtClaim(claims jwt.RegisteredClaims, margin time.Duration, required bool) (bool, error)
- func VerifyJWTExpiresAt(token string, margin time.Duration, required bool) (bool, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnrootImageFormat ¶
EnrootImageFormat transforms the input dockerImage into a string suitable for enroot.
See: https://docs.cscs.ch/software/container-engine/run/#pulling-images-manually
func IsNotExpired ¶
IsNotExpired returns true if expiresAt is still in the future, with a given margin. When expiresAt is zero, returns !required.
func VerifyExpiresAtClaim ¶
func VerifyExpiresAtClaim(claims jwt.RegisteredClaims, margin time.Duration, required bool) (bool, error)
VerifyExpiresAtClaim returns true is the expiry (claims.GetExpirationTime()) is still in the future, with a given margin. When the expiry is omitted, returns !required.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.