JavaScript is disabled on your browser.
Skip navigation links

AWS SDK for Java 1.x API Reference - 1.12.795

We announced the upcoming end-of-support for AWS SDK for Java (v1). We recommend that you migrate to AWS SDK for Java v2. For dates, additional details, and information on how to migrate, please refer to the linked announcement.
com.amazonaws.services.s3.internal

Class SkipMd5CheckStrategy



  • public class SkipMd5CheckStrategy
    extends Object 
    Logic for determining whether MD5 checksum validation should be performed or not.
    • Field Detail

      • DISABLE_GET_OBJECT_MD5_VALIDATION_PROPERTY

        public static final String DISABLE_GET_OBJECT_MD5_VALIDATION_PROPERTY
        System property to disable MD5 validation for GetObject. Any value set for this property will disable validation.
        See Also:
        Constant Field Values
      • DISABLE_PUT_OBJECT_MD5_VALIDATION_PROPERTY

        public static final String DISABLE_PUT_OBJECT_MD5_VALIDATION_PROPERTY
        System property to disable MD5 validation for both PutObject and UploadPart. Any value set for this property will disable validation.
        See Also:
        Constant Field Values
    • Method Detail

      • skipClientSideValidationPerGetResponse

        public boolean skipClientSideValidationPerGetResponse(ObjectMetadata metadata)
        Determines whether the client should use the Headers.ETAG header returned by S3 to validate the integrity of the message client side based on the server response. We skip the client side check if any of the following conditions are true:
        1. The system property "com.amazonaws.services.s3.disableGetObjectMD5Validation" is set
        2. The request involves SSE-C or SSE-KMS
        3. The Etag header is missing
        4. The Etag indicates that the object was created by a MultiPart Upload
        Returns:
        True if client side validation should be skipped, false otherwise.
      • skipClientSideValidationPerPutResponse

        public boolean skipClientSideValidationPerPutResponse(ObjectMetadata metadata)
        Determines whether the client should use the Headers.ETAG header returned by S3 to validate the integrity of the message client side based on the server response. We skip the client side check if any of the following conditions are true:
        1. The system property "com.amazonaws.services.s3.disablePutObjectMD5Validation" is set
        2. The request involves SSE-C or SSE-KMS
        3. The Etag header is missing
        Returns:
        True if client side validation should be skipped, false otherwise.
      • skipClientSideValidationPerUploadPartResponse

        public boolean skipClientSideValidationPerUploadPartResponse(ObjectMetadata metadata)
        Determines whether the client should use the Headers.ETAG header returned by S3 to validate the integrity of the message client side based on the server response. We skip the client side check if any of the following conditions are true:
        1. The system property "com.amazonaws.services.s3.disablePutObjectMD5Validation" is set
        2. The request involves SSE-C or SSE-KMS
        3. The Etag header is missing
        Returns:
        True if client side validation should be skipped, false otherwise.
      • skipClientSideValidationPerRequest

        public boolean skipClientSideValidationPerRequest(PutObjectRequest request)
        Determines whether the client should use the Headers.ETAG header returned by S3 to validate the integrity of the message client side. We skip the client side check if any of the following conditions are true:
        1. The system property "com.amazonaws.services.s3.disablePutObjectMD5Validation" is set
        2. The request involves SSE-C or SSE-KMS
        Returns:
        True if client side validation should be skipped, false otherwise.
      • skipClientSideValidationPerRequest

        public boolean skipClientSideValidationPerRequest(UploadPartRequest request)
        Determines whether the client should use the Headers.ETAG header returned by S3 to validate the integrity of the message client side. We skip the client side check if any of the following conditions are true:
        1. The system property "com.amazonaws.services.s3.disablePutObjectMD5Validation" is set
        2. The request involves SSE-C or SSE-KMS
        Returns:
        True if client side validation should be skipped, false otherwise.
      • skipServerSideValidation

        public boolean skipServerSideValidation(PutObjectRequest request)
        Determines whether the client should calculate and send the Headers.CONTENT_MD5 header to be validated by S3 per the request.

        Currently we always try and do server side validation unless it's been explicitly disabled by the "com.amazonaws.services.s3.disablePutObjectMD5Validation" property. Whether or not we actually calculate the MD5 header is determined in the client based on the source of the data (i.e. if it's a file we calculate, if not then we don't)

      • skipServerSideValidation

        public boolean skipServerSideValidation(UploadPartRequest request)
        Determines whether the client should calculate and send the Headers.CONTENT_MD5 header to be validated by S3 per the request.

        Currently we always try and do server side validation unless it's been explicitly disabled by the "com.amazonaws.services.s3.disablePutObjectMD5Validation" property. Whether or not we actually calculate the MD5 header is determined in the client based on the source of the data (i.e. if it's a file we calculate, if not then we don't)

      • skipClientSideValidationPerRequest

        public boolean skipClientSideValidationPerRequest(GetObjectRequest request)
        Based on the given GetObjectRequest, returns whether the specified request should skip MD5 check on the requested object content. Specifically, MD5 check should be skipped if one of the following conditions are true:
        1. The system property "com.amazonaws.services.s3.disableGetObjectMD5Validation" is set.
        2. The request is a range-get operation
        3. The request is a GET object operation that involves SSE-C
        Otherwise, MD5 check should not be skipped.
      • skipClientSideValidationPerRequest

        public boolean skipClientSideValidationPerRequest(PresignedUrlUploadRequest request)
        Determines whether the client should use the Headers.ETAG header returned by S3 to validate the integrity of the message client side. We skip the client side check if any of the following conditions are true:
        1. The system property "com.amazonaws.services.s3.disablePutObjectMD5Validation" is set
        2. The request involves SSE-C or SSE-KMS
        Returns:
        True if client side validation should be skipped, false otherwise.
Skip navigation links

AltStyle によって変換されたページ (->オリジナル) /