public DecryptionMaterials getDecryptionMaterials()

in sdk1/src/main/java/com/amazonaws/services/dynamodbv2/datamodeling/encryption/providers/WrappedMaterialsProvider.java [120:132]


  public DecryptionMaterials getDecryptionMaterials(EncryptionContext context) {
    try {
      if (macKey != null) {
        return new WrappedRawMaterials(
            wrappingKey, unwrappingKey, macKey, context.getMaterialDescription());
      } else {
        return new WrappedRawMaterials(
            wrappingKey, unwrappingKey, sigPair, context.getMaterialDescription());
      }
    } catch (GeneralSecurityException ex) {
      throw new DynamoDBMappingException("Unable to decrypt envelope key", ex);
    }
  }