~ubuntu-branches/ubuntu/trusty/ldap-account-manager/trusty-proposed

« back to all changes in this revision

Viewing changes to lib/modules/shadowAccount.inc

  • Committer: Package Import Robot
  • Author(s): Roland Gruber
  • Date: 2013-07-21 11:15:58 UTC
  • mfrom: (1.2.21)
  • Revision ID: package-import@ubuntu.com-20130721111558-ex49xgcpo71fh0xg
Tags: 4.2.1-2
* Apache 2.4 support
* Fix "transition towards Apache 2.4" 
  support conf-enabled (Closes: #669824)
* Fix "[ldap-account-manager] Can't install ldap-account-manager"
  support conf-enabled (Closes: #711778)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
<?php
2
2
/*
3
 
$Id: shadowAccount.inc 4642 2012-11-11 11:35:45Z gruberroland $
 
3
$Id: shadowAccount.inc 4904 2013-05-09 17:26:56Z gruberroland $
4
4
 
5
5
  This code is part of LDAP Account Manager (http://www.ldap-account-manager.org/)
6
6
  Copyright (C) 2003 - 2006  Tilo Lutz
160
160
                        'shadowLastChange' => _('Last password change'),
161
161
                        'shadowWarning' => _('Password warning'),
162
162
                        'shadowInactive' => _('Account inactive'),
163
 
                        'shadowExpire' => _('Password expiration')
 
163
                        'shadowExpire' => _('Password expiration'),
 
164
                        'shadowMinAge' => _('Minimum password age'),
 
165
                        'shadowMaxAge' => _('Maximum password age'),
164
166
                );
165
167
                // help Entries
166
168
                $return['help'] = array (
480
482
                if (isset($this->attributes['shadowLastChange'][0])) {
481
483
                        $shadowLastChange = date('d. m. Y',$this->attributes['shadowLastChange'][0]*24*3600);
482
484
                }
483
 
                $shadowWarn = '';
484
 
                if (isset($this->attributes['shadowWarn'][0])) {
485
 
                        $shadowWarn = $this->attributes['shadowWarn'][0];
486
 
                }
487
 
                $shadowInactive = '';
488
 
                if (isset($this->attributes['shadowInactive'][0])) {
489
 
                        $shadowInactive = $this->attributes['shadowInactive'][0];
490
 
                }
491
485
                $shadowExpire = '';
492
486
                if (isset($this->attributes['shadowExpire'][0])) {
493
487
                        $shadowExpire = date('d. m. Y',$this->attributes['shadowExpire'][0]*24*3600);
494
488
                }
495
 
                $shadowMin = '';
496
 
                if (isset($this->attributes['shadowMin'][0])) {
497
 
                        $shadowMin = $this->attributes['shadowMin'][0];
498
 
                }
499
 
                $shadowMax = '';
500
 
                if (isset($this->attributes['shadowMax'][0])) {
501
 
                        $shadowMax = $this->attributes['shadowMax'][0];
502
 
                }
503
 
                return array('shadowAccount_shadowLastChange' => array('<block><key>' . _('Last password change') . '</key><value>' . $shadowLastChange . '</value></block>'),
504
 
                        'shadowAccount_shadowWarning' => array('<block><key>' . _('Password warning') . '</key><value>' . $shadowWarn . '</value><block>'),
505
 
                        'shadowAccount_shadowInactive' => array('<block><key>' . _('Password expiration') . '</key><value>' . $shadowInactive . '</value></block>'),
 
489
                $return = array('shadowAccount_shadowLastChange' => array('<block><key>' . _('Last password change') . '</key><value>' . $shadowLastChange . '</value></block>'),
506
490
                        'shadowAccount_shadowExpire' => array('<block><key>' . _('Account expiration date') . '</key><value>' . $shadowExpire . '</value></block>'),
507
 
                        'shadowAccount_shadowMinAge' => array('<block><key>' . _('Minimum password age') . '</key><value>' . $shadowMin . '</value><block>'),
508
 
                        'shadowAccount_shadowMaxAge' => array('<block><key>' . _('Maximum password age') . '</key><value>' . $shadowMax . '</value><block>'),
509
491
                );
 
492
                $this->addSimplePDFField($return, 'shadowWarning', _('Password warning'));
 
493
                $this->addSimplePDFField($return, 'shadowInactive', _('Password expiration'));
 
494
                $this->addSimplePDFField($return, 'shadowMinAge', _('Minimum password age'), 'shadowMin');
 
495
                $this->addSimplePDFField($return, 'shadowMaxAge', _('Maximum password age'), 'shadowMax');
 
496
                return $return;
510
497
        }
511
498
 
512
499
        /**