Enforce escaping on all template content
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
$(document).ready(function() {
|
||||
var table = $('#data-table').dataTable({
|
||||
"deferRender": true,
|
||||
"data": [% results %],
|
||||
"data": [% results | none %],
|
||||
"columns": [
|
||||
{
|
||||
"data": 'ip',
|
||||
@@ -25,7 +25,7 @@ $(document).ready(function() {
|
||||
"type": 'portsort',
|
||||
"render": function(data, type, row, meta) {
|
||||
return type === 'display' ?
|
||||
'<a href="[% device_ports %]&q=' + encodeURIComponent(row.ip) + '&f=' + encodeURIComponent(data) + '&c_duplex=on">' + he.encode(data || '') + '</a>' :
|
||||
'<a href="[% device_ports | none %]&q=' + encodeURIComponent(row.ip) + '&f=' + encodeURIComponent(data) + '&c_duplex=on">' + he.encode(data || '') + '</a>' :
|
||||
he.encode(data || '');
|
||||
}
|
||||
}, {
|
||||
|
||||
Reference in New Issue
Block a user