rexCustomAwsSign

package
v1.0.33 Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2025 License: MIT Imports: 8 Imported by: 1

Documentation

Index

Constants

View Source
const (
	DeriveKeyPrefix = "REX4"

	// emptyStringSHA256 is a SHA256 of an empty string
	EmptyStringSHA256 = `e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855`
)

Variables

This section is empty.

Functions

func BuildCanonicalHeaders

func BuildCanonicalHeaders(r *http.Request) (canonicalHeaders string, signedHeaderStr string)

func BuildCanonicalString

func BuildCanonicalString(r *http.Request, canonicalHeaders, signedHeaders, bodyDigest string) string

func BuildCredentialString

func BuildCredentialString(region, service string, dt time.Time) string

func BuildSignature added in v1.0.32

func BuildSignature(Region, ServiceName, SecretAccessKey, stringToSign string, Time time.Time) string

func BuildSigningScope added in v1.0.31

func BuildSigningScope(region, service string, dt time.Time) string

func BuildStringToSign

func BuildStringToSign(reqTime, credentialString, canonicalString string) string

func DeriveSigningKey added in v1.0.31

func DeriveSigningKey(region, service, secretKey string, dt time.Time) []byte

func FormatDate

func FormatDate(now time.Time) string

func FormatShortTime added in v1.0.31

func FormatShortTime(dt time.Time) string

func HashSHA256 added in v1.0.32

func HashSHA256(data []byte) []byte

func HmacSHA256 added in v1.0.32

func HmacSHA256(key []byte, data []byte) []byte

func Sha256Content

func Sha256Content(bodyBytes []byte) (contentSha256 string)

func SignAuth added in v1.0.33

func SignAuth(accessKeyID, credentialString, signedHeaders, signature string) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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