From a4cd213c41ed9111f3bc2dc90aa30416b724e6b7 Mon Sep 17 00:00:00 2001
From: Alex Barth <alex_b@53995.no-reply.drupal.org>
Date: Sun, 20 Jun 2010 01:10:29 +0000
Subject: [PATCH] #830438 andrewlevine: More secret files in
 FeedsImportBatch::getFilePath().

---
 CHANGELOG.txt           | 1 +
 includes/FeedsBatch.inc | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index ae301b98..ea376bcb 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -3,6 +3,7 @@
 Feeds 6.x 1.0 XXXXXXXXXXXXXXXXXXXX
 ----------------------------------
 
+- #830438 andrewlevine: More secret files in FeedsImportBatch::getFilePath().
 - #759302 rjb, smartinm, et. al: Fix user warning: Duplicate entry.
 - #819876 alex_b: Fix field 'url' and 'guid' don't have default values.
 - #623444 mongolito404, pvhee, pdrake, servantleader, alex_b et. al.: Mapper for
diff --git a/includes/FeedsBatch.inc b/includes/FeedsBatch.inc
index 99697f66..1981205c 100644
--- a/includes/FeedsBatch.inc
+++ b/includes/FeedsBatch.inc
@@ -98,7 +98,7 @@ class FeedsImportBatch extends FeedsBatch {
       if (!file_check_directory($dir, TRUE)) {
         throw new Exception(t('Feeds directory either cannot be created or is not writable.'));
       }
-      $dest = file_destination($dir . get_class($this) .'_'. md5($this->url) .'_'. time(), FILE_EXISTS_RENAME);
+      $dest = file_destination($dir . get_class($this) .'_'. drupal_get_token($this->url) .'_'. time(), FILE_EXISTS_RENAME);
       $this->file_path = file_save_data($this->getRaw(), $dest);
       if($this->file_path === 0) {
         throw new Exception(t('Cannot write content to %dest', array('%dest' => $dest)));
-- 
GitLab