Search code examples
c#amazon-web-servicesamazon-s3

AWS S3 GET after PUT includes chunk-signature data


After doing a PutObject to S3 of some simple text data and then retrieving that object back using GetObject, the object contains some extranneous chunk-signature data that I don't need, i.e.

n;chunk-signature=<hash>
my data
n;chunk-signature=<hash>

Is there any way through the .NET SDK to disable this?


Solution

  • The fix is to change UseChunkEncoding to false in the PutObjectRequest.

                PutObjectRequest request = new PutObjectRequest
                {
                    BucketName = <bucket>,
                    Key = <key>,
                    InputStream = <stream>,
                    ContentType = <contentType>,
                    UseChunkEncoding = false                
                };