blob: 90e20fccdafd8583e1b7c6532c75f1913a819c3d (
plain) (
blame)
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
@model Project_Unite.Models.ModeratorBanListViewModel
@{
ViewBag.Moderator = true;
ViewBag.Title = "Bans";
}
<h2>Bans</h2>
<ul id="tabs" data-tabs="tabs" class="nav nav-tabs" role="tablist">
<li class="active"><a data-toggle="tab" href="#t_users">User bans</a></li>
<li><a data-toggle="tab" href="#t_ips">IP bans</a></li>
</ul>
<div class="tab-content">
<div class="tab-pane fade in active" id="t_users">
<h4>User bans</h4>
<p>Below is a list of all user bans. User bans prevent users from logging into their accounts.</p>
<table class="table">
<tr>
<th style="width:50%">User</th>
<th>Banner</th>
<th>Timestamp</th>
<th>Actions</th>
</tr>
@foreach(var u in Model.UserBans.OrderByDescending(x=>x.BannedAt))
{
<tr>
<td>@Html.UserLink(u.Id)</td>
<td>@Html.UserLink(u.BannedBy)</td>
<td>@u.BannedAt</td>
<td>
@if(ACL.Granted(User.Identity.Name, "CanIssueBan"))
{
if(ACL.CanManageRole(User.Identity.Name, u.HighestRole.Id))
{
@Html.ActionLink("Unban", "Unban", "Moderator", new { id=u.Id}, new { @class="btn btn-default"})
}
}
</td>
</tr>
}
</table>
</div>
<div class="tab-pane fade in" id="t_ips">
<h4>IP address bans</h4>
<p>Below is a list of IP address bans on the site. IP bans prevent users with a certain IP address from even attempting to access the website and multi-user domain by sending back "Forbidden" responses and denying connection.</p>
<h5>BE EXTREMELY CAUTIOUS.</h5>
<p>The system does NOT associate IP addresses with usernames - it can't. If you are unsure who's IP address you are unbanning, contact someone who is sure before taking any action. We have no idea what that computer or network is capable of.</p>
<table class="table">
<tr>
<th style="width:50%">User</th>
<th>Banner</th>
<th>Timestamp</th>
<th>Actions</th>
</tr>
@foreach (var u in Model.IPBans)
{
<tr>
<td>@u.Address</td>
<td>
@if (ACL.Granted(User.Identity.Name, "CanIssueIPBan"))
{
@Html.ActionLink("Unban", "UnbanIP", "Moderator", new { id = u.Id }, new { @class = "btn btn-danger" })
}
</td>
</tr>
}
</table>
</div>
</div>
|