less restrictive input checks
This commit is contained in:
parent
659437af53
commit
0be3028c30
|
@ -451,9 +451,6 @@ function get_preg($argument, $regexp) {
|
||||||
case 'password':
|
case 'password':
|
||||||
$pregexpr = '/^([[:alnum:]\\ \\|\\#\\*\\,\\.\\;\\:\\_\\+\\!\\%\\&\\/\\?\\{\\(\\)\\}-])*$/u';
|
$pregexpr = '/^([[:alnum:]\\ \\|\\#\\*\\,\\.\\;\\:\\_\\+\\!\\%\\&\\/\\?\\{\\(\\)\\}-])*$/u';
|
||||||
break;
|
break;
|
||||||
case 'cn': // first character must be a letter. All letters, numbers, space and @._- are allowed characters
|
|
||||||
$pregexpr = '/^[[:alpha:]]([[:alnum:]@\\.\\ \\_-])*(\\$)?$/u';
|
|
||||||
break;
|
|
||||||
case 'groupname': // first character must be a letter. All letters, numbers, space and ._- are allowed characters
|
case 'groupname': // first character must be a letter. All letters, numbers, space and ._- are allowed characters
|
||||||
case 'username': // first character must be a letter. All letters, numbers, space and ._- are allowed characters
|
case 'username': // first character must be a letter. All letters, numbers, space and ._- are allowed characters
|
||||||
$pregexpr = '/^[[:alpha:]]([[:alnum:]\\.\\ \\_-])*$/u';
|
$pregexpr = '/^[[:alpha:]]([[:alnum:]\\.\\ \\_-])*$/u';
|
||||||
|
@ -466,6 +463,7 @@ function get_preg($argument, $regexp) {
|
||||||
$pregexpr = '/^[a-zA-Z]([a-zA-Z0-9\\.\\_-])*\\$$/u';
|
$pregexpr = '/^[a-zA-Z]([a-zA-Z0-9\\.\\_-])*\\$$/u';
|
||||||
break;
|
break;
|
||||||
case 'realname': // Allow all but \, <, >, =, $, ?
|
case 'realname': // Allow all but \, <, >, =, $, ?
|
||||||
|
case 'cn':
|
||||||
$pregexpr = '/^[^\\\<>=\\$\\?]+$/';
|
$pregexpr = '/^[^\\\<>=\\$\\?]+$/';
|
||||||
break;
|
break;
|
||||||
case "telephone": // Allow numbers, space, brackets, /-+.
|
case "telephone": // Allow numbers, space, brackets, /-+.
|
||||||
|
|
Loading…
Reference in New Issue