Skip to content

Conversation

@analytically
Copy link
Contributor

@analytically analytically commented Nov 26, 2025

Add skip_s3_checksums to disable automatic checksum calculation and
validation for S3-compatible providers that don't support checksum
headers.

Add checksum_algorithm to specify which algorithm to use (CRC32,
CRC32C, SHA1, SHA256, CRC64NVME). Ignored when skip_s3_checksums
is enabled.

Removed UseV2Signing as it wasn't working and partially removed.

Add skip_s3_checksums to disable automatic checksum calculation and
validation for S3-compatible providers that don't support checksum
headers.

Add checksum_algorithm to specify which algorithm to use (CRC32,
CRC32C, SHA1, SHA256, CRC64NVME). Ignored when skip_s3_checksums
is enabled.

Removed UseV2Signing as it wasn't working and partially removed.

Signed-off-by: Mathias Bogaert <[email protected]>
@analytically analytically changed the title s3: implement skip_s3_checksums option s3: add checksum configuration options Nov 26, 2025
Copy link
Member

@taylorsilva taylorsilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, some tests would be nice though since the interaction between the two new params are spread out over different functions.

I would add tests:

var _ = Describe("Driver", func() {
Context("S3", func() {

and
var _ = Describe("S3 Driver", func() {

I would cover the basics:

  • Setting SkipS3Checksums results in the correct s3.Options being passed into the s3Client
  • Setting ChecksumAlgorithm results in the S3Driver being configured correctly
  • Setting ChecksumAlgorithm when SkipS3Checksums is true results in ChecksumAlgorithm being ignored and not passed into the S3Driver
  • When ChecksumAlgorithm is configured in the S3Driver, calling S3Driver.Put() passes in the ChecksumAlgorithm param.

TY!

Comment on lines +130 to +132
if source.ChecksumAlgorithm != "" && !source.SkipS3Checksums {
checksumAlgorithm = types.ChecksumAlgorithm(source.ChecksumAlgorithm)
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should check if the resulting checksumAlgorithm matches one of the types.ChecksumAlgorithm. As-is, someone can pass in anything and we'll happily pass it along.

@taylorsilva taylorsilva linked an issue Nov 26, 2025 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Resource should support skipping checksums for S3 backends

2 participants