Skip to content
Snippets Groups Projects
Commit b28c39db authored by Till Brehm's avatar Till Brehm
Browse files

Merge branch 'branch-3-2-11-p1' into 'develop'

Fixes #6596 improve language file editor input validation

Closes #6596

See merge request ispconfig/ispconfig3!1821
parents 79db22f9 1d027303
No related branches found
No related tags found
1 merge request!1821Fixes #6596 improve language file editor input validation
Pipeline #13955 passed
......@@ -64,6 +64,7 @@ if(isset($_POST['records']) && is_array($_POST['records'])) {
$val = stripslashes($val);
$val = preg_replace('/(^|[^\\\\])((\\\\\\\\)*)"/', '$1$2\\"', $val);
$val = str_replace('$', '', $val);
if(!preg_match("/^[a-z0-9_]+$/", $key)) die('Invalid language file key.');
$file_content .= '$wb['."'$key'".'] = "'.$val.'";'."\n";
$msg = 'File saved.';
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment