- type = !isempty(display) ? "x11" :
- !isempty(tty) ? "tty" : "unspecified";
-
- remote = !isempty(remote_host) && !streq(remote_host, "localhost") && !streq(remote_host, "localhost.localdomain");
-
- if (!dbus_message_append_args(m,
- DBUS_TYPE_UINT32, &uid,
- DBUS_TYPE_UINT32, &pid,
- DBUS_TYPE_STRING, &service,
- DBUS_TYPE_STRING, &type,
- DBUS_TYPE_STRING, &seat,
- DBUS_TYPE_UINT32, &vtnr,
- DBUS_TYPE_STRING, &tty,
- DBUS_TYPE_STRING, &display,
- DBUS_TYPE_BOOLEAN, &remote,
- DBUS_TYPE_STRING, &remote_user,
- DBUS_TYPE_STRING, &remote_host,
- DBUS_TYPE_INVALID)) {
- pam_syslog(handle, LOG_ERR, "Could not attach parameters to message.");
- r = PAM_BUF_ERR;
- goto finish;
+ if (seat && !streq(seat, "seat0") && vtnr != 0) {
+ pam_syslog(handle, LOG_DEBUG, "Ignoring vtnr %d for %s which is not seat0", vtnr, seat);
+ vtnr = 0;