Merge lp:~apw/launchpad/signing-reinstate-raw-uefi-custom-upload into lp:launchpad

Proposed by Andy Whitcroft
Status: Merged
Merged at revision: 18080
Proposed branch: lp:~apw/launchpad/signing-reinstate-raw-uefi-custom-upload
Merge into: lp:launchpad
Diff against target: 415 lines (+165/-46)
9 files modified
lib/lp/archivepublisher/configure.zcml (+7/-0)
lib/lp/archivepublisher/signing.py (+22/-2)
lib/lp/archivepublisher/tests/test_signing.py (+66/-32)
lib/lp/archiveuploader/nascentuploadfile.py (+8/-3)
lib/lp/soyuz/browser/queue.py (+1/-0)
lib/lp/soyuz/enums.py (+7/-1)
lib/lp/soyuz/model/queue.py (+5/-2)
lib/lp/soyuz/scripts/custom_uploads_copier.py (+7/-2)
lib/lp/soyuz/scripts/tests/test_custom_uploads_copier.py (+42/-4)
To merge this branch: bzr merge lp:~apw/launchpad/signing-reinstate-raw-uefi-custom-upload
Reviewer Review Type Date Requested Status
Colin Watson (community) Approve
Review via email: mp+295848@code.launchpad.net

Commit message

Reinstate the raw-uefi custom upload as a distinct type.

Description of the change

Reinstate the raw-uefi custom upload as a distinct type. This utilises the same machinery as raw-signing. The only difference is the location in dists, with raw-uefi landing in dists/*/uefi and raw-signing landing in dists/*/signing.

To post a comment you must log in.
Revision history for this message
Colin Watson (cjwatson) :
review: Approve
Revision history for this message
Andy Whitcroft (apw) wrote :

Changes as requested pushed to the branch. Thanks for your reviews.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'lib/lp/archivepublisher/configure.zcml'
--- lib/lp/archivepublisher/configure.zcml 2016-05-23 10:46:55 +0000
+++ lib/lp/archivepublisher/configure.zcml 2016-05-31 12:46:39 +0000
@@ -88,6 +88,13 @@
88 interface="lp.soyuz.interfaces.queue.ICustomUploadHandler"/>88 interface="lp.soyuz.interfaces.queue.ICustomUploadHandler"/>
89 </securedutility>89 </securedutility>
90 <securedutility90 <securedutility
91 class="lp.archivepublisher.signing.UefiUpload"
92 provides="lp.soyuz.interfaces.queue.ICustomUploadHandler"
93 name="UEFI">
94 <allow
95 interface="lp.soyuz.interfaces.queue.ICustomUploadHandler"/>
96 </securedutility>
97 <securedutility
91 class="lp.archivepublisher.signing.SigningUpload"98 class="lp.archivepublisher.signing.SigningUpload"
92 provides="lp.soyuz.interfaces.queue.ICustomUploadHandler"99 provides="lp.soyuz.interfaces.queue.ICustomUploadHandler"
93 name="SIGNING">100 name="SIGNING">
94101
=== modified file 'lib/lp/archivepublisher/signing.py'
--- lib/lp/archivepublisher/signing.py 2016-05-26 10:46:04 +0000
+++ lib/lp/archivepublisher/signing.py 2016-05-31 12:46:39 +0000
@@ -15,6 +15,7 @@
1515
16__all__ = [16__all__ = [
17 "SigningUpload",17 "SigningUpload",
18 "UefiUpload",
18 ]19 ]
1920
20import os21import os
@@ -63,6 +64,8 @@
63 """64 """
64 custom_type = "signing"65 custom_type = "signing"
6566
67 dists_directory = "signed"
68
66 @staticmethod69 @staticmethod
67 def parsePath(tarfile_path):70 def parsePath(tarfile_path):
68 tarfile_base = os.path.basename(tarfile_path)71 tarfile_base = os.path.basename(tarfile_path)
@@ -94,8 +97,8 @@
9497
95 self.setComponents(tarfile_path)98 self.setComponents(tarfile_path)
9699
97 dists_signed = os.path.join(100 dists_signed = os.path.join(pubconf.archiveroot, "dists",
98 pubconf.archiveroot, "dists", suite, "main", "signed")101 suite, "main", self.dists_directory)
99 self.targetdir = os.path.join(102 self.targetdir = os.path.join(
100 dists_signed, "%s-%s" % (self.package, self.arch))103 dists_signed, "%s-%s" % (self.package, self.arch))
101 self.archiveroot = pubconf.archiveroot104 self.archiveroot = pubconf.archiveroot
@@ -302,3 +305,20 @@
302305
303 def shouldInstall(self, filename):306 def shouldInstall(self, filename):
304 return filename.startswith("%s/" % self.version)307 return filename.startswith("%s/" % self.version)
308
309
310class UefiUpload(SigningUpload):
311 """Legacy UEFI Signing custom upload.
312
313 Provides backwards compatibility UEFI signing uploads. Existing
314 packages use the raw-uefi custom upload and expect the results
315 to be published to dists/*/uefi. These are a functional subset of
316 raw-signing custom uploads differing only in where they are published
317 in the archive.
318
319 We expect to be able to remove this upload type once all existing
320 packages are converted to the new form and location.
321 """
322 custom_type = "uefi"
323
324 dists_directory = "uefi"
305325
=== modified file 'lib/lp/archivepublisher/tests/test_signing.py'
--- lib/lp/archivepublisher/tests/test_signing.py 2016-05-26 10:46:39 +0000
+++ lib/lp/archivepublisher/tests/test_signing.py 2016-05-31 12:46:39 +0000
@@ -15,7 +15,10 @@
15 CustomUploadAlreadyExists,15 CustomUploadAlreadyExists,
16 CustomUploadBadUmask,16 CustomUploadBadUmask,
17 )17 )
18from lp.archivepublisher.signing import SigningUpload18from lp.archivepublisher.signing import (
19 SigningUpload,
20 UefiUpload,
21 )
19from lp.services.osutils import write_file22from lp.services.osutils import write_file
20from lp.services.tarfile_helpers import LaunchpadWriteTarFile23from lp.services.tarfile_helpers import LaunchpadWriteTarFile
21from lp.testing import TestCase24from lp.testing import TestCase
@@ -98,10 +101,10 @@
98 self.signingautokey = True101 self.signingautokey = True
99102
100103
101class TestSigning(TestCase):104class TestSigningHelpers(TestCase):
102105
103 def setUp(self):106 def setUp(self):
104 super(TestSigning, self).setUp()107 super(TestSigningHelpers, self).setUp()
105 self.temp_dir = self.makeTemporaryDirectory()108 self.temp_dir = self.makeTemporaryDirectory()
106 self.signing_dir = self.makeTemporaryDirectory()109 self.signing_dir = self.makeTemporaryDirectory()
107 self.pubconf = FakeConfigPrimary(self.temp_dir, self.signing_dir)110 self.pubconf = FakeConfigPrimary(self.temp_dir, self.signing_dir)
@@ -135,43 +138,42 @@
135 self.buffer = open(self.path, "wb")138 self.buffer = open(self.path, "wb")
136 self.archive = LaunchpadWriteTarFile(self.buffer)139 self.archive = LaunchpadWriteTarFile(self.buffer)
137140
138 def process_emulate(self):
139 self.archive.close()
140 self.buffer.close()
141 upload = SigningUpload()
142 # Under no circumstances is it safe to execute actual commands.
143 self.fake_call = FakeMethod(result=0)
144 upload.callLog = FakeMethodCallLog(upload=upload)
145 self.useFixture(MonkeyPatch("subprocess.call", self.fake_call))
146 upload.process(self.pubconf, self.path, self.suite)
147
148 return upload
149
150 def process(self):
151 self.archive.close()
152 self.buffer.close()
153 upload = SigningUpload()
154 upload.signUefi = FakeMethod()
155 upload.signKmod = FakeMethod()
156 # Under no circumstances is it safe to execute actual commands.
157 fake_call = FakeMethod(result=0)
158 self.useFixture(MonkeyPatch("subprocess.call", fake_call))
159 upload.process(self.pubconf, self.path, self.suite)
160 self.assertEqual(0, fake_call.call_count)
161
162 return upload
163
164 def getDistsPath(self):141 def getDistsPath(self):
165 return os.path.join(self.pubconf.archiveroot, "dists",142 return os.path.join(self.pubconf.archiveroot, "dists",
166 self.suite, "main")143 self.suite, "main")
167144
145
146class TestSigning(TestSigningHelpers):
147
168 def getSignedPath(self, loader_type, arch):148 def getSignedPath(self, loader_type, arch):
169 return os.path.join(self.getDistsPath(), "signed",149 return os.path.join(self.getDistsPath(), "signed",
170 "%s-%s" % (loader_type, arch))150 "%s-%s" % (loader_type, arch))
171151
172 def getUefiPath(self, loader_type, arch):152 def process_emulate(self):
173 return os.path.join(self.getDistsPath(), "uefi",153 self.archive.close()
174 "%s-%s" % (loader_type, arch))154 self.buffer.close()
155 upload = SigningUpload()
156 # Under no circumstances is it safe to execute actual commands.
157 self.fake_call = FakeMethod(result=0)
158 upload.callLog = FakeMethodCallLog(upload=upload)
159 self.useFixture(MonkeyPatch("subprocess.call", self.fake_call))
160 upload.process(self.pubconf, self.path, self.suite)
161
162 return upload
163
164 def process(self):
165 self.archive.close()
166 self.buffer.close()
167 upload = SigningUpload()
168 upload.signUefi = FakeMethod()
169 upload.signKmod = FakeMethod()
170 # Under no circumstances is it safe to execute actual commands.
171 fake_call = FakeMethod(result=0)
172 self.useFixture(MonkeyPatch("subprocess.call", fake_call))
173 upload.process(self.pubconf, self.path, self.suite)
174 self.assertEqual(0, fake_call.call_count)
175
176 return upload
175177
176 def test_archive_copy(self):178 def test_archive_copy(self):
177 # If there is no key/cert configuration, processing succeeds but179 # If there is no key/cert configuration, processing succeeds but
@@ -599,3 +601,35 @@
599 self.assertTrue(os.path.exists(self.kmod_x509))601 self.assertTrue(os.path.exists(self.kmod_x509))
600 self.assertEqual(stat.S_IMODE(os.stat(self.kmod_pem).st_mode), 0o600)602 self.assertEqual(stat.S_IMODE(os.stat(self.kmod_pem).st_mode), 0o600)
601 self.assertEqual(stat.S_IMODE(os.stat(self.kmod_x509).st_mode), 0o644)603 self.assertEqual(stat.S_IMODE(os.stat(self.kmod_x509).st_mode), 0o644)
604
605
606class TestUefi(TestSigningHelpers):
607
608 def getSignedPath(self, loader_type, arch):
609 return os.path.join(self.getDistsPath(), "uefi",
610 "%s-%s" % (loader_type, arch))
611
612 def process(self):
613 self.archive.close()
614 self.buffer.close()
615 upload = UefiUpload()
616 upload.signUefi = FakeMethod()
617 upload.signKmod = FakeMethod()
618 # Under no circumstances is it safe to execute actual commands.
619 fake_call = FakeMethod(result=0)
620 self.useFixture(MonkeyPatch("subprocess.call", fake_call))
621 upload.process(self.pubconf, self.path, self.suite)
622 self.assertEqual(0, fake_call.call_count)
623
624 return upload
625
626 def test_installed(self):
627 # Files in the tarball are installed correctly.
628 self.setUpUefiKeys()
629 self.openArchive("test", "1.0", "amd64")
630 self.archive.add_file("1.0/empty.efi", "")
631 self.process()
632 self.assertTrue(os.path.isdir(os.path.join(
633 self.getDistsPath(), "uefi")))
634 self.assertTrue(os.path.exists(os.path.join(
635 self.getSignedPath("test", "amd64"), "1.0", "empty.efi")))
602636
=== modified file 'lib/lp/archiveuploader/nascentuploadfile.py'
--- lib/lp/archiveuploader/nascentuploadfile.py 2016-05-06 09:16:30 +0000
+++ lib/lp/archiveuploader/nascentuploadfile.py 2016-05-31 12:46:39 +0000
@@ -33,7 +33,10 @@
33from lp.archivepublisher.debian_installer import DebianInstallerUpload33from lp.archivepublisher.debian_installer import DebianInstallerUpload
34from lp.archivepublisher.dist_upgrader import DistUpgraderUpload34from lp.archivepublisher.dist_upgrader import DistUpgraderUpload
35from lp.archivepublisher.rosetta_translations import RosettaTranslationsUpload35from lp.archivepublisher.rosetta_translations import RosettaTranslationsUpload
36from lp.archivepublisher.signing import SigningUpload36from lp.archivepublisher.signing import (
37 SigningUpload,
38 UefiUpload,
39 )
37from lp.archiveuploader.utils import (40from lp.archiveuploader.utils import (
38 determine_source_file_type,41 determine_source_file_type,
39 prefix_multi_line_string,42 prefix_multi_line_string,
@@ -258,8 +261,8 @@
258 PackageUploadCustomFormat.STATIC_TRANSLATIONS,261 PackageUploadCustomFormat.STATIC_TRANSLATIONS,
259 'raw-meta-data':262 'raw-meta-data':
260 PackageUploadCustomFormat.META_DATA,263 PackageUploadCustomFormat.META_DATA,
264 'raw-uefi': PackageUploadCustomFormat.UEFI,
261 'raw-signing': PackageUploadCustomFormat.SIGNING,265 'raw-signing': PackageUploadCustomFormat.SIGNING,
262 'raw-uefi': PackageUploadCustomFormat.SIGNING, # Compatibility
263 }266 }
264267
265 custom_handlers = {268 custom_handlers = {
@@ -268,6 +271,7 @@
268 PackageUploadCustomFormat.DDTP_TARBALL: DdtpTarballUpload,271 PackageUploadCustomFormat.DDTP_TARBALL: DdtpTarballUpload,
269 PackageUploadCustomFormat.ROSETTA_TRANSLATIONS:272 PackageUploadCustomFormat.ROSETTA_TRANSLATIONS:
270 RosettaTranslationsUpload,273 RosettaTranslationsUpload,
274 PackageUploadCustomFormat.UEFI: UefiUpload,
271 PackageUploadCustomFormat.SIGNING: SigningUpload,275 PackageUploadCustomFormat.SIGNING: SigningUpload,
272 }276 }
273277
@@ -309,7 +313,8 @@
309 """Return whether this custom upload can be automatically approved."""313 """Return whether this custom upload can be automatically approved."""
310 # Signing uploads will be signed, and must therefore be approved314 # Signing uploads will be signed, and must therefore be approved
311 # by a human.315 # by a human.
312 if self.custom_type == PackageUploadCustomFormat.SIGNING:316 if self.custom_type in (PackageUploadCustomFormat.UEFI,
317 PackageUploadCustomFormat.SIGNING):
313 return False318 return False
314 return True319 return True
315320
316321
=== modified file 'lib/lp/soyuz/browser/queue.py'
--- lib/lp/soyuz/browser/queue.py 2016-05-09 18:07:49 +0000
+++ lib/lp/soyuz/browser/queue.py 2016-05-31 12:46:39 +0000
@@ -574,6 +574,7 @@
574 (self.contains_installer, ("Installer", 'ubuntu-icon')),574 (self.contains_installer, ("Installer", 'ubuntu-icon')),
575 (self.contains_upgrader, ("Upgrader", 'ubuntu-icon')),575 (self.contains_upgrader, ("Upgrader", 'ubuntu-icon')),
576 (self.contains_ddtp, (ddtp, 'ubuntu-icon')),576 (self.contains_ddtp, (ddtp, 'ubuntu-icon')),
577 (self.contains_uefi, ("UEFI Objects for Signing", 'ubuntu-icon')),
577 (self.contains_signing, ("Objects for Signing", 'ubuntu-icon')),578 (self.contains_signing, ("Objects for Signing", 'ubuntu-icon')),
578 ]579 ]
579 return [580 return [
580581
=== modified file 'lib/lp/soyuz/enums.py'
--- lib/lp/soyuz/enums.py 2016-05-03 14:44:33 +0000
+++ lib/lp/soyuz/enums.py 2016-05-31 12:46:39 +0000
@@ -481,7 +481,13 @@
481 the Software Center.481 the Software Center.
482 """)482 """)
483483
484 SIGNING = DBItem(6, """484 UEFI = DBItem(6, """
485 uefi
486
487 A tarball containing EFI images to be signed.
488 """)
489
490 SIGNING = DBItem(7, """
485 signing491 signing
486492
487 A tarball containing images to be signed.493 A tarball containing images to be signed.
488494
=== modified file 'lib/lp/soyuz/model/queue.py'
--- lib/lp/soyuz/model/queue.py 2016-05-23 11:18:16 +0000
+++ lib/lp/soyuz/model/queue.py 2016-05-31 12:46:39 +0000
@@ -654,12 +654,15 @@
654 return PackageUploadCustomFormat.DDTP_TARBALL in self._customFormats654 return PackageUploadCustomFormat.DDTP_TARBALL in self._customFormats
655655
656 @cachedproperty656 @cachedproperty
657 def contains_uefi(self):
658 """See `IPackageUpload`."""
659 return PackageUploadCustomFormat.UEFI in self._customFormats
660
661 @cachedproperty
657 def contains_signing(self):662 def contains_signing(self):
658 """See `IPackageUpload`."""663 """See `IPackageUpload`."""
659 return PackageUploadCustomFormat.SIGNING in self._customFormats664 return PackageUploadCustomFormat.SIGNING in self._customFormats
660665
661 contains_uefi = contains_signing
662
663 @property666 @property
664 def package_name(self):667 def package_name(self):
665 """See `IPackageUpload`."""668 """See `IPackageUpload`."""
666669
=== modified file 'lib/lp/soyuz/scripts/custom_uploads_copier.py'
--- lib/lp/soyuz/scripts/custom_uploads_copier.py 2016-05-06 09:16:30 +0000
+++ lib/lp/soyuz/scripts/custom_uploads_copier.py 2016-05-31 12:46:39 +0000
@@ -18,7 +18,10 @@
18from lp.archivepublisher.debian_installer import DebianInstallerUpload18from lp.archivepublisher.debian_installer import DebianInstallerUpload
19from lp.archivepublisher.dist_upgrader import DistUpgraderUpload19from lp.archivepublisher.dist_upgrader import DistUpgraderUpload
20from lp.archivepublisher.rosetta_translations import RosettaTranslationsUpload20from lp.archivepublisher.rosetta_translations import RosettaTranslationsUpload
21from lp.archivepublisher.signing import SigningUpload21from lp.archivepublisher.signing import (
22 SigningUpload,
23 UefiUpload,
24 )
22from lp.registry.interfaces.pocket import PackagePublishingPocket25from lp.registry.interfaces.pocket import PackagePublishingPocket
23from lp.services.database.bulk import load_referencing26from lp.services.database.bulk import load_referencing
24from lp.soyuz.enums import PackageUploadCustomFormat27from lp.soyuz.enums import PackageUploadCustomFormat
@@ -40,6 +43,7 @@
40 PackageUploadCustomFormat.DDTP_TARBALL: DdtpTarballUpload,43 PackageUploadCustomFormat.DDTP_TARBALL: DdtpTarballUpload,
41 PackageUploadCustomFormat.ROSETTA_TRANSLATIONS:44 PackageUploadCustomFormat.ROSETTA_TRANSLATIONS:
42 RosettaTranslationsUpload,45 RosettaTranslationsUpload,
46 PackageUploadCustomFormat.UEFI: UefiUpload,
43 PackageUploadCustomFormat.SIGNING: SigningUpload,47 PackageUploadCustomFormat.SIGNING: SigningUpload,
44 }48 }
4549
@@ -63,7 +67,8 @@
63 return True67 return True
64 # Signing uploads will be signed, and must therefore be approved68 # Signing uploads will be signed, and must therefore be approved
65 # by a human.69 # by a human.
66 if custom.customformat == PackageUploadCustomFormat.SIGNING:70 if custom.customformat in (PackageUploadCustomFormat.UEFI,
71 PackageUploadCustomFormat.SIGNING):
67 return False72 return False
68 return True73 return True
6974
7075
=== modified file 'lib/lp/soyuz/scripts/tests/test_custom_uploads_copier.py'
--- lib/lp/soyuz/scripts/tests/test_custom_uploads_copier.py 2016-05-06 09:16:30 +0000
+++ lib/lp/soyuz/scripts/tests/test_custom_uploads_copier.py 2016-05-31 12:46:39 +0000
@@ -409,7 +409,7 @@
409 self.assertEqual(PackageUploadStatus.ACCEPTED, copied_pu.status)409 self.assertEqual(PackageUploadStatus.ACCEPTED, copied_pu.status)
410410
411 def test_copyUpload_unapproves_signing_from_different_archive(self):411 def test_copyUpload_unapproves_signing_from_different_archive(self):
412 # Copies of UEFI custom uploads to a primary archive are set to412 # Copies of signing custom uploads to a primary archive are set to
413 # UNAPPROVED, since they will normally end up being signed.413 # UNAPPROVED, since they will normally end up being signed.
414 target_series = self.factory.makeDistroSeries()414 target_series = self.factory.makeDistroSeries()
415 archive = self.factory.makeArchive(415 archive = self.factory.makeArchive(
@@ -422,22 +422,60 @@
422 self.assertEqual(PackageUploadStatus.UNAPPROVED, copied_pu.status)422 self.assertEqual(PackageUploadStatus.UNAPPROVED, copied_pu.status)
423423
424 def test_copyUpload_approves_signing_from_same_archive(self):424 def test_copyUpload_approves_signing_from_same_archive(self):
425 # Copies of signing custom uploads within the same archive are
426 # automatically accepted, since they have already been signed.
427 original_upload = self.makeUpload(
428 custom_type=PackageUploadCustomFormat.SIGNING)
429 target_series = self.factory.makeDistroSeries()
430 copier = CustomUploadsCopier(target_series)
431 copied_pu = copier.copyUpload(original_upload).packageupload
432 self.assertEqual(PackageUploadStatus.ACCEPTED, copied_pu.status)
433
434 def test_copyUpload_approves_signing_to_ppa(self):
435 # Copies of signing custom uploads to a PPA are automatically accepted,
436 # since PPAs have much more limited upload permissions than the main
437 # archive, and in any case PPAs do not have an upload approval
438 # workflow.
439 original_upload = self.makeUpload(
440 custom_type=PackageUploadCustomFormat.SIGNING)
441 target_series = self.factory.makeDistroSeries()
442 target_archive = self.factory.makeArchive(
443 distribution=target_series.distribution)
444 copier = CustomUploadsCopier(
445 target_series, target_archive=target_archive)
446 copied_pu = copier.copyUpload(original_upload).packageupload
447 self.assertEqual(PackageUploadStatus.ACCEPTED, copied_pu.status)
448
449 def test_copyUpload_unapproves_uefi_from_different_archive(self):
450 # Copies of UEFI custom uploads to a primary archive are set to
451 # UNAPPROVED, since they will normally end up being signed.
452 target_series = self.factory.makeDistroSeries()
453 archive = self.factory.makeArchive(
454 distribution=target_series.distribution)
455 original_upload = self.makeUpload(
456 archive=archive, custom_type=PackageUploadCustomFormat.UEFI)
457 copier = CustomUploadsCopier(
458 target_series, target_archive=target_series.main_archive)
459 copied_pu = copier.copyUpload(original_upload).packageupload
460 self.assertEqual(PackageUploadStatus.UNAPPROVED, copied_pu.status)
461
462 def test_copyUpload_approves_uefi_from_same_archive(self):
425 # Copies of UEFI custom uploads within the same archive are463 # Copies of UEFI custom uploads within the same archive are
426 # automatically accepted, since they have already been signed.464 # automatically accepted, since they have already been signed.
427 original_upload = self.makeUpload(465 original_upload = self.makeUpload(
428 custom_type=PackageUploadCustomFormat.SIGNING)466 custom_type=PackageUploadCustomFormat.UEFI)
429 target_series = self.factory.makeDistroSeries()467 target_series = self.factory.makeDistroSeries()
430 copier = CustomUploadsCopier(target_series)468 copier = CustomUploadsCopier(target_series)
431 copied_pu = copier.copyUpload(original_upload).packageupload469 copied_pu = copier.copyUpload(original_upload).packageupload
432 self.assertEqual(PackageUploadStatus.ACCEPTED, copied_pu.status)470 self.assertEqual(PackageUploadStatus.ACCEPTED, copied_pu.status)
433471
434 def test_copyUpload_approves_signing_to_ppa(self):472 def test_copyUpload_approves_uefi_to_ppa(self):
435 # Copies of UEFI custom uploads to a PPA are automatically accepted,473 # Copies of UEFI custom uploads to a PPA are automatically accepted,
436 # since PPAs have much more limited upload permissions than the main474 # since PPAs have much more limited upload permissions than the main
437 # archive, and in any case PPAs do not have an upload approval475 # archive, and in any case PPAs do not have an upload approval
438 # workflow.476 # workflow.
439 original_upload = self.makeUpload(477 original_upload = self.makeUpload(
440 custom_type=PackageUploadCustomFormat.SIGNING)478 custom_type=PackageUploadCustomFormat.UEFI)
441 target_series = self.factory.makeDistroSeries()479 target_series = self.factory.makeDistroSeries()
442 target_archive = self.factory.makeArchive(480 target_archive = self.factory.makeArchive(
443 distribution=target_series.distribution)481 distribution=target_series.distribution)