From f26f191a1773815979a1390f8c1637973df63896 Mon Sep 17 00:00:00 2001 From: Simon Quigley Date: Tue, 15 Apr 2025 22:24:54 -0500 Subject: [PATCH] [checkpackage-backend] Pass through packages starting with "^" or containing "*" Simply pass through packages starting with "^" or containing "*". For this cycle we can trust our distributors won't do anything unusual, but next cycle, we need to perform explicit validation on these items. If you are a downstream, please be careful! --- common/modules/pkgselectprocess/checkpackage-backend.cpp | 6 ++++++ debian/changelog | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/common/modules/pkgselectprocess/checkpackage-backend.cpp b/common/modules/pkgselectprocess/checkpackage-backend.cpp index 454f2b0..6cf2e8c 100644 --- a/common/modules/pkgselectprocess/checkpackage-backend.cpp +++ b/common/modules/pkgselectprocess/checkpackage-backend.cpp @@ -33,6 +33,12 @@ int main(int argc, char* argv[]) { for (std::string package_name : package_names) { if (seen_packages.contains(package_name)) continue; seen_packages.insert(package_name); + + // Tasks and wildcards should just be passed through as-is, for now + if (package_name.starts_with('^') || package_name.contains('*')) { + std::cout << package_name << " "; + continue; + } pkgCache::GrpIterator grp = cache->GetPkgCache()->FindGrp(package_name); if (!grp.end()) { pkgCache::PkgIterator it = grp.FindPreferredPkg(true); diff --git a/debian/changelog b/debian/changelog index b460ed9..2e9f62c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -8,6 +8,10 @@ calamares-settings-ubuntu (1:25.04.26) UNRELEASED; urgency=medium of several, miscellaneous shell scripts wrapped in YAML. * [pkgselectprocess] Explicitly log all apt commands in the debug logs. * [pkgselectprocess] Ensure apt-cdrom command outputs have their own prefix. + * [checkpackage-backend] Simply pass through packages starting with "^" or + containing "*". For this cycle we can trust our distributors won't do + anything unusual, but next cycle, we need to perform explicit validation + on these items. If you are a downstream, please be careful. -- Simon Quigley Tue, 15 Apr 2025 22:15:17 -0500