Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage (Read 320 times) previous topic - next topic
0 Members and 5 Guests are viewing this topic.

CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage

I use Artix' world/cups version 2:2.4.10-1. 

For debugging, I ran cupsd -f -c /etc/cups/cupsd.conf -s /etc/cups/cups-files.conf with LogLevel debug in /etc/cups/cupsd.conf.

Then I opened the CUPS webinterface administration panel, did click "Add Printer" -> "Discovered Network Printers: ( ) Brother MFC-L3730CDN series (Brother MFC-L3730CDN series)" -> "Continue".

Then, the "Connection:"-field was pre-filled with garbage, e.g. currently "�zc". Screenshot:





The unicode-garbage is different at each invocation. And it also appears when I want to add an USB printer.

Note that in the /var/log/cups/error_log the URI seems to be logged correctly:
Code: [Select]
D [11/Jul/2024:16:18:13 +0200] [CGI] admin.cgi started...
D [11/Jul/2024:16:18:13 +0200] cupsdSetBusyState: newbusy="Active clients", busy="Active clients"
D [11/Jul/2024:16:18:13 +0200] [Client 8] Server address is "/run/cups/cups.sock".
D [11/Jul/2024:16:18:13 +0200] [Client 8] Accepted from localhost (Domain)
D [11/Jul/2024:16:18:13 +0200] [Client 8] Waiting for request.
D [11/Jul/2024:16:18:13 +0200] [CGI] http=0x5637a9ce5d10
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: SECTION=\"admin\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: REFRESH_PAGE=\"\"
D [11/Jul/2024:16:18:13 +0200] [CGI] org.cups.sid cookie is \"e4bf2e4626104fc15c045c706dbabd0b\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: org.cups.sid=\"e4bf2e4626104fc15c045c706dbabd0b\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: OP=\"add-printer\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: DEVICE_URI=\"dnssd://Brother%20MFC-L3730CDN%20series._ipp._tcp.local/?uuid=e3248000-80ce-11db-8000-b42200b6fcb8|Brother MFC-L3730CDN series\"
D [11/Jul/2024:16:18:13 +0200] [CGI] op=\"add-printer\"...
D [11/Jul/2024:16:18:13 +0200] [CGI] do_am_printer: DEVICE_URI=\"dnssd://Brother%20MFC-L3730CDN%20series._ipp._tcp.local/?uuid=e3248000-80ce-11db-8000-b42200b6fcb8|Brother MFC-L3730CDN series\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: CURRENT_MAKE=\"Brother\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: CURRENT_MAKE_AND_MODEL=\"Brother MFC-L3730CDN series\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: PRINTER_INFO=\"Brother MFC-L3730CDN series\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: TEMPLATE_NAME=\"Brother_MFC-L3730CDN_series\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: DEVICE_URI=\"dnssd://Brother%20MFC-L3730CDN%20series._ipp._tcp.local/?uuid=e3248000-80ce-11db-8000-b42200b6fcb8\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: TITLE=\"Add Printer\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: SERVER_NAME=\"localhost\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: REMOTE_USER=\"root\"
D [11/Jul/2024:16:18:13 +0200] [CGI] cgiSetVariable: CUPS_VERSION=\"CUPS v2.4.10\"

Does anyone else has this? Is this Arch/ Artix specific, or a CUPS issue, or something else?

I also attach the logfiles that cupsd has created, as well as the /etc/cups/cupsd.conf and /etc/cups/printers.conf, with sensitive information (hostname, username, printer names) censored (replaced with string "[censored]").

 

Re: CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage

Reply #1
This has happened to me with Debian, Arch, and Artix. Simply delete what's there then pick your connection type using the examples shown.

For example using my HP, I use ipps://xxx.xxx.xxx.xxx

Then carry on with the other bits and for me, it all has been fine without issues.
Supercalifragilisticexpialidocious

Re: CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage

Reply #2
You mean delete the garbage?

Yes, that works, but it is a lot of manual labour to actually find out the correct stuff to put in (for some USB printers serial numbers e.g.; for this network printer I do not know it's IP, etc. -- So it is in the logs, but that is not the solution actually.)

Does anyone know more what the underlying issue is?

Re: CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage

Reply #3
You are correct, it's not "the" solution but it is a work-a-round.
When I started to look at this about a year ago, it appeared at the time it was related to IP Everywhere. Several threads blamed it on cups for going that route while others threads went as far as mentioning it was the way ghostscript handled it and the version in use.

I never found a solution and since then I just opted to install my printer the way I mentioned. Yes, it is a PITA. For me, it was easier to deal with the 2 minutes of going through the motions of installing my printer then to track down if a solution was ever found.

After all, at the time I saw that issue over a year ago, I installed my printer twice. So for 4 minutes during the course of a year - it wasn't a big deal to me. YMMV
Supercalifragilisticexpialidocious

Re: CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage

Reply #4
When I started to look at this about a year ago, it appeared at the time it was related to IP Everywhere. Several threads blamed it on cups for going that route while others threads went as far as mentioning it was the way ghostscript handled it and the version in use.
So it has already been reported upstream? And no one really knows what the issue is?

Do you have an upstream URL of a reported issue for me? (I somehow "fail" to find it because I do not know the correct search term; "Cups add printer: random unicode characters" does not yield anything useful for me, but it shows results about issues with printing with already added printers.)

Regards!

Re: CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage

Reply #5
I suggest opening a bug report with the data you used here.
The bug reports for cups go back only so far (albeit 3 years should be enough)

I didnt bother since this seemed to be a known issue  then and like I said, many folks thought it was related to the move of supporting ip everywhere and others felt is was due to a ghostscript version.

Was faster and easier for me to just set it manually then documented what I used for reference down the road - YMMV

Supercalifragilisticexpialidocious



Re: CUPS: Adding printer via web frontend: "Connection:" filled with unicode garbage

Reply #8
I now mark this topic as "Solved" because it is not an Artix specific issue.

Although the issue is still present, it is not Artix' responsibility to fix it. And upstream is aware of it.

Regards!