CHANGES IN CUPS V1.6.3
+ - Fixed a regression on the handling of auth keys on OS X if the
+ cups-files.conf was not present or did not contain a SystemAuthKey
+ value.
+ - The scheduler incorrectly did a reverse lookup of the server address
+ when HostNameLookups was turned off (STR #4302)
- The scheduler incorrectly computed the final content type value when
null filters were present.
dnl Extra platform-specific libraries...
CUPS_DEFAULT_PRINTOPERATOR_AUTH="@SYSTEM"
+CUPS_DEFAULT_SYSTEM_AUTHKEY=""
CUPS_SYSTEM_AUTHKEY=""
INSTALLXPC=""
if test "x$default_adminkey" != xdefault; then
CUPS_SYSTEM_AUTHKEY="SystemGroupAuthKey $default_adminkey"
+ CUPS_DEFAULT_SYSTEM_AUTHKEY="$default_adminkey"
elif grep -q system.print.operator /etc/authorization; then
CUPS_SYSTEM_AUTHKEY="SystemGroupAuthKey system.print.admin"
+ CUPS_DEFAULT_SYSTEM_AUTHKEY="system.print.admin"
else
CUPS_SYSTEM_AUTHKEY="SystemGroupAuthKey system.preferences"
+ CUPS_DEFAULT_SYSTEM_AUTHKEY="system.preferences"
fi
if test "x$default_operkey" != xdefault; then
AC_SUBST(CUPS_DEFAULT_PRINTOPERATOR_AUTH)
AC_DEFINE_UNQUOTED(CUPS_DEFAULT_PRINTOPERATOR_AUTH, "$CUPS_DEFAULT_PRINTOPERATOR_AUTH")
+AC_DEFINE_UNQUOTED(CUPS_DEFAULT_SYSTEM_AUTHKEY, "$CUPS_DEFAULT_SYSTEM_AUTHKEY")
AC_SUBST(CUPS_SYSTEM_AUTHKEY)
AC_SUBST(INSTALLXPC)
#define CUPS_DEFAULT_GROUP "sys"
#define CUPS_DEFAULT_SYSTEM_GROUPS "sys root system"
#define CUPS_DEFAULT_PRINTOPERATOR_AUTH "@SYSTEM"
+#define CUPS_DEFAULT_SYSTEM_AUTHKEY "system.print.admin"
/*
socklen_t peersize; /* Size of peer credentials */
#ifdef HAVE_AUTHORIZATION_H
const char *name; /* Authorizing name */
+ int no_peer = 0; /* Don't allow peer credentials? */
+
+ /*
+ * See if we should allow peer credentials...
+ */
for (name = (char *)cupsArrayFirst(con->best->names);
name;
name = (char *)cupsArrayNext(con->best->names))
+ {
if (!_cups_strncasecmp(name, "@AUTHKEY(", 9) ||
!_cups_strcasecmp(name, "@SYSTEM"))
{
- cupsdLogMessage(CUPSD_LOG_ERROR,
- "[Client %d] PeerCred authentication not allowed for "
- "resource.", con->http.fd);
- return;
+ /* Normally don't want peer credentials if we need an auth key... */
+ no_peer = 1;
}
+ else if (!_cups_strcasecmp(name, "@OWNER"))
+ {
+ /* but if @OWNER is present then we allow it... */
+ no_peer = 0;
+ break;
+ }
+ }
+
+ if (no_peer)
+ {
+ cupsdLogMessage(CUPSD_LOG_ERROR,
+ "[Client %d] PeerCred authentication not allowed for "
+ "resource per AUTHKEY policy.", con->http.fd);
+ return;
+ }
#endif /* HAVE_AUTHORIZATION_H */
if ((pwd = getpwnam(authorization + 9)) == NULL)
AccessLogLevel = CUPSD_ACCESSLOG_ACTIONS;
ConfigFilePerm = CUPS_DEFAULT_CONFIG_FILE_PERM;
FatalErrors = parse_fatal_errors(CUPS_DEFAULT_FATAL_ERRORS);
- default_auth_type = CUPSD_AUTH_BASIC;
+ default_auth_type = CUPSD_AUTH_BASIC;
#ifdef HAVE_SSL
DefaultEncryption = HTTP_ENCRYPT_REQUIRED;
SSLOptions = CUPSD_SSL_NONE;
cupsdClearString(&DefaultPolicy);
#ifdef HAVE_AUTHORIZATION_H
- cupsdClearString(&SystemGroupAuthKey);
+ cupsdSetString(&SystemGroupAuthKey, CUPS_DEFAULT_SYSTEM_AUTHKEY);
#endif /* HAVE_AUTHORIZATION_H */
MaxSubscriptions = 100;
!_cups_strcasecmp(line, "TempDir") ||
!_cups_strcasecmp(line, "User"))
{
- cupsdLogMessage(CUPSD_LOG_WARN,
+ cupsdLogMessage(CUPSD_LOG_INFO,
"Please move \"%s%s%s\" on line %d of %s to the %s file; "
"this will become an error in a future release.",
line, value ? " " : "", value ? value : "", linenum,