Skip to content

Draft: Recognize uploads through fog gem to be file storage

Aakriti Gupta requested to merge ag-file-storage-valid-wtih-fog-gem into master

What does this MR do?

While uploading Terraform State files, we use carrierwave and fog gems.

When checking if the file's checksum can be calculated, we check what the file storage object is. For Terraform uploads through Terraform::StateUploader we expect the storage to specifically be of the type CarrierWave::Storage::File, but when external object storage is used, the storage is actually of type Carrierwave::Storage::Fog. Both these classes inherit from CarrierWave::Storage::Abstract.

This discrepancy breaks checksum calculation for Geo.

One solution is to check explicitly for both these classes.

Screenshots (strongly suggested)

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

Does this MR contain changes to processing or storing of credentials or tokens, authorization and authentication methods or other items described in the security review guidelines? If not, then delete this Security section.

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team
Edited by Aakriti Gupta

Merge request reports

Loading