|
Menu |
|
|
Home |
| |
|
Discussions |
| |
|
Tools |
| |
|
Affiliates |
| |
|
Content |
| |
|
Info |
| | |
|
|
|
|
|
User Info |
|
Membership:
Latest: MichaelSnaRe
New Today: 0
New Yesterday: 0
Overall: 9144
People Online:
Visitors: 58
Members: 0
Total: 58
|
|
|
|
|
|
Full disclosure |
|
|
|
|
|
|
|
|
|
IT Security and Insecurity Portal |
|
|
Please help me decode this script |
|
Posted: Sat Mar 14, 2009 8:17 pm |
|
|
manokal |
Beginner |
|
|
Joined: Mar 14, 2009 |
Posts: 1 |
|
|
|
|
|
|
|
<?php // This file is protected by copyright law and provided under license. Reverse engineering of this file is strictly prohibited.
$OOO0O0O00=__FILE__;$OOO000000=urldecode('%61%68%36%73%62%65%68%71%6c%61%34%63%6f%5f%73%61%64');$OO00O0000=17764;$OOO0000O0=$OOO000000{4}.$OOO000000{9}.$OOO000000{3}.$OOO000000{5};$OOO0000O0.=$OOO000000{2}.$OOO000000{10}.$OOO000000{13}.$OOO000000{16};$OOO0000O0.=$OOO0000O0{3}.$OOO000000{11}.$OOO000000{12}.$OOO0000O0{7}.$OOO000000{5};$O0O0000O0='OOO0000O0';eval(($$O0O0000O0('aWYoITApJE8wMDBPME8wMD1mb3BlbigkT09PME8wTzAwLCdyYicpO2ZnZXRzKCRPMDAwTzBPMDAsMTAyNCk7ZmdldHMoJE8wMDBPME8wMCw0MDk2KTskT08wME8wME8wPShiYXNlNjRfZGVjb2RlKHN0cnRyKGZyZWFkKCRPMDAwTzBPMDAsOTI0KSwnVWpMb0g4ckpndS96VmxCa0ZJaW5aY2RwU3c2NHN2T05NUVRDUDlxRDFBeDJhNUVHV2Z0bUtleTArYmhYUlk3Mz0nLCdBQkNERUZHSElKS0xNTk9QUVJTVFVWV1hZWmFiY2RlZmdoaWprbG1ub3BxcnN0dXZ3eHl6MDEyMzQ1Njc4OSsvJykpKTtldmFsKCRPTzAwTzAwTzApOw==')));return;?>
vyQA4rZ1/LQAs0l9vLMPi8IZ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DpiPXoFAA4d8DwdI9s0It40P1u8YnZPl4uy95Sdv9ueKABWK/gtVCg8u9vJct4MK/sqcKvpuEgLItwpIesqb9sCalLDKlLM== |
|
|
|
|
|
|
|
|
Posted: Sat Mar 14, 2009 11:15 pm |
|
|
zerobytes |
Valuable expert |
|
|
Joined: Aug 30, 2008 |
Posts: 199 |
|
|
|
|
|
|
|
Code: |
ini_set("memory_limit","64M");
if (!defined('XCART_START')) {header("Location: ../../../");die("Access denied");}
function smarty_function_thumb($params,&$smarty)
{
if (!function_exists('UnsharpMask'))
{
function UnsharpMask($img,$amount,$radius,$threshold)
{
if ($amount >500) $amount = 500;
$amount = $amount * 0.016;
if ($radius >50) $radius = 50;
$radius = $radius * 2;
if ($threshold >255) $threshold = 255;
$radius = abs(round($radius));
if ($radius == 0) {return $img;imagedestroy($img);break;}
$w = imagesx($img);$h = imagesy($img);
$imgCanvas = $img;
$imgCanvas2 = $img;
$imgBlur = imagecreatetruecolor($w,$h);
for ($i = 0;$i <$radius;$i++)
{
imagecopy ($imgBlur,$imgCanvas,0,0,1,1,$w -1,$h -1);
imagecopymerge ($imgBlur,$imgCanvas,1,1,0,0,$w,$h,50);
imagecopymerge ($imgBlur,$imgCanvas,0,1,1,0,$w -1,$h,33.33333);
imagecopymerge ($imgBlur,$imgCanvas,1,0,0,1,$w,$h -1,25);
imagecopymerge ($imgBlur,$imgCanvas,0,0,1,0,$w -1,$h,33.33333);
imagecopymerge ($imgBlur,$imgCanvas,1,0,0,0,$w,$h,25);
imagecopymerge ($imgBlur,$imgCanvas,0,0,0,1,$w,$h -1,20 );
imagecopymerge ($imgBlur,$imgCanvas,0,1,0,0,$w,$h,16.666667);
imagecopymerge ($imgBlur,$imgCanvas,0,0,0,0,$w,$h,50);
}
$imgCanvas = $imgBlur;
for ($x = 0;$x <$w;$x++)
{
for ($y = 0;$y <$h;$y++)
{
$rgbOrig = ImageColorAt($imgCanvas2,$x,$y);
$rOrig = (($rgbOrig >>16) &0xFF);
$gOrig = (($rgbOrig >>8) &0xFF);
$bOrig = ($rgbOrig &0xFF);
$rgbBlur = ImageColorAt($imgCanvas,$x,$y);
$rBlur = (($rgbBlur >>16) &0xFF);
$gBlur = (($rgbBlur >>8) &0xFF);
$bBlur = ($rgbBlur &0xFF);
$rNew = (abs($rOrig -$rBlur) >= $threshold) ?max(0,min(255,($amount * ($rOrig -$rBlur)) +$rOrig)) : $rOrig;
$gNew = (abs($gOrig -$gBlur) >= $threshold) ?max(0,min(255,($amount * ($gOrig -$gBlur)) +$gOrig)) : $gOrig;
$bNew = (abs($bOrig -$bBlur) >= $threshold) ?max(0,min(255,($amount * ($bOrig -$bBlur)) +$bOrig)) : $bOrig;
if (($rOrig != $rNew) ||($gOrig != $gNew) ||($bOrig != $bNew))
{
$pixCol = ImageColorAllocate($img,$rNew,$gNew,$bNew);
ImageSetPixel($img,$x,$y,$pixCol);
}
}
}
return $img;
}
}
if (!function_exists('Watermark'))
{
function Watermark($source,$width,$height,$font,$text,$factor,$_FONTSIZE=20,$type,$trans,$loc){
if ($factor!=""){
$rel=0;
while($rel <$factor){
$size = imageTTFBBox($fontsize,0,$font,$text);
$rel=(abs($size[2])*100/$width);
$fontsize++;
}
if ($fontsize!=1) $fontsize--;
}else{
$fontsize=$_FONTSIZE;
$size = imageTTFBBox($fontsize,0,$font,$text);
}
$pos[x1]=$width-abs($size[2]+8);
if ($loc=='T') $pos[y1]=abs($size[7]-8);
elseif ($loc=='M') $pos[y1]=($height-abs($size[3]+8))/2;
else $pos[y1]=$height-abs($size[3]+8);
$pos[x2]=$width-3;
$pos[y2]=$height-3;
$white_trans = imagecolorallocatealpha($source,255,255,255,$trans);
$black_trans = imagecolorallocatealpha($source,0,0,0,($trans+20));
imagealphablending($source,true);
imagefttext($source,$fontsize,0,$pos[x1]+2,$pos[y1]+2,$black_trans,$font,$text);
imagefttext($source,$fontsize,0,$pos[x1],$pos[y1],$white_trans,$font,$text);
return $source;
imagedestroy( $source );
}
}
### Set Variables
global $config;
global $xcart_web_dir;
global $xcart_dir;
global $http_location;
global $https_location;
### Set Server Vars
$server_vars = isset($_SERVER) ?$_SERVER : $GLOBALS['HTTP_SERVER_VARS'];
### Read Config Variables From X-Cart
$params['text'] = "© ".$config['Company']['company_name'];
$params['upscale']=$config['Dynamic_Images']['di_upscale'];
$params['quality']=$config['Dynamic_Images']['di_quality'];
$params['sharpen']=$config['Dynamic_Images']['di_sharpen'];
$params['watermark']=$config['Dynamic_Images']['di_watermark'];
$params['prefix']=$config['Dynamic_Images']['di_keyword'];
$params['font']=$config['Dynamic_Images']['di_font'];
$params['trans']=$config['Dynamic_Images']['di_trans'];
$params['watermark_loc']=$config['Dynamic_Images']['di_watermark_loc'];
### Set Image Types
$_CONFIG['types'] = array('','.gif','.jpg','.png');
### Configure Cache Directory
if (empty($params['cache'])) {
$_CONFIG['cache'] = $xcart_dir."/images/cache/";
$_CONFIG['outpath'] = $xcart_dir."/images/cache/";
$_CONFIG['webpath'] = $xcart_web_dir."/images/cache/";
}else {
$_CONFIG['cache'] = $params['cache'];
}
### Configure Image URL -Location
$string = array($http_location,$https_location);
$healthy = array("%20","%5B","%5D");
$yummy = array(" ","[","]");
$params['file'] = str_replace($healthy,$yummy,$params['file']);
if (is_file($xcart_dir.(str_replace($string,"",str_replace("./","/",$params['file'])))))
{
$params['file'] = $xcart_dir.(str_replace($string,"",str_replace("./","/",$params['file'])));
}elseif (is_file(realpath($xcart_web_dir.(str_replace($string,"",str_replace("./","/",$params['file']))))))
{
$params['file'] = realpath($xcart_web_dir.(str_replace($string,"",str_replace("./","/",$params['file']))));
}elseif (is_file(realpath($server_vars['DOCUMENT_ROOT']).$xcart_web_dir.(str_replace($string,"",str_replace("./","/",$params['file'])))))
{
$params['file'] = realpath($server_vars['DOCUMENT_ROOT']).$xcart_web_dir.(str_replace($string,"",str_replace("./","/",$params['file'])));
}else {
$params['file'] = $xcart_dir."/no_image.gif";
}
### Check/Configure All Other Variables
if (empty($params['trans'])||($params['trans'] >127)||($params['trans'] <0)) $params['trans'] = 100;
if (!empty($params['prefix'])) $params['prefix'] = $params['prefix']."-";
if (empty($params['text'])) $params['text'] = "© ".$server_vars['HTTP_HOST'];
if (empty($params['quality'])) $params['quality'] = 80;
if (empty($params['email'])) $params['email'] = N;
if (empty($params['linkonly'])) $params['linkonly'] = N;
if (empty($params['special'])) $params['special'] = N;
if (empty($params['dev'])) $params['dev'] = false;
if (empty($params['crop'])) $params['crop'] = false;
if (empty($params['width']) AND empty($params['height'])
AND empty($params['longside']) AND empty($params['shortside'])) $params['width'] = 100;
### Get SOURCE (SRC) information
$temp = getimagesize($params['file']);
$_SRC['file'] = $params['file'];
$_SRC['width'] = $temp[0];
$_SRC['height'] = $temp[1];
$_SRC['type'] = $temp[2];
$_SRC['string'] = $temp[3];
$_SRC['filename'] = basename($params['file']);
$_SRC['modified'] = filemtime($params['file']);
### Hash for Filename
$_SRC['hash'] = md5($_SRC['file'].$_SRC['modified'].implode('',$params));
### Calculate destination (DST) information
if (is_numeric($params['width'])) $_DST['width'] = $params['width'];
else $_DST['width'] = round($params['height']/($_SRC['height']/$_SRC['width']));
if (is_numeric($params['height'])) $_DST['height'] = $params['height'];
else $_DST['height'] = round($params['width']/($_SRC['width']/$_SRC['height']));
### Maintain ratio if LONGSIDE or SHORTSIDE is specified
if (is_numeric($params['longside']))
{
if ($_SRC['width'] <$_SRC['height'])
{
$_DST['height'] = $params['longside'];
$_DST['width'] = round($params['longside']/($_SRC['height']/$_SRC['width']));
}
else
{
$_DST['width'] = $params['longside'];
$_DST['height'] = round($params['longside']/($_SRC['width']/$_SRC['height']));
}
}
elseif (is_numeric($params['shortside']))
{
if ($_SRC['width'] <$_SRC['height'])
{
$_DST['width'] = $params['shortside'];
$_DST['height'] = round($params['shortside']/($_SRC['width']/$_SRC['height']));
}
else
{
$_DST['height'] = $params['shortside'];
$_DST['width'] = round($params['shortside']/($_SRC['height']/$_SRC['width']));
}
}
### Crop Image?
if($params['crop'])
{
$width_ratio = $_SRC['width']/$_DST['width'];
$height_ratio = $_SRC['height']/$_DST['height'];
if ($width_ratio >$height_ratio)
{
$_DST['offset_w'] = round(($_SRC['width']-$_DST['width']*$height_ratio)/2);
$_SRC['width'] = round($_DST['width']*$height_ratio);
}
elseif ($width_ratio <$height_ratio)
{
$_DST['offset_h'] = round(($_SRC['height']-$_DST['height']*$width_ratio)/2);
$_SRC['height'] = round($_DST['height']*$width_ratio);
}
}
### Upscale or not if the original picture is smaller than the output size
if ($params['upscale'] == 'N'&&$_DST['height'] >$_SRC['height'] &&$_DST['width'] >$_SRC['width'])
{
$_DST['width'] = $_SRC['width'];
$_DST['height'] = $_SRC['height'];
}
if (!empty($params['type'])) $_DST['type'] = $params['type'];
else $_DST['type'] = $_SRC['type'];
### Create output string
$_DST['file'] = $params['prefix'].$_SRC['hash'].$_CONFIG['types'][$_DST['type']];
$_DST['string'] = 'style="width: '.$_DST['width'].'px; height: '.$_DST['height'].'px;" alt="'.$params['alt'].'" class="'.$params['class'].'"';
if ($params['id']) {
$_DST['string'] = $_DST['string'].' id="'.$params['id'].'"';
}
if ($params['name']) {
$_DST['string'] = $_DST['string'].' name="'.$params['name'].'"';
}
### Provide return strings
if ($params['email'] == "y")
{
$_RETURN['img'] = '<img src="http://'.$server_vars['HTTP_HOST'].$_CONFIG['webpath'].$_DST['file'].'" '.$params['html'].' '.$_DST['string'].' />';
}else{
if (empty($params['html'])) $_RETURN['img'] = '<img src="'.$_CONFIG['webpath'].$_DST['file'].'" '.$params['html'].' '.$_DST['string'].' title="" />';
else $_RETURN['img'] = '<img src="'.$_CONFIG['webpath'].$_DST['file'].'" '.$params['html'].' '.$_DST['string'].' />';
}
if ($params['linkonly'] == "Y"||$params['linkonly'] == "true")
{
$returner = $_CONFIG['webpath'].$_DST['file'];
}
else
{
$returner = $_RETURN['img'];
}
### Cache file intercept
if (is_file($_CONFIG['outpath'].$_DST['file']) AND !$params['dev']) return $returner;
### Otherwise continue
### SRC read in
if ($_SRC['type'] == 1) $_SRC['image'] = imagecreatefromgif($_SRC['file']);
if ($_SRC['type'] == 2) $_SRC['image'] = imagecreatefromjpeg($_SRC['file']);
if ($_SRC['type'] == 3) $_SRC['image'] = imagecreatefrompng($_SRC['file']);
### If the picture is very large,overwrites first linear down-scaled on quadruple goal size and $_SRC
if ($_DST['width']*2 <$_SRC['width'] AND $_DST['height']*2 <$_SRC['height'])
{
$_TMP['width'] = round($_DST['width']*2);
$_TMP['height'] = round($_DST['height']*2);
$_TMP['image'] = imagecreatetruecolor($_TMP['width'],$_TMP['height']);
### Preserve transparancy on TEMP image
imagealphablending($_TMP['image'],false);
imagecopyresized($_TMP['image'],$_SRC['image'],0,0,$_DST['offset_w'],$_DST['offset_h'],$_TMP['width'],$_TMP['height'],$_SRC['width'],$_SRC['height']);
$_SRC['image'] = $_TMP['image'];
$_SRC['width'] = $_TMP['width'];
$_SRC['height'] = $_TMP['height'];
$_DST['offset_w'] = 0;
$_DST['offset_h'] = 0;
unset($_TMP['image']);
}
### DST provide
$_DST['image'] = imagecreatetruecolor($_DST['width'],$_DST['height']);
### Preserve transparancy on DST image
imagealphablending($_DST['image'],false);
### if PNG turn off unsharp mask
if ($_SRC['type'] == 3) $params['sharpen'] = "false";
imagecopyresampled($_DST['image'],$_SRC['image'],0,0,$_DST['offset_w'],$_DST['offset_h'],$_DST['width'],$_DST['height'],$_SRC['width'],$_SRC['height']);
### Unsharp Mask
if ($params['sharpen'] == "Y") $_DST['image'] = UnsharpMask($_DST['image'],80,.5,3);
### Watermark
if ($_DST['width'] >100 AND $params['watermark'] == 'Y'){
$font = $xcart_dir.$params['font'];
Watermark($_DST['image'],$_DST['width'],$_DST['height'],$font,$params['text'],'90',$_FONTSIZE=8,$_SRC['type'],$params['trans'],$params['watermark_loc']);
}
if ($params['hint'] == "Y")
{
$trans = imagecolorallocatealpha($_DST['image'],255,255,255,25);
imagefilledrectangle($_DST['image'],0,$_DST['height']-9,$_DST['width'],$_DST['height'],$trans);
$magnifier = imagecreatefromstring(gzuncompress(base64_decode("eJzrDPBz5+WS4mJgYOD19HAJAtLcIMzBBiRXrilXA1IsxU6eIRxAUMOR0gHkcxZ4RBYD1QiBMOOlu3V/gIISJa4RJc5FqYklmfl5CiGZuakMBoZ6hkZ6RgYGJs77ex2BalRBaoLz00rKE4tSGXwTk4vyc1NTMhMV3DKLUsvzi7KLFXwjFEAa2svWnGdgYPTydHEMqZhTOsE++1CAyNHzm2NZjgau+dAmXlAwoatQmOld3t/NPxlLMvY7sovPzXHf7re05BPzjpQTMkZTPjm1HlHkv6clYWK43Zt16rcDjdZ/3j2cd7qD4/HHH3GaprFrw0QZDHicORXl2JsPsveVTDz//L3N+WpxJ5Hff+10Tjdd2/Vi17vea79Om5w9zzyne9GLnWGrN8atby/ayXPOsu2w4quvVtxNCVVz5nAf3nDpZckBCedpqSc28WTOWnT7rZNXZSlPvFybie9EFc6y3bIMCn3JAoJ+kyyfn9qWq+LZ9Las26Jv482cDRE6Ci0B6gVbo2oj9KabzD8vyMK4ZMqMs2kSvW4chz88SXNzmeGjtj1QZK9M3HHL8L7HITX3t19//VVY8CYDg9Kvy2vDXu+6mGGxNOiltMPsjn/t9eJr0ja/FOdi5TyQ9Lz3fOqstOr99/dnro2vZ1jy76D/vYivPsBoYPB09XNZ55TQBAAJjs5s</body>")));
imagealphablending($_DST['image'],true);
imagecopy($_DST['image'],$magnifier,$_DST['width']/2,$_DST['height']-14,0,0,11,11);
imagedestroy($magnifier);
}
### Overlay Image For Special Offer
if ($params['special'] == "Y")
{
$loadFile = realpath($params['load']);
$special = imagecreatefromstring(file_get_contents($loadFile));
imagealphablending($_DST['image'],true);
imagecopy($_DST['image'],$special,$_DST['width']-47,$_DST['height']-50,0,0,47,44);
imagedestroy($special);
}
### Thumbnail store
if ($_DST['type'] == 1)
{
imagetruecolortopalette($_DST['image'],false,256);
imagegif($_DST['image'],$_CONFIG['outpath'].$_DST['file']);
}
if ($_DST['type'] == 2)
{
imagejpeg($_DST['image'],$_CONFIG['outpath'].$_DST['file'],$params['quality']);
}
if ($_DST['type'] == 3)
{
imagesavealpha($_DST['image'],true);
imagepng($_DST['image'],$_CONFIG['outpath'].$_DST['file']);
}
imagedestroy($_DST['image']);
imagedestroy($_SRC['image']);
### Return
return $returner;
}
|
ZeroBytes |
|
|
|
|
|
www.waraxe.us Forum Index -> PHP script decode requests
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
All times are GMT
Page 1 of 1
|
|
|
Powered by phpBB © 2001-2008 phpBB Group
|
|
|
|
|
|