[Koha-devel] Huge performance issue cause by bug 13618 (XSS)

Mark Tompsett mtompset at hotmail.com
Thu Feb 11 05:07:31 CET 2016


Greetings,

Jonathan Druart wrote:
> Indeed, for each variable displayed in the template, a
> Template::Stash::AutoEscaping->get method is called.
...
> and then, in the template
> +[% FOR l IN loop %]
> +    [% l.foo %] [% l.bar %]
> +    <br/>
> +[% END %]
>
> It will display 10k foo and 10k bar
> There are indeed 20k (+ delta) calls to the
> Template::Stash::AutoEscaping method, as expected.
> But the load of the page increases from 2sec to 10sec (no plack,
> measured with Firebug > network tab)

It isn't brilliant, if it does work, because that's a lot of editing, but I 
was noticing people starting to use ".raw". Does a .raw have a large impact?
+[% FOR l IN loop %]
+    [% l.foo.raw %] [% l.bar.raw %]
+    <br/>
+[% END %]

If it increased from 2s to 3s with .raw, that wouldn’t be so bad. I'm just 
brainstorming.

GPML,
Mark Tompsett 



More information about the Koha-devel mailing list