code: private static String getPermissionsPolicyWithKMSResources(String s3Prefix) {
          return readResource(IAM_ROLE_PERMISSIONS_POLICY_WITH_KMS_RESOURCES_DOCUMENT)
                  .replace("{{S3_BUCKET_NAME}}", s3BucketName)
                  .replace("{{KMS_KEY_ARN}}", s3DestinationAWSKMSKeyId)
                  .replace("{{S3_REGION}}", s3RegionName)
                  .replace("{{S3_PREFIX}}", s3Prefix);
      }
docs: Method to return the permissions policy document with KMS resource.
  
  @param s3Prefix the s3Prefix to be specified in KMS Condition
  @return the permissions policy document