Package com.amazonaws.services.s3.model
Class EncryptedGetObjectRequest
java.lang.Object
com.amazonaws.AmazonWebServiceRequest
com.amazonaws.services.s3.model.GetObjectRequest
com.amazonaws.services.s3.model.EncryptedGetObjectRequest
- All Implemented Interfaces:
ReadLimitInfo
,SSECustomerKeyProvider
,Serializable
,Cloneable
An extension of GetObjectRequest
to allow additional encryption
material description to be specified on a per-request basis. In particular,
EncryptedGetObjectRequest
is only recognized by
AmazonS3EncryptionClient
.
If EncryptedGetObjectRequest
is used against the non-encrypting
AmazonS3Client
, the additional attributes will be ignored.
The additional material description must not conflict with the existing one saved in S3 or else will cause the get request to fail fast later on.
- See Also:
-
Field Summary
Fields inherited from class com.amazonaws.AmazonWebServiceRequest
NOOP
-
Constructor Summary
ConstructorsConstructorDescriptionEncryptedGetObjectRequest
(S3ObjectId s3ObjectId) EncryptedGetObjectRequest
(String bucketName, String key) EncryptedGetObjectRequest
(String bucketName, String key, boolean isRequesterPays) EncryptedGetObjectRequest
(String bucketName, String key, String versionId) -
Method Summary
Modifier and TypeMethodDescriptionReturns the supplemental material description to be used for retrieving the encryption materials.boolean
Returns true if key wrapping is expected; false otherwise.void
setExtraMaterialDescription
(ExtraMaterialsDescription supplemental) Sets the supplemental materials description for the encryption materials to be used with the current request.void
setInstructionFileSuffix
(String instructionFileSuffix) Explicitly sets the suffix of an instruction file to be used to retrieve the S3 encrypted object.void
setKeyWrapExpected
(boolean keyWrapExpected) withExtraMaterialsDescription
(ExtraMaterialsDescription supplemental) Sets the supplemental materials description for the encryption materials to be used with the current request.withExtraMaterialsDescription
(Map<String, String> supplemental) Fluent API to set the supplemental materials description for the encryption materials to be used with the current request.withInstructionFileSuffix
(String instructionFileSuffix) Fluent API to explicitly sets the suffix of an instruction file to be used to retrieve the S3 encrypted object.withKeyWrapExpected
(boolean keyWrapExpected) Fluent API forsetKeyWrapExpected(boolean)
.Methods inherited from class com.amazonaws.services.s3.model.GetObjectRequest
getBucketName, getKey, getMatchingETagConstraints, getModifiedSinceConstraint, getNonmatchingETagConstraints, getPartNumber, getProgressListener, getRange, getResponseHeaders, getS3ObjectId, getSSECustomerKey, getUnmodifiedSinceConstraint, getVersionId, isRequesterPays, setBucketName, setKey, setMatchingETagConstraints, setModifiedSinceConstraint, setNonmatchingETagConstraints, setPartNumber, setProgressListener, setRange, setRange, setRequesterPays, setResponseHeaders, setS3ObjectId, setSSECustomerKey, setUnmodifiedSinceConstraint, setVersionId, withBucketName, withKey, withMatchingETagConstraint, withModifiedSinceConstraint, withNonmatchingETagConstraint, withPartNumber, withProgressListener, withRange, withRange, withRequesterPays, withResponseHeaders, withS3ObjectId, withSSECustomerKey, withUnmodifiedSinceConstraint, withVersionId
Methods inherited from class com.amazonaws.AmazonWebServiceRequest
clone, copyBaseTo, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
-
Constructor Details
-
EncryptedGetObjectRequest
-
EncryptedGetObjectRequest
-
EncryptedGetObjectRequest
-
EncryptedGetObjectRequest
-
-
Method Details
-
getExtraMaterialDescription
Returns the supplemental material description to be used for retrieving the encryption materials.- Returns:
- the supplemental material description; never null.
-
setExtraMaterialDescription
Sets the supplemental materials description for the encryption materials to be used with the current request.- Parameters:
supplemental
- the materialsDescription to set; must not conflict with the existing one saved in S3 or else will cause the get request to fail fast later on
-
withExtraMaterialsDescription
public EncryptedGetObjectRequest withExtraMaterialsDescription(ExtraMaterialsDescription supplemental) Sets the supplemental materials description for the encryption materials to be used with the current request.- Parameters:
supplemental
- the materialsDescription to set; must not conflict with the existing one saved in S3 or else will cause the get request to fail fast later on
-
withExtraMaterialsDescription
Fluent API to set the supplemental materials description for the encryption materials to be used with the current request.- Parameters:
supplemental
- the materialsDescription to set; must not conflict with the existing one saved in S3 or else will cause the get request to fail fast later on
-
getInstructionFileSuffix
-
setInstructionFileSuffix
Explicitly sets the suffix of an instruction file to be used to retrieve the S3 encrypted object. Typically this is for more advanced use cases where multiple crypto instruction files have been created for the same S3 object. Each instruction file contains the same CEK encrypted under a different KEK, the IV, and other meta information (aka material description).- Parameters:
instructionFileSuffix
- suffix of the instruction file to be used.- See Also:
-
withInstructionFileSuffix
Fluent API to explicitly sets the suffix of an instruction file to be used to retrieve the S3 encrypted object. Typically this is for more advanced use cases where multiple crypto instruction files have been created for the same S3 object. Each instruction file contains the same CEK encrypted under a different KEK, the IV, and other meta information (aka material description).- Parameters:
instructionFileSuffix
- suffix of the instruction file to be used.- See Also:
-
isKeyWrapExpected
public boolean isKeyWrapExpected()Returns true if key wrapping is expected; false otherwise. Note, however, that ifCryptoMode.StrictAuthenticatedEncryption
or KMS is in use, key wrapping is always expected for the CEK regardless. -
setKeyWrapExpected
public void setKeyWrapExpected(boolean keyWrapExpected) - Parameters:
keyWrapExpected
- true if key wrapping is expected for the CEK; false otherwse. Note, however, that ifCryptoMode.StrictAuthenticatedEncryption
or KMS is in use, key wrapping is always expected for the CEK regardless.If keyWrapExpected is set to true but the CEK is found to be not key-wrapped, it would cause a
KeyWrapException
to be thrown.
-
withKeyWrapExpected
Fluent API forsetKeyWrapExpected(boolean)
.
-