Skip to content

Commit 03c6858

Browse files
authored
deprecate v4.SignHTTPRequestMiddleware (#2375)
1 parent 0be05fa commit 03c6858

File tree

2 files changed

+29
-5
lines changed

2 files changed

+29
-5
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"id": "4c5565e3-3b37-4494-8844-29e00bc1dc6b",
3+
"type": "bugfix",
4+
"description": "Mark v4.SignHTTPRequestMiddleware as deprecated, this middleware is no longer used by the SDK.",
5+
"modules": [
6+
"."
7+
]
8+
}

aws/signer/v4/middleware.go

+21-5
Original file line numberDiff line numberDiff line change
@@ -237,21 +237,32 @@ func (m *contentSHA256Header) HandleFinalize(
237237
return next.HandleFinalize(ctx, in)
238238
}
239239

240-
// SignHTTPRequestMiddlewareOptions is the configuration options for the SignHTTPRequestMiddleware middleware.
240+
// SignHTTPRequestMiddlewareOptions is the configuration options for
241+
// [SignHTTPRequestMiddleware].
242+
//
243+
// Deprecated: [SignHTTPRequestMiddleware] is deprecated.
241244
type SignHTTPRequestMiddlewareOptions struct {
242245
CredentialsProvider aws.CredentialsProvider
243246
Signer HTTPSigner
244247
LogSigning bool
245248
}
246249

247-
// SignHTTPRequestMiddleware is a `FinalizeMiddleware` implementation for SigV4 HTTP Signing
250+
// SignHTTPRequestMiddleware is a `FinalizeMiddleware` implementation for SigV4
251+
// HTTP Signing.
252+
//
253+
// Deprecated: AWS service clients no longer use this middleware. Signing as an
254+
// SDK operation is now performed through an internal per-service middleware
255+
// which opaquely selects and uses the signer from the resolved auth scheme.
248256
type SignHTTPRequestMiddleware struct {
249257
credentialsProvider aws.CredentialsProvider
250258
signer HTTPSigner
251259
logSigning bool
252260
}
253261

254-
// NewSignHTTPRequestMiddleware constructs a SignHTTPRequestMiddleware using the given Signer for signing requests
262+
// NewSignHTTPRequestMiddleware constructs a [SignHTTPRequestMiddleware] using
263+
// the given [Signer] for signing requests.
264+
//
265+
// Deprecated: SignHTTPRequestMiddleware is deprecated.
255266
func NewSignHTTPRequestMiddleware(options SignHTTPRequestMiddlewareOptions) *SignHTTPRequestMiddleware {
256267
return &SignHTTPRequestMiddleware{
257268
credentialsProvider: options.CredentialsProvider,
@@ -260,12 +271,17 @@ func NewSignHTTPRequestMiddleware(options SignHTTPRequestMiddlewareOptions) *Sig
260271
}
261272
}
262273

263-
// ID is the SignHTTPRequestMiddleware identifier
274+
// ID is the SignHTTPRequestMiddleware identifier.
275+
//
276+
// Deprecated: SignHTTPRequestMiddleware is deprecated.
264277
func (s *SignHTTPRequestMiddleware) ID() string {
265278
return "Signing"
266279
}
267280

268-
// HandleFinalize will take the provided input and sign the request using the SigV4 authentication scheme
281+
// HandleFinalize will take the provided input and sign the request using the
282+
// SigV4 authentication scheme.
283+
//
284+
// Deprecated: SignHTTPRequestMiddleware is deprecated.
269285
func (s *SignHTTPRequestMiddleware) HandleFinalize(ctx context.Context, in middleware.FinalizeInput, next middleware.FinalizeHandler) (
270286
out middleware.FinalizeOutput, metadata middleware.Metadata, err error,
271287
) {

0 commit comments

Comments
 (0)