Documentation ¶
Index ¶
- Constants
- type APIKeyInterceptor
- type ClientInterceptor
- type GithubValidator
- type JWTInterceptor
- type ServerInterceptor
- func (s *ServerInterceptor) Stream() grpc.StreamServerInterceptor
- func (s *ServerInterceptor) StreamServerInterceptor(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, ...) error
- func (s *ServerInterceptor) Unary() grpc.UnaryServerInterceptor
- func (s *ServerInterceptor) UnaryServerInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (resp interface{}, err error)
- type TeamsClient
- type TokenValidator
Constants ¶
View Source
const ( Audience = "hookd" GithubOIDCDiscoveryURL = "https://token.actions.githubusercontent.com/.well-known/jwks" Issuer = "https://token.actions.githubusercontent.com" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIKeyInterceptor ¶
func (*APIKeyInterceptor) GetRequestMetadata ¶
func (*APIKeyInterceptor) RequireTransportSecurity ¶
func (t *APIKeyInterceptor) RequireTransportSecurity() bool
type ClientInterceptor ¶
type GithubValidator ¶
type GithubValidator struct {
// contains filtered or unexported fields
}
func NewGithubValidator ¶
func NewGithubValidator() (*GithubValidator, error)
type JWTInterceptor ¶
func (*JWTInterceptor) GetRequestMetadata ¶
func (*JWTInterceptor) RequireTransportSecurity ¶
func (t *JWTInterceptor) RequireTransportSecurity() bool
type ServerInterceptor ¶
type ServerInterceptor struct { APIKeyStore database.ApiKeyStore TokenValidator TokenValidator TeamsClient TeamsClient }
func NewServerInterceptor ¶
func NewServerInterceptor(apiKeyStore database.ApiKeyStore, tokenValidator TokenValidator, teamsClient TeamsClient) *ServerInterceptor
func (*ServerInterceptor) Stream ¶
func (s *ServerInterceptor) Stream() grpc.StreamServerInterceptor
func (*ServerInterceptor) StreamServerInterceptor ¶
func (s *ServerInterceptor) StreamServerInterceptor(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error
func (*ServerInterceptor) Unary ¶
func (s *ServerInterceptor) Unary() grpc.UnaryServerInterceptor
func (*ServerInterceptor) UnaryServerInterceptor ¶
func (s *ServerInterceptor) UnaryServerInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (resp interface{}, err error)
type TeamsClient ¶
Click to show internal directories.
Click to hide internal directories.