cgi-bin: localhost

Matthias Hilbig necmas at gmx.de
Thu Aug 12 01:31:38 PDT 2004


Ah, that was also one of the mistakes I made when first installing CUPS.

Maybe a note in the default configuration file would be helpful for new users:

f.e.:

#
# Ports/addresses that we listen to.  The default port 631 is reserved
# for the Internet Printing Protocol (IPP) and is what we use here.
#
# You can have multiple Port/Listen lines to listen to more than one
# port or address, or to restrict access:
#
#    Port 80
#    Port 631
#    Listen hostname
#    Listen hostname:80
#    Listen hostname:631
#    Listen 1.2.3.4
#    Listen 1.2.3.4:631
#
# NOTE: Always listen to localhost, as the web frontend will not
# work otherwise.
#
# NOTE: Unfortunately, most web browsers don't support TLS or HTTP Upgrades
# for encryption.  If you want to support web-based encryption you'll
# probably need to listen on port 443 (the "https" port...)
#


Michael Sweet wrote:
> somogyi at de.ibm.com wrote:
> > Hello,
> >
> > We have the following problem:
> >
> > When CUPS is configured to listen only on a fixed address (with the "Listen x.x.x.x:631" parameter), then the CUPS web interface doesn't work.
> > This occours because the CUPS web interface connects to ipp://localhost, but the CUPS service listens on x.x.x.x:631 (not localhost).
> >
> > Example code part of CUPS ("cgi-bin/printers.c"):
> >   http = httpConnectEncrypt("localhost", ippPort(), cupsEncryption());
> >
> > (almost localhost everywhere in the cgi-bin source)
> >
> > Is it a bug, or a feature?
>
> It is as designed; you MUST listen on the local loopback interface
> for the authentication information that is passed to the CGIs to
> work.  We will not be changing this.
>
> --
> ______________________________________________________________________
> Michael Sweet, Easy Software Products           mike at easysw dot com
> Printing Software for UNIX                       http://www.easysw.com





More information about the cups mailing list