Revert "fix(security): Make jinja rendering tighter"
This reverts commit d70d2c5a29.
This commit is contained in:
parent
ae76b7cec1
commit
bc7b0319ea
1 changed files with 1 additions and 1 deletions
|
|
@ -71,7 +71,7 @@ def render_template(template, context, is_path=None, safe_render=True):
|
|||
or (template.endswith('.html') and '\n' not in template)):
|
||||
return get_jenv().get_template(template).render(context)
|
||||
else:
|
||||
if safe_render and "__" in template:
|
||||
if safe_render and ".__" in template:
|
||||
throw("Illegal template")
|
||||
try:
|
||||
return get_jenv().from_string(template).render(context)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue