Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
cups-1.3.10 totally breaks printing
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
Dragonlord
Guru
Guru


Joined: 22 Aug 2004
Posts: 446
Location: Switzerland

PostPosted: Sat Apr 18, 2009 6:22 pm    Post subject: cups-1.3.10 totally breaks printing Reply with quote

Upgrade to cups-1.3.10 and hell breaks loose. Nobody in the office can print anymore: all dead. Checked the logs and the following keeps piling:
[code]Request from "XXX.XXX.XXX.XXX" using invalid Host: field "server.xxx.xxx:631"[/quote]

Google gave no information. I found somewhere a reference that a slew of bugs got fixed in 1.3.10 including security flaws. Looks like they also introduced a heck lot of bugs in the same time. What the hell is going on here? No printing, no website at 631. What's that please for a bug-fix! Any ideas?
Back to top
View user's profile Send private message
kevstar31
Guru
Guru


Joined: 22 Nov 2006
Posts: 449
Location: Ohio

PostPosted: Sat Apr 18, 2009 8:20 pm    Post subject: Reply with quote

what is the output of:
Code:
cat /var/log/cups/access_log && cat /var/log/cups/error_log && cat /var/log/cups/page_log

at http://pastebin.com/ and post a link to it.

God Bless,
Kevin
_________________
while(true) std::cout << "Jesus I trust in you." << std::endl;
My Political Compass
Back to top
View user's profile Send private message
Dragonlord
Guru
Guru


Joined: 22 Aug 2004
Posts: 446
Location: Switzerland

PostPosted: Sat Apr 18, 2009 10:20 pm    Post subject: Reply with quote

Exactly what I mentioned above, tons and tons of this line. The server just disallows anything which is not localhost:631 .
_________________
DragonDreams: Leader and Head Programmer
Back to top
View user's profile Send private message
kernelOfTruth
Watchman
Watchman


Joined: 20 Dec 2005
Posts: 6111
Location: Vienna, Austria; Germany; hello world :)

PostPosted: Sat Apr 18, 2009 11:18 pm    Post subject: Reply with quote

see:

#266678
_________________
https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa

Hardcore Gentoo Linux user since 2004 :D
Back to top
View user's profile Send private message
Dragonlord
Guru
Guru


Joined: 22 Aug 2004
Posts: 446
Location: Switzerland

PostPosted: Sun Apr 19, 2009 1:28 am    Post subject: Reply with quote

Figured it out. Looks like the CUPS upstream guys are total morons. They change the behavior of the CUPS server in a way it's no fucking server anymore. All requests, no matter if printing or web interface are denied if the client does not identify itself in the header as localhost which literally turns a network application into a fucking brick. There's only one localhost in the entire universe and that the server itself. Everybody else has a hostname different from localhost. So denying anything but localhost totally kills the server. Whoever had this great idea should be banned from ever writing software again. Solution is to add a "ServerAlias *" which is labeled in the docs as highly insecure. Well... if I can choose between a server which is no server ( because it server nobody but localhost ) and this option then what the hell of a different choice one has. Upstream morons please fix your idiocy ASAP. This is not a bug this is a software engineering crime of the highest degree! ¬.=.¬
_________________
DragonDreams: Leader and Head Programmer
Back to top
View user's profile Send private message
overkll
Veteran
Veteran


Joined: 21 Sep 2004
Posts: 1249
Location: Austin, Texas

PostPosted: Sun Apr 19, 2009 2:26 am    Post subject: Reply with quote

If you change "Listen localhost:631" to "Port 631", it's back in server mode.

I found a different bug. If one uses the CUPS gui via a web browser, and enable "Show printers shared by other systems" and/or "Allow remote administration", the gui edits /etc/cups/cupsd.conf with the wrong syntax for "Allow". The gui uses "Allow @LOCAL", when the correct syntax is "Allow from @LOCAL"

It took some time, hair pulling and head banging to figure it out.
Back to top
View user's profile Send private message
kernelOfTruth
Watchman
Watchman


Joined: 20 Dec 2005
Posts: 6111
Location: Vienna, Austria; Germany; hello world :)

PostPosted: Sun Apr 19, 2009 10:51 am    Post subject: Reply with quote

adding the following to /etc/cups/cupsd.conf fixed it for me:

Code:
HostNameLookups On


Quote:
This is apparently the result of the following new "feature" in cups-1.3.10:

http://www.cups.org/articles.php?L582
"The scheduler no longer looks up the local hostname by default; turn on
hostname lookups to restore the previous behavior."

In other words, if you use the default cupsd.conf, with cups-1.3.10, ALL local
printers will stop working - and apparently, that's by design!

In order to make printing work again, you need to add the following two lines
to cupsd.conf:

# Unfuck cups-1.3.10 local printing
HostNameLookups On


kudos to Alexandre Rostovtsev ! (see bug report)
_________________
https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa

Hardcore Gentoo Linux user since 2004 :D
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum