durch / rust-s3

Rust library for interfacing with S3 API compatible services
MIT License
498 stars 195 forks source link

Fix etag generation for small files #324

Closed theCapypara closed 1 year ago

theCapypara commented 1 year ago

The etag algorithm was incorrect for files where the chunk size was < 2. The algorithm re-hashed the hashes, which isn't what is supposed to happen. This PR fixes the algorithm by not rehashing the digest for chunk size 1.

durch commented 1 year ago

@theCapypara great stuff, thank you