Bug 146869

Summary: LibreOffice connects to the print server (CUPS) when opening a document with PrinterName config-item
Product: LibreOffice Reporter: Vincent Lefevre <vincent-docf>
Component: LibreOfficeAssignee: Not Assigned <libreoffice-bugs>
Status: UNCONFIRMED ---    
Severity: normal    
Priority: medium    
Version: 7.3.0.2 rc   
Hardware: All   
OS: All   
Whiteboard: QA:needsComment
Crash report or crash signature: Regression By:
Attachments: testcase

Description Vincent Lefevre 2022-01-20 03:05:50 UTC
Created attachment 177663 [details]
testcase

When I open some document such as the one attached, LibreOffice tries to connect to the print server, while I don't intend to print the document. This can yield a timeout of 20 - 30 seconds if the print server isn't available or request a password. There are also potential privacy/security issues.

This issue seems to come from

<config:config-item config:name="PrinterName" config:type="string">Generic Printer</config:config-item>

in settings.xml.

The Debian bugs I had reported:
  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=428064 (2007, OpenOffice.Org)
  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=708533 (2013, LibreOffice)
Comment 1 Vincent Lefevre 2022-01-20 03:17:15 UTC
I forgot: to reproduce the timeout, create a /etc/cups/client.conf file with a line like

ServerName 192.168.0.2:443

(check with telnet that the connection hangs, or choose another IP address).