Package org.opensearch.common.crypto
Class DecryptedRangedStreamProvider
java.lang.Object
org.opensearch.common.crypto.DecryptedRangedStreamProvider
Contains adjusted range of partial encrypted content which needs to be used for decryption.
-
Constructor Summary
ConstructorsConstructorDescriptionDecryptedRangedStreamProvider(long[] adjustedRange, UnaryOperator<InputStream> decryptedStreamProvider) To construct adjusted encrypted range. -
Method Summary
Modifier and TypeMethodDescriptionlong[]Adjusted range of partial encrypted content which needs to be used for decryption.A utility stream provider which supplies the stream responsible for decrypting the content and reading the desired range of decrypted content by skipping extra content which got decrypted as a result of range adjustment.
-
Constructor Details
-
DecryptedRangedStreamProvider
public DecryptedRangedStreamProvider(long[] adjustedRange, UnaryOperator<InputStream> decryptedStreamProvider) To construct adjusted encrypted range.- Parameters:
adjustedRange- range of partial encrypted content which needs to be used for decryption.decryptedStreamProvider- stream provider for decryption and range re-adjustment.
-
-
Method Details
-
getAdjustedRange
public long[] getAdjustedRange()Adjusted range of partial encrypted content which needs to be used for decryption.- Returns:
- adjusted range
-
getDecryptedStreamProvider
A utility stream provider which supplies the stream responsible for decrypting the content and reading the desired range of decrypted content by skipping extra content which got decrypted as a result of range adjustment.- Returns:
- stream provider for decryption and supplying the desired range of content.
-