~ubuntu-branches/ubuntu/precise/smbldap-tools/precise

« back to all changes in this revision

Viewing changes to smbldap-passwd

  • Committer: Bazaar Package Importer
  • Author(s): Sergio Talens-Oliag
  • Date: 2009-10-15 21:34:50 UTC
  • mfrom: (1.2.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20091015213450-eptatqmy51ka9j3j
Tags: 0.9.5-1
New upstream release (Closes: Bug#548665).

Show diffs side-by-side

added added

removed removed

Lines of Context:
228
228
                    my $winmagic = 2147483647;
229
229
                    my $valacctflags = "[U]";
230
230
                    push(@mods, 'sambaPwdMustChange' => 0);
231
 
                    push(@mods, 'sambaPwdLastSet' => $winmagic);
 
231
                    push(@mods, 'sambaPwdLastSet' => 0);
232
232
                    push(@mods, 'sambaAcctFlags' => $valacctflags);
233
233
                }
234
234
        # Let's change nt/lm passwords
266
266
if ( $update_unix_passwd ) {
267
267
    my $shadowLastChange=int(time()/86400);
268
268
    my $modify;
269
 
    if ($< != 0) {
 
269
    if (($< != 0) || (!defined $config{defaultMaxPasswordAge})) {
270
270
        $modify = $ldap_master->modify ( "$dn",
271
271
                                            changes => [
272
272
                                                        replace => [userPassword => "$hash_password"],