![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| High Level Programming Post questions about C, C++, Java, SQL, and other programming languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Change of group to different users | gsiva | Shell Programming and Scripting | 2 | 08-23-2009 07:09 PM |
| How can i allow only a group of users in NIS? | younus_syed | SUN Solaris | 9 | 09-10-2008 06:41 PM |
| SSH for a group of users ? | deepusunil | Shell Programming and Scripting | 3 | 07-22-2008 11:57 AM |
| Max users in a group ? | anmiller | AIX | 4 | 09-05-2007 06:32 PM |
| How to obtain list of users ? | bobby36 | UNIX for Dummies Questions & Answers | 7 | 04-10-2007 12:34 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
to obtain users of each group in c
Hello
They have ordered to me that makes several small utilities in C/C++ for the servants, among them a small program in C/C++ to generate a file HTML with the groups of that servant and in addition that is the corresponding users of that group. For example of a group: Group: Sys Members: root, bin, Sys, adm…. and that all the groups. And not like doing it, to know the groups it is only question to read the /etc/group file, but nonencounter the form to know the members each group. That analogous functions to getpwent exist, setpwent… for groups, but encounter any information does not exceed they. Which use to make or another small program that generates a HTML with the data of all the users, but they do not serve me for this work in particular, or at least not like. Thanks. |
|
|||||
|
I think what you are looking for is the getgrent() function.
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|