summaryrefslogtreecommitdiffstats
path: root/iptables-editrule-html.lsp
blob: 42f64df96ee7c880daf13df5cc324c7ad593fb6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<% local form, viewlibrary, page_info = ... 
htmlviewfunctions = require("htmlviewfunctions")
html = require("acf.html")
%>

<h1><%= html.html_escape(form.label) %></h1>
<% 
for name,val in pairs(form.value) do val.name = name end
form.value.table.readonly = true
form.value.table.type = "text"
form.value.chain.readonly = true
form.value.position.readonly = true
form.action = page_info.script .. page_info.prefix .. page_info.controller .. "/" .. page_info.action
htmlviewfunctions.displayformstart(form)
%>

<h2>Rule Identification</h2>
<% 
htmlviewfunctions.displayformitem(form.value.table)
htmlviewfunctions.displayformitem(form.value.chain)
htmlviewfunctions.displayformitem(form.value.position)
%>
<h2>Basic Parameters</h2>
<% 
htmlviewfunctions.displayformitem(form.value.jump)
htmlviewfunctions.displayformitem(form.value.protocol)
htmlviewfunctions.displayformitem(form.value.in_interface)
htmlviewfunctions.displayformitem(form.value.out_interface)
htmlviewfunctions.displayformitem(form.value.source)
htmlviewfunctions.displayformitem(form.value.destination)
htmlviewfunctions.displayformitem(form.value.goto)
htmlviewfunctions.displayformitem(form.value.fragment)
htmlviewfunctions.displayformitem(form.value.set_counters)
%>
<h2>Extended Parameters</h2>
<% 
htmlviewfunctions.displayformitem(form.value.comment)
htmlviewfunctions.displayformitem(form.value.addrtype_src_type)
htmlviewfunctions.displayformitem(form.value.addrtype_dst_type)
htmlviewfunctions.displayformitem(form.value.icmp_type)
htmlviewfunctions.displayformitem(form.value.src_range)
htmlviewfunctions.displayformitem(form.value.dst_range)
htmlviewfunctions.displayformitem(form.value.mac_source)
htmlviewfunctions.displayformitem(form.value.sports)
htmlviewfunctions.displayformitem(form.value.dports)
htmlviewfunctions.displayformitem(form.value.ports)
htmlviewfunctions.displayformitem(form.value.state)
htmlviewfunctions.displayformitem(form.value.tcp_sport)
htmlviewfunctions.displayformitem(form.value.tcp_dport)
htmlviewfunctions.displayformitem(form.value.udp_sport)
htmlviewfunctions.displayformitem(form.value.udp_dport)
%>
<h2><%= html.html_escape(form.option) %></h2>
<% htmlviewfunctions.displayformend(form) %>