mirror of
https://github.com/PrivateBin/PrivateBin.git
synced 2026-03-05 13:30:32 -05:00
prevent use of paths in template names, only file names inside tpl directory are allowed
This commit is contained in:
@@ -66,7 +66,7 @@ class View
|
||||
*/
|
||||
public static function getTemplateFilePath(string $template): string
|
||||
{
|
||||
$file = self::isBootstrapTemplate($template) ? 'bootstrap' : $template;
|
||||
$file = self::isBootstrapTemplate($template) ? 'bootstrap' : basename($template);
|
||||
return PATH . 'tpl' . DIRECTORY_SEPARATOR . $file . '.php';
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user