You are an unregistered user, you can register here
Navigation

Information

Site

Donations
If you wish to make a donation you can by clicking the image below.


 
Go Back   The Unreal Admins Page > Forums > Hosted Forums > UTDC > General Chat

Reply
Thread Tools Display Modes
  #1  
Unread 28th December, 2007, 12:27 AM
[SwS]Next [SwS]Next is offline
Unstoppable
 
Join Date: Nov 2007
Posts: 219
Exclamation How Do You View UTDC Screen Shots From Using ASC

I am using ASC and I took a UTDC screen shot but how do I open it.

The file is in the logs folder and is a .ENC file. No clue on how to open it, please help!
__________________
CLICK EITHER OF MY SIGS TO DONATE!

Reply With Quote
  #2  
Unread 28th December, 2007, 01:17 AM
Baiter's Avatar
Baiter Baiter is offline
Holy Shit!!
 
Join Date: Apr 2004
Location: Houston, TX
Posts: 1,566
Default

Use the Picture Decode that comes in the UTDC download.
__________________
-={SDA}=-Baiter | Maker of Sniper's Heaven
Clan SDA | UT Server Baiter Edition | Play Sniper's Heaven!!! | SDA Gaming Servers
Reply With Quote
  #3  
Unread 28th December, 2007, 07:38 AM
[SwS]Next [SwS]Next is offline
Unstoppable
 
Join Date: Nov 2007
Posts: 219
Default

Thanks!
__________________
CLICK EITHER OF MY SIGS TO DONATE!

Reply With Quote
  #4  
Unread 28th December, 2007, 03:29 PM
g0sbv g0sbv is offline
Rampage
 
Join Date: Mar 2006
Posts: 99
Default

I got this script somewhere on this forum works excellent to view scrennies as soon as I have taken them..just created a dir on your server of forum that you web access to and chaneg the line bellow to inc you login info and the path to the server screen shots normaly logs and then you can access it from your browser to view screenshots that are encoded..





<?
/****
* a very simplistic attempt to enable you (and other people) http access to remote
* screenshots created by UTDCv17 via your webserver and/or your server on which the
* Unreal Tournament (tm, i guess) server software is running. this script can safely be used on publicly
* available web pages that do not require user authorization (i.e. if set up correctly,
* this script pretty safe to employ).
* however, if it is a well-frequented website, then your server might be annoyed
* by the huge number of FTP connections that this script establishes.
*
* IMPORTANT NOTE: compatibility with future versions of UTDC is uncertain.
* apparently UTDCv18 works fine, though.
*
* [begin deprecated gibberish]
* this script is meant to be installed on a server which has access to a directory
* in which UTDC's .enc files are stored. this can be access through the local filesystem, or access via FTP.
*
* by default most webservers DO NOT allow PHP scripts to access directories which are beyond
* the "web root" directory (open_basedir restriction). you can disable this setting, but i certainly do not
* suggest doing so. on the one hand this script can be considered rather safe (my own judgement), but
* by disabling the open_basedir restriction you also lower the security precautions for all other scripts
* that might be running on your webserver.
*
* as a solution i suggest a cronjob which copies the files from the gameserver's Log directory
* into a directory that is accessible for the webserver. another secure solution might be using a *local*
* FTP connection to access the files.
* [/end deprecated gibberish]
*
* setting up the configuration via FTPS:
*
* simply specify a valid FTPS address in the $logdir config variable. valid FTPS addresses have the following format:
* ftps://user:password@hostname:port/directory
* example:
* ftps://utserver:[email protected]:21/Logs
* if you omit ":port", then it will default to ":21", which is, as you might have guessed, the default ftp port.
* be careful, though. whenever someone is browsing the screenshots, the files are being re-requested from
* the FTP server (i.e. with every pageview at least one FTP(s) connection is being established),
* which might result in a long loading time. see below for more details.
*
* sidenote: even if your server is a windows box: do NOT use "\" as the folder delimiter, but use "/"
* instead.
* For example: "ftps://utserver:[email protected]:21\Program Files\ut\Logs\"
* is _WRONG_ !
*
* distribution of this script:
* feel free to use and distribute it. also feel free to use parts of this script in your own projects.
* the picture-decoding-algorithm is extremely simple, and if you are an experienced administrator, then
* you will probably be able to write your own implementation, in case you need to.
* however, charging money for anything that is related to this script is pretty awkward.
* if you nevertheless intend to do so, drop me a line, and i will probably grant permission.
*
* responsibility: you cant hold me responsible for anything that this script is causing you. if
* it makes you happy, then im glad. if it makes you sad, then i probably can't help it.
* if you need further advice on using this script, then i might supply you with the same
* if you post your inqiries at:
*
* http://www.unrealadmin.org/forums/sh...ad.php?t=11759
*
* @author Tim 'tsr' Rietmann < tsr at the-truth.de >
* @copyright see author and comments.
*/


/*
* configuration begins here
*/


/*
* $logdir contains the location under which the .enc screenshot files are available.
* there are various formats (http / https / ftp / ftps / ssh2 / direct file access / ...) supported. however,
* not all versions of PHP support all formats. check out http://php.net/manual/en/wrappers.php
* for more information. if you are in doubt, then i am urging you to use to the "ftps://"
* format for a fair deal of security, because this option is secure in all possible
* environments. the example below is using this very format.
*
* do neither remove the quotation marks, nor the tailing semicolon from the line(s)
* to follow!
* YOU ONLY NEED TO EDIT THE CFG LINE BELLOW THATS ALL
*/


$logdir = "ftp://yoururlogin:[email protected] t:21/Logs/";
























/*
* configuration ends here (wasnt much, was it?)
* if you modify any of the lines to follow, you risk fucking up everything. if you still consider
* it a necessity to edit text beyond this paragraph, then you probably know
* what you're doing, so errr, you probably know what you are doing. do it on your
* own risk, though.
*/


if (substr($logdir, strlen($logdir)-1) != "/") // add tailing slash
$logdir .= "/";


/***
* scans a directory and returns its contents as an array
*
* @param string $strPath directory to scan
* @param string $strExtension filter out all files that don't have this extension
* @return array list of files
*/

function getDir($strPath, $strExtension = null)
{
$resDir = @opendir($strPath);
if (!is_resource($resDir))
return null;

$arrReturn = array();

for ($strFile = @readdir($resDir); $strFile !== false; $strFile = @readdir($resDir))
{
if ($strExtension != null)
{
$strCurrentExt = substr($strFile, strlen($strFile) - strlen($strExtension));
if (strtolower($strExtension) != strtolower($strCurrentExt))
continue;
}

$arrResult[] = $strFile;
}
@closedir($resDir);

return $arrResult;
}

/***
* reads the contents of a screenshot file created with UTDCv17
* and returns its decoded content as a string.
* @param string $strFileName encoded screenshot file
* @return string binary contents of the source file
*/

function readUTDCPic($strFileName)
{

$resSource = @fopen($strFileName, r); // open source
// ^ PHP usually strips all login information from error messages, but its still better to suppress errors. you never know.

if (!$resSource)
return null;

$strContent = "";
while(is_resource($resSource))
{
$strContent .= fread($resSource,1); // read one byte
if (feof($resSource))
break;

fseek($resSource, 1, SEEK_CUR); // skip one byte
if (feof($resSource))
break;
}
@closedir($resSource);

return @base64_decode($strContent);
}


/***
* callback function for usort() that lets us sort the file list according to their "last modified" attribute
* this function is not generic, since it relies on $logdir
*/
function compareScreenie($strA, $strB)
{
global $logdir;
return $logdir.$strA < $logdir.$strB;
// filemtime() is not supported by ftp(s) wrappers. so lets not use it anymore; its causing
// an unnecessary amount of FTP connections, anyways.
// return @filemtime($logdir.$strA) < @filemtime($logdir.$strB);
}



/******************
* program begin *
******************/


// get a list of .enc files
$arrFiles = getDir($logdir, ".enc");

if (!is_array($arrFiles))
die ("either there are no files to display, or the admin of this page did not configure the logdir variable correctly.");

usort ($arrFiles, compareScreenie); // sort file list


// if the user wants to view a file, display it and exit.
$strRequest = get_magic_quotes_gpc() == 1 ? stripslashes($_GET['file']) : $_GET['file'];
if ($strRequest != "")
{
// check if the requested file really exists.
// i dont know how Troublesome deals with metacharacters within player's ingame names.
// to be on the safe side, lets filter out all slashes and double-check if the requested file is one
// of the files that our getDir function returned.

if (strpos($strRequest, "/") !== false || strpos($strRequest, "\\") !== false)
die("fuck off. <br \>the action you have just performed has been considered to be an attempt to hack this website. <br \> if you seriously did not intend to harm this website, please contact the administrator and tell him/her that his UTDC screenshot script gave you this error. thanks.");

if (!in_array($strRequest, $arrFiles, true))
die("the requested file does not exist.");

// thanks to "dark coder" for the fix of the following line. i fixed it a long time ago, but i forgot to make the fix public. sorry ! >:|
$binPic = readUTDCPic($logdir.$strRequest);
if ($binPic == null)
die("there seems to be an error in the configuration. <br \> please make sure the logdir config variable contains a valid URL.");
header("content-type: image/jpeg");
header('Content-Disposition: filename="'.$strRequest.'.jpg"');

echo $binPic;
exit;
}


// no file requested ? lets display the list.

?>

<html>
<head>
<style>
<!--
body
{
font-size: 8pt;
background-color: #FFFFFF;
color:gray;
text-align: left;
}
a
{
color:white;
color:gray;
text-decoration:none;
}

a:hover
{
color: #000000;
}
-->
</style>

<body>
<?

$me = basename($_SERVER['PHP_SELF']);
foreach ($arrFiles as $strFile)
{
echo '<a href="'.$me.'?file='.urlencode($strFile).'">'.html entities($strFile).'</a> <br />'."\n";
}

?>

</body>
</html>

Last edited by g0sbv : 28th December, 2007 at 03:33 PM.
Reply With Quote
  #5  
Unread 29th December, 2007, 04:43 AM
[SwS]Next [SwS]Next is offline
Unstoppable
 
Join Date: Nov 2007
Posts: 219
Default

ya........... LOL

I would rather just use the verified converter, LOL
__________________
CLICK EITHER OF MY SIGS TO DONATE!

Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 02:03 PM.


 

All pages are copyright The Unreal Admins Page.
You may not copy any pages without our express permission.