Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

otelaws created invalid request signatures in v0.36.4 #2980

Open
jamestoyer opened this issue Nov 7, 2022 · 2 comments
Open

otelaws created invalid request signatures in v0.36.4 #2980

jamestoyer opened this issue Nov 7, 2022 · 2 comments
Assignees
Labels
bug Something isn't working instrumentation: otelaws

Comments

@jamestoyer
Copy link

It appears there is an issue with the go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws in v0.36.4. After upgrading from v0.36.3 to v0.36.4 in one of our projects we have started to see the following error when accessing DynamoDB:

operation error DynamoDB: Query, https response error StatusCode: 400, RequestID: <request id>, api error InvalidSignatureException: The request signature we calculated does not match the signature you provided. Check your AWS Secret Access Key and signing method. Consult the service documentation for details.

Comparing the versions, it appears that #2856 is the only change between the two versions.

Steps to repro

Create a new AWS DynamoDB client and attempt to get an item. In v.0.36.3 this works but in v.0.36.4 this will fail.

Example code:

configOptions := []func(*awsconfig.LoadOptions) error{
  awsconfig.WithRegion("us-east-1"),
}

awsConfig, err := awsconfig.LoadDefaultConfig(ctx, configOptions...)

if err != nil {
  panic(err)
}

otelaws.AppendMiddlewares(&awsConfig.APIOptions)
dynamoDBService = dynamodb.NewFromConfig(awsConfig)

key := make(map[string]types.AttributeValue)
key["partition_key_name"] = &types.AttributeValueMemberS{Value: "partition_key_value"}

input := &dynamodb.GetItemInput{
  TableName: aws.String(<table name>),
  Key:       key.getDynamoDBKey(),
}
result, err := dynamoDBService.GetItem(ctx, input)
if err != nil {
  panic(err)
}

Where partition_key_name is the partition key of a given tale and partition_key_value is the value of an entry for it.

@MrAlias MrAlias added bug Something isn't working instrumentation: otelaws labels Nov 7, 2022
@andrewbenton
Copy link

I'm seeing the same issue with v0.36.4 after upgrading from v0.36.2

@Aneurysm9 Aneurysm9 self-assigned this Nov 11, 2022
@Aneurysm9 Aneurysm9 added this to the v0.36.5 milestone Nov 11, 2022
@MrAlias MrAlias modified the milestones: v0.36.5, v0.37.1 Dec 6, 2022
@lgcmotta
Copy link

lgcmotta commented Feb 7, 2023

I having the same problem with v0.38.0 (#3368)

@MrAlias MrAlias modified the milestones: v0.37.1, v0.39.0 Feb 8, 2023
@MrAlias MrAlias modified the milestones: v0.39.0, v0.42.0 Apr 28, 2023
@MrAlias MrAlias modified the milestones: v0.43.0, v0.44.0 Aug 28, 2023
@MrAlias MrAlias modified the milestones: v1.20.0/v0.45.0, v0.46.0 Sep 28, 2023
@pellared pellared modified the milestones: v0.46.0, v0.47.0 Nov 6, 2023
@pellared pellared removed this from the v0.47.0 milestone Dec 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working instrumentation: otelaws
Projects
None yet
Development

No branches or pull requests

6 participants