.. /* * This file is part of the SavaPage project . * Copyright (c) 2026 Datraverse B.V. * Author: Rijk Ravestein. * * SPDX-FileCopyrightText: (c) 2020 Datraverse B.V. * SPDX-License-Identifier: CC-BY-SA-4.0 * * For more information, please contact Datraverse B.V. at this * address: info@datraverse.com */ .. _ch-printer-driverless-file-transfer: Driverless File Transfer Print ------------------------------ Driverless Printing by file transfer is one of the gateways to authenticated printing from devices belonging to unauthenticated anonymous users, where either native or :ref:`IPP Everywhere ` printing support is lacking or where user trust cannot be enforced by a :ref:`Single Sign-On User Domain `. This situation is typical for a BYOD [4]_ context. :ref:`Web Print ` and :ref:`Mail Print ` offer casual printing without a hassle, since users are familiar with either file uploading or email and no printer driver needs to be installed. Since rendering of the document content is not handled by a know-it-all printer driver, not all document types are supported. See :ref:`Printable File Types ` for a list of supported types. Driverless File Transfer Print is also implemented in the :ref:`SavaPage Android Print App ` and :ref:`RESTful Print API `. .. note:: |MAILPRINT| uses ``127.0.0.1`` (localhost) as the IP address of the requesting user. .. [4] Bring Your Own Device (BYOD) is the policy of permitting employees to bring personally owned mobile devices (laptops, tablets, and smart phones) to their workplace, and use those devices to access privileged company information and applications. The term is also used to describe the same practice applied to students using personally owned devices in an educational setting. .. _ch-printer-driverless-pdf-processing: Processing Driverless PDF Transfer ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ PDF files received from :ref:`Driverless File Transfer Print ` are validated, repaired and processed before admitted as :ref:`SafePages `. These are the processing steps: .. _ch-printer-driverless-pdf-processing-step-1: 1. *Uploaded PDF document is read to check validity.* |br| |br| If the PDF is assessed as invalid by the PDF library used by |PRODUCT_NAME|, a repair is executed with :ref:`pdftocairo `. If repair fails, the document is rejected. |br| |br| .. note:: Although shown correctly as SafePages, PDF files might not have a completely valid PDF format. When these invalid PDFs are proxy printed, CUPS filtering may deliver Page Description Language (PDL) that incorrectly describes the PDF content. As a result, printed output will not be as expected. Text can be omitted, and in some cases we observed only a single blank page was printed. To prevent this situation, SavaPage tries to repair these files, which is a modest action with minor performance impact. .. warning:: Repair is a best-effort attempt and is no guarantee for success. 2. *If PDF is encrypted, it is decrypted.* :ref:`QPDF ` is used for this step. .. _ch-printer-driverless-pdf-processing-step-3: 3. *PDF is optimized* with the ``ps2pdf`` system command. .. _ch-printer-driverless-pdf-processing-step-4: 4. *PDF font syntax is verified*. |br| |br| If font errors are encountered, a repair is executed with :ref:`pdftocairo `, when not already executed in a previous step. When font errors persist, the PDF document is rejected. .. _ch-printer-driverless-pdf-processing-step-5: 5. *Non-embedded/non-standard PDF fonts are embedded withbest-fit fonts available on the host system.* .. note:: This is because font embedding performed by CUPS/Ghostscript might result in missing text as explained in :ref:`Step 1 `. .. _ch-printer-driverless-pdf-processing-step-6: 6. *PDF is cleaned* by executing :ref:`pdftocairo ` command (when not already executed in a previous step) and optionally a “Ghostscript prepress” command. .. note:: This is because the ``pdf2ps`` filter as executed by CUPS/Ghostscript might result in missing text and annotations as explained in :ref:`Step 1 `. .. _ch-printer-driverless-pdf-processing-step-7: 7. A final check is performed by reading the page properties of the PDF. If the check fails, a PDF optimization is performed as explained in :ref:`Step 3 `. You can enable/disable each step with the following configuration properties: .. list-table:: Driverless PDF Transfer Processing Configuration Properties :width: 100% :widths: 35 65 :header-rows: 1 * - Configuration property - Description * - print-in.pdf.optimize - Set to ``Y`` or ``N`` (default) to enable/disable optimization (cleaning) of PDF files with the ``ps2pdf`` system command in :ref:`Step 3 `. See `Optimizing PDFs with Ghostscript `__. Note: :ref:`Step 7 ` is always performed, regardless of the value of this configuration property. * - print-in.pdf.invalid.repair - Set to ``Y`` (default) or ``N`` to enable/disable repair of invalid PDF files with :ref:`pdftocairo `. if ``N``, invalid PDF files are rejected. * - print-in.pdf.encrypted.allow - Set to ``Y`` (default) or ``N`` to enable/disable decryption of encrypted PDF files with :ref:`QPDF `. If ``N``, encrypted PDF files are rejected. |br| |br| **Important**: this property also applies when :ref:`Printing Encrypted PDF ` with a printer driver. |br| |br| Also see :ref:`SafePages `. * - print-in.pdf.fonts.verify - Set to ``Y`` (default) or ``N`` to enable/disable PDF font syntax validation. If ``Y``, PDF files are checked with the ``pdffonts`` system command. When font syntax errors or warnings are encountered a repair is executed with :ref:`pdftocairo ` (when not already executed in a previous step). If font errors persist, the PDF document is rejected if "print-in.pdf.fonts.verify.reject" is ``Y``. * - print-in.pdf.fonts.verify.reject - Set to ``Y`` (default) or ``N`` to enable/disable rejection of PDF files with font issues that cannot be repaired. If ``N``, PDF files with font issues are accepted with an appropriate user/log message. * - print-in.pdf.fonts.embed - Set to ``Y`` (default) or ``N`` to enable/disable embedding of non-embedded / non-standard PDF fonts by executing :ref:`pdftocairo ` command (when not already executed in a previous step). * - print-in.pdf.clean - Set to ``Y`` (default) or ``N`` to enable/disable PDF cleaning by executing :ref:`pdftocairo ` command (when not already executed in a previous step). |br| |br| This is a replacement for the *deprecated* "proxy-print.repair.enable" property. See :ref:`Proxy Print`. * - print-in.pdf.prepress - Set to ``N`` (default) or ``Y`` to disable/enable PDF cleaning by executing command: |br| ``gs -sDEVICE=pdfwrite -dPDFSETTINGS=/prepress`` See |RST_LINK_CONFIG_EDITOR| on how to set this property. .. note:: The :ref:`pdftocairo ` and ``gs`` command embeds all fonts, even standard PDF fonts. .. tip:: Driverless PDF Transfer statistics are shown on the :ref:`Admin Web App Dashboard `. The final result of a Driverless PDF Transfer Print on the display of fonts is shown in the SafePages :ref:`Document Details ` popup dialog.