From 2a737c480d632eb54c1131654e12f638a1476978 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Thu, 15 Jan 2009 21:44:39 +0000 Subject: Modified html.lua and viewlibrary.lua and all html files to html_escape variables before displaying them. git-svn-id: svn://svn.alpinelinux.org/acf/snort/trunk@1678 ab2d0c66-481e-0410-8bed-d214d4d58bed --- snort-details-html.lsp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/snort-details-html.lsp b/snort-details-html.lsp index 6c4091f..ab6024d 100644 --- a/snort-details-html.lsp +++ b/snort-details-html.lsp @@ -11,26 +11,26 @@ io.write("") <% viewlibrary.dispatch_component("status") %> -

<%= data.label %>

+

<%= html.html_escape(data.label) %>

<% if #data.value == 0 then io.write("No alerts found") else for i,priority in ipairs(data.value) do %> -

<%= priority.name %>

+

<%= html.html_escape(priority.name) %>

<% for cls in pairs(priority.value) do %> -

<%= cls %>

+

<%= html.html_escape(cls) %>

<% for id,alert in pairs(priority.value[cls]) do %> -

<%= alert.value[1] %>
+

<%= html.html_escape(alert.value[1]) %>
<% for j=2, table.maxn(alert.value) do %> - <%= alert.value[j] %>
+ <%= html.html_escape(alert.value[j]) %>
<% end %> - (This alarm is repeated <%= alert.count %> times) + (This alarm is repeated <%= html.html_escape(alert.count) %> times) <% if (table.maxn(alert.url) ~= 0) then %> ( URL's: <% for k,url in ipairs(alert.url) do %> - <%= url %> + <%= html.html_escape(url) %> <% end %> ) <% end %> -- cgit v1.2.3