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 /** * Plugin Name: Page Restriction WordPress (WP) - Protect WP Pages/Post * Desc..

Decoded Output download

<?php 
/** 
* Plugin Name: Page Restriction WordPress (WP) - Protect WP Pages/Post 
* Description: This plugin allows restriction over users based on their roles and whether they are logged in or not. 
* Version: 8.0.5 
* Author: miniOrange 
* Author URI: http://miniorange.com 
* License: MIT/Expat 
* License URI: https://docs.miniorange.com/mit-license 
*/ 
 
require_once('page-restriction-save.php'); 
require_once('page-restriction-menu-settings.php'); 
include_once 'page-restriction-utility.php'; 
 
 
class page_and_post_restriction_add_on 
{ 
    function __construct() 
    { 
        update_option("papr_host_name", "https://login.xecurify.com"); 
        add_action("admin_menu", array($this, "papr_menu"), 11); 
        add_action("admin_init", "papr_save_setting", 1, 0); 
        add_action("admin_enqueue_scripts", array($this, "papr_plugin_settings_script")); 
        register_deactivation_hook(__FILE__, array($this, "papr_deactivate")); 
        remove_action("admin_notices", "papr_success_message"); 
        remove_action("admin_notices", "papr_error_message"); 
        add_action("save_post", array($this, "papr_save_meta_box_info"), 10, 3); 
        add_action("wp", array($this, "papr_initialize_page_restrict"), 0); 
        add_action("add_meta_boxes", array($this, "papr_add_custom_meta_box")); 
        add_shortcode("restrict_content", array($this, "papr_restrict_content")); 
        add_action("plugin_action_links_" . plugin_basename(__FILE__), array($this, "papr_add_plugin_settings")); 
    } 
    function papr_menu() 
    { 
        add_menu_page("Page and Post Restriction", "Page Restriction", "administrator", "page_restriction", "papr_page_restriction", plugin_dir_url(__FILE__) . "includes/images/miniorange.png"); 
    } 
    function papr_add_plugin_settings($hV) 
    { 
        $hV = array_merge(array("<a href="" . esc_url(admin_url("admin.php?page=page_restriction")) . "">" . __("Settings") . "</a>"), $hV); 
        return $hV; 
    } 
    function papr_deactivate() 
    { 
        wp_redirect("plugins.php"); 
        delete_option("papr_admin_email"); 
        delete_option("papr_admin_customer_key"); 
        delete_option("papr_host_name"); 
        delete_option("papr_new_registration"); 
        delete_option("papr_admin_phone"); 
        delete_option("papr_admin_password"); 
        delete_option("papr_admin_customer_key"); 
        delete_option("papr_admin_api_key"); 
        delete_option("papr_customer_token"); 
        delete_option("papr_message"); 
        delete_option("papr_allowed_roles_for_pages"); 
        delete_option("papr_restricted_pages"); 
        delete_option("papr_allowed_roles_for_posts"); 
        delete_option("papr_restricted_posts"); 
        delete_option("papr_allowed_redirect_for_pages"); 
        delete_option("papr_allowed_redirect_for_posts"); 
    } 
    function papr_plugin_settings_script($Jt) 
    { 
        if (!($Jt != "toplevel_page_page_restriction")) { 
            goto Fs; 
        } 
        return; 
        Fs: 
        wp_enqueue_script("jquery"); 
        wp_enqueue_script("jquery-ui-autocomplete"); 
        wp_enqueue_script("papr_admin_settings_phone_script", plugins_url("includes/js/phone.js", __FILE__)); 
        wp_enqueue_style("papr_admin_bootstrap_settings_script", plugins_url("includes/js/bootstrap/bootstrap.min.js", __FILE__)); 
        wp_enqueue_style("papr_admin_bootstrap_settings_script", plugins_url("includes/js/bootstrap/popper.min.js", __FILE__)); 
        wp_enqueue_style("papr_admin_settings_phone_style", plugins_url("includes/css/phone.css", __FILE__)); 
        wp_enqueue_style("papr_admin_bootstrap_settings_style", plugins_url("includes/css/bootstrap/bootstrap.min.css", __FILE__)); 
        wp_enqueue_style("papr_admin_settings_style", plugins_url("includes/css/papr_settings_style.css", __FILE__)); 
    } 
    function papr_restrict_content($Kj, $i_ = '') 
    { 
        $Yq = get_option("papr_blockrestriction_customerror_msg") ?? ''; 
        if (is_user_logged_in()) { 
            goto Gz; 
        } 
        return $Yq; 
        Gz: 
        if (!isset($Kj["role"])) { 
            goto Vz; 
        } 
        $BX = wp_get_current_user(); 
        $aw = $BX->roles; 
        foreach ($aw as $fP => $h_) { 
            if (!(stripos($Kj["role"], $h_) !== false)) { 
                goto OL; 
            } 
            return "<p>" . $i_ . "</p>"; 
            OL: 
            LB: 
        } 
        Tm: 
        return $Yq; 
        Vz: 
        return "<p>" . $i_ . "</p>"; 
    } 
    function is_post_category_restricted($JK, $Ot) 
    { 
        $G3 = wp_get_post_categories($JK); 
        foreach ($G3 as $fP => $vO) { 
            if (empty($Ot[$vO])) { 
                goto LE; 
            } 
            return true; 
            LE: 
            Xv: 
        } 
        Ic: 
        return false; 
    } 
    function papr_add_custom_meta_box($Oh) 
    { 
        global $mf; 
        $SK = get_option("papr_allowed_metabox_roles"); 
        if (!empty($SK)) { 
            goto Dz; 
        } 
        $SK = "Editor; Author;"; 
        Dz: 
        if (!($SK == "papr_no_roles")) { 
            goto Kj; 
        } 
        $SK = ''; 
        Kj: 
        $Kb = explode(";", $SK); 
        $current_user = wp_get_current_user(); 
        $Vv = $current_user->roles; 
        if (!papr_in_array($mf, array("post-new.php"))) { 
            goto wc; 
        } 
        if ($Oh == "page" && get_option("papr_select_all_pages") == "checked") { 
            goto jQ; 
        } 
        if (!(get_option("papr_select_all_posts") == "checked")) { 
            goto lx; 
        } 
        $Ac = maybe_unserialize(get_option("papr_allowed_redirect_for_posts")); 
        $Ac[get_the_ID()] = true; 
        update_option("papr_allowed_redirect_for_posts", $Ac); 
        lx: 
        goto O_; 
        jQ: 
        $Ac = maybe_unserialize(get_option("papr_allowed_redirect_for_pages")); 
        $Ac[get_the_ID()] = true; 
        update_option("papr_allowed_redirect_for_pages", $Ac); 
        O_: 
        wc: 
        if (!is_array($Vv)) { 
            goto z2; 
        } 
        if (!(empty(array_intersect($Kb, $Vv)) && !papr_in_array("administrator", $Vv))) { 
            goto T2; 
        } 
        return; 
        T2: 
        z2: 
        $Hd = get_post_type_object($Oh); 
        add_meta_box("demo-meta-box", "Page Restrict Access", array($this, "papr_meta_box"), $Oh, "side", "high", null); 
    } 
    function restrict_logged_in_users($v4, $du) 
    { 
        $this->apply_restriction_if_toggle_is_enabled($v4, $du); 
        $PJ = maybe_unserialize(get_option("papr_allowed_redirect_for_pages")) ? maybe_unserialize(get_option("papr_allowed_redirect_for_pages")) : array(); 
        $ni = maybe_unserialize(get_option("papr_allowed_redirect_for_posts")) ? maybe_unserialize(get_option("papr_allowed_redirect_for_posts")) : array(); 
        $Ot = maybe_unserialize(get_option("papr_allowed_redirect_for_category")) ? maybe_unserialize(get_option("papr_allowed_redirect_for_category")) : array(); 
        $Tq = get_option("papr_allowed_redirect_for_customposts") ? get_option("papr_allowed_redirect_for_customposts") : array(); 
        $Oh = get_post_type($v4); 
        if (!(is_page() && !empty($PJ[$v4]) || is_front_page() && !empty($PJ[get_option("page_on_front")]) || is_single() && (!empty($ni[$v4]) || $this->is_post_category_restricted($v4, $Ot)) || $du && !empty($Ot[$v4]) || papr_in_array($v4, $Tq))) { 
            goto Z8; 
        } 
        if (has_action("mo_restrict_page_option")) { 
            goto bz; 
        } 
        $this->restriction($v4, $du); 
        goto Et; 
        bz: 
        do_action("mo_restrict_page_option"); 
        Et: 
        Z8: 
    } 
    function restriction($v4, $du) 
    { 
        $Um = $this->check_type($v4, $du, "papr_before_login_"); 
        $sI = $Um["option"] ?? ''; 
        $xe = $Um["choice"] ?? ''; 
        if ($xe) { 
            goto K1; 
        } 
        $xe = "mo_display_message"; 
        K1: 
        if ($xe == "mo_display_message") { 
            goto pK; 
        } 
        if ($xe == "mo_display_page") { 
            goto A7; 
        } 
        if ($xe == "mo_display_redirect_IDP") { 
            goto Y5; 
        } 
        $Fg = get_option("papr_login_page_url"); 
        if (!empty($Fg)) { 
            goto xK; 
        } 
        auth_redirect(); 
        goto lK; 
        xK: 
        $hB = (isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] === "on" ? "https" : "http") . "://{$_SERVER["HTTP_HOST"]}{$_SERVER["REQUEST_URI"]}"; 
        if (strpos($Fg, "?") !== false) { 
            goto J0; 
        } 
        header("Location:" . $Fg . "?redirect_to=" . urlencode($hB)); 
        goto lp; 
        J0: 
        header("Location:" . $Fg . "&redirect_to=" . urlencode($hB)); 
        lp: 
        lK: 
        goto Ga; 
        Y5: 
        $th = $sI[$xe]; 
        $hB = (isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] === "on" ? "https" : "http") . "://{$_SERVER["HTTP_HOST"]}{$_SERVER["REQUEST_URI"]}"; 
        $sG = papr_is_sso_enabled(); 
        if ($th == "true" && ($sG != '' || class_exists("MoOAuthClient\MOUtils"))) { 
            goto K2; 
        } 
        if (!empty($UV)) { 
            goto Cy; 
        } 
        $UV = "Oops! You are not authorized to access this"; 
        Cy: 
        wp_die($UV); 
        goto bw; 
        K2: 
        $K0 = site_url() . "?option=saml_user_login&redirect_to=" . urlencode($hB); 
        if (!class_exists("MoOAuthClient\MOUtils")) { 
            goto K5; 
        } 
        $HW = $sI["mo_oauth_app_name"]; 
        $K0 = site_url() . "?option=oauthredirect&app_name=" . $HW . "&redirect_url=" . urlencode($hB) . "&restrictedredirect=true"; 
        K5: 
        header("Location:" . $K0); 
        exit; 
        bw: 
        Ga: 
        goto L4; 
        A7: 
        $W3 = $sI[$xe]; 
        $hB = (isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] === "on" ? "https" : "http") . "://{$_SERVER["HTTP_HOST"]}{$_SERVER["REQUEST_URI"]}"; 
        if (strpos($W3, "?") !== false) { 
            goto ze; 
        } 
        header("Location:" . $W3 . "?redirect_to=" . urlencode($hB)); 
        goto GT; 
        ze: 
        header("Location:" . $W3 . "&redirect_to=" . urlencode($hB)); 
        GT: 
        exit; 
        L4: 
        goto qa; 
        pK: 
        $UV = $sI["mo_display_message"] ?? ''; 
        if (!empty($UV)) { 
            goto vC; 
        } 
        $UV = "Oops! You are not authorized to access this"; 
        vC: 
        wp_die($UV); 
        qa: 
    } 
    function apply_restriction_if_toggle_is_enabled($v4, $du) 
    { 
        $Oo = get_option("papr_access_for_only_loggedin") != '' ? get_option("papr_access_for_only_loggedin") : ''; 
        $ip = maybe_unserialize(get_option("papr_login_unrestricted_pages")) ? maybe_unserialize(get_option("papr_login_unrestricted_pages")) : array(); 
        $Ko = get_option("papr_access_for_only_loggedin_posts") != '' ? get_option("papr_access_for_only_loggedin_posts") : ''; 
        $Ow = maybe_unserialize(get_option("papr_login_unrestricted_posts")) ? maybe_unserialize(get_option("papr_login_unrestricted_posts")) : array(); 
        $Ri = get_option("papr_access_for_only_loggedin_category") != '' ? get_option("papr_access_for_only_loggedin_category") : ''; 
        $Nn = maybe_unserialize(get_option("papr_login_unrestricted_category")) ? maybe_unserialize(get_option("papr_login_unrestricted_category")) : array(); 
        $Vr = get_option("papr_access_for_only_loggedin_customposts") != '' ? get_option("papr_access_for_only_loggedin_customposts") : ''; 
        $bE = get_option("papr_login_unrestricted_customposts") ? get_option("papr_login_unrestricted_customposts") : array(); 
        if (is_front_page() && empty($ip[get_option("page_on_front")]) && $Oo == 1) { 
            goto ha; 
        } 
        if (!is_front_page() && is_page() && $Oo == 1 && empty($ip[$v4])) { 
            goto t9; 
        } 
        if (is_single() && $Ko == 1 && empty($Ow[$v4])) { 
            goto p3; 
        } 
        if ($du && $Ri == 1 && empty($Nn[$v4])) { 
            goto UV; 
        } 
        if (!($Vr == 1 && empty($bE[$v4]))) { 
            goto Xl; 
        } 
        $this->restriction($v4, $du); 
        Xl: 
        goto er; 
        UV: 
        $this->restriction($v4, $du); 
        er: 
        goto k2; 
        p3: 
        $this->restriction($v4, $du); 
        k2: 
        goto Cu; 
        t9: 
        $this->restriction($v4, $du); 
        Cu: 
        goto WJ; 
        ha: 
        $this->restriction(get_option("page_on_front"), $du); 
        WJ: 
    } 
    function is_post_category_role_restricted($OR, $Ot) 
    { 
        $G3 = wp_get_post_categories($OR); 
        if (!is_array($Ot)) { 
            goto AD; 
        } 
        foreach ($G3 as $fP => $vO) { 
            if (!papr_in_array($vO, $Ot)) { 
                goto RZ; 
            } 
            return true; 
            RZ: 
            Sz: 
        } 
        oc: 
        AD: 
        return false; 
    } 
    function check_type($d5, $XN, $gV) 
    { 
        if (is_page($d5) || is_front_page()) { 
            goto EV; 
        } 
        if ($XN) { 
            goto xe; 
        } 
        $Mo = maybe_unserialize(get_option($gV . "post_access")); 
        goto NW; 
        xe: 
        $Mo = maybe_unserialize(get_option($gV . "category_access")); 
        NW: 
        goto ez; 
        EV: 
        $Mo = maybe_unserialize(get_option($gV . "page_access")); 
        ez: 
        return $Mo; 
    } 
    function papr_restrict_by_role($d5, $XN) 
    { 
        $Cc = get_option("papr_allowed_roles_for_posts"); 
        $sM = maybe_unserialize(get_option("papr_allowed_roles_for_pages")); 
        $kv = maybe_unserialize(get_option("papr_allowed_roles_for_category")); 
        $sC = get_option("papr_allowed_roles_for_customposts"); 
        $PJ = maybe_unserialize(get_option("papr_restricted_pages")); 
        $ni = maybe_unserialize(get_option("papr_restricted_posts")); 
        $Ot = maybe_unserialize(get_option("papr_restricted_category")); 
        $user = wp_get_current_user(); 
        $Cr = false; 
        if (!(is_array($sM) && !empty($sM[$d5]))) { 
            goto FH; 
        } 
        $b4 = explode(";", $sM[$d5]); 
        $WP = 0; 
        t_: 
        if (!($WP < sizeof($b4))) { 
            goto IV; 
        } 
        if (strcmp(strtolower($b4[$WP]), implode('', $user->roles))) { 
            goto pr; 
        } 
        $Cr = true; 
        goto IV; 
        pr: 
        kD: 
        $WP++; 
        goto t_; 
        IV: 
        FH: 
        if ($XN) { 
            goto Zd; 
        } 
        if (!is_page($d5)) { 
            goto XQ; 
        } 
        if (!is_array($PJ)) { 
            goto pW; 
        } 
        if (!$Cr) { 
            goto HF; 
        } 
        if (!($d5 !== 1)) { 
            goto g_; 
        } 
        return; 
        g_: 
        HF: 
        pW: 
        XQ: 
        goto gW; 
        Zd: 
        if (!is_array($Ot)) { 
            goto rd; 
        } 
        if (papr_in_array($d5, $Ot)) { 
            goto FR; 
        } 
        return; 
        FR: 
        rd: 
        gW: 
        $Vv = $user->roles; 
        foreach ($Vv as $fP => $kZ) { 
            if (is_front_page() && !empty($sM["mo_page_0"])) { 
                goto A4; 
            } 
            if (!(!empty($sM[$d5]) || !empty($Cc[$d5]) || !empty($kv[$d5]) || !empty($sC[$d5]) || $this->is_post_category_role_restricted($d5, $Ot))) { 
                goto DI; 
            } 
            if (!is_array($sM)) { 
                goto J7; 
            } 
            if (!(!empty($sM[$d5]) && stripos($sM[$d5], $kZ) !== false)) { 
                goto FD; 
            } 
            return; 
            FD: 
            J7: 
            if (!$this->is_post_category_role_restricted($d5, $Ot)) { 
                goto Je; 
            } 
            if (!is_array($kv)) { 
                goto S7; 
            } 
            $hz = wp_get_post_categories($d5); 
            foreach ($hz as $fP => $dq) { 
                if (!(stripos($kv[$dq], $kZ) !== false)) { 
                    goto vq; 
                } 
                return; 
                vq: 
                ik: 
            } 
            ue: 
            S7: 
            Je: 
            if (!is_array($sC)) { 
                goto Cr; 
            } 
            if (!(!empty($sC[$d5]) && stripos($sC[$d5], $kZ) !== false)) { 
                goto hX; 
            } 
            return; 
            hX: 
            Cr: 
            if (!is_array($Cc)) { 
                goto Eg; 
            } 
            $Ne = papr_in_array($d5, $ni); 
            if (!(!empty($Cc[$d5]) && $Ne && stripos($Cc[$d5], $kZ) !== false)) { 
                goto mF; 
            } 
            return; 
            mF: 
            Eg: 
            if (!is_array($kv)) { 
                goto Bw; 
            } 
            if (!(!empty($kv[$d5]) && stripos($kv[$d5], $kZ) !== false)) { 
                goto iW; 
            } 
            return; 
            iW: 
            Bw: 
            DI: 
            goto bx; 
            A4: 
            if (!(stripos(strtolower($sM["mo_page_0"]), $kZ) !== FALSE)) { 
                goto Ym; 
            } 
            return; 
            Ym: 
            bx: 
            AB: 
        } 
        Xj: 
        $hz = wp_get_post_categories($d5); 
        if (!(is_array($sM) || is_array($Cc) || is_array($kv) || is_array($sC))) { 
            goto da; 
        } 
        if (is_page() && is_array($sM) && isset($sM[$d5]) && strlen($sM[$d5]) == 0) { 
            goto aN; 
        } 
        if (is_single() && (!empty($Cc[$d5]) || !empty($sC[$d5]) || $this->is_post_category_role_restricted($d5, $Ot)) || is_front_page() && !empty($sM["mo_page_0"]) || is_page() && !empty($sM[$d5]) || $XN && !empty($kv[$d5])) { 
            goto tO; 
        } 
        goto Vi; 
        aN: 
        return; 
        goto Vi; 
        tO: 
        if (has_action("mo_restrict_page_option")) { 
            goto yu; 
        } 
        $Mo = $this->check_type($d5, $XN, "papr_after_login_"); 
        $sI = $Mo["option"] ?? ''; 
        $xe = $Mo["choice"] ?? ''; 
        if ($xe) { 
            goto lA; 
        } 
        $xe = "mo_display_message_log"; 
        lA: 
        if ($xe == "mo_display_message_log") { 
            goto hn; 
        } 
        if (!($xe == "mo_display_page_log")) { 
            goto hb; 
        } 
        $W3 = $sI[$xe]; 
        header("Location:" . $W3); 
        exit; 
        hb: 
        goto SV; 
        hn: 
        $UV = $sI["mo_display_message_log"] ?? ''; 
        if (!empty($UV)) { 
            goto ot; 
        } 
        $UV = "Oops! You are not authorized to access this"; 
        ot: 
        wp_die($UV); 
        SV: 
        goto kb; 
        yu: 
        do_action("mo_restrict_page_option"); 
        kb: 
        Vi: 
        da: 
    } 
    function papr_initialize_page_restrict() 
    { 
        if (papr_is_customer_license_key_verified()) { 
            goto Ha; 
        } 
        return; 
        Ha: 
        global $post; 
        $XN = get_query_var("cat") > 0 ? true : false; 
        if ($XN) { 
            goto AQ; 
        } 
        $d5 = get_the_ID() ? get_the_ID() : 0; 
        goto sl; 
        AQ: 
        $d5 = get_query_var("cat"); 
        sl: 
        $vU = false; 
        if (!get_option("mo_saml_guest_user_login")) { 
            goto po; 
        } 
        if (!(!session_id() || session_id() == '' || !isset($_SESSION))) { 
            goto IH; 
        } 
        session_start(); 
        IH: 
        if (!isset($_SESSION["mo_saml"])) { 
            goto r9; 
        } 
        if (!(isset($_SESSION["mo_saml"]["can_access_site"]) and $_SESSION["mo_saml"]["can_access_site"] == true)) { 
            goto CC; 
        } 
        $vU = true; 
        CC: 
        r9: 
        po: 
        if (!is_user_logged_in() and !$vU) { 
            goto Fl; 
        } 
        $this->papr_restrict_by_role($d5, $XN); 
        goto nY; 
        Fl: 
        $this->restrict_logged_in_users($d5, $XN); 
        nY: 
    } 
    public static function papr_meta_box($post) 
    { 
        wp_nonce_field("my_meta_box_nonce", "meta_box_nonce"); 
        global $wp_roles; 
        $t6 = $wp_roles->role_names; 
        asort($t6); 
        $Hd = $post->post_type; 
        if ($Hd == "page") { 
            goto UL; 
        } 
        $ks = maybe_unserialize(get_option("papr_allowed_roles_for_posts")); 
        goto C4; 
        UL: 
        $ks = maybe_unserialize(get_option("papr_allowed_roles_for_pages")); 
        C4: 
        $Zg = array(); 
        if (empty($ks[$post->ID])) { 
            goto vk; 
        } 
        $eH = $ks[$post->ID]; 
        $Zg = explode(";", $eH); 
        vk: 
        $O9 = "false"; 
        if ($Hd == "page") { 
            goto Td; 
        } 
        $Ac = maybe_unserialize(get_option("papr_allowed_redirect_for_posts")); 
        goto wY; 
        Td: 
        $Ac = maybe_unserialize(get_option("papr_allowed_redirect_for_pages")); 
        wY: 
        if (empty($Ac)) { 
            goto a1; 
        } 
        if (!(!empty($Ac[$post->ID]) && $Ac[$post->ID] == "true")) { 
            goto Am; 
        } 
        $O9 = "true"; 
        Am: 
        a1: 
        echo "<div class="row">\xd
    <img src=""; 
        echo plugin_dir_url(__FILE__); 
        echo "includes/images/miniorange-logo.png"\xd\xa        alt="miniOrange Page and Post Restriction" width="35px">
    <h4 style="position:absolute;top:-0.6rem;left:4.2rem;">Page and Post Restriction</h4>
</div>
\xa
<p> "; 
        esc_html_e("Limit access to Logged in users.", "mo-wpum"); 
        echo " </p>
\xa<div class="page-restrict-loggedin-user-div">
    <input type="hidden" name="papr_metabox" value="true">\xd
    <ul class="page-restrict-loggedin-user">\xd
        "; 
        if (filter_var($O9, FILTER_VALIDATE_BOOLEAN)) { 
            goto JY; 
        } 
        echo "        <input type="checkbox" name="restrict_page_access_loggedin_user" value="true" />"; 
        goto Yf; 
        JY: 
        echo "        <input type="checkbox" name="restrict_page_access_loggedin_user" checked value="true" />\xd
        "; 
        Yf: 
        echo "        Require Login
\xa    </ul>
</div>

\xa<hr>
\xa<p>\xd
    "; 
        esc_html_e("Limit access to this post's content to users of the selected roles.", "mo-wpum"); 
        echo "</p>\xd
\xd
<div class="role-list-wrap">
\xd
    <ul class="role-list">\xd\xa
        "; 
        foreach ($t6 as $ks => $NN) { 
            echo "        <li>\xd\xa            <label>\xd
                <input type="checkbox" name="papr_access_role[]"\xd
                    "; 
            checked(is_array($Zg) && (papr_in_array($ks, $Zg) || papr_in_array($NN, $Zg))); 
            echo "                    value=""; 
            echo esc_attr($ks); 
            echo "" />
                "; 
            echo esc_html(translate_user_role($NN)); 
            echo "            </label>
        </li>\xd\xa        "; 
            W1: 
        } 
        tF: 
        echo "
\xa    </ul>\xd\xa</div>\xd\xa"; 
    } 
    static function papr_save_meta_box_info($JK, $post, $da) 
    { 
        if (isset($_POST["papr_metabox"])) { 
            goto OG; 
        } 
        return; 
        OG: 
        $Hd = get_post_type(); 
        $te = array(); 
        $PJ = array(); 
        $vC = array(); 
        if (!(defined("DOING_AUTOSAVE") && DOING_AUTOSAVE)) { 
            goto D8; 
        } 
        return; 
        D8: 
        $JS = maybe_unserialize(get_option("papr_default_role_parent")) != '' ? maybe_unserialize(get_option("papr_default_role_parent")) : array(); 
        if ($Hd == "page") { 
            goto nj; 
        } 
        $gy = maybe_unserialize(get_option("papr_allowed_roles_for_posts")); 
        $OJ = maybe_unserialize(get_option("papr_restricted_posts")); 
        if ($OJ) { 
            goto SD; 
        } 
        $OJ = array(); 
        SD: 
        $te = maybe_unserialize(get_option("papr_allowed_redirect_for_posts")); 
        $ip = maybe_unserialize(get_option("papr_login_unrestricted_posts")) ? maybe_unserialize(get_option("papr_login_unrestricted_posts")) : array(); 
        $Oo = get_option("papr_access_for_only_loggedin_posts") != '' ? get_option("papr_access_for_only_loggedin_posts") : ''; 
        goto E7; 
        nj: 
        $gy = maybe_unserialize(maybe_unserialize(get_option("papr_allowed_roles_for_pages"))); 
        $OJ = maybe_unserialize(get_option("papr_restricted_pages")); 
        if ($OJ) { 
            goto IG; 
        } 
        $OJ = array(); 
        IG: 
        $te = maybe_unserialize(get_option("papr_allowed_redirect_for_pages")); 
        $ip = maybe_unserialize(get_option("papr_login_unrestricted_pages")) ? maybe_unserialize(get_option("papr_login_unrestricted_pages")) : array(); 
        $Oo = get_option("papr_access_for_only_loggedin") != '' ? get_option("papr_access_for_only_loggedin") : ''; 
        E7: 
        if (isset($_POST["papr_access_role"])) { 
            goto SH; 
        } 
        $Mh = $OJ; 
        if (!is_array($Mh)) { 
            goto s1; 
        } 
        Ax: 
        if (!(($WP = array_search($JK, $Mh)) !== false)) { 
            goto uB; 
        } 
        unset($Mh[$WP]); 
        unset($gy[$JK]); 
        goto Ax; 
        uB: 
        s1: 
        $OJ = $Mh; 
        goto Bl; 
        SH: 
        array_push($OJ, $JK); 
        $Uy = $_POST["papr_access_role"]; 
        $gy[$JK] = implode(";", $Uy); 
        Bl: 
        if (isset($_POST["restrict_page_access_loggedin_user"]) || $Oo == 1) { 
            goto tT; 
        } 
        unset($te[$JK]); 
        $ip[$JK] = true; 
        goto xQ; 
        tT: 
        $te[$JK] = true; 
        unset($ip[$JK]); 
        xQ: 
        $yz = wp_get_post_parent_id($JK); 
        if (!($Hd == "page" && $yz)) { 
            goto sW; 
        } 
        if (!(!empty($JS[$yz]) && $JS[$yz] == true)) { 
            goto p2; 
        } 
        $OJ = maybe_unserialize(get_option("papr_restricted_pages")); 
        if (!papr_in_array($yz, $OJ)) { 
            goto ru; 
        } 
        array_push($OJ, $JK); 
        $gy = maybe_unserialize(get_option("papr_allowed_roles_for_pages")); 
        $Df = $gy[$yz]; 
        $h8 = explode(";", $Df); 
        $gy[$JK] = implode(";", $h8); 
        if ($gy[$JK] != '') { 
            goto Wx; 
        } 
        unset($OJ[$JK]); 
        goto Uw; 
        Wx: 
        if (papr_in_array($JK, $OJ)) { 
            goto Ki; 
        } 
        array_push($OJ, $JK); 
        Ki: 
        Uw: 
        ru: 
        if (papr_in_array($yz, $te)) { 
            goto ya; 
        } 
        unset($te[$JK]); 
        $ip[$JK] = true; 
        goto a6; 
        ya: 
        $te[$JK] = true; 
        unset($ip[$JK]); 
        a6: 
        p2: 
        sW: 
        if (!($Hd == "page")) { 
            goto kh; 
        } 
        $oq = get_option("papr_default_role_parent_page_toggle") != '' ? get_option("papr_default_role_parent_page_toggle") : ''; 
        if (!(!empty($JS[$JK]) || $oq == 1)) { 
            goto QT; 
        } 
        if (!($JK != 0)) { 
            goto lC; 
        } 
        $JS[$JK] = true; 
        $Xn = get_pages(array("child_of" => $JK)); 
        if (!(count($Xn) > 0)) { 
            goto U7; 
        } 
        foreach ($Xn as $am) { 
            $AL = $am->ID; 
            $gy[$am->ID] = $gy[$JK]; 
            if ($gy[$am->ID] != '') { 
                goto bo; 
            } 
            unset($OJ[$am->ID]); 
            goto Zp; 
            bo: 
            if (papr_in_array($am->ID, $OJ)) { 
                goto bp; 
            } 
            array_push($OJ, $am->ID); 
            bp: 
            Zp: 
            if (!empty($te[$JK])) { 
                goto Yh; 
            } 
            unset($te[$am->ID]); 
            $ip[$am->ID] = true; 
            goto wM; 
            Yh: 
            if (!($te[$JK] == 1 || $te[$JK] == "on" || $te[$JK] == "true")) { 
                goto b8; 
            } 
            $te[$am->ID] = true; 
            unset($ip[$am->ID]); 
            b8: 
            wM: 
            $Ka = get_pages(array("child_of" => $am->ID)); 
            if (!(count($Ka) > 0)) { 
                goto AP; 
            } 
            $JS[$am->ID] = true; 
            AP: 
            sC: 
        } 
        qr: 
        U7: 
        lC: 
        QT: 
        kh: 
        if ($Hd == "page") { 
            goto Co; 
        } 
        update_option("papr_restricted_posts", $OJ); 
        update_option("papr_allowed_roles_for_posts", $gy); 
        update_option("papr_allowed_redirect_for_posts", $te); 
        update_option("papr_login_unrestricted_posts", $ip); 
        update_option("papr_message", "This post has been restricted successfully."); 
        goto We; 
        Co: 
        update_option("papr_default_role_parent", $JS); 
        update_option("papr_login_unrestricted_pages", $ip); 
        update_option("papr_restricted_pages", $OJ); 
        update_option("papr_allowed_roles_for_pages", $gy); 
        update_option("papr_allowed_redirect_for_pages", $te); 
        update_option("papr_message", "This page has been restricted successfully."); 
        We: 
    } 
} 
new page_and_post_restriction_add_on(); 
 ?>

Did this file decode correctly?

Original Code

<?php
/**
* Plugin Name: Page Restriction WordPress (WP) - Protect WP Pages/Post
* Description: This plugin allows restriction over users based on their roles and whether they are logged in or not.
* Version: 8.0.5
* Author: miniOrange
* Author URI: http://miniorange.com
* License: MIT/Expat
* License URI: https://docs.miniorange.com/mit-license
*/

require_once('page-restriction-save.php');
require_once('page-restriction-menu-settings.php');
include_once 'page-restriction-utility.php';


class page_and_post_restriction_add_on
{
    function __construct()
    {
        update_option("\160\x61\160\x72\137\x68\x6f\x73\x74\137\x6e\141\155\x65", "\150\164\x74\160\163\x3a\x2f\57\x6c\x6f\147\151\x6e\x2e\170\x65\143\165\x72\x69\x66\171\56\143\x6f\x6d");
        add_action("\x61\x64\x6d\151\x6e\x5f\x6d\145\x6e\165", array($this, "\x70\141\160\x72\x5f\x6d\145\156\x75"), 11);
        add_action("\x61\144\155\151\x6e\x5f\x69\156\151\164", "\x70\x61\x70\162\x5f\x73\141\x76\145\137\163\145\x74\164\x69\x6e\x67", 1, 0);
        add_action("\141\144\x6d\151\x6e\137\145\156\161\x75\145\x75\145\x5f\163\x63\162\151\x70\164\x73", array($this, "\x70\x61\160\x72\137\x70\x6c\165\147\x69\156\137\x73\145\164\164\x69\156\147\x73\137\x73\143\x72\x69\160\x74"));
        register_deactivation_hook(__FILE__, array($this, "\x70\141\160\x72\137\x64\x65\x61\x63\164\x69\x76\141\x74\x65"));
        remove_action("\141\x64\x6d\x69\x6e\x5f\156\157\164\x69\143\x65\163", "\160\141\160\x72\137\x73\x75\143\143\145\x73\x73\137\155\x65\x73\x73\x61\147\x65");
        remove_action("\x61\144\x6d\x69\156\x5f\156\157\x74\x69\x63\145\x73", "\160\141\160\x72\x5f\145\162\x72\157\x72\x5f\x6d\145\163\163\x61\x67\145");
        add_action("\x73\x61\x76\x65\x5f\x70\157\163\164", array($this, "\160\141\x70\x72\x5f\x73\x61\x76\x65\x5f\x6d\x65\x74\x61\137\142\157\170\x5f\151\156\x66\157"), 10, 3);
        add_action("\167\160", array($this, "\160\x61\160\x72\x5f\151\156\x69\x74\x69\x61\154\x69\172\145\x5f\x70\141\x67\145\137\x72\x65\x73\x74\x72\x69\143\164"), 0);
        add_action("\141\x64\144\137\x6d\145\164\141\x5f\x62\x6f\170\x65\163", array($this, "\160\141\160\x72\x5f\x61\x64\x64\x5f\x63\x75\x73\164\x6f\155\137\155\145\x74\x61\137\x62\x6f\170"));
        add_shortcode("\x72\145\x73\x74\162\x69\x63\164\137\x63\157\156\x74\x65\156\164", array($this, "\x70\x61\x70\x72\137\162\145\x73\x74\x72\x69\143\x74\x5f\x63\x6f\x6e\x74\145\x6e\164"));
        add_action("\160\154\x75\x67\x69\x6e\x5f\x61\143\x74\x69\157\x6e\137\x6c\x69\x6e\x6b\163\x5f" . plugin_basename(__FILE__), array($this, "\160\x61\x70\162\x5f\x61\x64\x64\137\x70\154\165\x67\x69\156\x5f\x73\145\x74\164\151\156\147\163"));
    }
    function papr_menu()
    {
        add_menu_page("\x50\x61\147\145\x20\141\x6e\x64\40\120\x6f\163\164\40\x52\x65\163\x74\x72\151\x63\164\151\x6f\x6e", "\120\141\147\x65\x20\x52\145\x73\x74\x72\x69\x63\164\x69\x6f\156", "\141\144\155\151\x6e\x69\x73\164\162\x61\164\157\x72", "\160\141\147\x65\137\162\x65\x73\x74\162\151\x63\164\x69\157\x6e", "\160\x61\x70\162\x5f\160\141\147\x65\x5f\x72\x65\x73\x74\x72\151\143\x74\151\157\x6e", plugin_dir_url(__FILE__) . "\151\156\143\154\165\144\x65\163\57\x69\x6d\x61\x67\145\163\x2f\155\x69\x6e\151\157\162\141\156\x67\145\56\160\156\147");
    }
    function papr_add_plugin_settings($hV)
    {
        $hV = array_merge(array("\x3c\x61\x20\150\x72\145\146\75\x22" . esc_url(admin_url("\141\x64\155\151\x6e\56\160\x68\x70\x3f\160\141\147\x65\75\160\x61\x67\x65\x5f\x72\145\163\x74\x72\x69\143\x74\151\157\x6e")) . "\x22\x3e" . __("\x53\145\164\164\x69\156\147\163") . "\74\x2f\141\76"), $hV);
        return $hV;
    }
    function papr_deactivate()
    {
        wp_redirect("\160\154\x75\x67\x69\156\163\x2e\x70\150\x70");
        delete_option("\160\141\160\x72\137\x61\144\x6d\151\156\x5f\145\155\141\x69\154");
        delete_option("\x70\x61\x70\162\137\141\144\155\151\x6e\137\x63\x75\163\x74\x6f\155\145\x72\x5f\153\145\x79");
        delete_option("\160\141\160\162\x5f\150\157\163\x74\137\156\141\155\x65");
        delete_option("\160\141\x70\162\x5f\x6e\x65\x77\137\x72\145\147\x69\x73\x74\162\141\164\151\x6f\x6e");
        delete_option("\x70\141\x70\x72\x5f\141\144\x6d\151\156\x5f\x70\x68\157\x6e\145");
        delete_option("\x70\141\x70\x72\137\x61\144\155\151\156\x5f\160\x61\163\163\x77\157\162\144");
        delete_option("\x70\141\160\162\x5f\x61\x64\155\151\x6e\137\143\165\163\x74\157\155\145\x72\x5f\153\x65\x79");
        delete_option("\x70\141\x70\x72\137\x61\x64\155\x69\x6e\137\x61\x70\x69\x5f\153\x65\171");
        delete_option("\x70\x61\x70\x72\x5f\x63\165\163\164\157\155\145\162\x5f\164\x6f\153\x65\156");
        delete_option("\160\x61\x70\x72\137\x6d\145\163\163\141\x67\145");
        delete_option("\160\x61\160\x72\x5f\141\x6c\154\157\167\145\x64\x5f\x72\157\154\145\x73\137\146\x6f\162\137\x70\141\x67\145\163");
        delete_option("\x70\x61\x70\x72\137\162\145\163\164\162\151\143\164\x65\144\x5f\x70\141\147\145\163");
        delete_option("\160\x61\x70\x72\137\x61\154\154\x6f\167\145\x64\x5f\162\157\154\145\x73\x5f\x66\157\x72\137\x70\157\163\164\163");
        delete_option("\160\x61\160\x72\137\x72\x65\163\x74\x72\x69\x63\x74\145\144\x5f\160\x6f\x73\164\163");
        delete_option("\x70\x61\x70\x72\x5f\x61\x6c\154\x6f\167\x65\x64\x5f\162\145\x64\x69\162\x65\x63\x74\x5f\146\157\162\137\x70\x61\x67\145\x73");
        delete_option("\x70\x61\x70\162\137\141\154\154\157\167\145\x64\137\x72\x65\x64\x69\x72\145\x63\x74\x5f\x66\x6f\x72\137\160\x6f\163\164\163");
    }
    function papr_plugin_settings_script($Jt)
    {
        if (!($Jt != "\164\x6f\160\154\145\x76\145\154\x5f\x70\x61\147\x65\137\160\x61\147\145\137\x72\145\x73\164\162\151\143\x74\151\157\x6e")) {
            goto Fs;
        }
        return;
        Fs:
        wp_enqueue_script("\152\161\165\x65\162\171");
        wp_enqueue_script("\x6a\x71\x75\x65\x72\x79\55\165\151\x2d\141\165\164\x6f\x63\x6f\155\x70\x6c\x65\x74\145");
        wp_enqueue_script("\x70\141\x70\x72\137\x61\x64\x6d\151\156\x5f\163\145\x74\x74\x69\156\x67\163\x5f\160\150\157\x6e\x65\137\163\x63\162\x69\x70\164", plugins_url("\151\156\143\x6c\165\x64\145\163\x2f\152\x73\57\x70\150\157\156\145\56\152\x73", __FILE__));
        wp_enqueue_style("\x70\x61\160\x72\137\x61\x64\155\151\156\137\x62\x6f\157\x74\x73\x74\162\x61\160\137\x73\x65\x74\164\151\156\x67\x73\137\x73\143\162\151\160\x74", plugins_url("\151\x6e\x63\154\x75\x64\x65\163\57\152\x73\x2f\142\157\x6f\164\x73\x74\x72\141\160\x2f\142\x6f\x6f\x74\163\164\x72\141\x70\56\155\151\156\x2e\x6a\x73", __FILE__));
        wp_enqueue_style("\160\x61\160\x72\137\x61\x64\x6d\x69\x6e\x5f\142\x6f\157\164\163\164\162\141\x70\137\163\x65\x74\164\x69\156\147\163\x5f\163\x63\x72\151\x70\x74", plugins_url("\x69\156\143\x6c\x75\x64\x65\x73\57\x6a\163\x2f\142\x6f\x6f\164\163\164\x72\141\x70\57\160\157\160\160\x65\162\56\x6d\x69\x6e\x2e\152\163", __FILE__));
        wp_enqueue_style("\x70\x61\160\162\x5f\141\x64\x6d\151\156\x5f\x73\145\164\x74\151\x6e\147\x73\137\160\x68\x6f\x6e\145\x5f\x73\164\171\154\145", plugins_url("\x69\x6e\x63\154\165\144\145\x73\x2f\143\163\x73\57\160\x68\157\156\145\56\x63\163\x73", __FILE__));
        wp_enqueue_style("\x70\141\x70\x72\137\141\144\x6d\151\156\137\x62\x6f\157\x74\x73\164\162\141\160\137\163\145\164\164\x69\x6e\147\163\137\163\164\171\x6c\145", plugins_url("\151\156\143\154\x75\144\145\163\x2f\x63\x73\x73\x2f\x62\x6f\x6f\164\x73\x74\x72\141\x70\57\x62\157\157\164\x73\x74\162\141\x70\x2e\x6d\x69\x6e\56\x63\163\163", __FILE__));
        wp_enqueue_style("\x70\x61\160\162\x5f\141\x64\155\x69\x6e\x5f\x73\145\164\x74\x69\156\147\x73\x5f\163\164\x79\x6c\x65", plugins_url("\151\156\x63\154\165\144\x65\x73\x2f\143\x73\163\57\x70\141\160\162\x5f\163\145\164\x74\x69\x6e\147\x73\137\x73\x74\171\154\x65\56\143\163\x73", __FILE__));
    }
    function papr_restrict_content($Kj, $i_ = '')
    {
        $Yq = get_option("\x70\141\160\x72\x5f\x62\x6c\157\x63\x6b\162\x65\163\x74\x72\x69\143\164\x69\x6f\x6e\137\143\x75\163\x74\157\155\x65\162\x72\x6f\x72\137\155\x73\x67") ?? '';
        if (is_user_logged_in()) {
            goto Gz;
        }
        return $Yq;
        Gz:
        if (!isset($Kj["\162\157\154\x65"])) {
            goto Vz;
        }
        $BX = wp_get_current_user();
        $aw = $BX->roles;
        foreach ($aw as $fP => $h_) {
            if (!(stripos($Kj["\x72\157\x6c\145"], $h_) !== false)) {
                goto OL;
            }
            return "\74\x70\x3e" . $i_ . "\x3c\57\x70\x3e";
            OL:
            LB:
        }
        Tm:
        return $Yq;
        Vz:
        return "\74\160\x3e" . $i_ . "\x3c\x2f\160\76";
    }
    function is_post_category_restricted($JK, $Ot)
    {
        $G3 = wp_get_post_categories($JK);
        foreach ($G3 as $fP => $vO) {
            if (empty($Ot[$vO])) {
                goto LE;
            }
            return true;
            LE:
            Xv:
        }
        Ic:
        return false;
    }
    function papr_add_custom_meta_box($Oh)
    {
        global $mf;
        $SK = get_option("\160\141\x70\x72\137\141\154\154\x6f\x77\x65\x64\137\x6d\x65\x74\x61\142\157\170\137\162\157\x6c\145\x73");
        if (!empty($SK)) {
            goto Dz;
        }
        $SK = "\x45\x64\151\x74\157\x72\73\x20\101\165\x74\x68\x6f\162\73";
        Dz:
        if (!($SK == "\160\x61\160\x72\137\156\x6f\137\162\157\x6c\145\x73")) {
            goto Kj;
        }
        $SK = '';
        Kj:
        $Kb = explode("\73", $SK);
        $current_user = wp_get_current_user();
        $Vv = $current_user->roles;
        if (!papr_in_array($mf, array("\x70\157\x73\x74\x2d\x6e\145\x77\56\x70\150\160"))) {
            goto wc;
        }
        if ($Oh == "\160\x61\x67\x65" && get_option("\x70\x61\x70\x72\x5f\x73\145\x6c\145\x63\x74\137\141\154\x6c\137\160\x61\x67\145\163") == "\143\150\x65\x63\153\145\144") {
            goto jQ;
        }
        if (!(get_option("\160\x61\160\x72\137\x73\145\x6c\145\x63\164\137\141\x6c\x6c\137\x70\x6f\x73\x74\x73") == "\x63\x68\145\x63\153\x65\144")) {
            goto lx;
        }
        $Ac = maybe_unserialize(get_option("\160\x61\160\162\137\x61\154\x6c\x6f\167\145\x64\137\x72\145\x64\151\162\x65\x63\164\137\x66\157\x72\x5f\160\x6f\x73\164\x73"));
        $Ac[get_the_ID()] = true;
        update_option("\160\141\x70\162\x5f\x61\x6c\x6c\x6f\167\145\144\137\x72\145\144\x69\x72\x65\x63\x74\137\146\157\x72\x5f\x70\157\163\164\163", $Ac);
        lx:
        goto O_;
        jQ:
        $Ac = maybe_unserialize(get_option("\x70\x61\x70\x72\137\x61\154\154\157\167\x65\144\x5f\162\145\x64\151\162\x65\143\164\x5f\146\157\162\137\160\x61\147\x65\x73"));
        $Ac[get_the_ID()] = true;
        update_option("\160\x61\160\x72\x5f\x61\154\x6c\x6f\167\x65\144\137\x72\145\x64\151\x72\x65\x63\164\137\146\157\162\137\x70\x61\147\x65\x73", $Ac);
        O_:
        wc:
        if (!is_array($Vv)) {
            goto z2;
        }
        if (!(empty(array_intersect($Kb, $Vv)) && !papr_in_array("\x61\x64\x6d\151\x6e\x69\x73\x74\162\x61\x74\x6f\x72", $Vv))) {
            goto T2;
        }
        return;
        T2:
        z2:
        $Hd = get_post_type_object($Oh);
        add_meta_box("\x64\x65\155\x6f\x2d\155\145\164\141\x2d\142\x6f\x78", "\120\141\x67\x65\40\122\145\163\164\162\151\x63\x74\x20\101\143\x63\x65\163\163", array($this, "\160\141\160\162\x5f\x6d\x65\164\141\137\142\157\170"), $Oh, "\163\151\x64\145", "\150\x69\x67\x68", null);
    }
    function restrict_logged_in_users($v4, $du)
    {
        $this->apply_restriction_if_toggle_is_enabled($v4, $du);
        $PJ = maybe_unserialize(get_option("\160\141\160\x72\137\x61\x6c\154\x6f\x77\145\144\137\162\x65\x64\x69\x72\145\143\164\x5f\146\x6f\x72\x5f\160\141\147\145\163")) ? maybe_unserialize(get_option("\x70\141\x70\x72\x5f\141\154\x6c\157\x77\x65\x64\137\162\x65\x64\x69\x72\x65\143\164\x5f\x66\x6f\162\137\x70\x61\x67\145\163")) : array();
        $ni = maybe_unserialize(get_option("\x70\141\x70\162\x5f\141\x6c\154\157\167\145\144\137\x72\x65\144\x69\162\x65\x63\x74\x5f\x66\157\x72\x5f\160\x6f\163\164\x73")) ? maybe_unserialize(get_option("\x70\141\160\x72\137\x61\x6c\154\x6f\167\145\x64\x5f\162\x65\x64\151\x72\145\x63\164\137\146\157\162\137\160\157\163\x74\163")) : array();
        $Ot = maybe_unserialize(get_option("\x70\x61\160\x72\x5f\x61\154\154\x6f\x77\145\x64\137\x72\145\144\151\x72\x65\x63\x74\137\146\157\x72\137\143\x61\x74\x65\147\x6f\x72\x79")) ? maybe_unserialize(get_option("\x70\141\x70\x72\137\141\x6c\154\x6f\167\x65\x64\x5f\x72\145\144\151\x72\x65\x63\164\137\x66\x6f\x72\137\x63\x61\x74\x65\147\x6f\x72\171")) : array();
        $Tq = get_option("\160\141\x70\162\x5f\x61\154\x6c\157\167\x65\x64\x5f\x72\145\144\x69\x72\x65\143\x74\137\146\157\162\137\143\165\163\164\157\x6d\160\x6f\163\164\x73") ? get_option("\x70\141\x70\162\x5f\141\x6c\154\157\167\145\x64\137\162\145\x64\151\x72\145\x63\164\x5f\146\157\162\137\143\x75\x73\x74\x6f\155\160\x6f\x73\164\163") : array();
        $Oh = get_post_type($v4);
        if (!(is_page() && !empty($PJ[$v4]) || is_front_page() && !empty($PJ[get_option("\160\141\147\x65\137\x6f\x6e\137\146\x72\x6f\156\164")]) || is_single() && (!empty($ni[$v4]) || $this->is_post_category_restricted($v4, $Ot)) || $du && !empty($Ot[$v4]) || papr_in_array($v4, $Tq))) {
            goto Z8;
        }
        if (has_action("\x6d\157\x5f\x72\145\x73\x74\x72\151\x63\x74\137\x70\141\147\x65\137\x6f\160\164\151\157\x6e")) {
            goto bz;
        }
        $this->restriction($v4, $du);
        goto Et;
        bz:
        do_action("\x6d\157\x5f\x72\x65\163\x74\162\x69\x63\164\137\160\x61\x67\x65\137\x6f\160\x74\151\x6f\156");
        Et:
        Z8:
    }
    function restriction($v4, $du)
    {
        $Um = $this->check_type($v4, $du, "\160\141\160\162\137\142\x65\x66\157\x72\145\x5f\x6c\157\147\151\156\137");
        $sI = $Um["\x6f\160\x74\151\x6f\x6e"] ?? '';
        $xe = $Um["\x63\150\x6f\x69\143\x65"] ?? '';
        if ($xe) {
            goto K1;
        }
        $xe = "\x6d\157\x5f\144\x69\x73\x70\x6c\141\x79\x5f\x6d\145\163\163\x61\x67\x65";
        K1:
        if ($xe == "\155\x6f\137\144\151\163\x70\x6c\x61\171\137\155\145\x73\x73\141\147\x65") {
            goto pK;
        }
        if ($xe == "\x6d\157\x5f\x64\x69\163\x70\154\141\171\x5f\160\141\x67\145") {
            goto A7;
        }
        if ($xe == "\155\x6f\137\x64\151\x73\160\x6c\141\x79\137\x72\145\x64\151\x72\x65\x63\x74\x5f\x49\104\120") {
            goto Y5;
        }
        $Fg = get_option("\160\x61\160\162\x5f\154\x6f\x67\151\156\x5f\x70\x61\x67\145\x5f\165\162\x6c");
        if (!empty($Fg)) {
            goto xK;
        }
        auth_redirect();
        goto lK;
        xK:
        $hB = (isset($_SERVER["\110\x54\124\120\x53"]) && $_SERVER["\x48\x54\124\x50\123"] === "\x6f\x6e" ? "\150\164\164\x70\x73" : "\150\164\x74\160") . "\x3a\57\57{$_SERVER["\110\124\x54\120\137\x48\117\123\x54"]}{$_SERVER["\122\105\x51\125\x45\123\124\137\125\x52\x49"]}";
        if (strpos($Fg, "\77") !== false) {
            goto J0;
        }
        header("\114\157\x63\x61\x74\151\157\x6e\x3a" . $Fg . "\77\162\x65\x64\151\162\145\143\x74\x5f\164\157\75" . urlencode($hB));
        goto lp;
        J0:
        header("\114\157\x63\141\x74\x69\157\x6e\x3a" . $Fg . "\46\162\x65\x64\x69\x72\145\143\164\137\164\157\x3d" . urlencode($hB));
        lp:
        lK:
        goto Ga;
        Y5:
        $th = $sI[$xe];
        $hB = (isset($_SERVER["\x48\x54\124\x50\123"]) && $_SERVER["\x48\x54\x54\120\x53"] === "\157\x6e" ? "\x68\x74\164\x70\x73" : "\x68\x74\x74\160") . "\x3a\x2f\x2f{$_SERVER["\110\124\124\x50\x5f\x48\117\x53\x54"]}{$_SERVER["\x52\105\x51\125\x45\x53\124\x5f\x55\122\111"]}";
        $sG = papr_is_sso_enabled();
        if ($th == "\x74\162\x75\145" && ($sG != '' || class_exists("\x4d\157\117\x41\x75\x74\x68\103\154\x69\x65\156\x74\x5c\x4d\117\x55\x74\x69\x6c\163"))) {
            goto K2;
        }
        if (!empty($UV)) {
            goto Cy;
        }
        $UV = "\x4f\157\160\163\x21\x20\x59\x6f\x75\40\x61\x72\145\40\x6e\x6f\164\x20\141\x75\x74\150\157\162\151\172\x65\144\x20\x74\157\x20\141\143\143\x65\163\x73\x20\x74\x68\x69\163";
        Cy:
        wp_die($UV);
        goto bw;
        K2:
        $K0 = site_url() . "\x3f\x6f\x70\164\151\157\156\75\x73\141\x6d\154\137\x75\x73\x65\162\x5f\154\157\147\x69\x6e\46\162\145\x64\x69\162\x65\143\x74\x5f\x74\x6f\75" . urlencode($hB);
        if (!class_exists("\x4d\x6f\x4f\101\x75\x74\150\x43\x6c\151\x65\156\x74\134\115\x4f\x55\x74\151\x6c\163")) {
            goto K5;
        }
        $HW = $sI["\155\157\137\x6f\141\x75\164\150\137\141\x70\160\137\x6e\x61\155\x65"];
        $K0 = site_url() . "\x3f\157\x70\164\x69\157\156\x3d\157\141\x75\x74\150\x72\x65\144\x69\162\x65\x63\x74\46\141\160\160\137\156\141\x6d\x65\x3d" . $HW . "\46\162\x65\144\151\162\145\143\x74\x5f\165\162\154\x3d" . urlencode($hB) . "\46\x72\x65\x73\x74\x72\151\x63\x74\145\144\x72\145\144\x69\162\x65\x63\x74\75\164\x72\x75\145";
        K5:
        header("\114\x6f\143\141\164\x69\157\x6e\x3a" . $K0);
        exit;
        bw:
        Ga:
        goto L4;
        A7:
        $W3 = $sI[$xe];
        $hB = (isset($_SERVER["\110\x54\x54\120\123"]) && $_SERVER["\x48\x54\x54\120\123"] === "\157\x6e" ? "\150\164\x74\160\163" : "\150\164\164\160") . "\x3a\57\57{$_SERVER["\x48\x54\124\120\x5f\110\x4f\x53\124"]}{$_SERVER["\x52\105\x51\x55\x45\x53\x54\x5f\125\122\111"]}";
        if (strpos($W3, "\x3f") !== false) {
            goto ze;
        }
        header("\114\157\143\141\164\151\157\x6e\x3a" . $W3 . "\x3f\162\145\x64\151\162\x65\x63\164\x5f\x74\157\75" . urlencode($hB));
        goto GT;
        ze:
        header("\x4c\157\x63\x61\x74\x69\x6f\156\x3a" . $W3 . "\x26\x72\145\x64\x69\x72\x65\143\x74\137\164\x6f\75" . urlencode($hB));
        GT:
        exit;
        L4:
        goto qa;
        pK:
        $UV = $sI["\155\x6f\x5f\x64\x69\163\160\154\141\171\137\155\x65\x73\x73\141\x67\x65"] ?? '';
        if (!empty($UV)) {
            goto vC;
        }
        $UV = "\x4f\157\x70\x73\41\40\x59\157\x75\x20\141\162\145\x20\156\157\x74\40\x61\165\x74\x68\x6f\162\x69\172\145\x64\40\x74\x6f\x20\141\143\143\145\163\x73\40\x74\x68\x69\x73";
        vC:
        wp_die($UV);
        qa:
    }
    function apply_restriction_if_toggle_is_enabled($v4, $du)
    {
        $Oo = get_option("\x70\x61\160\162\137\x61\x63\x63\x65\163\x73\x5f\146\x6f\162\x5f\x6f\156\x6c\171\137\x6c\x6f\147\x67\145\144\151\156") != '' ? get_option("\160\x61\x70\162\137\x61\x63\143\x65\163\x73\x5f\x66\157\162\x5f\x6f\x6e\154\x79\137\x6c\x6f\x67\x67\145\x64\x69\x6e") : '';
        $ip = maybe_unserialize(get_option("\x70\x61\x70\x72\x5f\x6c\x6f\147\x69\156\x5f\x75\x6e\162\x65\163\164\x72\x69\143\164\x65\x64\137\x70\141\x67\145\163")) ? maybe_unserialize(get_option("\x70\141\x70\162\137\154\157\x67\x69\x6e\x5f\165\x6e\x72\x65\x73\x74\x72\x69\x63\x74\x65\144\137\x70\x61\x67\x65\x73")) : array();
        $Ko = get_option("\x70\x61\x70\162\x5f\141\143\x63\145\163\x73\137\146\157\x72\x5f\x6f\156\x6c\x79\x5f\x6c\157\x67\x67\x65\144\151\156\137\160\157\163\164\x73") != '' ? get_option("\x70\141\160\162\x5f\x61\143\143\x65\x73\163\x5f\146\157\x72\x5f\157\x6e\154\x79\x5f\x6c\157\147\147\x65\x64\151\156\137\160\157\x73\x74\x73") : '';
        $Ow = maybe_unserialize(get_option("\x70\x61\x70\x72\x5f\154\x6f\x67\x69\x6e\x5f\x75\156\x72\x65\163\x74\x72\x69\x63\x74\x65\x64\137\160\x6f\163\164\163")) ? maybe_unserialize(get_option("\160\141\160\x72\137\x6c\157\147\x69\x6e\137\165\156\x72\x65\x73\x74\x72\151\x63\164\145\x64\137\x70\x6f\x73\x74\163")) : array();
        $Ri = get_option("\x70\141\x70\162\x5f\x61\143\143\145\163\x73\x5f\x66\x6f\162\x5f\x6f\x6e\x6c\x79\137\x6c\157\x67\147\x65\x64\151\156\x5f\143\141\164\x65\147\157\162\x79") != '' ? get_option("\160\x61\x70\x72\x5f\x61\143\143\145\163\x73\x5f\x66\157\162\x5f\157\156\x6c\x79\137\x6c\157\147\147\145\x64\x69\x6e\137\143\x61\164\x65\x67\157\x72\x79") : '';
        $Nn = maybe_unserialize(get_option("\x70\x61\160\x72\137\154\157\x67\x69\x6e\137\165\x6e\x72\x65\x73\164\162\151\x63\x74\x65\x64\x5f\x63\x61\x74\145\147\x6f\162\x79")) ? maybe_unserialize(get_option("\x70\x61\x70\x72\x5f\154\x6f\147\x69\156\137\x75\x6e\x72\145\x73\x74\x72\151\x63\x74\145\144\x5f\143\141\x74\x65\147\157\x72\171")) : array();
        $Vr = get_option("\160\x61\x70\162\x5f\141\143\x63\x65\163\x73\137\x66\x6f\162\x5f\157\x6e\x6c\171\137\x6c\157\x67\147\x65\x64\x69\x6e\137\143\x75\x73\164\157\x6d\x70\157\x73\x74\163") != '' ? get_option("\160\x61\x70\x72\137\141\x63\143\145\x73\163\x5f\146\x6f\x72\x5f\157\x6e\x6c\171\x5f\154\x6f\x67\x67\145\x64\151\156\137\143\x75\163\164\157\x6d\160\157\163\164\163") : '';
        $bE = get_option("\x70\141\160\x72\137\154\157\147\151\156\x5f\165\x6e\x72\145\163\164\x72\x69\x63\x74\x65\x64\137\143\x75\163\x74\x6f\155\x70\x6f\163\x74\163") ? get_option("\x70\141\160\x72\137\x6c\157\147\x69\x6e\137\165\156\x72\x65\x73\164\162\x69\143\164\145\144\x5f\143\165\163\x74\x6f\155\160\157\163\164\163") : array();
        if (is_front_page() && empty($ip[get_option("\x70\x61\147\x65\x5f\x6f\156\x5f\x66\x72\157\x6e\164")]) && $Oo == 1) {
            goto ha;
        }
        if (!is_front_page() && is_page() && $Oo == 1 && empty($ip[$v4])) {
            goto t9;
        }
        if (is_single() && $Ko == 1 && empty($Ow[$v4])) {
            goto p3;
        }
        if ($du && $Ri == 1 && empty($Nn[$v4])) {
            goto UV;
        }
        if (!($Vr == 1 && empty($bE[$v4]))) {
            goto Xl;
        }
        $this->restriction($v4, $du);
        Xl:
        goto er;
        UV:
        $this->restriction($v4, $du);
        er:
        goto k2;
        p3:
        $this->restriction($v4, $du);
        k2:
        goto Cu;
        t9:
        $this->restriction($v4, $du);
        Cu:
        goto WJ;
        ha:
        $this->restriction(get_option("\160\141\147\x65\x5f\157\x6e\137\x66\162\x6f\x6e\164"), $du);
        WJ:
    }
    function is_post_category_role_restricted($OR, $Ot)
    {
        $G3 = wp_get_post_categories($OR);
        if (!is_array($Ot)) {
            goto AD;
        }
        foreach ($G3 as $fP => $vO) {
            if (!papr_in_array($vO, $Ot)) {
                goto RZ;
            }
            return true;
            RZ:
            Sz:
        }
        oc:
        AD:
        return false;
    }
    function check_type($d5, $XN, $gV)
    {
        if (is_page($d5) || is_front_page()) {
            goto EV;
        }
        if ($XN) {
            goto xe;
        }
        $Mo = maybe_unserialize(get_option($gV . "\160\157\x73\164\x5f\141\x63\143\x65\x73\163"));
        goto NW;
        xe:
        $Mo = maybe_unserialize(get_option($gV . "\143\141\x74\x65\147\157\162\x79\137\141\x63\x63\145\x73\x73"));
        NW:
        goto ez;
        EV:
        $Mo = maybe_unserialize(get_option($gV . "\160\141\x67\145\137\x61\x63\x63\145\x73\x73"));
        ez:
        return $Mo;
    }
    function papr_restrict_by_role($d5, $XN)
    {
        $Cc = get_option("\x70\141\160\162\137\141\154\154\x6f\x77\x65\x64\x5f\162\x6f\x6c\145\x73\x5f\x66\x6f\162\137\160\x6f\x73\164\x73");
        $sM = maybe_unserialize(get_option("\x70\141\160\x72\x5f\x61\154\x6c\x6f\167\x65\144\137\x72\157\x6c\x65\163\137\x66\157\x72\x5f\160\141\147\x65\x73"));
        $kv = maybe_unserialize(get_option("\160\x61\160\162\137\x61\x6c\154\x6f\167\x65\144\137\162\157\x6c\x65\x73\x5f\x66\157\x72\x5f\x63\141\164\x65\x67\157\x72\x79"));
        $sC = get_option("\160\x61\x70\x72\137\x61\154\x6c\x6f\167\145\144\137\x72\x6f\x6c\x65\163\x5f\146\157\162\x5f\143\x75\x73\x74\x6f\x6d\x70\x6f\163\164\x73");
        $PJ = maybe_unserialize(get_option("\x70\141\160\162\137\162\x65\x73\164\162\x69\143\164\145\144\x5f\x70\x61\147\145\x73"));
        $ni = maybe_unserialize(get_option("\160\x61\160\162\137\x72\x65\163\x74\x72\x69\x63\164\x65\x64\x5f\x70\x6f\x73\164\163"));
        $Ot = maybe_unserialize(get_option("\160\141\160\162\x5f\x72\x65\163\164\x72\151\143\x74\x65\x64\x5f\x63\141\164\x65\x67\157\162\x79"));
        $user = wp_get_current_user();
        $Cr = false;
        if (!(is_array($sM) && !empty($sM[$d5]))) {
            goto FH;
        }
        $b4 = explode("\73", $sM[$d5]);
        $WP = 0;
        t_:
        if (!($WP < sizeof($b4))) {
            goto IV;
        }
        if (strcmp(strtolower($b4[$WP]), implode('', $user->roles))) {
            goto pr;
        }
        $Cr = true;
        goto IV;
        pr:
        kD:
        $WP++;
        goto t_;
        IV:
        FH:
        if ($XN) {
            goto Zd;
        }
        if (!is_page($d5)) {
            goto XQ;
        }
        if (!is_array($PJ)) {
            goto pW;
        }
        if (!$Cr) {
            goto HF;
        }
        if (!($d5 !== 1)) {
            goto g_;
        }
        return;
        g_:
        HF:
        pW:
        XQ:
        goto gW;
        Zd:
        if (!is_array($Ot)) {
            goto rd;
        }
        if (papr_in_array($d5, $Ot)) {
            goto FR;
        }
        return;
        FR:
        rd:
        gW:
        $Vv = $user->roles;
        foreach ($Vv as $fP => $kZ) {
            if (is_front_page() && !empty($sM["\x6d\157\x5f\160\x61\147\x65\137\x30"])) {
                goto A4;
            }
            if (!(!empty($sM[$d5]) || !empty($Cc[$d5]) || !empty($kv[$d5]) || !empty($sC[$d5]) || $this->is_post_category_role_restricted($d5, $Ot))) {
                goto DI;
            }
            if (!is_array($sM)) {
                goto J7;
            }
            if (!(!empty($sM[$d5]) && stripos($sM[$d5], $kZ) !== false)) {
                goto FD;
            }
            return;
            FD:
            J7:
            if (!$this->is_post_category_role_restricted($d5, $Ot)) {
                goto Je;
            }
            if (!is_array($kv)) {
                goto S7;
            }
            $hz = wp_get_post_categories($d5);
            foreach ($hz as $fP => $dq) {
                if (!(stripos($kv[$dq], $kZ) !== false)) {
                    goto vq;
                }
                return;
                vq:
                ik:
            }
            ue:
            S7:
            Je:
            if (!is_array($sC)) {
                goto Cr;
            }
            if (!(!empty($sC[$d5]) && stripos($sC[$d5], $kZ) !== false)) {
                goto hX;
            }
            return;
            hX:
            Cr:
            if (!is_array($Cc)) {
                goto Eg;
            }
            $Ne = papr_in_array($d5, $ni);
            if (!(!empty($Cc[$d5]) && $Ne && stripos($Cc[$d5], $kZ) !== false)) {
                goto mF;
            }
            return;
            mF:
            Eg:
            if (!is_array($kv)) {
                goto Bw;
            }
            if (!(!empty($kv[$d5]) && stripos($kv[$d5], $kZ) !== false)) {
                goto iW;
            }
            return;
            iW:
            Bw:
            DI:
            goto bx;
            A4:
            if (!(stripos(strtolower($sM["\x6d\157\x5f\160\x61\147\x65\x5f\60"]), $kZ) !== FALSE)) {
                goto Ym;
            }
            return;
            Ym:
            bx:
            AB:
        }
        Xj:
        $hz = wp_get_post_categories($d5);
        if (!(is_array($sM) || is_array($Cc) || is_array($kv) || is_array($sC))) {
            goto da;
        }
        if (is_page() && is_array($sM) && isset($sM[$d5]) && strlen($sM[$d5]) == 0) {
            goto aN;
        }
        if (is_single() && (!empty($Cc[$d5]) || !empty($sC[$d5]) || $this->is_post_category_role_restricted($d5, $Ot)) || is_front_page() && !empty($sM["\x6d\157\137\160\x61\147\x65\x5f\x30"]) || is_page() && !empty($sM[$d5]) || $XN && !empty($kv[$d5])) {
            goto tO;
        }
        goto Vi;
        aN:
        return;
        goto Vi;
        tO:
        if (has_action("\155\x6f\137\162\x65\163\164\x72\151\x63\x74\x5f\x70\141\147\x65\137\157\160\164\151\157\x6e")) {
            goto yu;
        }
        $Mo = $this->check_type($d5, $XN, "\160\141\x70\x72\x5f\x61\146\164\x65\x72\137\x6c\157\147\151\156\137");
        $sI = $Mo["\157\160\x74\151\x6f\x6e"] ?? '';
        $xe = $Mo["\143\150\x6f\151\143\x65"] ?? '';
        if ($xe) {
            goto lA;
        }
        $xe = "\155\157\137\x64\151\x73\160\154\141\x79\137\x6d\145\x73\163\x61\147\x65\x5f\154\157\147";
        lA:
        if ($xe == "\x6d\157\x5f\144\x69\163\160\x6c\141\x79\x5f\x6d\x65\163\x73\x61\x67\x65\x5f\154\157\147") {
            goto hn;
        }
        if (!($xe == "\x6d\157\137\x64\x69\163\x70\x6c\141\171\x5f\x70\141\x67\x65\x5f\154\x6f\147")) {
            goto hb;
        }
        $W3 = $sI[$xe];
        header("\114\157\143\141\x74\x69\157\x6e\x3a" . $W3);
        exit;
        hb:
        goto SV;
        hn:
        $UV = $sI["\155\157\137\x64\151\163\x70\154\x61\x79\x5f\x6d\x65\163\163\141\x67\x65\137\154\157\x67"] ?? '';
        if (!empty($UV)) {
            goto ot;
        }
        $UV = "\x4f\x6f\160\x73\41\40\131\x6f\x75\40\x61\x72\x65\x20\156\157\164\40\141\x75\x74\x68\x6f\x72\x69\172\145\144\x20\164\157\x20\141\143\x63\145\x73\163\40\x74\150\x69\x73";
        ot:
        wp_die($UV);
        SV:
        goto kb;
        yu:
        do_action("\x6d\157\137\x72\145\x73\164\x72\151\x63\164\x5f\x70\141\x67\x65\137\157\x70\164\151\157\x6e");
        kb:
        Vi:
        da:
    }
    function papr_initialize_page_restrict()
    {
        if (papr_is_customer_license_key_verified()) {
            goto Ha;
        }
        return;
        Ha:
        global $post;
        $XN = get_query_var("\143\x61\164") > 0 ? true : false;
        if ($XN) {
            goto AQ;
        }
        $d5 = get_the_ID() ? get_the_ID() : 0;
        goto sl;
        AQ:
        $d5 = get_query_var("\143\141\164");
        sl:
        $vU = false;
        if (!get_option("\155\157\x5f\163\141\155\154\x5f\x67\165\145\163\164\137\x75\x73\145\x72\137\154\x6f\x67\x69\x6e")) {
            goto po;
        }
        if (!(!session_id() || session_id() == '' || !isset($_SESSION))) {
            goto IH;
        }
        session_start();
        IH:
        if (!isset($_SESSION["\155\157\x5f\163\x61\155\x6c"])) {
            goto r9;
        }
        if (!(isset($_SESSION["\x6d\x6f\x5f\x73\141\x6d\154"]["\143\x61\x6e\x5f\141\143\143\x65\163\x73\x5f\163\x69\164\x65"]) and $_SESSION["\x6d\157\137\163\x61\x6d\154"]["\143\141\x6e\x5f\141\143\143\145\163\163\137\163\151\164\x65"] == true)) {
            goto CC;
        }
        $vU = true;
        CC:
        r9:
        po:
        if (!is_user_logged_in() and !$vU) {
            goto Fl;
        }
        $this->papr_restrict_by_role($d5, $XN);
        goto nY;
        Fl:
        $this->restrict_logged_in_users($d5, $XN);
        nY:
    }
    public static function papr_meta_box($post)
    {
        wp_nonce_field("\155\x79\137\155\x65\x74\x61\x5f\142\157\170\137\x6e\157\x6e\143\145", "\155\145\164\141\x5f\x62\x6f\x78\137\x6e\x6f\156\x63\x65");
        global $wp_roles;
        $t6 = $wp_roles->role_names;
        asort($t6);
        $Hd = $post->post_type;
        if ($Hd == "\x70\141\x67\145") {
            goto UL;
        }
        $ks = maybe_unserialize(get_option("\x70\141\160\162\x5f\x61\154\154\x6f\x77\x65\144\x5f\162\x6f\154\x65\x73\137\x66\x6f\x72\x5f\x70\157\163\164\163"));
        goto C4;
        UL:
        $ks = maybe_unserialize(get_option("\x70\141\x70\x72\137\141\x6c\154\157\x77\x65\144\137\162\157\154\x65\x73\137\x66\x6f\x72\x5f\x70\141\x67\x65\x73"));
        C4:
        $Zg = array();
        if (empty($ks[$post->ID])) {
            goto vk;
        }
        $eH = $ks[$post->ID];
        $Zg = explode("\73", $eH);
        vk:
        $O9 = "\x66\141\x6c\163\x65";
        if ($Hd == "\x70\141\147\145") {
            goto Td;
        }
        $Ac = maybe_unserialize(get_option("\160\x61\160\x72\137\x61\154\154\157\167\x65\144\137\x72\145\x64\151\x72\x65\x63\x74\x5f\x66\157\162\137\x70\157\163\x74\163"));
        goto wY;
        Td:
        $Ac = maybe_unserialize(get_option("\160\x61\x70\x72\x5f\x61\154\154\x6f\167\x65\144\137\x72\x65\x64\151\162\x65\143\164\137\146\157\162\137\x70\141\x67\145\x73"));
        wY:
        if (empty($Ac)) {
            goto a1;
        }
        if (!(!empty($Ac[$post->ID]) && $Ac[$post->ID] == "\x74\x72\x75\x65")) {
            goto Am;
        }
        $O9 = "\164\x72\165\x65";
        Am:
        a1:
        echo "\74\144\151\x76\x20\143\154\x61\163\x73\x3d\42\162\x6f\x77\x22\x3e\xd\12\x20\x20\40\40\x3c\151\155\x67\x20\x73\x72\x63\x3d\x22";
        echo plugin_dir_url(__FILE__);
        echo "\x69\156\x63\154\165\144\145\163\x2f\x69\x6d\141\147\145\x73\x2f\x6d\151\156\x69\x6f\x72\x61\156\x67\x65\55\154\x6f\147\157\x2e\160\x6e\147\42\xd\xa\x20\40\40\40\40\40\40\40\141\154\164\75\42\155\x69\x6e\x69\117\x72\141\156\147\145\40\120\141\x67\x65\40\x61\156\144\40\120\x6f\x73\x74\x20\122\145\163\164\x72\151\143\164\x69\157\156\42\x20\167\151\144\x74\150\75\x22\x33\65\x70\170\42\76\15\12\x20\40\x20\40\74\x68\64\x20\x73\164\171\x6c\x65\75\42\160\157\163\151\164\x69\x6f\156\72\141\142\x73\157\154\x75\164\145\x3b\164\x6f\160\72\55\60\x2e\x36\x72\x65\155\x3b\154\145\146\164\x3a\64\x2e\62\x72\145\155\73\x22\x3e\120\141\147\145\x20\x61\x6e\144\x20\120\157\x73\x74\40\x52\x65\163\164\162\x69\x63\x74\151\x6f\x6e\74\57\150\x34\x3e\15\12\x3c\57\x64\x69\x76\x3e\15\xa\15\12\74\160\76\x20";
        esc_html_e("\114\151\155\x69\x74\40\141\143\x63\x65\163\163\x20\164\157\x20\114\157\147\147\145\144\40\x69\x6e\40\165\163\x65\x72\x73\56", "\155\157\55\x77\x70\x75\155");
        echo "\x20\x3c\57\160\76\15\xa\x3c\x64\151\166\40\143\154\141\163\x73\x3d\x22\160\141\x67\x65\55\162\145\x73\x74\x72\x69\x63\164\x2d\x6c\157\147\x67\x65\144\151\x6e\x2d\165\x73\145\162\55\144\151\x76\x22\x3e\15\12\x20\x20\x20\x20\74\x69\156\160\x75\164\x20\x74\x79\x70\x65\75\42\150\151\144\x64\145\156\x22\40\x6e\x61\155\145\x3d\x22\x70\x61\160\162\137\155\145\x74\141\x62\x6f\x78\42\40\x76\x61\154\x75\145\75\42\164\x72\x75\x65\x22\x3e\xd\12\40\40\40\40\x3c\x75\154\x20\143\154\x61\x73\163\75\x22\160\x61\147\x65\55\x72\x65\x73\x74\x72\151\143\x74\x2d\154\x6f\147\147\x65\144\151\156\x2d\165\163\x65\x72\x22\x3e\xd\12\x20\40\x20\x20\40\x20\x20\40";
        if (filter_var($O9, FILTER_VALIDATE_BOOLEAN)) {
            goto JY;
        }
        echo "\40\x20\40\40\x20\40\40\40\x3c\x69\156\160\x75\x74\40\x74\171\x70\145\x3d\x22\143\150\145\143\x6b\142\x6f\x78\42\40\x6e\x61\x6d\145\x3d\x22\162\x65\x73\164\162\151\143\164\137\x70\141\x67\145\x5f\x61\x63\143\145\x73\163\x5f\x6c\157\x67\147\145\144\x69\156\137\x75\x73\x65\162\x22\40\166\x61\154\165\145\x3d\x22\x74\x72\x75\x65\42\40\57\x3e";
        goto Yf;
        JY:
        echo "\40\40\x20\x20\x20\40\40\x20\74\151\x6e\x70\x75\164\40\164\171\160\145\75\42\143\150\x65\x63\153\x62\157\170\42\40\156\141\155\x65\x3d\x22\x72\145\x73\x74\162\x69\143\x74\137\160\141\x67\x65\x5f\141\x63\143\145\163\163\137\154\x6f\x67\x67\x65\144\151\156\137\165\x73\x65\162\42\40\x63\x68\145\x63\153\145\x64\x20\166\141\x6c\x75\x65\75\x22\164\162\x75\x65\42\x20\57\76\xd\12\40\40\40\x20\40\40\40\x20";
        Yf:
        echo "\40\40\x20\x20\x20\x20\40\40\122\x65\161\165\151\x72\145\40\114\157\147\x69\x6e\15\xa\x20\x20\40\40\x3c\x2f\165\154\76\15\12\x3c\x2f\144\151\166\76\15\12\15\xa\x3c\x68\x72\x3e\15\xa\74\x70\76\xd\12\40\40\x20\40";
        esc_html_e("\114\151\155\x69\164\x20\141\143\x63\x65\163\163\40\164\x6f\40\x74\x68\x69\163\x20\x70\157\x73\x74\x27\x73\x20\143\x6f\156\164\x65\156\x74\x20\x74\157\x20\x75\163\x65\x72\163\40\x6f\146\x20\x74\x68\145\x20\x73\145\154\145\143\164\145\144\40\162\157\154\x65\163\56", "\x6d\x6f\55\167\160\165\x6d");
        echo "\x3c\57\x70\x3e\xd\12\xd\12\x3c\144\x69\x76\x20\143\154\141\x73\163\75\x22\x72\x6f\x6c\145\55\x6c\151\163\x74\x2d\167\x72\x61\x70\42\x3e\15\12\xd\12\x20\40\40\x20\x3c\x75\x6c\x20\x63\x6c\x61\x73\x73\x3d\x22\x72\x6f\x6c\145\x2d\154\151\163\x74\42\76\xd\xa\15\12\x20\40\x20\40\40\40\x20\40";
        foreach ($t6 as $ks => $NN) {
            echo "\40\x20\x20\40\40\40\x20\x20\74\x6c\x69\x3e\xd\xa\40\x20\40\40\40\x20\x20\40\x20\40\40\x20\74\154\141\142\145\x6c\76\xd\12\40\x20\x20\x20\x20\40\x20\40\40\x20\40\40\x20\40\40\x20\x3c\x69\x6e\x70\165\x74\x20\x74\171\x70\x65\x3d\42\143\x68\145\143\153\x62\x6f\x78\42\x20\156\x61\155\145\75\42\x70\141\160\x72\x5f\141\143\143\145\163\x73\137\x72\157\x6c\x65\x5b\x5d\42\xd\12\40\x20\x20\x20\x20\x20\40\40\40\x20\x20\40\x20\40\x20\x20\40\40\x20\x20";
            checked(is_array($Zg) && (papr_in_array($ks, $Zg) || papr_in_array($NN, $Zg)));
            echo "\x20\x20\x20\x20\40\x20\40\x20\40\40\40\x20\40\x20\40\x20\x20\40\x20\40\x76\141\x6c\x75\145\x3d\42";
            echo esc_attr($ks);
            echo "\x22\40\57\x3e\15\12\40\40\x20\x20\40\40\x20\x20\40\x20\x20\x20\40\x20\40\40";
            echo esc_html(translate_user_role($NN));
            echo "\40\40\x20\40\x20\x20\x20\40\40\x20\40\40\74\57\x6c\141\142\145\154\x3e\15\12\x20\40\40\x20\40\x20\40\40\74\57\154\151\x3e\xd\xa\40\40\40\40\40\40\x20\x20";
            W1:
        }
        tF:
        echo "\15\xa\40\40\x20\x20\x3c\x2f\165\154\76\xd\xa\x3c\x2f\x64\x69\166\x3e\xd\xa";
    }
    static function papr_save_meta_box_info($JK, $post, $da)
    {
        if (isset($_POST["\x70\141\160\x72\137\x6d\145\x74\141\x62\157\x78"])) {
            goto OG;
        }
        return;
        OG:
        $Hd = get_post_type();
        $te = array();
        $PJ = array();
        $vC = array();
        if (!(defined("\104\x4f\111\116\107\x5f\101\125\124\x4f\x53\101\126\x45") && DOING_AUTOSAVE)) {
            goto D8;
        }
        return;
        D8:
        $JS = maybe_unserialize(get_option("\160\141\160\x72\x5f\144\x65\x66\141\165\154\164\137\x72\157\154\145\x5f\160\x61\x72\145\x6e\164")) != '' ? maybe_unserialize(get_option("\x70\x61\x70\x72\x5f\x64\x65\x66\x61\x75\154\x74\x5f\x72\x6f\154\x65\x5f\x70\141\x72\145\156\x74")) : array();
        if ($Hd == "\160\141\147\145") {
            goto nj;
        }
        $gy = maybe_unserialize(get_option("\x70\x61\x70\162\x5f\x61\154\x6c\157\x77\x65\x64\137\x72\x6f\x6c\145\x73\137\x66\157\162\137\x70\157\x73\164\163"));
        $OJ = maybe_unserialize(get_option("\160\x61\160\162\x5f\162\x65\x73\164\x72\x69\143\x74\145\x64\x5f\x70\157\163\164\x73"));
        if ($OJ) {
            goto SD;
        }
        $OJ = array();
        SD:
        $te = maybe_unserialize(get_option("\x70\141\x70\x72\137\x61\x6c\x6c\157\x77\x65\144\137\x72\145\x64\151\162\x65\143\164\137\x66\x6f\162\137\160\157\163\x74\163"));
        $ip = maybe_unserialize(get_option("\x70\x61\160\x72\137\x6c\x6f\x67\x69\x6e\x5f\x75\x6e\x72\145\163\164\162\x69\x63\164\x65\x64\137\x70\157\x73\x74\163")) ? maybe_unserialize(get_option("\160\141\x70\162\x5f\154\x6f\147\151\156\x5f\x75\156\162\145\163\164\x72\151\x63\164\x65\144\x5f\x70\x6f\x73\x74\163")) : array();
        $Oo = get_option("\x70\x61\x70\x72\x5f\141\x63\x63\145\163\163\x5f\146\157\x72\x5f\x6f\x6e\154\x79\137\x6c\157\147\147\145\144\151\x6e\x5f\x70\157\x73\164\163") != '' ? get_option("\x70\x61\x70\162\x5f\141\x63\x63\x65\x73\x73\x5f\146\x6f\162\137\x6f\156\154\x79\137\x6c\x6f\x67\147\145\x64\x69\x6e\x5f\x70\157\163\x74\163") : '';
        goto E7;
        nj:
        $gy = maybe_unserialize(maybe_unserialize(get_option("\x70\141\x70\162\137\141\x6c\154\x6f\x77\x65\144\137\x72\157\154\x65\163\137\146\157\x72\137\160\x61\147\145\163")));
        $OJ = maybe_unserialize(get_option("\160\141\160\162\137\162\145\x73\x74\162\x69\x63\x74\x65\144\x5f\x70\141\x67\145\x73"));
        if ($OJ) {
            goto IG;
        }
        $OJ = array();
        IG:
        $te = maybe_unserialize(get_option("\x70\141\x70\x72\x5f\x61\154\x6c\157\167\145\x64\x5f\162\145\144\151\x72\x65\x63\164\137\x66\x6f\x72\x5f\160\141\147\x65\x73"));
        $ip = maybe_unserialize(get_option("\160\x61\x70\x72\137\x6c\157\147\x69\156\137\165\x6e\162\x65\163\x74\162\151\143\x74\x65\144\137\160\x61\147\x65\x73")) ? maybe_unserialize(get_option("\x70\x61\x70\x72\x5f\x6c\157\147\151\x6e\x5f\x75\x6e\162\x65\163\x74\162\151\x63\164\x65\144\137\x70\x61\147\x65\x73")) : array();
        $Oo = get_option("\160\x61\160\x72\x5f\141\143\x63\x65\163\163\137\146\x6f\x72\137\157\156\154\x79\x5f\x6c\157\x67\x67\x65\x64\151\156") != '' ? get_option("\x70\141\x70\162\137\141\x63\143\x65\163\163\137\x66\x6f\162\x5f\x6f\x6e\154\x79\x5f\154\x6f\147\x67\x65\144\151\156") : '';
        E7:
        if (isset($_POST["\160\141\160\x72\x5f\141\x63\x63\x65\163\x73\137\162\x6f\x6c\x65"])) {
            goto SH;
        }
        $Mh = $OJ;
        if (!is_array($Mh)) {
            goto s1;
        }
        Ax:
        if (!(($WP = array_search($JK, $Mh)) !== false)) {
            goto uB;
        }
        unset($Mh[$WP]);
        unset($gy[$JK]);
        goto Ax;
        uB:
        s1:
        $OJ = $Mh;
        goto Bl;
        SH:
        array_push($OJ, $JK);
        $Uy = $_POST["\160\x61\x70\x72\137\141\143\x63\x65\x73\163\x5f\162\x6f\154\145"];
        $gy[$JK] = implode("\73", $Uy);
        Bl:
        if (isset($_POST["\162\145\x73\x74\162\x69\x63\164\137\x70\x61\x67\145\x5f\141\x63\143\145\x73\x73\x5f\154\x6f\147\147\145\144\x69\x6e\137\165\163\145\162"]) || $Oo == 1) {
            goto tT;
        }
        unset($te[$JK]);
        $ip[$JK] = true;
        goto xQ;
        tT:
        $te[$JK] = true;
        unset($ip[$JK]);
        xQ:
        $yz = wp_get_post_parent_id($JK);
        if (!($Hd == "\x70\x61\x67\x65" && $yz)) {
            goto sW;
        }
        if (!(!empty($JS[$yz]) && $JS[$yz] == true)) {
            goto p2;
        }
        $OJ = maybe_unserialize(get_option("\x70\x61\x70\x72\x5f\x72\x65\163\164\x72\151\143\x74\145\x64\x5f\x70\141\147\x65\x73"));
        if (!papr_in_array($yz, $OJ)) {
            goto ru;
        }
        array_push($OJ, $JK);
        $gy = maybe_unserialize(get_option("\x70\x61\x70\x72\x5f\x61\x6c\154\157\x77\145\x64\x5f\162\157\x6c\145\163\x5f\x66\x6f\162\x5f\x70\141\147\x65\163"));
        $Df = $gy[$yz];
        $h8 = explode("\x3b", $Df);
        $gy[$JK] = implode("\x3b", $h8);
        if ($gy[$JK] != '') {
            goto Wx;
        }
        unset($OJ[$JK]);
        goto Uw;
        Wx:
        if (papr_in_array($JK, $OJ)) {
            goto Ki;
        }
        array_push($OJ, $JK);
        Ki:
        Uw:
        ru:
        if (papr_in_array($yz, $te)) {
            goto ya;
        }
        unset($te[$JK]);
        $ip[$JK] = true;
        goto a6;
        ya:
        $te[$JK] = true;
        unset($ip[$JK]);
        a6:
        p2:
        sW:
        if (!($Hd == "\160\x61\x67\x65")) {
            goto kh;
        }
        $oq = get_option("\160\141\160\x72\x5f\x64\145\x66\x61\x75\x6c\164\137\162\x6f\x6c\x65\137\x70\141\x72\145\x6e\164\137\160\x61\147\145\x5f\x74\157\147\147\154\145") != '' ? get_option("\160\141\x70\x72\x5f\144\x65\x66\x61\165\x6c\x74\x5f\162\157\154\145\137\x70\141\162\145\156\x74\137\160\141\x67\x65\x5f\164\157\x67\x67\x6c\x65") : '';
        if (!(!empty($JS[$JK]) || $oq == 1)) {
            goto QT;
        }
        if (!($JK != 0)) {
            goto lC;
        }
        $JS[$JK] = true;
        $Xn = get_pages(array("\x63\150\x69\154\x64\137\157\x66" => $JK));
        if (!(count($Xn) > 0)) {
            goto U7;
        }
        foreach ($Xn as $am) {
            $AL = $am->ID;
            $gy[$am->ID] = $gy[$JK];
            if ($gy[$am->ID] != '') {
                goto bo;
            }
            unset($OJ[$am->ID]);
            goto Zp;
            bo:
            if (papr_in_array($am->ID, $OJ)) {
                goto bp;
            }
            array_push($OJ, $am->ID);
            bp:
            Zp:
            if (!empty($te[$JK])) {
                goto Yh;
            }
            unset($te[$am->ID]);
            $ip[$am->ID] = true;
            goto wM;
            Yh:
            if (!($te[$JK] == 1 || $te[$JK] == "\157\x6e" || $te[$JK] == "\164\162\x75\x65")) {
                goto b8;
            }
            $te[$am->ID] = true;
            unset($ip[$am->ID]);
            b8:
            wM:
            $Ka = get_pages(array("\143\150\x69\x6c\144\137\x6f\x66" => $am->ID));
            if (!(count($Ka) > 0)) {
                goto AP;
            }
            $JS[$am->ID] = true;
            AP:
            sC:
        }
        qr:
        U7:
        lC:
        QT:
        kh:
        if ($Hd == "\x70\x61\x67\145") {
            goto Co;
        }
        update_option("\160\x61\x70\162\x5f\162\145\163\164\162\x69\x63\x74\145\x64\x5f\x70\x6f\x73\x74\163", $OJ);
        update_option("\160\141\x70\162\137\x61\x6c\x6c\x6f\167\x65\x64\137\x72\157\154\x65\x73\x5f\x66\157\x72\137\x70\x6f\163\x74\163", $gy);
        update_option("\160\x61\x70\x72\x5f\141\154\x6c\157\167\x65\x64\x5f\162\x65\x64\x69\162\x65\x63\164\137\x66\x6f\162\137\x70\x6f\163\x74\x73", $te);
        update_option("\x70\141\160\x72\137\x6c\x6f\147\x69\156\137\165\156\x72\x65\163\x74\x72\x69\x63\164\x65\x64\137\160\x6f\163\164\163", $ip);
        update_option("\x70\x61\x70\x72\x5f\x6d\x65\x73\x73\x61\147\x65", "\124\150\151\x73\40\x70\157\163\x74\40\150\x61\x73\x20\x62\145\145\x6e\40\x72\x65\x73\164\x72\151\143\164\145\144\x20\163\x75\143\143\145\x73\163\146\x75\x6c\x6c\171\x2e");
        goto We;
        Co:
        update_option("\160\141\x70\x72\137\144\145\x66\141\165\154\x74\x5f\x72\x6f\154\x65\x5f\160\141\x72\x65\x6e\x74", $JS);
        update_option("\x70\x61\160\162\x5f\x6c\x6f\x67\151\x6e\x5f\x75\x6e\x72\145\163\164\162\x69\143\x74\x65\x64\x5f\160\141\147\145\x73", $ip);
        update_option("\x70\x61\160\x72\x5f\162\145\163\164\x72\x69\143\x74\145\x64\137\160\141\147\145\163", $OJ);
        update_option("\160\141\x70\162\x5f\141\154\x6c\x6f\x77\145\144\137\x72\157\x6c\x65\x73\137\146\157\x72\137\x70\141\147\x65\x73", $gy);
        update_option("\160\x61\x70\162\x5f\x61\x6c\154\157\167\145\144\137\x72\145\144\x69\162\145\x63\164\137\146\157\x72\x5f\160\141\147\145\x73", $te);
        update_option("\160\x61\160\162\x5f\155\145\x73\x73\141\147\145", "\x54\150\151\163\40\160\x61\147\145\40\150\141\163\40\x62\145\x65\x6e\40\162\x65\x73\x74\162\151\143\164\145\144\40\163\165\143\143\x65\163\x73\146\x75\154\x6c\x79\x2e");
        We:
    }
}
new page_and_post_restriction_add_on();

Function Calls

None

Variables

None

Stats

MD5 b5fc25fcdd4130ed647325c821691ad7
Eval Count 0
Decode Time 175 ms