From 220735007a2888e918244b1e2aadfbfbcb18cb4c Mon Sep 17 00:00:00 2001 From: Clinton Ebadi Date: Sat, 7 Feb 2015 16:03:05 -0500 Subject: [PATCH] sec: split normal user view into its own template --- sec.mlt | 116 ++----------------------------------------------- secnormal.mlt | 118 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 122 insertions(+), 112 deletions(-) create mode 100644 secnormal.mlt diff --git a/sec.mlt b/sec.mlt index e48049a..020c0f9 100644 --- a/sec.mlt +++ b/sec.mlt @@ -211,117 +211,9 @@ elseif $"mod" <> "" then <% end; -if showNormal then %> - - - - - - - - - - - - -
Machines:
Your users:
- - - -

Request change to your cron permissions

- -
- - - - - - - -
Allowed to use cron?
Reason:
-
- -<% val rules = Sec.findFirewallRules {node = nodeNum, uname = uname}; -switch rules of - _::_ => %> -

Your firewall rules

- -<% foreach rule in rules do %> -
- - - - -[Request deletion] - -

-<% end -end%> - -

Request a new firewall rule

- -

You can find a description of rule formats on our wiki. Enter here the rule you want, without the initial user portion. We also allow all members access to some services if they are commonly requested.

- -

When requesting a Server or ProxiedServer rule, use a port above 50000 (there is a list of allocated ports). We may grant Server requests for ports under 50000 if it can be justified, but never for a ProxiedServer.

- -

We very rarely grant requests for Client rules that don't include remote host whitelists. For example, important security concerns make it a bad idea for us to give anybody blanket IRC permissions. Instead, request specific servers. We will refuse such requests that include networks that are popularly considered fronts for illegal activity.

- -
- - - - - - - -
Rule
Reason:
-
- -<% end %> +if showNormal then + @secnormal [("uname", [uname]), + ("nodeNum", [Int.toString nodeNum])]; +end %> <% @footer[] %> \ No newline at end of file diff --git a/secnormal.mlt b/secnormal.mlt new file mode 100644 index 0000000..356c45b --- /dev/null +++ b/secnormal.mlt @@ -0,0 +1,118 @@ +<% +val uname = $"uname"; +val nodeNum = case $"nodeNum" of node => Web.stoi node; +val nodeName = Init.nodeName nodeNum; +val yourname = Init.getUserName (); + +val socks = Sec.socketPerms {node = nodeNum, uname = uname}; +val tpe = Sec.isTpe {node = nodeNum, uname = uname}; +val cron = Sec.cronAllowed {node = nodeNum, uname = uname}; +%> + + + + + + + + + + + +
Machines:
Your users:
+ + + +

Request change to your cron permissions

+ +
+ + + + + + + +
Allowed to use cron?
Reason:
+
+ +<% val rules = Sec.findFirewallRules {node = nodeNum, uname = uname}; +switch rules of + _::_ => %> +

Your firewall rules

+ +<% foreach rule in rules do %> +
+ + + + +[Request deletion] + +

+<% end +end%> + +

Request a new firewall rule

+ +

You can find a description of rule formats on our wiki. Enter here the rule you want, without the initial user portion. We also allow all members access to some services if they are commonly requested.

+ +

When requesting a Server or ProxiedServer rule, use a port above 50000 (there is a list of allocated ports). We may grant Server requests for ports under 50000 if it can be justified, but never for a ProxiedServer.

+ +

We very rarely grant requests for Client rules that don't include remote host whitelists. For example, important security concerns make it a bad idea for us to give anybody blanket IRC permissions. Instead, request specific servers. We will refuse such requests that include networks that are popularly considered fronts for illegal activity.

+ +
+ + + + + + + +
Rule
Reason:
+
-- 2.20.1