Indicator-session assumes there's only one active user

Bug #1263438 reported by Alkis Georgopoulos
18
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Session Menu
Triaged
Medium
Unassigned
indicator-session (Ubuntu)
Confirmed
Undecided
Unassigned
Nominated for Precise by Alkis Georgopoulos
Nominated for Trusty by Alkis Georgopoulos

Bug Description

In the policykit sense, an "active" user is one that is using a physical console, and so has rights to shutdown the system etc.
Remote users, like NX users, LTSP users, XDMCP users, or users that use X+VNC scripts to remotely log in, are correctly not considered active, and thus don't have some privileges like shutting down the system.

The problem is that indicator-session is using the policykit meaning of the word "active",
instead of checking for "currently logged in and working" users,
i.e. it thinks that only one user can be working on a PC at a given time.

From src/backend-dbus/users.c, line 593:
      ret->is_current_user = uid == p->active_uid;

So if I'm logged in from a thin client, or via NX, or via XDMCP etc etc, indicator-session doesn't match the uid of its own process to tell me who I am, but just relies on the matching of the "active" user.
Thus I can't see my username if I enable "show-real-name-on-panel", I don't see the dot that means "current user" in the menu's user list etc.

A solution would be to use getuid() in the code above.

no longer affects: ltsp (Ubuntu)
Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

I tested the getuid() change and it works fine on LTSP thin and fat clients.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in indicator-session (Ubuntu):
status: New → Confirmed
Changed in indicator-session:
importance: Undecided → Medium
status: New → Triaged
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.