return $str;
}
-$pages = Array("Overview" => "index.php",
- "Users" => "users/index.php",
- "Channels" => "channels/index.php",
+$pages = Array("Overview" => "",
+ "Users" => "users",
+ "Channels" => "channels",
"Server Bans" => "server_bans.php",
"Spamfilter" => "spamfilter.php",
+ "Network" => "network",
"News" => "news.php");
</tr><tr>
<th>Connected to</th>
<td colspan="2"><code><?php echo $user->user->servername; ?></code></td>
- <td></td>
+
</tr>
<tr>
<th>Logged in as</th>
?>
<tr>
<th>Oper</th>
- <td colspan="2">
+ <td>
<table class="table table-responsive caption-top table-hover">
<tr>
<td>Oper Login</td>
?>
<tr>
<th>Service Bot</th>
- <td colspan="2">
+ <td>
This user is a Services Bot.
</td>
</tr>
?>
<tr>
<th>Deaf</th>
- <td colspan="2">User is ignoring channel messages.</td>
+ <td>User is ignoring channel messages.</td>
</tr>
<?php
}
?>
<tr>
<th>Invisible</th>
- <td colspan="2">Not shown in /WHO searches.</td>
+ <td>Not shown in /WHO searches.</td>
</tr>
<?php
}
?>
<tr>
<th>Private channels</th>
- <td colspan="2">Channels hidden in /WHOIS outputs.</td>
+ <td>Channels hidden in /WHOIS outputs.</td>
</tr>
<?php
}
?>
<tr>
<th>Registered Nick</th>
- <td colspan="2">This user is using a registered nick.</td>
+ <td>This user is using a registered nick.</td>
</tr>
<?php
}
?>
<tr>
<th>Server Notices</th>
- <td colspan="2">This user is receiving server notices.</td>
+ <td>This user is receiving server notices.</td>
</tr>
<?php
}
?>
<tr>
<th>Virtual Host</th>
- <td colspan="2">Using a custom hostmask</td>
+ <td>Using a custom hostmask</td>
</tr>
<?php
}
?>
<tr>
<th>Wallops</th>
- <td colspan="2">Listening to <code>/WALLOPS</code> notices from IRC Operators.</td>
+ <td>Listening to <code>/WALLOPS</code> notices from IRC Operators.</td>
</tr>
<?php
}
?>
<tr>
<th>Hostmask</th>
- <td colspan="2">Using a hostmask (hiding their IP from non-IRCops).</td>
+ <td>Using a hostmask (hiding their IP from non-IRCops).</td>
</tr>
<?php
}
?>
<tr>
<th>Secure</th>
- <td colspan="2">
+ <td>
<table class="table table-responsive caption-top table-hover">
<tr>
<td>Cipher</td>
</tr>
<tr>
<td>Cert Fingerprint</td>
- <td><?php echo (isset($user->tls->certfp)) ? "<span class=\"badge-pill badge-info\">".$user->tls->certfp."</span>" : "<span class=\"badge-pill badge-info\">None</span>"; ?></td>
+ <td><?php echo (isset($user->tls->certfp)) ? "".$user->tls->certfp."" : "<span class=\"badge-pill badge-info\">None</span>"; ?></td>
</tr>
</table>
</td>
--- /dev/null
+<?php
+require_once "../common.php";
+require_once "../header.php";
+
+$title = "User Lookup";
+$nickname = "";
+$nick = NULL;
+if (isset($_GET['nick']))
+{
+ $nickname = $_GET['nick'];
+ $nick = $rpc->server()->get($nickname);
+ echo highlight_string("<?php ".var_export($nick, true));
+ if (!$nick)
+ {
+ Message::Fail("Could not find user: \"$nickname\"");
+ } else {
+ $nickname = $nick->name;
+ $title .= " for \"" . $nickname . "\"";
+ }
+}
+?>
+<title><?php echo $title; ?></title>
+<h4><?php echo $title; ?></h4>
+<br>
+<form method="get" action="details.php">
+<div class="input-group short-form-control justify-content-center align-items-center">
+ <input style="margin: 0%; height: 24px;" class="left-pan form-control" id="nick" name="nick" type="text" value=<?php echo $nickname; ?>>
+ <div class="input-group-append">
+ <br><button type="submit" class="btn btn-primary">Go</button>
+ </div>
+</div>
+</form>
+
+<?php if (!$nick)
+ return; ?>
+<br>
+<div class="row">
+ <div class="col-sm-3">
+ <div class="card">
+ <div class="card-body">
+ <h5 class="card-title">Basic Information</h5>
+ <p class="card-text"><?php generate_html_whois($nick); ?></p>
+ </div>
+ </div>
+ </div>
+ <div class="col-sm-4">
+ <div class="card">
+ <div class="card-body">
+ <h5 class="card-title">User Settings</h5>
+ <p class="card-text"><?php generate_html_usersettings($nick); ?></p>
+ </div>
+ </div>
+ </div>
+</div>
+<div class="row">
+ <div class="col-sm-3">
+ <div class="card">
+ <div class="card-body">
+ <h5 class="card-title">User Settings</h5>
+ <p class="card-text"><?php generate_html_usersettings($nick); ?></p>
+ </div>
+ </div>
+ </div>
+</div>
\ No newline at end of file
--- /dev/null
+<?php
+require_once "../common.php";
+require_once UPATH . "/header.php";
+
+if (!empty($_POST)) {
+ do_log($_POST);
+}
+
+/* Get the server list */
+$servers = $rpc->server()->getAll();
+?>
+<h4>Servers Overview</h4>
+
+Click on a server name to view more information.
+
+<div id="Servers">
+
+ <?php
+ if (isset($_POST['sf_name']) && strlen($_POST['sf_name']))
+ Message::Info("Listing servers which match name: \"" . $_POST['sf_name'] . "\"");
+
+ ?>
+ <table class="table table-responsive caption-top table-striped">
+ <thead>
+ <th scope="col"><h5>Filter:</h5></th>
+ <form action="" method="post">
+ <th scope="col" colspan="2">Name<input name="sf_name" type="text" class="form-control short-form-control">
+ <th scope="col"> <input class="btn btn-primary" type="submit" value="Search"></th></form>
+ </thead></table>
+
+ <table class="table table-responsive caption-top table-striped">
+ <thead class="table-primary">
+ <th scope="col"><input type="checkbox" label='selectall' onClick="toggle_server(this)" /></th>
+ <th scope="col">Name</th>
+ <th scope="col">Host / IP</th>
+ <th scope="col"><span data-toggle="tooltip" data-placement="bottom" title="This shows [Secure] if the server is using SSL/TLS or is on localhost." style="border-bottom: 1px dotted #000000">Secure</span></th>
+ <th scope="col">Connected to</th>
+ </thead>
+
+ <tbody>
+ <form method="post">
+ <?php
+
+ foreach($servers as $server)
+ {
+
+
+ /* Some basic filtering for NAME */
+ if (isset($_POST['sf_name']) && strlen($_POST['sf_name']) &&
+ strpos(strtolower($server->name), strtolower($_POST['sf_name'])) !== 0 &&
+ strpos(strtolower($server->name), strtolower($_POST['sf_name'])) == false)
+ continue;
+
+
+ echo "<tr>";
+ echo "<th scope=\"row\"><input type=\"checkbox\" value='" . base64_encode($server->id)."' name=\"serverch[]\"></th>";
+ $isBot = (strpos($server->server->modes, "B") !== false) ? ' <span class="badge-pill badge-dark">Bot</span>' : "";
+ echo "<td><a href=\"details.php?nick=".$server->id."\">$server->name$isBot</a></td>";
+ echo "<td>".$server->hostname." (".$server->ip.")</td>";
+ $secure = (isset($server->tls)) ? "<span class=\"badge-pill badge-success\">Secure</span>" : "<span class=\"badge-pill badge-danger\">Insecure</span>";
+ if (strpos($server->server->modes, "S") !== false)
+ $secure = "";
+ echo "<td>".$secure."</td>";
+ echo "<td>".$server->server->uplink."</td>";
+ }
+ ?>
+ </tbody></table>
+</div>
+
+<?php require_once UPATH.'/footer.php'; ?>