iamgoogle

package
v0.34.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 15, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package iamgoogle provides Google-specific IAM primitives. See: https://developers.google.com/identity/protocols/oauth2/openid-connect

Index

Constants

View Source
const Issuer = "https://accounts.google.com"

Issuer is the issuer of Google ID tokens.

Variables

This section is empty.

Functions

func Email

func Email(payload *idtoken.Payload) (string, bool)

Email returns the payload's `email` claim.

func HostedDomain

func HostedDomain(payload *idtoken.Payload) (string, bool)

HostedDomain returns the payload's `hd` claim.

func IsEmailVerified

func IsEmailVerified(payload *idtoken.Payload) bool

IsEmailVerified returns true if the payload has the `email_verified` claim.

func IsGoogleCloudServiceAccountEmail

func IsGoogleCloudServiceAccountEmail(payload *idtoken.Payload) bool

IsGoogleCloudServiceAccountEmail returns true if the payload has a verified email belonging to a Google Cloud service account.

func IsGoogleIDToken

func IsGoogleIDToken(token iamjwt.Token) bool

IsGoogleIDToken returns true if the JWT payload is from a Google ID token. See: https://developers.google.com/identity/protocols/oauth2/openid-connect

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL