/*
- * "$Id: auth.c 5442 2006-04-20 14:00:02Z mike $"
+ * "$Id: auth.c 181 2006-06-22 20:01:18Z jlovell $"
*
* Authorization routines for the Common UNIX Printing System (CUPS).
*
* Local globals...
*/
-#if defined(__hpux) && defined(HAVE_LIBPAM)
+#if defined(__hpux) && HAVE_LIBPAM
static cupsd_authdata_t *auth_data; /* Current client being authenticated */
#endif /* __hpux && HAVE_LIBPAM */
*/
for (iface = (cupsd_netif_t *)cupsArrayFirst(NetIFList);
- iface && !strcmp(masks->mask.name.name, iface->name);
+ iface;
iface = (cupsd_netif_t *)cupsArrayNext(NetIFList))
{
+ if (strcmp(masks->mask.name.name, iface->name))
+ continue;
+
if (iface->address.addr.sa_family == AF_INET)
{
/*
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: con->uri=\"%s\", con->best=%p(%s)",
- con->uri, con->best, con->best ? con->best->location : "");
+ con->uri, con->best, con->best ? con->best->location ?
+ con->best->location : "(null)" : "");
if (owner)
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: owner=\"%s\"", owner);
*/
if (best->encryption >= HTTP_ENCRYPT_REQUIRED && !con->http.tls &&
+ strcasecmp(con->http.hostname, "localhost") &&
best->satisfy == AUTH_SATISFY_ALL)
{
cupsdLogMessage(CUPSD_LOG_DEBUG2,
/*
- * End of "$Id: auth.c 5442 2006-04-20 14:00:02Z mike $".
+ * End of "$Id: auth.c 181 2006-06-22 20:01:18Z jlovell $".
*/