C
C
Captain Cocoa2018-02-08 15:35:13
PHP
Captain Cocoa, 2018-02-08 15:35:13

How to decrypt PHP code?

Hello everyone, there was a problem on the wordpress site, someone either hacked the site or somehow encrypted the file code category.php, going to the page of any category of the site gives this

Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /home/users/r/radvancor/domains/DOMAIN/wp-content/themes/id2/category.php on line 1

And the file category.phplooks like this:
https://jsfiddle.net/5ndmbyaL/
Tell me if you can somehow decrypt this code or some other way to solve the problem. And how could this even happen?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
L
Lone Ice, 2018-02-08
@daemonhk

You don't need to decrypt anything, just get rid of the virus you caught. This code usually encrypts spam, redirects, downloads of other viruses to your site, and other crap. Restore your file from backups, because some viruses replace entire files (your option), and some simply add smaller code to the beginning of the file.

O
OKyJIucT, 2018-02-08
@OKyJIucT

Solution #3 is for you - https://www.ryadel.com/en/php-fix-warning-preg_rep...
Or roll back your PHP version to 5.4.

X
xmoonlight, 2018-02-08
@xmoonlight

And if my answer ( and on protection ) has not helped you yet, then do not mark it as a solution yet, but just like it!

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question