Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Allow enforcement of password complexity rules in the admin.

 - Validate password with regex if mod_admin_identity.password_regex present
 - Allow configuration with Admin interface Config section

Thanks to Alain O' Dea.
  • Loading branch information...
commit 40a1b8beff3027a83770cc08d58398bdfdf06da5 1 parent 760fef9
@arjan arjan authored
View
1  CONTRIBUTORS
@@ -5,6 +5,7 @@
# lists people. For example, Google employees are listed here
# but not in AUTHORS, because Google holds the copyright.
+Alain O'Dea <alain.odea@gmail.com>
Arjan Scherpenisse <arjan@scherpenisse.net>
Daniel Hedlund <daniel@digitree.org>
Dmitrii Dimandt <dmitriid@gmail.com>
View
6 modules/mod_admin_identity/templates/_action_dialog_set_username_password.tpl
@@ -21,7 +21,11 @@
<p>
<label for="new_password" style="color:white">{_ Password _}</label>
<input type="text" id="new_password" name="new_password" value="{{ password|escape }}" />
- {% validate id="new_password" type={presence} %}
+ {% if m.config.mod_admin_identity.password_regex.value %}
+ {% validate id="new_password" type={presence} type={format pattern=m.config.mod_admin_identity.password_regex.value} %}
+ {% else %}
+ {% validate id="new_password" type={presence} %}
+ {% endif %}
</p>
<button type="submit">{_ Save _}</button>
Please sign in to comment.
Something went wrong with that request. Please try again.