Re: List of accounts
Re: List of accounts
- Subject: Re: List of accounts
- From: Juan Manuel Palacios <email@hidden>
- Date: Mon, 10 Aug 2009 14:44:13 -0430
On Aug 10, 2009, at 1:46 PM, Tim Murison wrote:
Hi,
I'm trying to determine how to get a list of BSD user ids that can
login to
the machine, either with a GUI or via ssh.
My current approach is to build something like the 'dscacheutil -q
user'
command filtering on users who have a valid shell. I'm thinking that
a valid
shell would be determined by looking in the /etc/shells file.
Is there a better way of doing this?
-Tim
I wrote a small script a while ago:
http://trac.macports.org/browser/users/jmpp/showids.sh
It currently seems to have some output formatting issues on Leopard
when you call it with the -v verbose flag (perhaps dscl's output
changed a bit from Tiger's), but other than that it comes in handy
when you want to see which uid's and gid's are taken on your system.
Further parsing and/or deeper inspection of the Directory Services
info might get your the exact information you need. Feel free to use &
hack at will.
Regards,...
-jmpp
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden