Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
$_F=__FILE__;$_X='P3F2P2lIaTxWKjxZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZ..
Decoded Output download
?><?php
/*
=====================================================
DataLife Engine - by SoftNews Media Group
-----------------------------------------------------
https://dle-news.ru/
-----------------------------------------------------
Copyright (c) 2004-2023 SoftNews Media Group
=====================================================
This code is protected by copyright
=====================================================
File: redis.class.php
-----------------------------------------------------
Use: redis class
=====================================================
*/
if( !defined( 'DATALIFEENGINE' ) ) {
header( "HTTP/1.1 403 Forbidden" );
header ( 'Location: ../../' );
die( "Hacking attempt!" );
}
class dle_fastcache
{
protected $server = null;
protected $suite_key = null;
protected $max_age = null;
public $connection = null;
public function __construct( $config ) {
$this->suite_key = md5( DBNAME . PREFIX . SECURE_AUTH_KEY ).'_';
$this->server = $this->connect();
if($this->connection !== -1 ) {
$redis_server = explode(":", $config['memcache_server']);
$this->connection = 1;
if ( count($redis_server) == 2 ) {
try {
if( !$this->server->connect( trim($redis_server[0]), trim($redis_server[1]) ) ) {
$this->connection = 0;
}
} catch (Exception $e) {
$this->connection = 0;
}
} else {
try {
if( !$this->server->connect(trim($redis_server[0])) ) {
$this->connection = 0;
}
} catch (Exception $e) {
$this->connection = 0;
}
}
$auth = array();
if( $config['redis_user'] ) $auth['user'] = $config['redis_user'];
if( $config['redis_pass'] ) $auth['pass'] = $config['redis_pass'];
if( count($auth) ) {
try {
if( !$this->server->auth($auth) ) {
$this->connection = -2;
}
} catch (Exception $e) {
$this->connection = -2;
}
}
if($this->connection > 0) {
try {
if( !$this->server->ping() ){
$this->connection = 0;
}
} catch (Exception $e) {
$this->connection = 0;
}
}
}
if ( $config['clear_cache'] ) $this->max_age = $config['clear_cache'] * 60; else $this->max_age = 86400;
}
protected function connect() {
if( class_exists( 'Redis' ) ) {
return new Redis();
} else {
$this->connection = -1;
}
}
public function get( $key ) {
if($this->connection < 1 ) return false;
return $this->server->get($this->suite_key.$key);
}
public function set($key, $value, $max_age = false) {
if($this->connection < 1 ) return false;
if( $max_age ) {
$this->server->setEx($this->suite_key . $key, $max_age, $value);
} else {
$this->server->setEx($this->suite_key . $key, $this->max_age, $value);
}
return true;
}
public function clear( $cache_areas = false ) {
if($this->connection < 1 ) return false;
if ( $cache_areas ) {
if(!is_array($cache_areas)) {
$cache_areas = array($cache_areas);
}
}
if( $cache_areas ) {
foreach($cache_areas as $cache_area){
$allKeys = $this->server->keys($this->suite_key.$cache_area.'*');
if(is_array($allKeys) AND count($allKeys)) {
foreach ( $allKeys as $key) {
$this->server->del($key);
}
}
}
} else {
$this->_clear_all();
}
return true;
}
protected function _clear_all() {
if($this->connection < 1 ) return false;
$allKeys = $this->server->keys($this->suite_key.'*');
if(is_array($allKeys) AND count($allKeys)) {
foreach ( $allKeys as $key) {
$this->server->del($key);
}
}
return true;
}
public function __destruct() {
if($this->connection < 1 ) return;
if( $this->server ) {
$this->server->close();
}
}
}
Did this file decode correctly?
Original Code
$_F=__FILE__;$_X='P3F2P2lIaTxWKjxZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWTxTbFVNVXkwQnNTdWZhMGZzUy1TIHdTUW5CTS9zSTlTUHNLMFVTTkVuN2lTPC0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tPFNITU1pOTpWVkt7cy1mc0k5CkU3VjwtLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLTxTW25pd0UwYUhNUyhnKVNiQUF9LWJBYkxTUW5CTS9zSTlTUHNLMFVTTkVuN2k8WVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVk8U2pIMDlTZ25L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zS1NCN2ZnTTBuZlNfZ3tzVUVfVXt7KClTTzwJCTwJCTBCKCRNSDA5LXFnbmZmc2dNMG5mU3ZTbVMpU0VzTTdFZlNCVXs5czs8CQk8CQkkVXt7a3N3OVNZUyRNSDA5LXE5c0Uzc0UtcVJzdzkoJE1IMDktcTk3ME1zX1JzdwonKicpOzw8CQkwQigwOV9VRUVVdygkVXt7a3N3OSlTZC9sU2duN2ZNKCRVe3trc3c5KSlTTzwJCQlCbkVzVWdIUyhTJFV7e2tzdzlTVTlTJFJzdylTTzwJCQkJJE1IMDktcTlzRTNzRS1xS3N7KCRSc3cpOzwJCQk1PAkJNTwJCTwJCUVzTTdFZlNNRTdzOzwJCTwJNTwJPAk8CWk3IHswZ1NCN2ZnTTBuZlNfX0tzOU1FN2dNKClTTzwJCTwJCTBCKCRNSDA5LXFnbmZmc2dNMG5mU3ZTbVMpU0VzTTdFZjs8CQk8CQkwQihTJE1IMDktcTlzRTNzRVMpU088CQkJJE1IMDktcTlzRTNzRS1xZ3tuOXMoKTs8CQk1PAk1PAk8NTw=';$_D=strrev('edoced_46esab');eval($_D('JF9YPWJhc2U2NF9kZWNvZGUoJF9YKTskX1g9c3RydHIoJF9YLCdnRDB7QlhHVFtXNE1lPDk9Zl1yQThxc0ZsRTVSM20+IFBRdnljSXpkd0sxalVPL05hcHRZLngyQ3ViN0w2a29IUwpuVkpaaX1oJywnYzZpbGZCSFVDVlh0UApzOW56SjA3PmU4RHJ9a3YxWmJNUzxMWXdqQXlkXVRhe05HZ21SPUZbSTVFMnUzUUtXaCAuby9xT3A0eCcpOyRfUj1zdHJfcmVwbGFjZSgnX19GSUxFX18nLCInIi4kX0YuIiciLCRfWCk7ZXZhbCgkX1IpOyRfUj0wOyRfWD0wOw=='));
Function Calls
strtr | 1 |
strrev | 1 |
str_replace | 1 |
base64_decode | 2 |
Stats
MD5 | 1366ac905c3dd73e578833308e7121b3 |
Eval Count | 2 |
Decode Time | 60 ms |