Re: Current active login session
Re: Current active login session
- Subject: Re: Current active login session
- From: Dreamcat4 <email@hidden>
- Date: Sat, 21 Aug 2010 17:44:36 +0100
I wonder what the ownership of /dev/console changes to when there are
0 logged in users? root:wheel ?
It definitely works when switching between logged in users:
janitors-Mac-mini:~ janitor$ while ls -lsa /dev/console; do sleep 1; done
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 id staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
0 crw------- 1 janitor staff 0, 0 21 Aug 01:40 /dev/console
^C
janitors-Mac-mini:~ janitor$
So a big thumbs up :)
On Sat, Aug 21, 2010 at 1:27 PM, Antoine Missout
<email@hidden> wrote:
> Am I missing something or can't I just check who owns /dev/console ?
>
> http://developer.apple.com/mac/library/technotes/tn2005/tn2083.html
> "The console user is the user whose GUI login session is using the console. The console device, /dev/console, is owned by the console user."
>
> Seems simple enough...
>
> - Antoine
>
>
>
>
> On Aug 20, 2010, at 8:45 AM, Quinn The Eskimo! wrote:
>
>>
>>> If it was possible to get the answer in another manner directly from the daemon without relying on the agents, that'd be much better.
>>
>> Not in any well supported fashion.
>
>
>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Darwin-kernel mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden