From 32e6d9992885a0f3b4175b3484f17ec4741a226f Mon Sep 17 00:00:00 2001 From: falti Date: Sat, 11 Feb 2017 16:14:32 +0100 Subject: [PATCH] Allow special characters in passwords --- docs/src/js/smoke.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/src/js/smoke.js b/docs/src/js/smoke.js index 9d33e54..bf1bd93 100755 --- a/docs/src/js/smoke.js +++ b/docs/src/js/smoke.js @@ -251,19 +251,19 @@ // Se obtiene el nivel de fuerza de la contraseña switch (smkStrongPass) { case ('weak'):// Debe contener al menos 4 caracteres - strongPassRegex = /^(?=.*[a-z0-9])\w{6,}$/; + strongPassRegex = /^(?=.*[a-z0-9])[\w\!%.,-]{6,}$/; textPass = languaje.textSPassWeak; break; case ('medium'):// Debe contener al menos 6 caracteres y un numero - strongPassRegex = /^(?=.*\d)(?=.*[a-z])\w{6,}$/; + strongPassRegex = /^(?=.*\d)(?=.*[a-z])[\w\!%.,-]{6,}$/; textPass = languaje.textSPassMedium; break; case ('strong'):// Debe contener al menos 6 caracteres, un numero y una mayúscula - strongPassRegex = /^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])\w{6,}$/; + strongPassRegex = /^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])[\w\!%.,-]{6,}$/; textPass = languaje.textSPassStrong; break; default:// Debe contener al menos 4 caracteres - strongPassRegex = /^(?=.*[a-z0-9])\w{4,}$/; + strongPassRegex = /^(?=.*[a-z0-9])[\w\!%.,-]{4,}$/; textPass = languaje.textSPassDefault; } // Se valida que el value del input cumpla con la expresión regular