Changeset 13 for LATMOS-Accounts/lib/LATMOS/Accounts/Bases
- Timestamp:
- 03/02/09 22:02:23 (15 years ago)
- Location:
- LATMOS-Accounts/lib/LATMOS/Accounts/Bases
- Files:
-
- 2 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LATMOS-Accounts/lib/LATMOS/Accounts/Bases/Unix.pm
r10 r13 54 54 } 55 55 56 sub _canonicals_fields { 57 my ($self, $type) = @_; 58 $type = lc($type); 59 { 60 user => { 61 uidNumber => 'uid', 62 gidNumber => 'gid', 63 gecos => 'gecos', 64 homeDirectory => 'home', 65 loginShell => 'shell', 66 userPassword => ($self->{use_shadow} ? 'spassword' : 'password'), 67 }, 68 group => { 69 gidNumber => 'gid', 70 memberUID => 'user_list', 71 }, 72 }->{$type} 73 } 74 75 sub list_canonicals_fields { 76 my ($self, $type) = @_; 77 keys %{ $self->_canonicals_fields($type) || {} } 78 } 79 80 sub get_field_name { 81 my ($self, $type, $cfield) = @_; 82 ($self->_canonicals_fields($type) || {})->{$cfield} 83 } 84 85 56 86 my @password_fields = qw(account password uid gid gecos home shell); 57 87 my @shadow_fields = qw(account spassword last_changed before_ch after_ch exp_warn exp_disable disable res);
Note: See TracChangeset
for help on using the changeset viewer.