smithy

package
v1.32.7 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package smithy adapts concrete AWS auth and signing types to the generic smithy versions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BearerTokenAdapter

type BearerTokenAdapter struct {
	Token bearer.Token
}

BearerTokenAdapter adapts smithy bearer.Token to smithy auth.Identity.

func (*BearerTokenAdapter) Expiration

func (v *BearerTokenAdapter) Expiration() time.Time

Expiration returns the time of expiration for the token.

type BearerTokenProviderAdapter

type BearerTokenProviderAdapter struct {
	Provider bearer.TokenProvider
}

BearerTokenProviderAdapter adapts smithy bearer.TokenProvider to smithy auth.IdentityResolver.

func (*BearerTokenProviderAdapter) GetIdentity

func (v *BearerTokenProviderAdapter) GetIdentity(ctx context.Context, _ smithy.Properties) (
	auth.Identity, error,
)

GetIdentity retrieves a bearer token using the underlying provider.

type BearerTokenSignerAdapter

type BearerTokenSignerAdapter struct {
	Signer bearer.Signer
}

BearerTokenSignerAdapter adapts smithy bearer.Signer to smithy http auth.Signer.

func (*BearerTokenSignerAdapter) SignRequest

func (v *BearerTokenSignerAdapter) SignRequest(ctx context.Context, r *smithyhttp.Request, identity auth.Identity, _ smithy.Properties) error

SignRequest signs the request with the provided bearer token.

type CredentialsAdapter

type CredentialsAdapter struct {
	Credentials aws.Credentials
}

CredentialsAdapter adapts aws.Credentials to auth.Identity.

func (*CredentialsAdapter) Expiration

func (v *CredentialsAdapter) Expiration() time.Time

Expiration returns the time of expiration for the credentials.

type CredentialsProviderAdapter

type CredentialsProviderAdapter struct {
	Provider aws.CredentialsProvider
}

CredentialsProviderAdapter adapts aws.CredentialsProvider to auth.IdentityResolver.

func (*CredentialsProviderAdapter) GetIdentity

func (v *CredentialsProviderAdapter) GetIdentity(ctx context.Context, _ smithy.Properties) (
	auth.Identity, error,
)

GetIdentity retrieves AWS credentials using the underlying provider.

type V4SignerAdapter

type V4SignerAdapter struct {
	Signer     v4.HTTPSigner
	Logger     logging.Logger
	LogSigning bool
}

V4SignerAdapter adapts v4.HTTPSigner to smithy http.Signer.

func (*V4SignerAdapter) SignRequest

func (v *V4SignerAdapter) SignRequest(ctx context.Context, r *smithyhttp.Request, identity auth.Identity, props smithy.Properties) error

SignRequest signs the request with the provided identity.

Jump to

Keyboard shortcuts

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