{"action":"created","issue":{"url":"https://api.github.com/repos/aws/aws-sdk-java/issues/79","labels_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/79/labels{/name}","comments_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/79/comments","events_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/79/events","html_url":"https://github.com/aws/aws-sdk-java/issues/79","id":15215010,"number":79,"title":"Intermittent \"signature we calculated does not match\" errors","user":{"login":"rtyley","id":52038,"avatar_url":"https://avatars.githubusercontent.com/u/52038?v=3","gravatar_id":"","url":"https://api.github.com/users/rtyley","html_url":"https://github.com/rtyley","followers_url":"https://api.github.com/users/rtyley/followers","following_url":"https://api.github.com/users/rtyley/following{/other_user}","gists_url":"https://api.github.com/users/rtyley/gists{/gist_id}","starred_url":"https://api.github.com/users/rtyley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rtyley/subscriptions","organizations_url":"https://api.github.com/users/rtyley/orgs","repos_url":"https://api.github.com/users/rtyley/repos","events_url":"https://api.github.com/users/rtyley/events{/privacy}","received_events_url":"https://api.github.com/users/rtyley/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2013-06-06T10:05:52Z","updated_at":"2015-10-20T10:03:27Z","closed_at":"2013-06-19T09:36:14Z","body":"We (and [other users](https://forums.aws.amazon.com/message.jspa?messageID=457861#457861)) have been seeing weird _intermittent_ signing errors - in a given day, many thousands of requests succeed, but about a dozen requests fail (`v1.4.4.1` & `v1.4.5`) :\r\n\r\n```\r\ncom.amazonaws.AmazonServiceException: 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.\r\n\r\nThe Canonical String for this request should have been\r\n'POST\r\n/\r\n\r\ncontent-length:222\r\ncontent-type:application/x-amz-json-1.0\r\nhost:dynamodb.eu-west-1.amazonaws.com\r\nuser-agent:aws-sdk-java/1.4.5 Linux/3.4.43-43.43.amzn1.x86_64 Java_HotSpot(TM)_64-Bit_Server_VM/17.0-b16\r\nx-amz-date:20130605T125514Z\r\nx-amz-target:DynamoDB_20120810.Query\r\n\r\ncontent-length;content-type;host;user-agent;x-amz-date;x-amz-target\r\n87fa64cc8ba1483914fbde19afaf5a727957ed72845e4c1039320495fe46acb1'\r\n\r\nThe String-to-Sign should have been\r\n'AWS4-HMAC-SHA256\r\n20130605T125514Z\r\n20130605/eu-west-1/dynamodb/aws4_request\r\nf53aaa5fe95ed6c0e9f34f8bfd630cb87a189ed2be914e402842fe104e7cdfdf'\r\n\r\n        at com.amazonaws.http.AmazonHttpClient.handleErrorResponse(AmazonHttpClient.java:653) ~[ios_purchases_api.jar:na]\r\n        at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:347) ~[ios_purchases_api.jar:na]\r\n        at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:199) ~[ios_purchases_api.jar:na]\r\n        at com.amazonaws.services.dynamodbv2.AmazonDynamoDBClient.invoke(AmazonDynamoDBClient.java:1245)\r\n```\r\n\r\nWe're currently getting a dozen or so errors like this a day in Production, and they seem bizarre, given that we are making lots of successful requests with the exact same credentials.\r\n\r\nWe use a single instance of the `com.amazonaws.services.dynamodbv2.AmazonDynamoDBClient` class, shared between threads, which lives for the life of the JVM. Is any of that incorrect use?\r\n\r\ncc'ing @fulghum because of the big changes to `com.amazonaws.auth.AWS4Signer ` in v1.4.4 https://github.com/aws/aws-sdk-java/commit/c2f2e516#diff-4\r\n\r\n(initially reported at https://forums.aws.amazon.com/thread.jspa?messageID=457465)"},"comment":{"url":"https://api.github.com/repos/aws/aws-sdk-java/issues/comments/149505292","html_url":"https://github.com/aws/aws-sdk-java/issues/79#issuecomment-149505292","issue_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/79","id":149505292,"user":{"login":"guptaabhishek849","id":1288790,"avatar_url":"https://avatars.githubusercontent.com/u/1288790?v=3","gravatar_id":"","url":"https://api.github.com/users/guptaabhishek849","html_url":"https://github.com/guptaabhishek849","followers_url":"https://api.github.com/users/guptaabhishek849/followers","following_url":"https://api.github.com/users/guptaabhishek849/following{/other_user}","gists_url":"https://api.github.com/users/guptaabhishek849/gists{/gist_id}","starred_url":"https://api.github.com/users/guptaabhishek849/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guptaabhishek849/subscriptions","organizations_url":"https://api.github.com/users/guptaabhishek849/orgs","repos_url":"https://api.github.com/users/guptaabhishek849/repos","events_url":"https://api.github.com/users/guptaabhishek849/events{/privacy}","received_events_url":"https://api.github.com/users/guptaabhishek849/received_events","type":"User","site_admin":false},"created_at":"2015-10-20T10:03:27Z","updated_at":"2015-10-20T10:03:27Z","body":"I am seeing the same issue from the C++ library which is making s3 REST Calls. I am sending multiple request is parallel with around 64 threads and seeing this issue for 1/~5000 requests and retry passes for the failed request.\r\n\r\n@yifeireplay , @fulghum , Can you tell what was the fix that was put in to fix the issue?\r\n\r\nThanks"}}