1 |
prometheanfire 15/07/29 03:27:30 |
2 |
|
3 |
Added: CVE-2015-3289_2015.1.0.patch |
4 |
Log: |
5 |
bumping for CVE-2015-3289 |
6 |
|
7 |
(Portage version: 2.2.20/cvs/Linux x86_64, signed Manifest commit with key 0x33ED3FD25AFC78BA) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 app-admin/glance/files/CVE-2015-3289_2015.1.0.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-admin/glance/files/CVE-2015-3289_2015.1.0.patch?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-admin/glance/files/CVE-2015-3289_2015.1.0.patch?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: CVE-2015-3289_2015.1.0.patch |
16 |
=================================================================== |
17 |
From 88f92eb11d556bf43e2800a05973ad2da0db0195 Mon Sep 17 00:00:00 2001 |
18 |
From: Flavio Percoco <flaper87@×××××.com> |
19 |
Date: Fri, 8 May 2015 11:44:14 +0200 |
20 |
Subject: [PATCH] Save image data after setting the data |
21 |
|
22 |
The image's locations are missing when image's are imported using tasks |
23 |
because the ImportToStore task is not saving the image metadata after |
24 |
the import. This patch fixes that. |
25 |
|
26 |
Change-Id: I43dec450d5fc4bee2131d78dbe3c2b2373c3f739 |
27 |
Closes-bug: #1453068 |
28 |
(cherry picked from commit 4efb56aae9288952bdb0d368a7c307e8524b80d8) |
29 |
--- |
30 |
glance/async/flows/base_import.py | 4 ++++ |
31 |
glance/tests/unit/async/flows/test_import.py | 4 ++++ |
32 |
2 files changed, 8 insertions(+) |
33 |
|
34 |
diff --git a/glance/async/flows/base_import.py b/glance/async/flows/base_import.py |
35 |
index 487247c..7656bde 100644 |
36 |
--- a/glance/async/flows/base_import.py |
37 |
+++ b/glance/async/flows/base_import.py |
38 |
@@ -283,6 +283,10 @@ class _ImportToStore(task.Task): |
39 |
|
40 |
image_import.set_image_data(image, file_path or self.uri, None) |
41 |
|
42 |
+ # NOTE(flaper87): We need to save the image again after the locations |
43 |
+ # have been set in the image. |
44 |
+ self.image_repo.save(image) |
45 |
+ |
46 |
|
47 |
class _SaveImage(task.Task): |
48 |
|
49 |
diff --git a/glance/tests/unit/async/flows/test_import.py b/glance/tests/unit/async/flows/test_import.py |
50 |
index 0f355bc..7acd599 100644 |
51 |
--- a/glance/tests/unit/async/flows/test_import.py |
52 |
+++ b/glance/tests/unit/async/flows/test_import.py |
53 |
@@ -112,6 +112,10 @@ class TestImportTask(test_utils.BaseTestCase): |
54 |
"%s.tasks_import" % image_path) |
55 |
self.assertFalse(os.path.exists(tmp_image_path)) |
56 |
self.assertTrue(os.path.exists(image_path)) |
57 |
+ self.assertEqual(1, len(list(self.image.locations))) |
58 |
+ self.assertEqual("file://%s/%s" % (self.test_dir, |
59 |
+ self.image.image_id), |
60 |
+ self.image.locations[0]['url']) |
61 |
|
62 |
def test_import_flow_missing_work_dir(self): |
63 |
self.config(engine_mode='serial', group='taskflow_executor') |
64 |
-- |
65 |
2.3.6 |