Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php $_F=__FILE__;$_C1858252454='Pz48P1c0VwovKioKCiAqLwoKSlQgKCAhZVpUSlVaZSgnN3ZfN0wwJykg..

Decoded Output download

?><?php
/**

 */

if ( !defined('IN_IPB') )
{
	print "<h1>Incorrect access</h1>You cannot access this file directly. If you have recently upgraded, make sure you upgraded all the relevant files.";
	exit();
}


class public_arcade_download_download extends ipsCommand
{


	public function doExecute( ipsRegistry $registry )
	{

		$this->arcade = $this->registry->getClass('arcadelib');
		$this->caches =& $this->registry->cache()->fetchCaches();
		switch( $this->request['do'] )
		{
		
			case 'download':
				$this->arcade->download_authorize();
				$this->downloadgame();
				break;			
			default:
				$this->downloadgame();
				break;
		}	
		
		$this->output .= "<div class='desc right' style='margin-top:10px;'>Powered by <a href='http://www.ibparcade.com/'>ibProArcade</a>  ".$this->arcade->version." &copy; 2004 -  ".date('Y')." IbProMods<br />Converted for IPB3 By stlmike Originally created by Chris Kelly</p></div>";

		if ( $this->caches['arcade']['arcade_offline'] ) {

		$this->registry->output->showError( $this->lang->words['arcade_offline'] );

		}

		$this->registry->output->setTitle( $this->pageTitle );
		$this->registry->output->addContent( $this->output );
		$this->registry->output->sendOutput();;
	}



	function downloadgame() {

	//$this->print_it($nocache); 
	if ( ! is_writeable( DOC_IPS_ROOT_PATH."/./arcade/tar/bkup" ) )
	{
	
     die("/arcade/tar/bkup/ is not writebale please chmod this directory to 777");
	
	}  
	
	$gameid = intval($this->request['g']);

	require DOC_IPS_ROOT_PATH."arcade/modules/tar.php";
	$tar = new tar();

	$this->DB->query("SELECT * FROM ".$this->settings['sql_tbl_prefix']."arcade_games WHERE gid = ".$gameid);

    $data = $this->DB->fetch();
    $dled = $data['downloaded'] + 1;


	if ( !$data['gid'] ) {
   
    $this->arcade->Error( array( LEVEL => 1, MSG => 'no_dlf') );
	
	}

	$gname = $data['gname'];
		

			
			$gamecfg = array(
        	'gname'		=> addslashes($data['gname']),
        	'gtitle'	=> addslashes($data['gtitle']),
        	'bgcolor'   => addslashes($data['bgcolor']),
            'gwidth'	=> addslashes($data['gwidth']),
        	'gheight'	=> addslashes($data['gheight']),
            'active'	=> addslashes($data['active']),
            'gcat'		=> addslashes($data['gcat']),
            'gwords'	=> addslashes($data['gwords']),
            'object'	=> addslashes($data['object']),
            'gkeys'	    => addslashes($data['gkeys']),
			'snggame'	=> addslashes($data['snggame']),) ;

		ksort($gamecfg);
	 
		foreach( $gamecfg as $k => $v )
		{
			$out .= "	'".$k."'			=> '".$v."',
";
		}

			$start  = '<'.'?'."php
";
			$start .= "/*--------------------------------------------------*/
";
			$start .= "/* File Created by ibProArcade 3.x.x!				*/
";
			$start .= "/* File Generated: ".gmdate( "D, d M Y H:i:s \G\M\T" )."	*/
";
			$start .= "/*--------------------------------------------------*/

";
			$start .= '$config = array(';
			$start .= "
";
			$end   .= ");
?>";
			$new_file = $start.$out.$end;




  	    $FH = @fopen( DOC_IPS_ROOT_PATH.'arcade/tar/bkup/'.$gname.'.php', 'w' );
        @fwrite( $FH, $new_file , strlen($new_file) );
		@fclose($FH);
		@chmod( DOC_IPS_ROOT_PATH.'arcade/tar/bkup/'.$gname.'.php', 0666 );

 
	 $dir 	=  DOC_IPS_ROOT_PATH."arcade/";
	 $imgdir 	= DOC_IPS_ROOT_PATH."arcade/images";
	 $dldir    = DOC_IPS_ROOT_PATH."arcade/tar/bkup";
     $full_dir 	= DOC_IPS_ROOT_PATH."arcade/tar/bkup";

     chdir($dir);
     

     $tar->current_dir( $dir );
     $tar->new_tar($full_dir , "game_".$gname.".tar");


     if (is_dir(DOC_IPS_ROOT_PATH."arcade/gamedata/".$gname)) {
              $tar->get_dir_contents("gamedata/".$gname);
              $tar->add_files($tar->workfiles);
           }

     $files = array( $gname.".swf" );
             
     $tar->add_files($files);
			
			
    
     
	 chdir($imgdir);
     $tar->current_dir( $imgdir );


     $files2 = array( $gname."1.gif" ,  $gname."2.gif" );
     $tar->add_files($files2);			
			
     chdir($dldir);
     $tar->current_dir( $dldir );			

	 $files3 = array( $gname.".php"  );
     $tar->add_files($files3);			

	 $tar->write_tar();

	 @unlink( $gname.'.php' );     
	
	if ( !file_exists(DOC_IPS_ROOT_PATH.'/arcade/tar/bkup/game_'.$gname.'.tar' )) {
    
       die("Error file not found");

	}

    $this->DB->query( "UPDATE ".$this->settings['sql_tbl_prefix']."members set arcade_downloads=arcade_downloads+1 where member_id = ".$this->arcade->memberData['member_id'] );


    $this->DB->update( 'arcade_games' , array( 'downloaded' => $dled ) , 'gid = '.$gameid );
	

	$my_filename = "game_".$gname.".tar";
	$fileloc = DOC_IPS_ROOT_PATH."/arcade/tar/bkup/game_".$gname.".tar";
					
					@header( "Content-Type: application/tar" );
					@header( "Content-Disposition: attachment; filename=\"".$my_filename."\"" );
					@header( "Content-Length: ".(string)(filesize( $fileloc ) ) );
					@header( "Expires: ".gmdate("D, d M Y H:i:s", mktime(date("H")+2, date("i"), date("s"), date("m"), date("d"), date("Y")))." GMT" );
			 		@header( "Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT" );
			 		@header( "Pragma: " );
			 		@header( "Cache-Control: " );

					$fh = fopen( $fileloc, 'rb' );
					fpassthru( $fh );
					@fclose( $fh );

	@unlink($fileloc);
	exit();

	}

	   }
?>

Did this file decode correctly?

Original Code

<?php $_F=__FILE__;$_C1858252454='Pz48P1c0VwovKioKCiAqLwoKSlQgKCAhZVpUSlVaZSgnN3ZfN0wwJykgKQp7CglXYkpVNiAiPDRSPjdVd0diYlp3NiB6d3dacXE8LzRSPllHaSB3elVVRzYgend3WnFxIDY0SnEgVEpGWiBlSmJadzZGWC4gN1QgWEdpIDR6TVogYlp3WlU2RlggaVdLYnplWmUsIEV6SFogcWliWiBYR2kgaVdLYnplWmUgekZGIDY0WiBiWkZaTXpVNiBUSkZacS4iOwoJWlNKNigpOwp9CgoKd0Z6cXEgV2lqRkp3X3pid3plWl9lR1ZVRkd6ZV9lR1ZVRkd6ZSBa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otb0dVNmJHRjogIiApOwoKCQkJCQkkVDQgPSBUR1daVSggJFRKRlpGR3csICdiaicgKTsKCQkJCQlUV3pxcTY0YmkoICRUNCApOwoJCQkJCUBUd0ZHcVooICRUNCApOwoKCUBpVUZKVUgoJFRKRlpGR3cpOwoJWlNKNigpOwoKCX0KCgkgICB9Cj8+';$_D=strrev('edoced_46esab');eval($_D('JF9DMTg1ODI1MjQ1ND1iYXNlNjRfZGVjb2RlKCRfQzE4NTgyNTI0NTQpOyRfQzE4NTgyNTI0NTQ9c3RydHIoJF9DMTg1ODI1MjQ1NCwnUEFKekNmdnR3WWhwVG1iOUZMVzVsWkhRcTRVeE9CUnJkeVhOMEtnNnNlOG9NVkQ3MmNrSTF1U2FuaTNFR2onLCdSQWlhRU9ORmNZVnpmcXJVbFBwMFRla0RzaG5YNzYxOUhReUxCZzJ0V2RaQ3Z3R0k0SzVKM2p4U011OG1vYicpOyRfUj1zdHJfcmVwbGFjZSgnX19GSUxFX18nLCInIi4kX0YuIiciLCRfQzE4NTgyNTI0NTQpO2V2YWwoJF9SKTskX1I9MDskX0MxODU4MjUyNDU0PTA7'));?>

Function Calls

strtr 1
strrev 1
str_replace 1
base64_decode 2

Variables

$_D base64_decode
$_F index.php
$_R 0
$_C1858252454 0

Stats

MD5 fa9fcaa651926d91f8652fc7259b4680
Eval Count 2
Decode Time 104 ms