mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-05 10:54:27 +02:00
- bugfix removed security hole when using {$smarty.template}
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
===== SVN trunk =====
|
||||
09/02/2011
|
||||
- bugfix removed security hole when using {$smarty.template}
|
||||
|
||||
01/02/2011
|
||||
- removed assert() from config and template parser
|
||||
|
||||
|
@@ -56,12 +56,10 @@ class Smarty_Internal_Compile_Private_Special_Variable extends Smarty_Internal_C
|
||||
break;
|
||||
|
||||
case 'template':
|
||||
$_template_name = basename($compiler->template->getTemplateFilepath());
|
||||
return "'$_template_name'";
|
||||
return 'basename($_smarty_tpl->getTemplateFilepath())';
|
||||
|
||||
case 'current_dir':
|
||||
$_template_dir_name = dirname($compiler->template->getTemplateFilepath());
|
||||
return "'$_template_dir_name'";
|
||||
return 'dirname($_smarty_tpl->getTemplateFilepath())';
|
||||
|
||||
case 'version':
|
||||
$_version = Smarty::SMARTY_VERSION;
|
||||
|
Reference in New Issue
Block a user