#!/usr/bin/perl use warnings; use strict; use User::grent qw(:FIELDS); while (my $group = getgrent) { print 'Name : ', $gr_name, "\n"; print 'Password: ', $gr_passwd, "\n"; print 'Group ID: ', $gr_gid, "\n"; print 'Members : ', join(', ', @{$group->members}), "\n\n"; }