[MIR] cpdb-backend-file

Bug #2003272 reported by Till Kamppeter
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cpdb-backend-file (Ubuntu)
Fix Released
High
Unassigned

Bug Description

[Availability]
The package cpdb-backend-file is already in Ubuntu universe.
The package cpdb-backend-file builds for the architectures it is designed to work on.
It currently builds and works for architectures: amd64, arm64, armhf, ppc64el, riscv64, s390x
Link to package https://launchpad.net/ubuntu/+source/cpdb-backend-file

[Rationale]
See the principle rationale for introducing the Common Print Dialog Backends (CPDB) concept in the MIR for cpdb-libs, bug #1747759.

This package is one of the backends, the backend for printing into a (PDF) file. So having installed it, CPDB-supporting print dialogs show a printer entry to print into a PDF file in the user's home directory.

This backend works independent of any printing system, there is no CUPS involved and no other system daemon. The backend tells the dialog that it needs a file name and the dialog opens a "Save as ..." dialog. Then the backend gets the user-selected file name and the job data stream and saves it in a file. All running as the calling user, so file can be saved only where the user is allowed to.

The backend provides the only printer entry in print dialogs if on the system is no print environment (like CUPS) installed or no print queue set up. Therefore it is required to be in Ubuntu Main.

The New Architecture is introduced as standard part of the distro in Ubuntu 23.10 at the latest. Therefore cpdb-libs NEEDS to be in main before Feature Freeze 23.10, ideally some weeks before.

There are very good chances that the changes on GTK and Qt already land in 23.04. In this case we need cpdb-libs in Main already by Feature Freeze of 23.04. This way the CPDB-based print dialog will be tested more before the switchover into the New Architecture will take place.

[Security]
No CVEs/security issues in this software in the past

 - no `suid` or `sgid` binaries
 - no executables in `/sbin` and `/usr/sbin`
 - Package does not install system services, timers or recurring jobs
 - Packages does not open privileged ports (ports < 1024)
 - Packages does not contain extensions to security-sensitive software

cpdb-backend-file provides a D-Bus service, but running as normal user.

The backends are triggered via session D-Bus and always run as the same user as the calling print dialog, so they do not introduce additional security problems.

The separation of the communication with individual print technologies makes this code only be needed once (in the appropriate backend) instead of in each print dialog. This simplifies the security maintenance.

[Quality assurance - function/usage]
- The package works well right after install

Once installed it gets auto-detected and automatically used by applications which have a print dialog using CPDB (cpdb-libs, MIR bug: 1747759). So no explicit user action with this package required. It is a kind of plug-in. For the user a "Pint to file" printer will appear in the print dialog, so that they can send any printable content into a PDF instead of printing it on physical paper. Usage is totally intuitive.

[Quality assurance - maintenance]
- The package is maintained well in Debian/Ubuntu and has not too many
  and long term critical bugs open
  - Ubuntu https://bugs.launchpad.net/ubuntu/+source/cpdb-backend-file/+bug
  - Debian https://bugs.debian.org/cgi-bin/pkgreport.cgi?src=cpdb-backend-file
  - Upstream https://github.com/OpenPrinting/cpdb-backend-file/issues
- No open bugs at all, only this MIR ...
- The package does not deal with exotic hardware we cannot support (it drops the print content in a regular PDF file)

[Quality assurance - testing]
- The package does not run a test at build time because it does not contain upstream "make check" or "make test".
- The package runs an autopkgtest (debian/tests/text-frontend-vs-file-backend), and is currently passing on all architectures mentioned above under [Availability]

- The package does have not failing autopkgtests right now

[Quality assurance - packaging]
- debian/watch is present and works
- debian/control defines a correct Maintainer field

- Please link to a recent build log of the package: https://launchpadlibrarian.net/646763031/buildlog_ubuntu-lunar-amd64.cpdb-backend-file_1.0.1-1ubuntu1_BUILDING.txt.gz

- This package does not yield any lintian Warnings, Errors
- Lintian overrides are not present
- This package does not rely on obsolete or about to be demoted packages.

Depends only on libc6, libglib2.0, libcpdb-libs-common1

- The package will be installed by default, but does not ask debconf
  questions higher than medium

No debconf questions at all, AFAIK.

- Packaging and build is easy, link to d/rules

https://salsa.debian.org/printing-team/cpdb-backend-file/-/blob/debian/main/debian/rules

[UI standards]
- Application is not end-user facing (does not need translation)

- End-user applications without desktop file, not needed because this is a backend/plugin, no (G)UI.

[Dependencies]

Depends only on libc6, libglib2.0, libcpdb-libs-common1

- There are further dependencies (libcpdb-libs-common1) that are not yet in
  main, MIR for them is bug 1747759 (cpdb-libs).

[Standards compliance]
- This package correctly follows FHS and Debian Policy

[Maintenance/Owner]
- Owning Team will be Ubuntu Printing Team - ubuntu-printing
- Team is subscribed to the package

- This does not use static builds
- This does not use vendored code
- This package is not rust based

- The package has been built in the archive more recently than the last
  test rebuild

[Background information]
The Package description explains the package well
Upstream Name is cpdb-backend-file (unchanged)
Link to upstream project https://github.com/OpenPrinting/cpdb-backend-file

Changed in cpdb-backend-file (Ubuntu):
importance: Undecided → High
Changed in cpdb-backend-file (Ubuntu):
assignee: nobody → Didier Roche-Tolomelli (didrocks)
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

I have uploaded upstream version 2.0b3 now as it is required to have 2.x backends by the also uploaded 2.0b3 version of cpdb-libs which is in turn needed by GTK 4.9.4.

Changes in the debian/ directory are minimal, only for the changes in the binary package naming of cpdb-libs and for changes in the source package documentation files.

There is no new dependency. Dependencies on cpdb-libs are versioned now as this package does not build and also does not work with cpdb-libs 1.x.

cpdb-backend-file needs to get seeded, as no binary package of cpdb-libs depends on it. It is needed in a standard installation as otherwise some print dialogs could not allow to print to a file.

Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote (last edit ):

Setting it as incomplete as the MIR is not ready: as stated in the report, it does not include tests during builds, which are mandatory.

Tests are a strong requirement for elevating our quality in the distro and not something we can decide to not tackle when the MIR is filed. Please ensure that this requirement is matched (you have documentation on the MIR template if it’s hard to test).

Once the testing requirement is done, please reassign to me and I will do the check assessements from the MIR team perspective.

Changed in cpdb-backend-file (Ubuntu):
importance: High → Undecided
assignee: Didier Roche-Tolomelli (didrocks) → Till Kamppeter (till-kamppeter)
status: New → Incomplete
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

New upstream release uploaded with "make check" test plus fixes of bugs discovered during the test script development:

https://launchpad.net/ubuntu/+source/cpdb-backend-file/2.0~b4-0ubuntu1

The script src/run-tests.sh starts this backend and the cpdb-text-frontend text mode example frontend of cpdb-libs (>= 2.0b4) in one dbus-run-session environment. The frontend discovers the backend and some test tasks are done with it, like listing options and printing a job.

Changed in cpdb-backend-file (Ubuntu):
assignee: Till Kamppeter (till-kamppeter) → Didier Roche-Tolomelli (didrocks)
status: Incomplete → New
importance: Undecided → High
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Both cpdb-backend-file (2.0~b4-0ubuntu2) and cpdb-libs (2.0~b4-0ubuntu2), with both build test and autopkgtest has successfully migrated from -proposed to release now.

Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote :

Review for Package: cpdb-backend-file

[Summary]
MIR team ACK under the constraint to resolve the below listed
required TODOs.
This does not need a security review.

Notes:
Required TODOs:
- The MIR for cpdb-libs (bug #1747759) should be ACKed first.
- The package should get the desktop team to subscribe before being promoted

[Duplication]
There is no other package in main providing the same functionality.

[Dependencies]
OK:
- no -dev/-debug/-doc packages that need exclusion
- No dependencies in main that are only superficially tested requiring
  more tests now.

Problems:
- the package depends on cpdb-libs (MIR bug #1747759) which should be ACKed first.

[Embedded sources and static linking]
OK:
- no embedded source present
- no static linking
- does not have unexpected Built-Using entries

OK:
- not a go package, no extra constraints to consider in that regard
- not a rust package, no extra constraints to consider in that regard
- Does not include vendored code

[Security]
OK:
- history of CVEs does not look concerning
- does not run a daemon as root
- does not use webkit1,2
- does not use lib*v8 directly
- does not parse data formats (files [images, video, audio,
  xml, json, asn.1], network packets, structures, ...) from
  an untrusted source.
- does not open a port/socket
- does not process arbitrary web content
- does not use centralized online accounts
- does not integrate arbitrary javascript into the desktop
- does not deal with system authentication (eg, pam), etc)
- does not deal with security attestation (secure boot, tpm, signatures)
- does not deal with cryptography (en-/decryption, certificates, signing, ...)

[Common blockers]
OK:
- does not FTBFS currently
- does have a test suite that runs at build time
- test suite fails will fail the build upon error.
- does have a non-trivial test suite that runs as autopkgtest
- no new python2 dependency

[Packaging red flags]
OK:
- Ubuntu does carry a delta, but it is reasonable and maintenance under control
- symbols tracking not applicable for this kind of code.
- debian/watch is present and looks ok
- Upstream update history is good
- Debian/Ubuntu update history is good
- the current release is packaged
- promoting this does not seem to cause issues for MOTUs that so far
 - no massive Lintian warnings
- debian/rules is rather clean
- It is not on the lto-disabled list

[Upstream red flags]
OK:
- no Errors/warnings during the build
- no incautious use of malloc/sprintf (as far as we can check it)
- no use of sudo, gksu, pkexec, or LD_LIBRARY_PATH (usage is OK inside
  tests)
- no use of user nobody
- no use of setuid
- no important open bugs (crashers, etc) in Debian or Ubuntu
- no dependency on webkit, qtwebkit, seed or libgoa-*
- not part of the UI
- translation not needed in this case present

Changed in cpdb-backend-file (Ubuntu):
status: New → Fix Committed
assignee: Didier Roche-Tolomelli (didrocks) → nobody
status: Fix Committed → Incomplete
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

The MIR of the underlying libraries, cpdb-libs, bug 1747759, is only waiting for the security team's ACK now.

@seb128, could you make the desktop team to subscribe to this package (and also cpdb-libs and cpdb-backend-cups)?

Revision history for this message
Sebastien Bacher (seb128) wrote :

the cpdb-libs MIR has got accepted and the desktop-packages team subscribed so promoting

$ ./change-override -c main -B cpdb-backend-file
Override component to main
cpdb-backend-file 2.0~b4-0ubuntu2 in mantic: universe/net -> main
cpdb-backend-file 2.0~b4-0ubuntu2 in mantic amd64: universe/net/optional/100% -> main
cpdb-backend-file 2.0~b4-0ubuntu2 in mantic arm64: universe/net/optional/100% -> main
cpdb-backend-file 2.0~b4-0ubuntu2 in mantic armhf: universe/net/optional/100% -> main
cpdb-backend-file 2.0~b4-0ubuntu2 in mantic ppc64el: universe/net/optional/100% -> main
cpdb-backend-file 2.0~b4-0ubuntu2 in mantic riscv64: universe/net/optional/100% -> main
cpdb-backend-file 2.0~b4-0ubuntu2 in mantic s390x: universe/net/optional/100% -> main
Override [y|N]? y
7 publications overridden.

Changed in cpdb-backend-file (Ubuntu):
status: Incomplete → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.