46 public $picto =
'generic';
53 public $WithoutAmbi = 0;
112 return $langs->trans(
"NoDescription");
123 $langs->load(
"bills");
124 return $langs->trans(
"NoExample");
135 return $langs->trans(
"NotAvailable");
172 $classname =
'modGeneratePass'.ucfirst($id);
174 $dirmodels = array_merge(array(
'/'), (array) $conf->modules_parts[
'models']);
175 foreach ($dirmodels as $reldir) {
176 $file =
dol_buildpath($reldir.
'core/modules/security/generate/').$classname.
'.class.php';
177 if (is_file($file)) {
179 if (class_exists($classname)) {
180 return new $classname($db, $conf, $langs, $user);
Parent class for password rules/management modules.
getDescription()
Return description of module.
static loadAndInstantiate($id, $db, $conf, $langs, $user)
Locate, load and instantiate a password generator/validator model by its id (the value stored in USER...
isEnabled()
Return if a module can be used or not.
validatePassword($password)
Validate a password.
getExample()
Return an example of password generated by this module.
getNewGeneratedPassword()
Build new password.
dol_buildpath($path, $type=0, $returnemptyifnotfound=0)
Return path of url or filesystem.