forked from ArtiomL/adct
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
75 lines (74 loc) · 2.95 KB
/
Copy pathindex.php
File metadata and controls
75 lines (74 loc) · 2.95 KB
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
74
75
<!--
adct - index.php
https://github.com/ArtiomL/adct
Artiom Lichtenstein
v3.0.1, 09/12/2017
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Real Server <?php echo substr(substr(strrchr($_SERVER["SERVER_ADDR"],'.'),1),-1); echo " " . $_SERVER["REQUEST_URI"]; ?></title>
<meta name="author" content="Artiom Lichtenstein">
<script language="JavaScript" type="text/javascript">
function funColExpand(obj, link) {
var elobj = document.getElementById(obj);
var elink = document.getElementById(link);
if ( (!elobj) || (!elink) ) return false;
if ( elobj.style.display === 'none' ) {
elobj.style.display = 'block';
elink.innerHTML = '<b>- Less Raw Data</b>';
}
else {
elobj.style.display = 'none';
elink.innerHTML = '<b>+ More Raw Data</b>';
}
}
</script>
<link href="css/fonts.css" rel="stylesheet" type="text/css">
<link href="css/skeleton.min.css" rel="stylesheet" type="text/css">
</head>
<body>
<div class="container">
<div class="docs-section" style="margin-top: 30px">
Hello <?php if (isset($_SERVER["PHP_AUTH_USER"])) { echo $_SERVER["PHP_AUTH_USER"]; } else { echo "World"; } ?>!<br>
ip.src: <?php echo $_SERVER["REMOTE_ADDR"]; ?><br>
tcp.srcport: <?php echo $_SERVER["REMOTE_PORT"]; ?><br>
ip.dst: <?php echo $_SERVER["SERVER_ADDR"]; ?><br>
tcp.dstport: <?php echo $_SERVER["SERVER_PORT"]; ?><br>
</div>
<div class="docs-section" style="margin-top: 30px; color:#ff0000;">
<?php echo $_SERVER["REQUEST_METHOD"] . " "; echo $_SERVER["REQUEST_URI"] . " "; echo $_SERVER["SERVER_PROTOCOL"] . "<br>";
$arrHeaders = apache_request_headers();
foreach ($arrHeaders as $header => $value)
echo "$header: $value <br />\n";
?>
</div>
<div class="docs-section" style="margin-top: 30px; color:#0000ff;">
<?php echo $_SERVER["SERVER_PROTOCOL"] . " 200 OK<br>";
echo "Server: " . $_SERVER["SERVER_SOFTWARE"] . "<br>";
flush();
$arrHeaders = apache_response_headers();
foreach ($arrHeaders as $header => $value)
echo "$header: $value <br />\n";
?>
<div style="cursor:hand; cursor:pointer; margin-top: 3%;" onClick="funColExpand('RawData','RawLink');" id="RawLink"><b>+ More Raw Data</b></div>
<div id="RawData" style="display:none">
<ol>
<?php
foreach($_SERVER as $header => $value)
echo "<li>$header = $value</li>\n";
?>
</ol>
</div>
</div>
<div class="docs-section" style="margin-top: 30px; float:right;">
Artiom Lichtenstein<br>Systems Engineer<br>F5 Networks<br><a href="https://artioml.net/" target="_blank">https://artioml.net</a>
<p style="margin-top: 10px;">
<a href="https://github.com/ArtiomL/adct" target="_blank"><img src="https://img.shields.io/maintenance/yes/2017.svg"></a>
<a href="https://hub.docker.com/r/artioml/adct/" target="_blank"><img src="https://img.shields.io/docker/pulls/artioml/adct.svg?label=docker"></a>
</p>
</div>
</div>
</body>
</html>