When to encode as HTML in Grails -


i see grails sample code programmer has called method called encodeashtml(). figure should use in grails applications (for security reasons, assume?), wondering when should use method. objects/properties/etc. candidates encodeashtml() method?

thank you!

use encodeashtml() (or encodeasjavascript, etc) you've got user. every string modified user (got input form, request parameter, external api call, etc)

see also:


Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -