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 /** * This file is a part of the miniorange-saml-20-single-sign-on plugin. * ..
Decoded Output download
<?php
/**
* This file is a part of the miniorange-saml-20-single-sign-on plugin.
*
* @link https://plugins.miniorange.com/
* @author miniOrange
* @package miniorange-saml-20-single-sign-on
*/
/**
* Plugin Name: miniOrange SSO using SAML 2.0
* Plugin URI: https://miniorange.com/
* Description: (Standard)miniOrange SAML 2.0 SSO enables user to perform Single Sign On with any SAML 2.0 enabled Identity Provider.
* Version: 16.1.4
* Author: miniOrange
* Author URI: https://miniorange.com/
*/
define("MO_SAML_PLUGIN_DIR", dirname(__FILE__));
define("MO_SAML_OPTIONS_ENUM", "/includes/lib/mo-options-enum.php");
require_once MO_SAML_PLUGIN_DIR . MO_SAML_OPTIONS_ENUM;
require_once Mo_Saml_Plugin_Files::MO_SAML_SSO_WIDGET;
require_once Mo_Saml_Plugin_Files::MO_SAML_LICENSE_LIB_AUTOLOADER;
require_once Mo_Saml_Plugin_Files::MO_SAML_XML_SEC_LIBS;
use MOSAML\LicenseLibrary\Classes\Mo_License_Library;
use RobRichards\XMLSecLibs\XMLSecurityKey;
use RobRichards\XMLSecLibs\XMLSecurityDSig;
use MOSAML\LicenseLibrary\Mo_License_Service;
use RobRichards\XMLSecLibs\XMLSecEnc;
require_once Mo_Saml_Plugin_Files::MO_SAML_CLASS_CUSTOMER;
require_once Mo_Saml_Plugin_Files::MO_SAML_SETTINGS_PAGE;
require_once Mo_Saml_Plugin_Files::MO_SAML_METADATA_READER;
require_once Mo_Saml_Plugin_Files::MO_SAML_CERTIFICATE_UTILITY;
require_once Mo_Saml_Plugin_Files::MO_SAML_IMPORT_EXPORT;
require_once Mo_Saml_Plugin_Files::MO_SAML_PLUGIN_VERSION_UPDATE;
class saml_mo_login
{
function __construct()
{
new Mo_License_Library();
add_action("admin_menu", array($this, "miniorange_sso_menu"));
add_action("admin_init", array($this, "miniorange_login_widget_saml_save_settings"));
add_action("admin_enqueue_scripts", array($this, "plugin_settings_style"));
register_deactivation_hook(__FILE__, array($this, "mo_sso_saml_deactivate"));
add_action("admin_enqueue_scripts", array($this, "plugin_settings_script"));
remove_action("admin_notices", array($this, "mo_saml_success_message"));
remove_action("admin_notices", array($this, "mo_saml_error_message"));
add_action("wp_authenticate", array($this, "mo_saml_authenticate"));
add_action("wp", array($this, "mo_saml_auto_redirect"));
add_action("admin_init", "mo_saml_download");
add_action("login_form", array($this, "mo_saml_modify_login_form"));
add_shortcode("MO_SAML_FORM", array($this, "mo_get_saml_shortcode"));
add_action("admin_init", array($this, "default_certificate"));
register_activation_hook(__FILE__, array($this, "mo_saml_plugin_activate_actions"));
add_action("plugin_action_links_" . plugin_basename(__FILE__), array($this, "mo_saml_plugin_action_links"));
if (!Mo_License_Service::is_customer_license_valid(false, false)) {
goto DU;
}
add_action("widgets_init", "mo_saml_register_widget");
DU:
}
function default_certificate()
{
$kK = file_get_contents(plugin_dir_path(__FILE__) . "resources" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Public_Certificate);
$zo = file_get_contents(plugin_dir_path(__FILE__) . "resources" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Private_Key);
if (!(!get_option("mo_saml_current_cert") && !get_option("mo_saml_current_cert_private_key"))) {
goto av;
}
if (get_option("mo_saml_cert") && get_option("mo_saml_cert_private_key")) {
goto ma;
}
update_option("mo_saml_current_cert", $kK);
update_option("mo_saml_current_cert_private_key", $zo);
goto MJ;
ma:
update_option("mo_saml_current_cert", get_option("mo_saml_cert"));
update_option("mo_saml_current_cert_private_key", get_option("mo_saml_cert_private_key"));
MJ:
av:
}
function mo_login_widget_saml_options()
{
global $wpdb;
update_option("mo_saml_host_name", "https://login.xecurify.com");
$xU = get_option("mo_saml_host_name");
mo_register_saml_sso();
}
function mo_saml_plugin_activate_actions()
{
$this->keep_settings_intact();
$this->mo_saml_check_openssl();
}
function keep_settings_intact()
{
if (!("true" !== get_option(mo_options_enum_sso_login::KEEP_CONFIGURATION_INTACT))) {
goto nz;
}
update_option(mo_options_enum_sso_login::KEEP_CONFIGURATION_INTACT, "true");
nz:
}
function mo_saml_check_openssl()
{
if (mo_saml_is_extension_installed("openssl")) {
goto Di;
}
wp_die("PHP openssl extension is not installed or disabled,please enable it to activate the plugin.");
Di:
add_option("Activated_Plugin", "Plugin-Slug");
}
public function mo_sso_saml_deactivate()
{
Mo_License_Service::reset_license_values();
if (!is_multisite()) {
goto OI;
}
global $wpdb;
$hP = $wpdb->get_col("SELECT blog_id FROM {$wpdb->blogs}");
$B8 = get_current_blog_id();
do_action("mo_saml_flush_cache");
foreach ($hP as $blog_id) {
switch_to_blog($blog_id);
delete_option("mo_saml_host_name");
delete_option("mo_saml_new_registration");
delete_option("mo_saml_admin_phone");
delete_option("mo_saml_admin_password");
delete_option("mo_saml_verify_customer");
delete_option("mo_saml_admin_customer_key");
delete_option("mo_saml_admin_api_key");
delete_option("mo_saml_customer_token");
delete_option("mo_saml_message");
delete_option("mo_saml_registration_status");
delete_option("mo_saml_idp_config_complete");
delete_option("mo_saml_transactionId");
delete_option("vl_check_t");
delete_option("vl_check_s");
delete_option("mo_saml_cert");
delete_option("sml_lk");
delete_option("mo_saml_cert_private_key");
delete_option("mo_saml_enable_cloud_broker");
V0:
}
UR:
switch_to_blog($B8);
goto iD;
OI:
do_action("mo_saml_flush_cache");
delete_option("mo_saml_host_name");
delete_option("mo_saml_new_registration");
delete_option("mo_saml_admin_phone");
delete_option("mo_saml_admin_password");
delete_option("mo_saml_verify_customer");
delete_option("mo_saml_admin_customer_key");
delete_option("mo_saml_admin_api_key");
delete_option("mo_saml_customer_token");
delete_option("mo_saml_message");
delete_option("mo_saml_registration_status");
delete_option("mo_saml_idp_config_complete");
delete_option("mo_saml_transactionId");
delete_option("vl_check_t");
delete_option("vl_check_s");
delete_option("mo_saml_cert");
delete_option("sml_lk");
delete_option("mo_saml_cert_private_key");
delete_option("mo_saml_enable_cloud_broker");
iD:
}
function plugin_settings_style($H_)
{
if (!("toplevel_page_mo_saml_settings" != $H_ && "miniorange-saml-2-0-sso_page_mo_error_codes" !== $H_)) {
goto uS;
}
return;
uS:
if (!(isset($_REQUEST["tab"]) && $_REQUEST["tab"] == "licensing")) {
goto hQ;
}
wp_enqueue_style("mo_saml_bootstrap_css", plugins_url("includes/css/bootstrap/bootstrap.min.css", __FILE__), array(), mo_options_plugin_constants::Version, "all");
hQ:
wp_enqueue_style("mo_saml_admin_settings_style_tracker", plugins_url("includes/css/progress-tracker.css", __FILE__), array(), mo_options_plugin_constants::Version, "all");
wp_enqueue_style("mo_saml_admin_settings_style", plugins_url("includes/css/style_settings.min.css", __FILE__), array(), mo_options_plugin_constants::Version, "all");
wp_enqueue_style("mo_saml_admin_settings_phone_style", plugins_url("includes/css/phone.min.css", __FILE__), array(), mo_options_plugin_constants::Version, "all");
wp_enqueue_style("mo_saml_wpb-fa", plugins_url("includes/css/font-awesome.min.css", __FILE__), array(), mo_options_plugin_constants::Version, "all");
}
function plugin_settings_script($H_)
{
if (!("toplevel_page_mo_saml_settings" != $H_)) {
goto t5;
}
return;
t5:
wp_enqueue_script("jquery");
wp_enqueue_script("mo_saml_admin_bootstrap_script", plugins_url("includes/js/bootstrap.js", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("mo_saml_admin_settings_script", plugins_url("includes/js/settings.min.js", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("mo_saml_admin_settings_phone_script", plugins_url("includes/js/phone.min.js", __FILE__), array(), mo_options_plugin_constants::Version, false);
if (!(isset($_REQUEST["tab"]) && $_REQUEST["tab"] == "licensing")) {
goto CQ;
}
wp_enqueue_script("mo_saml_modernizr_script", plugins_url("includes/js/modernizr.js", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("mo_saml_popover_script", plugins_url("includes/js/bootstrap/popper.min.js", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("mo_saml_bootstrap_script", plugins_url("includes/js/bootstrap/bootstrap.min.js", __FILE__), array(), mo_options_plugin_constants::Version, false);
CQ:
}
function mo_saml_activation_message()
{
$jW = "updated";
$dq = get_option("mo_saml_message");
echo "<div class='" . esc_attr($jW) . "'> <p>" . SAMLSPUtilities::mo_saml_kses_esc_message($dq) . "</p></div>";
}
static function mo_check_option_admin_referer($AH)
{
return isset($_POST["option"]) and $_POST["option"] == $AH and check_admin_referer($AH);
}
function miniorange_login_widget_saml_save_settings()
{
if (!current_user_can("manage_options")) {
goto RE;
}
if (!(is_admin() && get_option("Activated_Plugin") == "Plugin-Slug")) {
goto k3;
}
delete_option("Activated_Plugin");
update_option("mo_saml_message", "Go to plugin <b><a href="admin.php?page=mo_saml_settings">settings</a></b> to configure SAML Single Sign On by miniOrange.");
add_action("admin_notices", array($this, "mo_saml_activation_message"));
k3:
if (!(self::mo_check_option_admin_referer("login_widget_saml_save_settings") && Mo_License_Service::is_customer_license_valid())) {
goto cH;
}
if (mo_saml_is_extension_installed("curl")) {
goto K8;
}
update_option("mo_saml_message", "ERROR:PHP cURL extension is not installed or disabled. Save Identity Provider Configuration failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
K8:
$Nv = '';
$Hv = '';
$LO = '';
$nv = '';
$q2 = '';
$Fw = '';
$fK = '';
$Wx = '';
if ($this->mo_saml_check_empty_or_null($_POST["saml_identity_name"]) || $this->mo_saml_check_empty_or_null($_POST["saml_login_url"]) || $this->mo_saml_check_empty_or_null($_POST["saml_issuer"]) || $this->mo_saml_check_empty_or_null($_POST["saml_nameid_format"])) {
goto n9;
}
if (!preg_match("/^\w*$/", $_POST["saml_identity_name"])) {
goto iZ;
}
$Nv = sanitize_text_field(trim($_POST["saml_identity_name"]));
$LO = SAMLSPUtilities::mo_saml_sanitize_url(trim($_POST["saml_login_url"]));
if (!isset($_POST["saml_login_binding_type"])) {
goto zL;
}
$Hv = sanitize_text_field($_POST["saml_login_binding_type"]);
zL:
$Fw = sanitize_text_field(trim($_POST["saml_issuer"]));
$Jz = sanitize_text_field(trim($_POST["saml_identity_provider_guide_name"]));
$fK = $_POST["saml_x509_certificate"];
$q2 = sanitize_text_field($_POST["saml_nameid_format"]);
goto p7;
iZ:
update_option("mo_saml_message", "Please match the requested format for Identity Provider Name. Only alphabets, numbers and underscore is allowed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
p7:
goto OU;
n9:
update_option("mo_saml_message", "All the fields are required. Please enter valid entries.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
OU:
update_option("saml_identity_name", $Nv);
update_option("saml_login_binding_type", $Hv);
update_option("saml_login_url", $LO);
update_option("saml_logout_binding_type", $nv);
update_option("saml_issuer", $Fw);
update_option("saml_nameid_format", $q2);
update_option("saml_identity_provider_guide_name", $Jz);
if (isset($_POST["saml_request_signed"])) {
goto vM;
}
update_option("saml_request_signed", "unchecked");
goto GL;
vM:
update_option("saml_request_signed", "checked");
GL:
foreach ($fK as $Jp => $lG) {
if (empty($lG)) {
goto zd;
}
$fK[$Jp] = SAMLSPUtilities::sanitize_certificate($lG);
if (@openssl_x509_read($fK[$Jp])) {
goto xl;
}
update_option("mo_saml_message", "Invalid certificate: Please provide a valid certificate.");
SAMLSPUtilities::mo_saml_show_error_message();
delete_option("saml_x509_certificate");
return;
xl:
goto T6;
zd:
unset($fK[$Jp]);
T6:
yk:
}
JE:
if (!empty($fK)) {
goto yt;
}
update_option("mo_saml_message", "Invalid Certificate:Please provide a certificate");
SAMLSPUtilities::mo_saml_show_error_message();
return;
yt:
update_option("saml_x509_certificate", maybe_serialize($fK));
if (isset($_POST["saml_response_signed"])) {
goto zc;
}
update_option("saml_response_signed", "Yes");
goto Vb;
zc:
update_option("saml_response_signed", "checked");
Vb:
if (isset($_POST["saml_assertion_signed"])) {
goto Pe;
}
update_option("saml_assertion_signed", "Yes");
goto oz;
Pe:
update_option("saml_assertion_signed", "checked");
oz:
if (isset($_POST["enable_iconv"])) {
goto wO;
}
update_option("mo_saml_encoding_enabled", '');
goto a0;
wO:
update_option("mo_saml_encoding_enabled", "checked");
a0:
update_option("mo_saml_message", "Identity Provider details saved successfully.");
SAMLSPUtilities::mo_saml_show_success_message();
cH:
if (!(self::mo_check_option_admin_referer("mo_saml_add_sso_button_wp_option") && Mo_License_Service::is_customer_license_valid())) {
goto gS;
}
if (mo_saml_is_sp_configured()) {
goto Wd;
}
update_option("mo_saml_message", "Please complete " . addLink("Service Provider", SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "save"), $_SERVER["REQUEST_URI"])) . " configuration first.");
SAMLSPUtilities::mo_saml_show_error_message();
goto Ax;
Wd:
if (isset($_POST["mo_saml_add_sso_button_wp"])) {
goto kG;
}
$Ps = "false";
goto pl;
kG:
$Ps = sanitize_text_field($_POST["mo_saml_add_sso_button_wp"]);
pl:
update_option("mo_saml_add_sso_button_wp", $Ps);
update_option("mo_saml_message", "Sign in option updated.");
SAMLSPUtilities::mo_saml_show_success_message();
Ax:
gS:
if (!(self::mo_check_option_admin_referer("login_widget_saml_attribute_mapping") && Mo_License_Service::is_customer_license_valid())) {
goto KJ;
}
if (mo_saml_is_extension_installed("curl")) {
goto n4;
}
update_option("mo_saml_message", "ERROR:PHP cURL extension is not installed or disabled. Save Attribute Mapping failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
n4:
update_option("saml_am_username", sanitize_text_field($_POST["saml_am_username"]));
update_option("saml_am_email", sanitize_text_field($_POST["saml_am_email"]));
update_option("saml_am_first_name", sanitize_text_field($_POST["saml_am_first_name"]));
update_option("saml_am_last_name", sanitize_text_field($_POST["saml_am_last_name"]));
update_option("saml_am_display_name", sanitize_text_field($_POST["saml_am_display_name"]));
update_option("mo_saml_message", "Attribute Mapping details saved successfully");
SAMLSPUtilities::mo_saml_show_success_message();
KJ:
if (!self::mo_check_option_admin_referer("clear_attrs_list")) {
goto lq;
}
delete_option("mo_saml_test_config_attrs");
update_option("mo_saml_message", "Attributes list removed successfully");
SAMLSPUtilities::mo_saml_show_success_message();
lq:
if (!(self::mo_check_option_admin_referer("login_widget_saml_role_mapping") && Mo_License_Service::is_customer_license_valid())) {
goto nP;
}
if (mo_saml_is_extension_installed("curl")) {
goto DE;
}
update_option("mo_saml_message", "ERROR:PHP cURL extension is not installed or disabled. Save Role Mapping failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
DE:
if (isset($_POST["mo_saml_dont_update_existing_user_role"])) {
goto Tx;
}
update_option("saml_am_dont_update_existing_user_role", "unchecked");
goto GS;
Tx:
update_option("saml_am_dont_update_existing_user_role", "checked");
GS:
if (!isset($_POST["saml_am_default_user_role"])) {
goto HN;
}
$ji = sanitize_text_field($_POST["saml_am_default_user_role"]);
update_option("saml_am_default_user_role", $ji);
HN:
update_option("mo_saml_message", "Role Mapping details saved successfully.");
SAMLSPUtilities::mo_saml_show_success_message();
nP:
if (!(self::mo_check_option_admin_referer("mo_saml_update_idp_settings_option") && Mo_License_Service::is_customer_license_valid())) {
goto U9;
}
if (!(isset($_POST["mo_saml_sp_base_url"]) && isset($_POST["mo_saml_sp_entity_id"]))) {
goto xN;
}
$Tb = SAMLSPUtilities::mo_saml_sanitize_url($_POST["mo_saml_sp_base_url"]);
$yX = sanitize_text_field($_POST["mo_saml_sp_entity_id"]);
if (!(substr($Tb, -1) == "/")) {
goto W8;
}
$Tb = substr($Tb, 0, -1);
W8:
update_option("mo_saml_sp_base_url", $Tb);
update_option("mo_saml_sp_entity_id", $yX);
xN:
update_option("mo_saml_message", "Settings updated successfully.");
SAMLSPUtilities::mo_saml_show_success_message();
U9:
if (!(self::mo_check_option_admin_referer("saml_upload_metadata") && Mo_License_Service::is_customer_license_valid())) {
goto kv;
}
if (!function_exists("wp_handle_upload")) {
require_once Mo_Saml_WordPress_Files::MO_SAML_WP_ADMIN_FILE;
}
$this->_handle_upload_metadata();
kv:
if (!self::mo_check_option_admin_referer("upgrade_cert")) {
goto kJ;
}
$kK = file_get_contents(plugin_dir_path(__FILE__) . "resources" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Public_Certificate);
$zo = file_get_contents(plugin_dir_path(__FILE__) . "resources" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Private_Key);
update_option("mo_saml_current_cert", $kK);
update_option("mo_saml_current_cert_private_key", $zo);
update_option("mo_saml_certificate_roll_back_available", true);
update_option("mo_saml_message", "Certificate Upgraded successfully");
SAMLSPUtilities::mo_saml_show_success_message();
kJ:
if (!self::mo_check_option_admin_referer("rollback_cert")) {
goto SY;
}
$kK = file_get_contents(plugin_dir_path(__FILE__) . "resources" . DIRECTORY_SEPARATOR . "sp-certificate.crt");
$zo = file_get_contents(plugin_dir_path(__FILE__) . "resources" . DIRECTORY_SEPARATOR . "sp-key.key");
update_option("mo_saml_current_cert", $kK);
update_option("mo_saml_current_cert_private_key", $zo);
update_option("mo_saml_message", "Certificate Roll-backed successfully");
delete_option("mo_saml_certificate_roll_back_available");
SAMLSPUtilities::mo_saml_show_success_message();
SY:
if (!(self::mo_check_option_admin_referer("mo_saml_relay_state_option") && Mo_License_Service::is_customer_license_valid())) {
goto I4;
}
$XS = SAMLSPUtilities::mo_saml_sanitize_url($_POST["mo_saml_relay_state"]);
update_option("mo_saml_relay_state", $XS);
update_option("mo_saml_message", "Relay State has been updated successfully.");
SAMLSPUtilities::mo_saml_show_success_message();
I4:
if (!(self::mo_check_option_admin_referer("mo_saml_widget_option") && Mo_License_Service::is_customer_license_valid())) {
goto Gj;
}
$fF = sanitize_text_field($_POST["mo_saml_custom_login_text"]);
update_option("mo_saml_custom_login_text", stripcslashes($fF));
$gP = sanitize_text_field($_POST["mo_saml_custom_greeting_text"]);
update_option("mo_saml_custom_greeting_text", stripcslashes($gP));
$Lu = sanitize_text_field($_POST["mo_saml_greeting_name"]);
update_option("mo_saml_greeting_name", stripcslashes($Lu));
$NE = sanitize_text_field($_POST["mo_saml_custom_logout_text"]);
update_option("mo_saml_custom_logout_text", stripcslashes($NE));
update_option("mo_saml_message", "Widget Settings updated successfully.");
SAMLSPUtilities::mo_saml_show_success_message();
Gj:
if (!self::mo_check_option_admin_referer("mo_saml_register_customer")) {
goto tH;
}
if (mo_saml_is_extension_installed("curl")) {
goto gA;
}
update_option("mo_saml_message", "ERROR: PHP cURL extension is not installed or disabled. Registration failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
gA:
$BK = '';
$FG = '';
$W7 = '';
$AT = '';
if ($this->mo_saml_check_empty_or_null($_POST["email"]) || $this->mo_saml_check_empty_or_null($_POST["password"]) || $this->mo_saml_check_empty_or_null($_POST["confirmPassword"])) {
goto la;
}
if (strlen($_POST["password"]) < 6 || strlen($_POST["confirmPassword"]) < 6) {
goto Jt;
}
if (!filter_var($_POST["email"], FILTER_VALIDATE_EMAIL)) {
goto Ng;
}
if ($this->checkPasswordPattern(strip_tags($_POST["password"]))) {
goto w9;
}
$BK = sanitize_email($_POST["email"]);
$FG = sanitize_text_field($_POST["phone"]);
$W7 = sanitize_text_field($_POST["password"]);
$AT = sanitize_text_field($_POST["confirmPassword"]);
goto t4;
w9:
update_option("mo_saml_message", "Minimum 6 characters should be present. Maximum 15 characters should be present. Only following symbols (!@#.$%^&*-_) should be present.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
t4:
goto Dh;
Ng:
update_option("mo_saml_message", "Please enter a valid email address.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Dh:
goto aA;
Jt:
update_option("mo_saml_message", "Choose a password with minimum length 6.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
aA:
goto nL;
la:
update_option("mo_saml_message", "All the fields are required. Please enter valid entries.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
nL:
update_option("mo_saml_admin_email", $BK);
update_option("mo_saml_admin_phone", $FG);
if (strcmp($W7, $AT) == 0) {
goto qd;
}
update_option("mo_saml_message", "Passwords do not match.");
delete_option("mo_saml_verify_customer");
SAMLSPUtilities::mo_saml_show_error_message();
goto N9;
qd:
update_option("mo_saml_admin_password", $W7);
$BK = get_option("mo_saml_admin_email");
$fG = new CustomerSaml();
$IL = $fG->check_customer();
if ($IL) {
goto jr;
}
return;
jr:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "CUSTOMER_NOT_FOUND") == 0) {
goto L0;
}
$this->get_current_customer();
goto He;
L0:
$IL = $fG->send_otp_token($BK, '');
if ($IL) {
goto ZL;
}
return;
ZL:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto KH;
}
update_option("mo_saml_message", "There was an error in sending email. Please verify your email and try again.");
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_FAILURE_EMAIL");
SAMLSPUtilities::mo_saml_show_error_message();
goto mK;
KH:
update_option("mo_saml_message", " A one time passcode is sent to " . get_option("mo_saml_admin_email") . ". Please enter the otp here to verify your email.");
update_option("mo_saml_transactionId", $IL["txId"]);
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_SUCCESS_EMAIL");
SAMLSPUtilities::mo_saml_show_success_message();
mK:
He:
N9:
tH:
if (self::mo_check_option_admin_referer("mo_saml_validate_otp")) {
goto iX;
}
if (self::mo_check_option_admin_referer("mo_saml_verify_license")) {
goto Sl;
}
if (self::mo_check_option_admin_referer("mo_saml_contact_us_query_option")) {
goto PQ;
}
if (self::mo_check_option_admin_referer("mo_saml_resend_otp_email")) {
goto AH;
}
if (self::mo_check_option_admin_referer("mo_saml_resend_otp_phone")) {
goto gF;
}
if (self::mo_check_option_admin_referer("mo_saml_go_back")) {
goto aP;
}
if (self::mo_check_option_admin_referer("mo_saml_register_with_phone_option")) {
goto QK;
}
if (self::mo_check_option_admin_referer("mo_saml_registered_only_access_option") && Mo_License_Service::is_customer_license_valid()) {
goto sg;
}
if (self::mo_check_option_admin_referer("mo_saml_force_authentication_option") && Mo_License_Service::is_customer_license_valid()) {
goto jJ;
}
if (self::mo_check_option_admin_referer("mo_saml_enable_rss_access_option") && Mo_License_Service::is_customer_license_valid()) {
goto Ct;
}
if (self::mo_check_option_admin_referer("mo_saml_enable_login_redirect_option") && Mo_License_Service::is_customer_license_valid()) {
goto Q5;
}
if (self::mo_check_option_admin_referer("mo_saml_allow_wp_signin_option") && Mo_License_Service::is_customer_license_valid()) {
goto Oo;
}
if (isset($_POST["option"]) && $_POST["option"] == "mo_saml_forgot_password_form_option") {
goto iP;
}
if (!self::mo_check_option_admin_referer("mo_saml_verify_customer")) {
goto JV;
}
if (mo_saml_is_extension_installed("curl")) {
goto vc;
}
update_option("mo_saml_message", "ERROR: PHP cURL extension is not installed or disabled. Login failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
vc:
$BK = '';
$W7 = '';
if ($this->mo_saml_check_empty_or_null($_POST["email"]) || $this->mo_saml_check_empty_or_null($_POST["password"])) {
goto UC;
}
if ($this->checkPasswordPattern(strip_tags($_POST["password"]))) {
goto pv;
}
$BK = sanitize_email($_POST["email"]);
$W7 = sanitize_text_field($_POST["password"]);
goto E2;
pv:
update_option("mo_saml_message", "Minimum 6 characters should be present. Maximum 15 characters should be present. Only following symbols (!@#.$%^&*-_) should be present.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
E2:
goto rK;
UC:
update_option("mo_saml_message", "All the fields are required. Please enter valid entries.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
rK:
update_option("mo_saml_admin_email", $BK);
update_option("mo_saml_admin_password", $W7);
$fG = new Customersaml();
$IL = $fG->get_customer_key();
if ($IL) {
goto l0;
}
return;
l0:
$ds = json_decode($IL, true);
if (json_last_error() == JSON_ERROR_NONE) {
goto NX;
}
update_option("mo_saml_message", "Invalid username or password. Please try again.");
SAMLSPUtilities::mo_saml_show_error_message();
goto C8;
NX:
update_option("mo_saml_admin_customer_key", $ds["id"]);
update_option("mo_saml_admin_api_key", $ds["apiKey"]);
update_option("mo_saml_customer_token", $ds["token"]);
if (empty($ds["phone"])) {
goto Cj;
}
update_option("mo_saml_admin_phone", $ds["phone"]);
Cj:
update_option("mo_saml_admin_password", '');
update_option("mo_saml_message", "Customer retrieved successfully");
update_option("mo_saml_registration_status", "Existing User");
delete_option("mo_saml_verify_customer");
if (get_option("sml_lk")) {
goto FU;
}
SAMLSPUtilities::mo_saml_show_success_message();
goto W7;
FU:
$Jp = get_option("mo_saml_customer_token");
$uk = AESEncryption::decrypt_data(get_option("sml_lk"), $Jp);
$IL = $fG->mo_saml_vl($uk, false);
if ($IL) {
goto HE;
}
return;
HE:
$IL = json_decode($IL, true);
update_option("vl_check_t", time());
if (!empty($IL) && is_array($IL) && array_key_exists("status", $IL) && strcasecmp($IL["status"], "SUCCESS") == 0) {
goto qq;
}
update_option("mo_saml_message", "License key for this instance is incorrect. Make sure you have not tampered with it at all. Please enter a valid license key.");
delete_option("sml_lk");
SAMLSPUtilities::mo_saml_show_error_message();
goto GT;
qq:
$Xb = plugin_dir_path(__FILE__);
$PF = home_url();
$PF = trim($PF, "/");
if (preg_match("#^http(s)?://#", $PF)) {
goto V4;
}
$PF = "http://" . $PF;
V4:
$yy = parse_url($PF);
$m6 = preg_replace("/^www\./", '', $yy["host"]);
$Sg = wp_upload_dir();
$cm = $m6 . "-" . $Sg["basedir"];
$rg = hash_hmac("sha256", $cm, "4DHfjgfjasndfsajfHGJ");
$Sx = $this->djkasjdksa();
$co = round(strlen($Sx) / rand(2, 20));
$Sx = substr_replace($Sx, $rg, $co, 0);
$yY = base64_decode($Sx);
if (is_writable($Xb . "license")) {
goto Zo;
}
$Sx = str_rot13($Sx);
$jG = "bGNkamthc2pka3NhY2w=";
$lX = base64_decode($jG);
update_option($lX, $Sx);
goto wk;
Zo:
file_put_contents($Xb . "license", $yY);
wk:
update_option("lcwrtlfsaml", true);
SAMLSPUtilities::mo_saml_show_success_message();
GT:
W7:
C8:
update_option("mo_saml_admin_password", '');
JV:
goto UM;
iP:
if (mo_saml_is_extension_installed("curl")) {
goto YG;
}
update_option("mo_saml_message", "ERROR: PHP cURL extension is not installed or disabled. Resend OTP failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
YG:
$BK = get_option("mo_saml_admin_email");
$fG = new Customersaml();
$IL = $fG->mo_saml_forgot_password($BK);
if ($IL) {
goto XP;
}
return;
XP:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto zK;
}
update_option("mo_saml_message", "An error occured while processing your request. Please Try again.");
SAMLSPUtilities::mo_saml_show_error_message();
goto e5;
zK:
update_option("mo_saml_message", "Your password has been reset successfully. Please enter the new password sent to " . $BK . ".");
SAMLSPUtilities::mo_saml_show_success_message();
e5:
UM:
goto Rk;
Oo:
$Fy = "false";
if (isset($_POST["mo_saml_allow_wp_signin"])) {
goto zQ;
}
$gZ = "false";
goto gR;
zQ:
$gZ = sanitize_text_field($_POST["mo_saml_allow_wp_signin"]);
gR:
if ($gZ == "true") {
goto ra;
}
update_option("mo_saml_allow_wp_signin", "False");
goto kz;
ra:
update_option("mo_saml_allow_wp_signin", "true");
kz:
if (!isset($_POST["mo_saml_backdoor_url"])) {
goto B9;
}
$Fy = sanitize_text_field(trim($_POST["mo_saml_backdoor_url"]));
B9:
update_option("mo_saml_backdoor_url", $Fy);
update_option("mo_saml_message", "Sign In settings updated.");
SAMLSPUtilities::mo_saml_show_success_message();
Rk:
goto Cv;
Q5:
if (mo_saml_is_sp_configured()) {
goto d2;
}
update_option("mo_saml_message", "Please complete " . addLink("Service Provider", SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "save"), $_SERVER["REQUEST_URI"])) . " configuration first.");
SAMLSPUtilities::mo_saml_show_error_message();
goto x0;
d2:
if (isset($_POST["mo_saml_enable_login_redirect"])) {
goto eV;
}
$vP = "false";
goto Qf;
eV:
$vP = sanitize_text_field($_POST["mo_saml_enable_login_redirect"]);
Qf:
if ($vP == "true") {
goto vL;
}
update_option("mo_saml_enable_login_redirect", "false");
update_option("mo_saml_allow_wp_signin", "False");
goto Mz;
vL:
update_option("mo_saml_enable_login_redirect", "true");
update_option("mo_saml_allow_wp_signin", "true");
Mz:
update_option("mo_saml_message", "Sign in options updated.");
SAMLSPUtilities::mo_saml_show_success_message();
x0:
Cv:
goto CY;
Ct:
if (mo_saml_is_sp_configured()) {
goto Rv;
}
update_option("mo_saml_message", "Please complete " . addLink("Service Provider", SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "save"), $_SERVER["REQUEST_URI"])) . " configuration first.");
SAMLSPUtilities::mo_saml_show_error_message();
goto PY;
Rv:
if (isset($_POST["mo_saml_enable_rss_access"])) {
goto nO;
}
$VF = false;
goto bN;
nO:
$VF = sanitize_text_field($_POST["mo_saml_enable_rss_access"]);
bN:
if ($VF == "true") {
goto vm;
}
update_option("mo_saml_enable_rss_access", "false");
goto BA;
vm:
update_option("mo_saml_enable_rss_access", "true");
BA:
update_option("mo_saml_message", "RSS Feed option updated.");
SAMLSPUtilities::mo_saml_show_success_message();
PY:
CY:
goto vx;
jJ:
if (mo_saml_is_sp_configured()) {
goto Gx;
}
update_option("mo_saml_message", "Please complete " . addLink("Service Provider", SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "save"), $_SERVER["REQUEST_URI"])) . " configuration first.");
SAMLSPUtilities::mo_saml_show_error_message();
goto ls;
Gx:
if (isset($_POST["mo_saml_force_authentication"])) {
goto WC;
}
$vP = "false";
goto iO;
WC:
$vP = sanitize_text_field($_POST["mo_saml_force_authentication"]);
iO:
if ($vP == "true") {
goto V5;
}
update_option("mo_saml_force_authentication", "false");
goto m8;
V5:
update_option("mo_saml_force_authentication", "true");
m8:
update_option("mo_saml_message", "Sign in options updated.");
SAMLSPUtilities::mo_saml_show_success_message();
ls:
vx:
goto o7;
sg:
if (mo_saml_is_sp_configured()) {
goto J1;
}
update_option("mo_saml_message", "Please complete " . addLink("Service Provider", SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "save"), $_SERVER["REQUEST_URI"])) . " configuration first.");
SAMLSPUtilities::mo_saml_show_error_message();
goto Pf;
J1:
if (isset($_POST["mo_saml_registered_only_access"])) {
goto pt;
}
$vP = "false";
goto jV;
pt:
$vP = sanitize_text_field($_POST["mo_saml_registered_only_access"]);
jV:
if ($vP == "true") {
goto l6;
}
update_option("mo_saml_registered_only_access", "false");
goto u0;
l6:
update_option("mo_saml_registered_only_access", "true");
u0:
update_option("mo_saml_message", "Sign in options updated.");
SAMLSPUtilities::mo_saml_show_success_message();
Pf:
o7:
goto cD;
QK:
if (mo_saml_is_extension_installed("curl")) {
goto U2;
}
update_option("mo_saml_message", "ERROR: PHP cURL extension is not installed or disabled. Resend OTP failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
U2:
$FG = sanitize_text_field($_POST["phone"]);
$FG = str_replace(" ", '', $FG);
$FG = str_replace("-", '', $FG);
update_option("mo_saml_admin_phone", $FG);
$fG = new CustomerSaml();
$IL = $fG->send_otp_token('', $FG, FALSE, TRUE);
if ($IL) {
goto kL;
}
return;
kL:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto jG;
}
update_option("mo_saml_message", "There was an error in sending SMS. Please click on Resend OTP to try again.");
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_FAILURE_PHONE");
SAMLSPUtilities::mo_saml_show_error_message();
goto Gq;
jG:
update_option("mo_saml_message", " A one time passcode is sent to " . get_option("mo_saml_admin_phone") . ". Please enter the otp here to verify your email.");
update_option("mo_saml_transactionId", $IL["txId"]);
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_SUCCESS_PHONE");
SAMLSPUtilities::mo_saml_show_success_message();
Gq:
cD:
goto Kq;
aP:
update_option("mo_saml_registration_status", '');
update_option("mo_saml_verify_customer", '');
delete_option("mo_saml_new_registration");
delete_option("mo_saml_admin_email");
delete_option("mo_saml_admin_phone");
delete_site_option("sml_lk");
delete_site_option("t_site_status");
delete_site_option("site_ck_l");
Kq:
goto gD;
gF:
if (mo_saml_is_extension_installed("curl")) {
goto ju;
}
update_option("mo_saml_message", "ERROR: PHP cURL extension is not installed or disabled. Resend OTP failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
ju:
$FG = get_option("mo_saml_admin_phone");
$fG = new CustomerSaml();
$IL = $fG->send_otp_token('', $FG, FALSE, TRUE);
if ($IL) {
goto aQ;
}
return;
aQ:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto vf;
}
update_option("mo_saml_message", "There was an error in sending email. Please click on Resend OTP to try again.");
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_FAILURE_PHONE");
SAMLSPUtilities::mo_saml_show_error_message();
goto y2;
vf:
update_option("mo_saml_message", " A one time passcode is sent to " . $FG . " again. Please check if you got the otp and enter it here.");
update_option("mo_saml_transactionId", $IL["txId"]);
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_SUCCESS_PHONE");
SAMLSPUtilities::mo_saml_show_success_message();
y2:
gD:
goto rW;
AH:
if (mo_saml_is_extension_installed("curl")) {
goto px;
}
update_option("mo_saml_message", "ERROR: PHP cURL extension is not installed or disabled. Resend OTP failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
px:
$BK = get_option("mo_saml_admin_email");
$fG = new CustomerSaml();
$IL = $fG->send_otp_token($BK, '');
if ($IL) {
goto Lq;
}
return;
Lq:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto Q3;
}
update_option("mo_saml_message", "There was an error in sending email. Please click on Resend OTP to try again.");
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_FAILURE_EMAIL");
SAMLSPUtilities::mo_saml_show_error_message();
goto XC;
Q3:
update_option("mo_saml_message", " A one time passcode is sent to " . get_option("mo_saml_admin_email") . " again. Please check if you got the otp and enter it here.");
update_option("mo_saml_transactionId", $IL["txId"]);
update_option("mo_saml_registration_status", "MO_OTP_DELIVERED_SUCCESS_EMAIL");
SAMLSPUtilities::mo_saml_show_success_message();
XC:
rW:
goto mX;
PQ:
if (mo_saml_is_extension_installed("curl")) {
goto Eo;
}
update_option("mo_saml_message", "ERROR: PHP cURL extension is not installed or disabled. Query submit failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Eo:
$BK = sanitize_email($_POST["mo_saml_contact_us_email"]);
$FG = sanitize_text_field($_POST["mo_saml_contact_us_phone"]);
$wy = sanitize_text_field($_POST["mo_saml_contact_us_query"]);
if (isset($_POST["send_plugin_config"]) === true) {
goto h4;
}
update_option("send_plugin_config", "off");
goto aI;
h4:
$yB = miniorange_import_export(true, true);
$wy .= $yB;
delete_option("send_plugin_config");
aI:
$fG = new CustomerSaml();
if ($this->mo_saml_check_empty_or_null($BK) || $this->mo_saml_check_empty_or_null($wy)) {
goto GN;
}
if (!filter_var($BK, FILTER_VALIDATE_EMAIL)) {
goto ur;
}
$Gl = $fG->submit_contact_us($BK, $FG, $wy);
if ($Gl) {
goto nI;
}
return;
nI:
update_option("mo_saml_message", "Thanks for getting in touch! We shall get back to you shortly.");
SAMLSPUtilities::mo_saml_show_success_message();
goto oA;
ur:
update_option("mo_saml_message", "Please enter a valid email address.");
SAMLSPUtilities::mo_saml_show_error_message();
oA:
goto dT;
GN:
update_option("mo_saml_message", "Please fill up Email and Query fields to submit your query.");
SAMLSPUtilities::mo_saml_show_error_message();
dT:
mX:
goto Jf;
Sl:
if (!$this->mo_saml_check_empty_or_null($_POST["saml_licence_key"])) {
goto q8;
}
update_option("mo_saml_message", "All the fields are required. Please enter valid license key.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
q8:
$uk = sanitize_text_field(trim($_POST["saml_licence_key"]));
$fG = new Customersaml();
$Kt = json_decode($fG->mo_saml_vl($uk, false), true);
if (!empty($Kt["status"])) {
goto OD;
}
update_option("mo_saml_message", "The license key you have entered is invalid. Please enter a valid license key.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
OD:
$IL = $fG->check_customer_ln();
if ($IL) {
goto Et;
}
return;
Et:
$IL = json_decode($IL, true);
if (!(is_array($IL) && array_key_exists("licenseExpiry", $IL) && !empty($IL["licenseExpiry"]))) {
goto AV;
}
$sY = $IL["licenseExpiry"];
AV:
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto lG;
}
$Jp = get_option("mo_saml_customer_token");
update_option("site_ck_l", AESEncryption::encrypt_data("false", $Jp));
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "licensing"), $_SERVER["REQUEST_URI"]);
update_option("mo_saml_message", "You have not upgraded yet. " . addLink("Click here", $Ug) . " to upgrade to premium version.");
SAMLSPUtilities::mo_saml_show_error_message();
goto QT;
lG:
$IL = json_decode($fG->mo_saml_vl($uk, false), true);
update_option("vl_check_t", time());
if (is_array($IL) && strcasecmp($IL["status"], "SUCCESS") == 0) {
goto PW;
}
if (is_array($IL) && strcasecmp($IL["status"], "FAILED") == 0) {
goto Fa;
}
update_option("mo_saml_message", "An error occured while processing your request. Please Try again.");
SAMLSPUtilities::mo_saml_show_error_message();
goto XD;
Fa:
if (strcasecmp($IL["message"], "Code has Expired") == 0) {
goto tn;
}
update_option("mo_saml_message", "You have entered an invalid license key. Please enter a valid license key.");
goto vt;
tn:
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "licensing"), $_SERVER["REQUEST_URI"]);
update_option("mo_saml_message", "License key you have entered has already been used. Please enter a key which has not been used before on any other instance or if you have exausted all your keys then " . addLink("Click here", $Ug) . " to buy more.");
vt:
SAMLSPUtilities::mo_saml_show_error_message();
XD:
goto eZ;
PW:
$Jp = get_option("mo_saml_customer_token");
update_option("sml_lk", AESEncryption::encrypt_data($uk, $Jp));
$dq = "Your license is verified. You can now setup the plugin.";
update_option("mo_saml_message", $dq);
$Jp = get_option("mo_saml_customer_token");
update_option("site_ck_l", AESEncryption::encrypt_data("true", $Jp));
update_option("t_site_status", AESEncryption::encrypt_data("false", $Jp));
$Xb = plugin_dir_path(__FILE__);
$PF = home_url();
$PF = trim($PF, "/");
if (preg_match("#^http(s)?://#", $PF)) {
goto A4;
}
$PF = "http://" . $PF;
A4:
$yy = parse_url($PF);
$m6 = preg_replace("/^www\./", '', $yy["host"]);
$Sg = wp_upload_dir();
$cm = $m6 . "-" . $Sg["basedir"];
$rg = hash_hmac("sha256", $cm, "4DHfjgfjasndfsajfHGJ");
$Sx = $this->djkasjdksa();
$co = round(strlen($Sx) / rand(2, 20));
$Sx = substr_replace($Sx, $rg, $co, 0);
$yY = base64_decode($Sx);
if (is_writable($Xb . "license")) {
goto iA;
}
$Sx = str_rot13($Sx);
$jG = "bGNkamthc2pka3NhY2w=";
$lX = base64_decode($jG);
update_option($lX, $Sx);
goto me;
iA:
file_put_contents($Xb . "license", $yY);
me:
update_option("lcwrtlfsaml", true);
if (empty($sY)) {
goto y0;
}
Mo_License_Service::update_license_expiry($sY);
y0:
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "general"), $_SERVER["REQUEST_URI"]);
SAMLSPUtilities::mo_saml_show_success_message();
eZ:
QT:
Jf:
goto wx;
iX:
if (mo_saml_is_extension_installed("curl")) {
goto xX;
}
update_option("mo_saml_message", "ERROR:PHP cURL extension is not installed or disabled. Validate OTP failed.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
xX:
$Jb = '';
if ($this->mo_saml_check_empty_or_null($_POST["otp_token"])) {
goto dS;
}
$Jb = sanitize_text_field($_POST["otp_token"]);
goto MI;
dS:
update_option("mo_saml_message", "Please enter a value in otp field.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
MI:
$fG = new CustomerSaml();
$IL = $fG->validate_otp_token(get_option("mo_saml_transactionId"), $Jb);
if ($IL) {
goto KD;
}
return;
KD:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto jO;
}
update_option("mo_saml_message", "Invalid one time passcode. Please enter a valid otp.");
SAMLSPUtilities::mo_saml_show_error_message();
goto ad;
jO:
$this->create_customer();
ad:
wx:
if (!self::mo_check_option_admin_referer("mo_saml_free_trial")) {
goto C2;
}
if (decryptSamlElement()) {
goto u2;
}
$uk = postResponse();
$fG = new Customersaml();
$IL = $fG->mo_saml_vl($uk, false);
if ($IL) {
goto nF;
}
return;
nF:
$IL = json_decode($IL, true);
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto dc;
}
if (strcasecmp($IL["status"], "FAILED") == 0) {
goto UH;
}
update_option("mo_saml_message", "An error occured while processing your request. Please Try again.");
SAMLSPUtilities::mo_saml_show_error_message();
goto W0;
UH:
update_option("mo_saml_message", "There was an error activating your TRIAL version. Please contact [email protected] for getting new license for trial version.");
SAMLSPUtilities::mo_saml_show_error_message();
W0:
goto Lu;
dc:
$Jp = get_option("mo_saml_customer_token");
$Jp = get_option("mo_saml_customer_token");
update_option("t_site_status", AESEncryption::encrypt_data("true", $Jp));
update_option("mo_saml_message", "Your 5 days TRIAL is activated. You can now setup the plugin.");
SAMLSPUtilities::mo_saml_show_success_message();
Lu:
goto NJ;
u2:
update_option("mo_saml_message", "There was an error activating your TRIAL version. Either your trial period is expired or you are using wrong trial version. Please contact [email protected] for getting new license for trial version.");
SAMLSPUtilities::mo_saml_show_error_message();
NJ:
C2:
if (!self::mo_check_option_admin_referer("mo_saml_check_license")) {
goto Sd;
}
$fG = new Customersaml();
$IL = $fG->check_customer_ln();
if ($IL) {
goto q5;
}
return;
q5:
$IL = json_decode($IL, true);
update_option("vl_check_t", time());
if (strcasecmp($IL["status"], "SUCCESS") == 0) {
goto wJ;
}
$Jp = get_option("mo_saml_customer_token");
update_option("site_ck_l", AESEncryption::encrypt_data("false", $Jp));
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "licensing"), $_SERVER["REQUEST_URI"]);
update_option("mo_saml_message", "You have not upgraded yet. " . addLink("Click here", $Ug) . " to upgrade to premium version.");
SAMLSPUtilities::mo_saml_show_error_message();
goto qS;
wJ:
if (!empty($IL["licensePlan"]) && !$this->mo_saml_check_empty_or_null($IL["licensePlan"])) {
goto nt;
}
$Jp = get_option("mo_saml_customer_token");
update_option("site_ck_l", AESEncryption::encrypt_data("false", $Jp));
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "licensing"), $_SERVER["REQUEST_URI"]);
update_option("mo_saml_message", "You have not upgraded yet. " . addLink("Click here", $Ug) . " to upgrade to premium version.");
SAMLSPUtilities::mo_saml_show_error_message();
goto LC;
nt:
update_option("mo_saml_license_name", base64_encode($IL["licensePlan"]));
$Jp = get_option("mo_saml_customer_token");
if (!(!empty($IL["noOfUsers"]) && !$this->mo_saml_check_empty_or_null($IL["noOfUsers"]))) {
goto iJ;
}
update_option("mo_saml_usr_lmt", AESEncryption::encrypt_data($IL["noOfUsers"], $Jp));
iJ:
if (!(!empty($IL["licenseExpiry"]) && !$this->mo_saml_check_empty_or_null($IL["licenseExpiry"]))) {
goto OY;
}
update_option("mo_saml_license_expiry_date", $this->mo_saml_parse_expiry_date($IL["licenseExpiry"]));
OY:
update_option("site_ck_l", AESEncryption::encrypt_data("true", $Jp));
$Xb = plugin_dir_path(__FILE__);
$PF = home_url();
$PF = trim($PF, "/");
if (preg_match("#^http(s)?://#", $PF)) {
goto vi;
}
$PF = "http://" . $PF;
vi:
$yy = parse_url($PF);
$m6 = preg_replace("/^www\./", '', $yy["host"]);
$Sg = wp_upload_dir();
$cm = $m6 . "-" . $Sg["basedir"];
$rg = hash_hmac("sha256", $cm, "4DHfjgfjasndfsajfHGJ");
$Sx = $this->djkasjdksa();
$co = round(strlen($Sx) / rand(2, 20));
$Sx = substr_replace($Sx, $rg, $co, 0);
$yY = base64_decode($Sx);
if (is_writable($Xb . "license")) {
goto eH;
}
$Sx = str_rot13($Sx);
$jG = "bGNkamthc2pka3NhY2w=";
$lX = base64_decode($jG);
update_option($lX, $Sx);
goto l1;
eH:
file_put_contents($Xb . "license", $yY);
l1:
update_option("lcwrtlfsaml", true);
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "general"), $_SERVER["REQUEST_URI"]);
Mo_License_Service::refresh_license_expiry();
update_option("mo_saml_message", "You have successfully synced your license.");
SAMLSPUtilities::mo_saml_show_success_message();
LC:
qS:
Sd:
if (!self::mo_check_option_admin_referer("mo_saml_remove_account")) {
goto eT;
}
$this->mo_sso_saml_deactivate();
add_option("mo_saml_registration_status", "removed_account");
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("tab" => "login"), $_SERVER["REQUEST_URI"]);
header("Location: " . $Ug);
eT:
RE:
}
function create_customer()
{
$fG = new CustomerSaml();
$ds = $fG->create_customer();
if ($ds) {
goto KA;
}
return;
KA:
$ds = json_decode($ds, true);
if (strcasecmp($ds["status"], "CUSTOMER_USERNAME_ALREADY_EXISTS") == 0) {
goto Sw;
}
if (!(strcasecmp($ds["status"], "SUCCESS") == 0)) {
goto b8;
}
update_option("mo_saml_admin_customer_key", $ds["id"]);
update_option("mo_saml_admin_api_key", $ds["apiKey"]);
update_option("mo_saml_customer_token", $ds["token"]);
update_option("mo_saml_admin_password", '');
update_option("mo_saml_message", "Thank you for registering with Xecurify.");
update_option("mo_saml_registration_status", '');
delete_option("mo_saml_verify_customer");
delete_option("mo_saml_new_registration");
SAMLSPUtilities::mo_saml_show_success_message();
b8:
goto uC;
Sw:
$this->get_current_customer();
uC:
update_option("mo_saml_admin_password", '');
}
function get_current_customer()
{
$fG = new CustomerSaml();
$IL = $fG->get_customer_key();
if ($IL) {
goto tr;
}
return;
tr:
$ds = json_decode($IL, true);
if (json_last_error() == JSON_ERROR_NONE) {
goto QM;
}
update_option("mo_saml_message", "You already have an account with miniOrange. Please enter a valid password.");
update_option("mo_saml_verify_customer", "true");
delete_option("mo_saml_new_registration");
SAMLSPUtilities::mo_saml_show_error_message();
goto tf;
QM:
update_option("mo_saml_admin_customer_key", $ds["id"]);
update_option("mo_saml_admin_api_key", $ds["apiKey"]);
update_option("mo_saml_customer_token", $ds["token"]);
update_option("mo_saml_admin_password", '');
update_option("mo_saml_message", "Your account has been retrieved successfully.");
delete_option("mo_saml_verify_customer");
delete_option("mo_saml_new_registration");
SAMLSPUtilities::mo_saml_show_success_message();
tf:
}
public function mo_saml_check_empty_or_null($lG)
{
if (!(!isset($lG) || empty($lG))) {
goto Mf;
}
return true;
Mf:
return false;
}
function miniorange_sso_menu()
{
$H_ = add_menu_page("MO SAML Settings " . __("Configure SAML Identity Provider for SSO", "mo_saml_settings"), "miniOrange SAML 2.0 SSO", "administrator", "mo_saml_settings", array($this, "mo_login_widget_saml_options"), plugin_dir_url(__FILE__) . "images/miniorange.png");
add_submenu_page("mo_saml_settings", "Error Codes", "Error Codes", "administrator", "mo_error_codes", array("Mo_Saml_Error_Codes_View", "mo_saml_get_error_codes_view"));
}
function mo_saml_redirect_for_authentication($XS)
{
if (!mo_saml_is_customer_license_key_verified()) {
goto eL;
}
if (!(get_option("mo_saml_registered_only_access") == "true")) {
goto WN;
}
$base_url = home_url();
echo "<script>window.location.href='" . esc_url($base_url) . "/?option=saml_user_login&redirect_to='+encodeURIComponent(window.location.href);</script>";
exit;
WN:
if (!(mo_saml_is_sp_configured() && Mo_License_Service::is_customer_license_valid() && get_option("mo_saml_enable_login_redirect") == "true")) {
goto lv;
}
$Tb = get_option("mo_saml_sp_base_url");
if (!empty($Tb)) {
goto HL;
}
$Tb = home_url();
HL:
if (!(get_option("mo_saml_relay_state") && get_option("mo_saml_relay_state") != '')) {
goto sk;
}
$XS = get_option("mo_saml_relay_state");
sk:
$XS = mo_saml_get_relay_state($XS);
$Zi = empty($XS) ? "/" : $XS;
$bL = htmlspecialchars_decode(get_option("saml_login_url"));
$Iy = get_option("saml_login_binding_type");
$S7 = get_option("mo_saml_force_authentication");
$f4 = $Tb . "/";
$yX = get_option("mo_saml_sp_entity_id");
$q2 = get_option("saml_nameid_format");
if (!empty($q2)) {
goto SG;
}
$q2 = "1.1:nameid-format:emailAddress";
SG:
if (!empty($yX)) {
goto pg;
}
$yX = $Tb . "/wp-content/plugins/miniorange-saml-20-single-sign-on/";
pg:
$LP = SAMLSPUtilities::createAuthnRequest($f4, $yX, $bL, $S7, $Iy, $q2);
if (empty($Iy) || $Iy == "HttpRedirect") {
goto mU;
}
if (!(get_option("saml_request_signed") == "unchecked")) {
goto MM;
}
$Is = base64_encode($LP);
SAMLSPUtilities::postSAMLRequest($bL, $Is, $Zi);
exit;
MM:
$mC = '';
$Xu = '';
$Is = SAMLSPUtilities::signXML($LP, "NameIDPolicy");
SAMLSPUtilities::postSAMLRequest($bL, $Is, $Zi);
goto cW;
mU:
$qU = $bL;
if (strpos($bL, "?") !== false) {
goto aR;
}
$qU .= "?";
goto Df;
aR:
$qU .= "&";
Df:
if (!(get_option("saml_request_signed") == "unchecked")) {
goto nG;
}
$qU .= "SAMLRequest=" . $LP . "&RelayState=" . urlencode($Zi);
header("Location: " . $qU);
exit;
nG:
$LP = "SAMLRequest=" . $LP . "&RelayState=" . urlencode($Zi) . "&SigAlg=" . urlencode(XMLSecurityKey::RSA_SHA256);
$AP = array("type" => "private");
$Jp = new XMLSecurityKey(XMLSecurityKey::RSA_SHA256, $AP);
$Ha = get_option("mo_saml_current_cert_private_key");
$Jp->loadKey($Ha, FALSE);
$eR = new XMLSecurityDSig();
$FK = $Jp->signData($LP);
$FK = base64_encode($FK);
$qU .= $LP . "&Signature=" . urlencode($FK);
header("Location: " . $qU);
exit;
cW:
lv:
eL:
}
function mo_saml_authenticate()
{
$WF = '';
if (!isset($_REQUEST["redirect_to"])) {
goto cy;
}
$WF = SAMLSPUtilities::mo_saml_sanitize_url($_REQUEST["redirect_to"]);
cy:
if (!is_user_logged_in()) {
goto wu;
}
$this->mo_saml_login_redirect($WF);
wu:
if (!(get_option("mo_saml_enable_login_redirect") == "true" && Mo_License_Service::is_customer_license_valid())) {
goto ba;
}
$bT = get_option("mo_saml_backdoor_url") ? trim(get_option("mo_saml_backdoor_url")) : "false";
if (isset($_GET["loggedout"]) && $_GET["loggedout"] == "true") {
goto FC;
}
if (!(get_option("mo_saml_allow_wp_signin") == "true")) {
goto IZ;
}
if (isset($_GET["saml_sso"]) && $_GET["saml_sso"] == $bT || isset($_POST["saml_sso"]) && $_POST["saml_sso"] == $bT) {
goto TR;
}
if (!isset($_REQUEST["redirect_to"])) {
goto Vt;
}
$WF = SAMLSPUtilities::mo_saml_sanitize_url($_REQUEST["redirect_to"]);
if (!(strpos($WF, "wp-admin") !== false && strpos($WF, "saml_sso=" . $bT) !== false)) {
goto zn;
}
return;
zn:
Vt:
goto aL;
TR:
return;
aL:
IZ:
goto EP;
FC:
header("Location: " . home_url());
exit;
EP:
$this->mo_saml_redirect_for_authentication($WF);
ba:
}
function mo_saml_login_redirect($WF)
{
$Lc = false;
if (!(strcmp(admin_url(), $WF) == 0 || strcmp(wp_login_url(), $WF) == 0)) {
goto NH;
}
$Lc = true;
NH:
if (!empty($WF) && !$Lc) {
goto CG;
}
header("Location: " . site_url());
goto an;
CG:
header("Location: " . htmlspecialchars_decode($WF));
an:
exit;
}
function mo_saml_auto_redirect()
{
if (!(current_user_can("read") || is_user_logged_in())) {
goto TO;
}
return;
TO:
if (!(get_option("mo_saml_registered_only_access") == "true")) {
goto Ca;
}
if (!(get_option("mo_saml_enable_rss_access") == "true" && is_feed())) {
goto hj;
}
return;
hj:
$XS = saml_get_current_page_url();
$this->mo_saml_redirect_for_authentication($XS);
Ca:
}
function mo_saml_modify_login_form()
{
if (!(get_option("mo_saml_add_sso_button_wp") == "true")) {
goto RS;
}
$this->mo_saml_add_sso_button();
RS:
$bT = get_option("mo_saml_backdoor_url") ? trim(get_option("mo_saml_backdoor_url")) : "false";
echo "<input type="hidden" name="saml_sso" value="" . esc_attr($bT) . "">" . "\xa";
}
function mo_saml_add_sso_button()
{
if (!(!is_user_logged_in() && Mo_License_Service::is_customer_license_valid(false, false))) {
goto Pu;
}
$Rk = get_option("saml_identity_name");
$r3 = $Rk ? "Login with " . $Rk : "Login with SSO";
$Xz = "\xa <script>\xa window.onload = function() {
\x9 var target_btn = document.getElementById("mo_saml_button");\xa\x9 var before_element = document.querySelector("#loginform p");
\x9 before_element.before(target_btn);\xa };\xa function loginWithSSOButton(id) {
if( id === "mo_saml_login_sso_button")
document.getElementById("saml_user_login_input").value = "saml_user_login";\xa document.getElementById("loginform").submit();
}
\x9 \x9</script>\xa\x9 <input id="saml_user_login_input" type="hidden" name="option" value="" />
<div id="mo_saml_button" style="height:88px;">
<div id="mo_saml_login_sso_button" onclick="loginWithSSOButton(this.id)" style="width:100%;display:flex;justify-content:center;align-items:center;font-size:14px;margin-bottom:1.3rem" class="button button-primary">
\x9 \x9<img style="width:20px;height:15px;padding-right:1px" src="" . esc_url(plugin_dir_url(__FILE__)) . "images/lock-icon.png">" . esc_html($r3) . "</div>\xa <div style="padding:5px;font-size:14px;height:20px;text-align:center"><b>OR</b></div>\xa </div>";
echo $Xz;
Pu:
}
function djkasjdksa()
{
$QJ = "!~@#$%^&*()_+|{}<>?0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
$SU = strlen($QJ);
$ul = '';
$YE = 0;
Yy:
if (!($YE < 10000)) {
goto N3;
}
$ul .= $QJ[rand(0, $SU - 1)];
JJ:
$YE++;
goto Yy;
N3:
return $ul;
}
function mo_get_saml_shortcode()
{
if (Mo_License_Service::is_customer_license_valid(false, false)) {
goto ca;
}
$Xz = '';
goto EH;
ca:
if (!is_user_logged_in()) {
goto A2;
}
$current_user = wp_get_current_user();
$gP = "Hello,";
if (!get_option("mo_saml_custom_greeting_text")) {
goto VS;
}
$gP = get_option("mo_saml_custom_greeting_text");
VS:
$Lu = '';
if (!get_option("mo_saml_greeting_name")) {
goto qv;
}
switch (get_option("mo_saml_greeting_name")) {
case "USERNAME":
$Lu = $current_user->user_login;
goto sf;
case "EMAIL":
$Lu = $current_user->user_email;
goto sf;
case "FNAME":
$Lu = $current_user->user_firstname;
goto sf;
case "LNAME":
$Lu = $current_user->user_lastname;
goto sf;
case "FNAME_LNAME":
$Lu = $current_user->user_firstname . " " . $current_user->user_lastname;
goto sf;
case "LNAME_FNAME":
$Lu = $current_user->user_lastname . " " . $current_user->user_firstname;
goto sf;
default:
$Lu = $current_user->user_login;
}
Oq:
sf:
qv:
if (!empty(trim($Lu))) {
goto SR;
}
$Lu = $current_user->user_login;
SR:
$Y9 = $gP . " " . $Lu;
$Qb = "Logout";
if (!get_option("mo_saml_custom_logout_text")) {
goto zu;
}
$Qb = get_option("mo_saml_custom_logout_text");
zu:
$Xz = $Y9 . " | <a href="" . wp_logout_url(home_url()) . "" title="logout" >" . $Qb . "</a></li>";
$Ug = saml_get_current_page_url();
update_option("logout_redirect_url", $Ug);
goto EL;
A2:
$Tb = get_option("mo_saml_sp_base_url");
if (!empty($Tb)) {
goto kU;
}
$Tb = home_url();
kU:
if (mo_saml_is_sp_configured() && mo_saml_is_customer_license_key_verified()) {
goto ob;
}
$Xz = "SP is not configured.";
goto C_;
ob:
$R_ = "Login with " . get_option("saml_identity_name");
if (!get_option("mo_saml_custom_login_text")) {
goto Nv;
}
$R_ = get_option("mo_saml_custom_login_text");
Nv:
$wP = get_option("saml_identity_name");
$R_ = str_replace("##IDP##", $wP, $R_);
$WF = urlencode(saml_get_current_page_url());
$Xz = "<a href="" . $Tb . "/?option=saml_user_login&redirect_to=" . $WF . "">" . $R_ . "</a>";
C_:
EL:
EH:
return $Xz;
}
function _handle_upload_metadata()
{
if (!(isset($_FILES["metadata_file"]) || isset($_POST["metadata_url"]))) {
goto YL;
}
if (!empty($_FILES["metadata_file"]["tmp_name"])) {
goto eK;
}
if (mo_saml_is_extension_installed("curl")) {
goto Kw;
}
update_option("mo_saml_message", "PHP cURL extension is not installed or disabled. Cannot fetch metadata from URL.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Kw:
$Ug = filter_var(htmlspecialchars($_POST["metadata_url"]), FILTER_SANITIZE_URL);
$HS = SAMLSPUtilities::mo_saml_wp_remote_call($Ug, array("sslverify" => false), true);
if (!is_null($HS)) {
goto vz;
}
$rm = null;
goto u4;
vz:
$rm = $HS;
u4:
goto B7;
eK:
$rm = @file_get_contents(sanitize_text_field($_FILES["metadata_file"]["tmp_name"]));
B7:
if (!is_null($rm)) {
goto U8;
}
update_option("mo_saml_message", "Invalid Metadata File or URL");
SAMLSPUtilities::mo_saml_show_error_message();
return;
goto lY;
U8:
$this->upload_metadata($rm);
lY:
YL:
}
function upload_metadata($rm)
{
if (!empty($rm)) {
goto j2;
}
update_option("mo_saml_message", "Error: Couldn't upload metadata. Metadata File is empty.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
j2:
$Eo = set_error_handler(array($this, "handleXmlError"));
$cp = new DOMDocument();
$cp->loadXML($rm);
restore_error_handler();
$Ci = $cp->firstChild;
if (!empty($Ci)) {
goto w2;
}
if (!empty($_FILES["metadata_file"]["tmp_name"])) {
goto Nq;
}
if (!empty($_POST["metadata_url"])) {
goto B3;
}
update_option("mo_saml_message", "Please provide a valid metadata file or a valid URL.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
goto k_;
B3:
update_option("mo_saml_message", "Please provide a valid metadata URL.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
k_:
goto ps;
Nq:
update_option("mo_saml_message", "Please provide a valid metadata file.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
ps:
goto TB;
w2:
$Al = new IDPMetadataReader($cp);
$NH = $Al->getIdentityProviders();
if (preg_match("/^\w*$/", $_POST["saml_identity_metadata_provider"])) {
goto JW;
}
update_option("mo_saml_message", __("Please match the requested format for Identity Provider Name. Only alphabets, numbers and underscore is allowed.", "miniorange-saml-20-single-sign-on"));
SAMLSPUtilities::mo_saml_show_error_message();
return;
JW:
if (!(empty($NH) && !empty($_FILES["metadata_file"]["tmp_name"]))) {
goto sF;
}
update_option("mo_saml_message", "Please provide a valid metadata file.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
sF:
if (!(empty($NH) && !empty($_POST["metadata_url"]))) {
goto Ys;
}
update_option("mo_saml_message", "Please provide a valid metadata URL.");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Ys:
foreach ($NH as $Jp => $mi) {
$Nv = sanitize_text_field($_POST["saml_identity_metadata_provider"]);
$Hv = "HttpRedirect";
$LO = '';
$bD = $mi->getLoginDetails();
$tY = $mi->getLogoutDetails();
if (!empty($bD["HTTP-Redirect"])) {
goto H9;
}
if (empty($bD["HTTP-POST"])) {
goto x4;
}
$Hv = "HttpPost";
$LO = $mi->getLoginURL("HTTP-POST");
x4:
goto Ie;
H9:
$LO = $mi->getLoginURL("HTTP-Redirect");
Ie:
$Fw = $mi->getEntityID();
$fK = $mi->getSigningCertificate();
update_option("saml_identity_name", $Nv);
update_option("saml_login_binding_type", $Hv);
update_option("saml_login_url", $LO);
update_option("saml_issuer", $Fw);
update_option("saml_nameid_format", "1.1:nameid-format:unspecified");
update_option("saml_x509_certificate", maybe_serialize($fK));
goto RR;
fH:
}
RR:
update_option("mo_saml_message", "Identity Provider details saved successfully.");
SAMLSPUtilities::mo_saml_show_success_message();
TB:
}
function handleXmlError($YZ, $py, $Hb, $PX)
{
if ($YZ == E_WARNING && substr_count($py, "DOMDocument::loadXML()") > 0) {
goto wn;
}
return false;
goto zP;
wn:
return;
zP:
}
function mo_saml_plugin_action_links($u2)
{
$u2 = array_merge(array("<a href="" . esc_url(admin_url("admin.php?page=mo_saml_settings")) . "">" . __("Settings", "textdomain") . "</a>"), $u2);
return $u2;
}
function checkPasswordPattern($W7)
{
$Fb = "/^[(\w)*(\!\@\#\$\%\^\&\*\.\-\_)*]+$/";
return !preg_match($Fb, $W7);
}
function mo_saml_parse_expiry_date($yG)
{
$pe = new DateTime($yG);
$pN = $pe->getTimestamp();
return date("F j, Y", $pN);
}
}
new saml_mo_login();
?>
Did this file decode correctly?
Original Code
<?php
/**
* This file is a part of the miniorange-saml-20-single-sign-on plugin.
*
* @link https://plugins.miniorange.com/
* @author miniOrange
* @package miniorange-saml-20-single-sign-on
*/
/**
* Plugin Name: miniOrange SSO using SAML 2.0
* Plugin URI: https://miniorange.com/
* Description: (Standard)miniOrange SAML 2.0 SSO enables user to perform Single Sign On with any SAML 2.0 enabled Identity Provider.
* Version: 16.1.4
* Author: miniOrange
* Author URI: https://miniorange.com/
*/
define("\x4d\x4f\x5f\123\x41\115\114\x5f\x50\x4c\x55\107\x49\116\137\104\x49\122", dirname(__FILE__));
define("\x4d\x4f\x5f\123\x41\x4d\x4c\137\117\120\124\x49\x4f\116\x53\x5f\x45\116\x55\115", "\57\x69\156\x63\x6c\x75\144\x65\163\57\x6c\x69\x62\x2f\155\x6f\x2d\157\x70\164\151\157\x6e\x73\x2d\145\156\165\155\x2e\160\x68\160");
require_once MO_SAML_PLUGIN_DIR . MO_SAML_OPTIONS_ENUM;
require_once Mo_Saml_Plugin_Files::MO_SAML_SSO_WIDGET;
require_once Mo_Saml_Plugin_Files::MO_SAML_LICENSE_LIB_AUTOLOADER;
require_once Mo_Saml_Plugin_Files::MO_SAML_XML_SEC_LIBS;
use MOSAML\LicenseLibrary\Classes\Mo_License_Library;
use RobRichards\XMLSecLibs\XMLSecurityKey;
use RobRichards\XMLSecLibs\XMLSecurityDSig;
use MOSAML\LicenseLibrary\Mo_License_Service;
use RobRichards\XMLSecLibs\XMLSecEnc;
require_once Mo_Saml_Plugin_Files::MO_SAML_CLASS_CUSTOMER;
require_once Mo_Saml_Plugin_Files::MO_SAML_SETTINGS_PAGE;
require_once Mo_Saml_Plugin_Files::MO_SAML_METADATA_READER;
require_once Mo_Saml_Plugin_Files::MO_SAML_CERTIFICATE_UTILITY;
require_once Mo_Saml_Plugin_Files::MO_SAML_IMPORT_EXPORT;
require_once Mo_Saml_Plugin_Files::MO_SAML_PLUGIN_VERSION_UPDATE;
class saml_mo_login
{
function __construct()
{
new Mo_License_Library();
add_action("\x61\x64\155\x69\156\137\155\145\x6e\x75", array($this, "\155\151\x6e\x69\x6f\162\x61\x6e\147\145\137\x73\163\x6f\137\x6d\145\x6e\165"));
add_action("\141\144\155\x69\x6e\x5f\x69\x6e\x69\x74", array($this, "\155\x69\x6e\x69\x6f\162\x61\x6e\147\x65\x5f\x6c\x6f\x67\151\x6e\x5f\167\x69\144\147\145\x74\x5f\163\x61\x6d\154\x5f\x73\x61\x76\145\137\163\x65\164\x74\151\x6e\147\x73"));
add_action("\x61\144\x6d\151\x6e\x5f\145\x6e\x71\x75\145\165\x65\x5f\163\143\162\151\160\x74\163", array($this, "\x70\x6c\x75\x67\x69\156\137\x73\145\x74\x74\x69\x6e\147\x73\x5f\x73\x74\171\154\x65"));
register_deactivation_hook(__FILE__, array($this, "\155\x6f\137\x73\x73\x6f\x5f\x73\141\155\x6c\137\x64\x65\141\x63\x74\x69\x76\141\164\x65"));
add_action("\x61\144\155\x69\156\137\x65\156\x71\165\x65\165\x65\137\x73\x63\162\x69\x70\x74\163", array($this, "\160\154\165\x67\151\156\137\x73\145\164\164\151\x6e\147\163\x5f\163\x63\x72\151\160\x74"));
remove_action("\x61\144\155\x69\156\x5f\x6e\x6f\164\151\143\145\163", array($this, "\155\x6f\137\x73\141\x6d\x6c\x5f\163\165\x63\x63\x65\163\x73\x5f\155\x65\x73\163\141\147\x65"));
remove_action("\141\x64\155\151\x6e\x5f\156\x6f\x74\x69\x63\145\x73", array($this, "\155\157\x5f\163\141\x6d\154\x5f\x65\x72\x72\x6f\x72\x5f\x6d\145\163\163\141\147\145"));
add_action("\167\x70\x5f\141\165\x74\x68\145\156\x74\x69\143\x61\164\145", array($this, "\155\157\137\163\x61\x6d\154\137\x61\165\x74\150\145\156\164\151\x63\x61\x74\x65"));
add_action("\167\160", array($this, "\155\157\137\x73\x61\x6d\x6c\x5f\141\165\x74\x6f\137\x72\145\144\x69\x72\x65\x63\164"));
add_action("\141\x64\155\x69\156\x5f\151\156\151\164", "\x6d\x6f\x5f\163\x61\x6d\154\137\x64\x6f\167\156\154\x6f\x61\x64");
add_action("\x6c\x6f\147\151\156\137\x66\157\162\155", array($this, "\155\x6f\x5f\x73\141\x6d\x6c\137\x6d\157\144\151\x66\x79\137\x6c\x6f\x67\x69\156\137\x66\157\162\x6d"));
add_shortcode("\x4d\x4f\x5f\123\x41\115\x4c\137\106\117\122\x4d", array($this, "\155\157\137\147\x65\164\x5f\x73\141\x6d\154\137\x73\150\157\162\164\x63\x6f\144\145"));
add_action("\x61\x64\x6d\x69\x6e\x5f\x69\156\x69\164", array($this, "\144\145\146\141\165\x6c\x74\x5f\143\145\x72\164\151\x66\x69\x63\x61\164\x65"));
register_activation_hook(__FILE__, array($this, "\155\x6f\x5f\x73\x61\155\154\137\160\154\165\x67\x69\156\x5f\141\143\x74\x69\x76\x61\164\x65\x5f\x61\143\164\x69\x6f\x6e\x73"));
add_action("\160\x6c\165\147\x69\x6e\x5f\141\x63\x74\x69\157\156\x5f\x6c\x69\x6e\153\163\137" . plugin_basename(__FILE__), array($this, "\x6d\x6f\137\163\141\x6d\154\137\160\154\x75\147\151\156\x5f\x61\x63\x74\x69\x6f\156\x5f\x6c\151\x6e\x6b\x73"));
if (!Mo_License_Service::is_customer_license_valid(false, false)) {
goto DU;
}
add_action("\167\151\x64\147\145\x74\x73\137\151\156\x69\x74", "\155\x6f\x5f\x73\141\155\154\x5f\x72\x65\x67\x69\x73\164\145\162\137\167\151\144\x67\x65\164");
DU:
}
function default_certificate()
{
$kK = file_get_contents(plugin_dir_path(__FILE__) . "\x72\145\x73\157\165\162\143\145\163" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Public_Certificate);
$zo = file_get_contents(plugin_dir_path(__FILE__) . "\162\145\x73\x6f\165\x72\x63\145\x73" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Private_Key);
if (!(!get_option("\x6d\x6f\x5f\x73\x61\x6d\154\x5f\143\165\x72\x72\x65\x6e\164\137\143\145\162\x74") && !get_option("\x6d\157\137\x73\141\x6d\154\x5f\143\165\x72\x72\x65\x6e\x74\x5f\x63\x65\x72\x74\x5f\x70\x72\x69\x76\x61\164\x65\137\153\145\171"))) {
goto av;
}
if (get_option("\155\x6f\x5f\x73\x61\155\154\137\x63\x65\x72\x74") && get_option("\155\157\137\163\141\x6d\x6c\x5f\x63\145\x72\164\x5f\160\162\151\166\x61\x74\145\x5f\x6b\x65\171")) {
goto ma;
}
update_option("\155\x6f\137\163\x61\x6d\x6c\x5f\143\165\162\x72\x65\156\x74\137\x63\x65\162\x74", $kK);
update_option("\x6d\157\137\x73\141\155\154\x5f\143\165\162\x72\x65\156\164\x5f\x63\x65\162\164\x5f\160\x72\x69\x76\141\164\145\x5f\153\145\x79", $zo);
goto MJ;
ma:
update_option("\x6d\157\137\163\x61\x6d\154\137\x63\165\162\162\145\156\164\x5f\x63\145\162\x74", get_option("\155\x6f\x5f\x73\x61\x6d\154\137\143\x65\x72\164"));
update_option("\155\x6f\x5f\x73\x61\x6d\154\137\x63\x75\x72\162\x65\x6e\x74\x5f\x63\145\x72\x74\x5f\x70\x72\151\x76\x61\x74\145\137\153\145\x79", get_option("\155\x6f\137\x73\141\x6d\x6c\137\143\145\162\x74\137\160\x72\151\x76\x61\164\x65\137\x6b\x65\171"));
MJ:
av:
}
function mo_login_widget_saml_options()
{
global $wpdb;
update_option("\155\x6f\x5f\163\x61\155\154\x5f\x68\x6f\x73\x74\x5f\156\141\x6d\145", "\x68\x74\x74\160\163\72\x2f\x2f\x6c\x6f\x67\x69\156\x2e\170\x65\x63\x75\162\151\146\x79\x2e\143\x6f\155");
$xU = get_option("\x6d\x6f\137\x73\141\155\x6c\137\x68\x6f\x73\x74\x5f\156\x61\x6d\x65");
mo_register_saml_sso();
}
function mo_saml_plugin_activate_actions()
{
$this->keep_settings_intact();
$this->mo_saml_check_openssl();
}
function keep_settings_intact()
{
if (!("\164\162\165\x65" !== get_option(mo_options_enum_sso_login::KEEP_CONFIGURATION_INTACT))) {
goto nz;
}
update_option(mo_options_enum_sso_login::KEEP_CONFIGURATION_INTACT, "\x74\x72\x75\145");
nz:
}
function mo_saml_check_openssl()
{
if (mo_saml_is_extension_installed("\157\x70\145\x6e\x73\x73\154")) {
goto Di;
}
wp_die("\120\110\x50\x20\157\160\145\156\x73\163\x6c\40\x65\170\164\145\156\x73\151\x6f\x6e\40\151\163\40\156\157\164\x20\x69\156\163\164\141\x6c\x6c\145\x64\40\x6f\162\40\x64\151\x73\x61\142\x6c\145\144\54\x70\x6c\x65\141\163\x65\x20\x65\156\141\x62\x6c\145\40\x69\164\x20\x74\x6f\40\x61\143\164\x69\x76\x61\x74\145\40\164\x68\145\x20\160\x6c\165\147\x69\x6e\x2e");
Di:
add_option("\101\x63\164\x69\x76\141\x74\x65\x64\x5f\x50\x6c\165\x67\x69\x6e", "\120\154\x75\x67\x69\x6e\x2d\x53\154\165\147");
}
public function mo_sso_saml_deactivate()
{
Mo_License_Service::reset_license_values();
if (!is_multisite()) {
goto OI;
}
global $wpdb;
$hP = $wpdb->get_col("\x53\x45\114\x45\103\124\x20\x62\154\157\x67\137\x69\x64\x20\106\122\x4f\115\40{$wpdb->blogs}");
$B8 = get_current_blog_id();
do_action("\155\157\137\x73\x61\155\x6c\137\146\x6c\165\x73\x68\x5f\x63\141\143\150\145");
foreach ($hP as $blog_id) {
switch_to_blog($blog_id);
delete_option("\x6d\x6f\137\163\141\x6d\154\137\150\x6f\x73\164\137\x6e\141\x6d\x65");
delete_option("\x6d\157\x5f\x73\x61\x6d\x6c\x5f\156\145\167\x5f\x72\145\147\151\163\x74\x72\141\164\151\x6f\156");
delete_option("\155\x6f\x5f\163\141\155\154\137\x61\x64\155\x69\x6e\x5f\160\150\157\156\x65");
delete_option("\x6d\x6f\x5f\163\x61\155\154\137\141\144\x6d\151\156\x5f\x70\x61\x73\163\x77\x6f\162\144");
delete_option("\x6d\157\x5f\163\141\x6d\x6c\x5f\x76\x65\162\151\x66\x79\137\x63\x75\x73\x74\x6f\x6d\x65\162");
delete_option("\155\x6f\x5f\x73\x61\155\x6c\137\x61\144\x6d\x69\x6e\x5f\x63\x75\x73\x74\x6f\x6d\x65\162\137\x6b\145\x79");
delete_option("\155\x6f\137\x73\x61\155\154\137\141\144\x6d\x69\156\137\141\160\151\137\x6b\145\x79");
delete_option("\155\x6f\137\163\x61\x6d\154\137\143\165\x73\x74\x6f\155\x65\x72\137\164\x6f\153\x65\x6e");
delete_option("\x6d\x6f\x5f\x73\x61\x6d\154\x5f\155\x65\x73\x73\141\x67\x65");
delete_option("\x6d\157\x5f\163\x61\155\154\x5f\x72\145\x67\151\x73\x74\162\x61\x74\151\x6f\x6e\137\163\164\x61\x74\165\x73");
delete_option("\x6d\x6f\x5f\x73\x61\x6d\x6c\137\151\x64\160\x5f\x63\157\156\146\x69\x67\137\x63\157\155\160\154\x65\x74\145");
delete_option("\x6d\x6f\x5f\x73\141\x6d\154\137\164\x72\x61\156\163\x61\143\x74\151\157\156\x49\x64");
delete_option("\x76\x6c\137\143\150\x65\143\153\137\164");
delete_option("\166\x6c\x5f\x63\150\x65\143\153\137\163");
delete_option("\x6d\x6f\137\x73\x61\x6d\154\137\x63\145\162\164");
delete_option("\x73\155\154\x5f\x6c\x6b");
delete_option("\155\157\x5f\x73\x61\x6d\154\137\143\145\162\164\137\x70\162\x69\x76\141\164\x65\137\153\145\171");
delete_option("\x6d\157\137\163\x61\x6d\154\x5f\145\156\141\142\x6c\x65\x5f\x63\154\157\x75\x64\x5f\x62\162\157\x6b\x65\162");
V0:
}
UR:
switch_to_blog($B8);
goto iD;
OI:
do_action("\x6d\x6f\137\x73\141\x6d\154\x5f\x66\x6c\165\163\150\137\143\141\143\150\145");
delete_option("\155\157\x5f\163\x61\x6d\x6c\137\150\157\163\164\137\156\141\x6d\x65");
delete_option("\155\x6f\137\x73\141\x6d\x6c\x5f\x6e\x65\x77\137\x72\145\x67\x69\163\164\x72\x61\x74\151\x6f\156");
delete_option("\x6d\157\x5f\x73\x61\x6d\154\x5f\x61\144\x6d\x69\156\x5f\160\150\157\x6e\x65");
delete_option("\155\157\137\163\x61\155\154\137\141\x64\x6d\151\156\x5f\160\141\x73\x73\x77\x6f\x72\x64");
delete_option("\155\x6f\x5f\163\x61\155\x6c\137\166\145\x72\151\146\171\x5f\143\x75\x73\x74\x6f\155\x65\162");
delete_option("\x6d\x6f\x5f\163\141\x6d\x6c\137\141\144\x6d\151\156\x5f\x63\165\x73\164\157\155\145\162\137\153\x65\171");
delete_option("\x6d\157\x5f\x73\141\x6d\154\137\x61\x64\x6d\151\x6e\x5f\x61\160\151\x5f\x6b\x65\x79");
delete_option("\x6d\157\x5f\x73\141\155\x6c\x5f\143\165\163\x74\x6f\x6d\x65\162\137\x74\157\153\x65\x6e");
delete_option("\x6d\x6f\137\163\x61\155\x6c\137\x6d\x65\x73\x73\x61\x67\x65");
delete_option("\155\x6f\x5f\163\x61\x6d\154\x5f\x72\145\147\x69\x73\164\162\x61\164\x69\x6f\x6e\137\163\x74\141\x74\165\x73");
delete_option("\155\x6f\x5f\x73\x61\x6d\x6c\137\x69\144\160\x5f\143\x6f\156\x66\151\x67\x5f\143\x6f\155\160\154\145\164\145");
delete_option("\x6d\x6f\x5f\x73\141\x6d\x6c\137\164\x72\141\x6e\163\141\x63\x74\151\157\x6e\x49\x64");
delete_option("\x76\x6c\x5f\x63\x68\145\x63\x6b\137\x74");
delete_option("\166\x6c\x5f\143\150\x65\x63\x6b\x5f\163");
delete_option("\x6d\x6f\x5f\x73\141\155\x6c\x5f\143\x65\x72\164");
delete_option("\163\155\154\x5f\x6c\x6b");
delete_option("\x6d\x6f\x5f\x73\141\x6d\154\137\x63\x65\162\x74\137\160\162\x69\166\x61\x74\x65\137\153\x65\x79");
delete_option("\x6d\x6f\x5f\163\141\x6d\154\137\145\x6e\x61\x62\x6c\145\x5f\143\x6c\x6f\165\144\137\142\x72\x6f\153\x65\162");
iD:
}
function plugin_settings_style($H_)
{
if (!("\164\157\160\x6c\145\166\x65\154\137\x70\x61\147\x65\137\155\157\137\163\x61\155\x6c\137\163\145\164\x74\151\156\147\x73" != $H_ && "\155\151\x6e\151\x6f\x72\141\156\x67\145\x2d\x73\141\155\154\x2d\62\55\x30\x2d\x73\x73\x6f\137\x70\141\x67\x65\137\155\157\x5f\145\x72\x72\157\162\137\143\157\x64\145\163" !== $H_)) {
goto uS;
}
return;
uS:
if (!(isset($_REQUEST["\164\141\142"]) && $_REQUEST["\164\141\x62"] == "\154\x69\143\145\x6e\163\151\156\147")) {
goto hQ;
}
wp_enqueue_style("\155\x6f\x5f\x73\x61\x6d\154\x5f\142\x6f\x6f\x74\163\x74\x72\141\160\x5f\x63\x73\163", plugins_url("\151\x6e\x63\x6c\165\x64\x65\x73\57\x63\x73\x73\x2f\x62\157\x6f\164\x73\x74\x72\141\160\x2f\142\157\x6f\x74\163\164\x72\x61\160\x2e\155\151\x6e\x2e\143\163\x73", __FILE__), array(), mo_options_plugin_constants::Version, "\141\154\x6c");
hQ:
wp_enqueue_style("\155\157\137\x73\141\x6d\154\137\141\144\155\151\x6e\x5f\x73\145\x74\x74\x69\156\x67\163\137\x73\164\171\x6c\145\x5f\x74\x72\141\143\x6b\145\x72", plugins_url("\151\156\x63\154\x75\144\x65\163\x2f\143\x73\163\57\x70\x72\157\x67\162\145\163\x73\55\x74\162\x61\143\x6b\x65\162\x2e\x63\163\163", __FILE__), array(), mo_options_plugin_constants::Version, "\141\154\x6c");
wp_enqueue_style("\x6d\157\x5f\163\x61\x6d\x6c\x5f\x61\144\155\x69\x6e\137\x73\145\x74\x74\151\x6e\x67\x73\137\163\164\171\x6c\x65", plugins_url("\151\156\143\x6c\x75\x64\x65\x73\x2f\x63\163\x73\x2f\x73\x74\x79\154\x65\137\163\x65\164\164\x69\x6e\x67\163\56\155\x69\156\x2e\143\163\x73", __FILE__), array(), mo_options_plugin_constants::Version, "\141\x6c\154");
wp_enqueue_style("\x6d\157\x5f\x73\141\155\154\137\141\x64\155\151\156\x5f\163\145\164\164\x69\x6e\147\x73\137\x70\x68\x6f\x6e\x65\x5f\x73\x74\171\x6c\x65", plugins_url("\151\x6e\143\x6c\165\144\x65\163\x2f\x63\x73\163\57\160\x68\x6f\156\x65\x2e\x6d\151\x6e\56\x63\x73\163", __FILE__), array(), mo_options_plugin_constants::Version, "\141\x6c\154");
wp_enqueue_style("\x6d\157\x5f\x73\x61\x6d\x6c\x5f\x77\160\142\x2d\x66\x61", plugins_url("\x69\156\x63\x6c\x75\144\x65\x73\x2f\x63\x73\163\x2f\x66\157\156\x74\x2d\x61\167\x65\163\157\155\x65\56\155\151\x6e\56\x63\x73\x73", __FILE__), array(), mo_options_plugin_constants::Version, "\x61\x6c\154");
}
function plugin_settings_script($H_)
{
if (!("\x74\157\x70\154\x65\x76\x65\154\x5f\160\141\147\x65\137\x6d\157\x5f\x73\x61\155\x6c\x5f\163\145\164\x74\x69\156\x67\x73" != $H_)) {
goto t5;
}
return;
t5:
wp_enqueue_script("\x6a\x71\165\x65\x72\x79");
wp_enqueue_script("\x6d\x6f\137\x73\x61\x6d\x6c\x5f\x61\x64\x6d\x69\x6e\137\142\x6f\157\164\163\x74\162\x61\160\137\163\143\x72\151\160\x74", plugins_url("\151\156\143\154\x75\x64\x65\x73\57\x6a\163\x2f\142\x6f\x6f\x74\x73\x74\x72\141\160\56\152\163", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("\155\157\137\x73\x61\155\x6c\x5f\x61\144\x6d\x69\x6e\x5f\x73\145\164\x74\151\x6e\x67\163\x5f\163\x63\162\x69\160\x74", plugins_url("\151\x6e\x63\x6c\165\x64\145\163\x2f\x6a\x73\57\163\x65\164\164\151\156\147\x73\x2e\155\151\x6e\56\152\x73", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("\155\157\x5f\x73\141\155\x6c\x5f\x61\144\155\151\156\137\163\x65\164\x74\151\156\x67\x73\137\x70\150\x6f\x6e\145\x5f\163\x63\x72\x69\160\x74", plugins_url("\151\x6e\143\154\165\144\145\163\x2f\x6a\163\57\x70\150\x6f\x6e\145\56\x6d\x69\156\56\x6a\x73", __FILE__), array(), mo_options_plugin_constants::Version, false);
if (!(isset($_REQUEST["\x74\141\x62"]) && $_REQUEST["\164\141\x62"] == "\154\151\x63\145\x6e\x73\x69\x6e\x67")) {
goto CQ;
}
wp_enqueue_script("\155\x6f\137\x73\x61\x6d\x6c\x5f\x6d\x6f\x64\145\x72\156\x69\x7a\162\x5f\163\143\x72\x69\x70\164", plugins_url("\151\x6e\x63\154\165\144\145\163\57\x6a\x73\x2f\x6d\x6f\x64\145\162\x6e\x69\x7a\x72\56\x6a\x73", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("\x6d\x6f\137\x73\x61\155\x6c\137\x70\157\160\x6f\x76\145\x72\x5f\x73\x63\x72\151\x70\x74", plugins_url("\151\x6e\143\x6c\x75\144\x65\163\x2f\152\x73\x2f\142\157\x6f\164\x73\164\x72\x61\x70\x2f\160\x6f\x70\160\145\x72\56\x6d\x69\x6e\x2e\152\x73", __FILE__), array(), mo_options_plugin_constants::Version, false);
wp_enqueue_script("\x6d\x6f\137\163\141\155\154\x5f\x62\157\157\x74\x73\164\x72\x61\x70\x5f\x73\x63\x72\151\x70\x74", plugins_url("\x69\x6e\143\x6c\165\x64\x65\163\x2f\x6a\x73\57\142\157\x6f\x74\x73\164\162\141\160\x2f\142\157\157\164\x73\x74\162\x61\x70\56\155\x69\156\x2e\152\x73", __FILE__), array(), mo_options_plugin_constants::Version, false);
CQ:
}
function mo_saml_activation_message()
{
$jW = "\165\160\144\x61\164\145\x64";
$dq = get_option("\155\157\x5f\163\x61\x6d\154\x5f\155\145\x73\163\141\x67\x65");
echo "\x3c\x64\151\166\40\143\154\141\x73\x73\75\x27" . esc_attr($jW) . "\x27\x3e\x20\74\160\76" . SAMLSPUtilities::mo_saml_kses_esc_message($dq) . "\74\57\x70\76\x3c\x2f\x64\151\x76\x3e";
}
static function mo_check_option_admin_referer($AH)
{
return isset($_POST["\x6f\x70\x74\x69\157\156"]) and $_POST["\157\x70\164\x69\157\x6e"] == $AH and check_admin_referer($AH);
}
function miniorange_login_widget_saml_save_settings()
{
if (!current_user_can("\x6d\x61\156\141\x67\145\x5f\x6f\160\164\151\x6f\x6e\x73")) {
goto RE;
}
if (!(is_admin() && get_option("\x41\143\164\x69\x76\x61\x74\145\x64\137\x50\x6c\x75\147\x69\x6e") == "\x50\x6c\165\147\151\x6e\x2d\123\154\165\x67")) {
goto k3;
}
delete_option("\x41\143\x74\151\166\x61\x74\145\x64\137\120\x6c\165\147\x69\156");
update_option("\155\157\x5f\163\141\155\x6c\x5f\x6d\x65\163\x73\x61\x67\145", "\x47\157\40\164\157\40\160\x6c\x75\147\x69\156\x20\74\142\x3e\x3c\141\40\150\x72\x65\146\75\42\141\144\x6d\x69\x6e\x2e\160\x68\160\x3f\x70\141\147\145\75\155\157\137\x73\141\x6d\x6c\137\163\145\164\164\x69\156\x67\163\x22\x3e\163\145\164\x74\x69\156\147\x73\x3c\x2f\x61\76\74\57\142\76\40\x74\157\40\143\157\x6e\x66\x69\x67\165\162\x65\40\123\x41\115\x4c\40\x53\151\156\147\154\x65\x20\x53\151\x67\x6e\x20\x4f\156\x20\x62\x79\x20\x6d\x69\x6e\x69\117\162\x61\x6e\x67\x65\56");
add_action("\x61\x64\x6d\x69\156\x5f\x6e\157\x74\151\x63\x65\163", array($this, "\155\x6f\x5f\163\x61\155\154\x5f\141\143\x74\151\x76\x61\164\151\157\156\x5f\155\145\163\x73\141\x67\145"));
k3:
if (!(self::mo_check_option_admin_referer("\x6c\x6f\147\151\x6e\137\167\151\x64\147\x65\164\137\x73\141\x6d\x6c\x5f\163\141\166\145\x5f\163\145\x74\164\x69\x6e\147\163") && Mo_License_Service::is_customer_license_valid())) {
goto cH;
}
if (mo_saml_is_extension_installed("\x63\x75\x72\154")) {
goto K8;
}
update_option("\x6d\157\x5f\x73\141\x6d\x6c\x5f\x6d\x65\x73\x73\x61\x67\x65", "\105\122\122\117\x52\72\120\x48\x50\40\x63\125\122\x4c\x20\145\170\x74\145\x6e\163\151\x6f\x6e\x20\x69\163\x20\x6e\157\164\40\x69\x6e\x73\x74\141\x6c\154\145\x64\40\157\162\x20\x64\151\163\141\142\x6c\x65\144\56\x20\123\141\166\145\x20\111\144\145\x6e\x74\x69\164\171\x20\120\162\157\166\x69\x64\x65\162\40\103\157\x6e\x66\151\147\x75\x72\141\164\x69\x6f\156\x20\146\141\x69\x6c\x65\144\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
K8:
$Nv = '';
$Hv = '';
$LO = '';
$nv = '';
$q2 = '';
$Fw = '';
$fK = '';
$Wx = '';
if ($this->mo_saml_check_empty_or_null($_POST["\163\141\x6d\154\x5f\x69\x64\x65\x6e\x74\x69\164\x79\x5f\156\x61\155\x65"]) || $this->mo_saml_check_empty_or_null($_POST["\163\141\155\154\137\x6c\x6f\147\151\156\x5f\165\162\x6c"]) || $this->mo_saml_check_empty_or_null($_POST["\163\141\155\x6c\137\151\163\163\165\x65\162"]) || $this->mo_saml_check_empty_or_null($_POST["\163\x61\x6d\x6c\137\x6e\x61\x6d\x65\151\144\x5f\146\157\162\x6d\141\164"])) {
goto n9;
}
if (!preg_match("\57\136\134\167\52\x24\57", $_POST["\163\141\x6d\154\137\151\x64\145\156\164\x69\164\x79\137\x6e\x61\155\x65"])) {
goto iZ;
}
$Nv = sanitize_text_field(trim($_POST["\163\x61\x6d\x6c\x5f\x69\144\x65\x6e\x74\151\x74\171\x5f\x6e\141\155\145"]));
$LO = SAMLSPUtilities::mo_saml_sanitize_url(trim($_POST["\x73\141\x6d\154\137\x6c\x6f\147\151\x6e\x5f\x75\x72\154"]));
if (!isset($_POST["\163\x61\x6d\154\137\154\157\147\151\156\137\x62\151\156\x64\x69\x6e\x67\137\164\x79\160\145"])) {
goto zL;
}
$Hv = sanitize_text_field($_POST["\163\x61\x6d\154\137\154\157\147\x69\156\x5f\x62\151\156\144\151\156\x67\137\x74\x79\x70\145"]);
zL:
$Fw = sanitize_text_field(trim($_POST["\163\141\x6d\154\137\x69\x73\x73\x75\145\x72"]));
$Jz = sanitize_text_field(trim($_POST["\163\x61\155\154\137\x69\144\145\156\164\x69\x74\171\137\160\162\x6f\166\x69\144\145\x72\137\147\x75\x69\144\x65\x5f\156\141\x6d\145"]));
$fK = $_POST["\x73\x61\x6d\154\137\x78\65\x30\71\x5f\143\x65\x72\x74\x69\x66\x69\143\x61\164\145"];
$q2 = sanitize_text_field($_POST["\x73\141\x6d\x6c\x5f\x6e\141\x6d\x65\x69\x64\x5f\146\157\162\x6d\141\164"]);
goto p7;
iZ:
update_option("\155\x6f\x5f\163\x61\155\154\137\x6d\x65\163\163\x61\x67\x65", "\120\x6c\145\141\163\145\40\155\141\x74\143\150\40\164\150\145\x20\162\x65\x71\x75\x65\x73\164\145\144\40\146\x6f\x72\x6d\x61\x74\x20\x66\157\x72\x20\111\x64\x65\x6e\164\x69\x74\x79\40\x50\x72\157\166\x69\144\145\x72\40\116\141\155\x65\x2e\40\x4f\156\x6c\171\40\141\x6c\160\x68\141\x62\x65\164\163\x2c\40\x6e\x75\x6d\x62\x65\162\x73\40\x61\156\x64\x20\x75\156\144\145\x72\x73\143\157\162\145\40\x69\x73\x20\x61\154\x6c\157\x77\145\144\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
p7:
goto OU;
n9:
update_option("\x6d\x6f\x5f\163\x61\x6d\x6c\x5f\155\x65\163\x73\141\147\x65", "\101\x6c\x6c\40\x74\x68\145\x20\146\151\145\x6c\144\163\x20\x61\162\145\40\162\145\161\x75\x69\x72\x65\144\56\40\x50\x6c\x65\141\x73\145\x20\145\156\x74\145\x72\40\166\141\154\151\144\x20\x65\x6e\x74\x72\151\145\x73\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
OU:
update_option("\163\x61\155\154\137\x69\x64\x65\156\x74\151\164\171\x5f\x6e\141\155\x65", $Nv);
update_option("\x73\141\x6d\x6c\137\154\x6f\x67\151\x6e\137\142\x69\x6e\x64\x69\x6e\x67\137\164\x79\x70\145", $Hv);
update_option("\x73\x61\x6d\x6c\x5f\154\x6f\x67\x69\156\x5f\165\162\x6c", $LO);
update_option("\x73\141\155\154\137\x6c\x6f\147\x6f\165\x74\x5f\x62\151\x6e\144\x69\156\x67\x5f\x74\x79\160\145", $nv);
update_option("\x73\141\x6d\154\x5f\151\163\x73\165\x65\162", $Fw);
update_option("\x73\141\155\154\137\x6e\141\x6d\x65\x69\x64\137\x66\157\x72\155\x61\x74", $q2);
update_option("\x73\141\155\x6c\x5f\151\144\x65\x6e\164\151\x74\171\137\x70\x72\157\x76\x69\144\x65\162\137\x67\x75\151\x64\x65\137\x6e\141\x6d\x65", $Jz);
if (isset($_POST["\x73\x61\155\x6c\137\162\x65\161\165\145\x73\164\137\x73\151\147\x6e\145\144"])) {
goto vM;
}
update_option("\163\141\x6d\154\x5f\x72\x65\x71\x75\x65\x73\x74\137\x73\x69\x67\156\145\144", "\x75\x6e\x63\150\145\x63\x6b\x65\x64");
goto GL;
vM:
update_option("\x73\141\155\154\137\162\x65\x71\x75\x65\163\x74\137\x73\151\x67\156\145\x64", "\143\150\x65\143\x6b\145\x64");
GL:
foreach ($fK as $Jp => $lG) {
if (empty($lG)) {
goto zd;
}
$fK[$Jp] = SAMLSPUtilities::sanitize_certificate($lG);
if (@openssl_x509_read($fK[$Jp])) {
goto xl;
}
update_option("\x6d\x6f\x5f\x73\x61\155\154\137\155\x65\x73\x73\141\147\145", "\x49\156\166\x61\x6c\151\x64\x20\143\145\162\164\x69\x66\x69\x63\141\164\x65\72\x20\x50\154\x65\141\163\145\x20\160\162\157\x76\151\x64\145\40\x61\x20\x76\x61\x6c\151\144\40\x63\x65\x72\x74\151\146\151\x63\141\x74\145\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
delete_option("\163\x61\x6d\154\x5f\170\x35\x30\71\x5f\x63\145\x72\164\151\x66\151\x63\x61\x74\x65");
return;
xl:
goto T6;
zd:
unset($fK[$Jp]);
T6:
yk:
}
JE:
if (!empty($fK)) {
goto yt;
}
update_option("\155\x6f\x5f\x73\x61\x6d\x6c\x5f\155\x65\x73\163\x61\x67\x65", "\x49\156\166\x61\154\x69\x64\40\103\145\162\164\x69\146\151\143\x61\x74\x65\72\x50\x6c\x65\141\x73\x65\x20\160\162\157\166\151\x64\145\40\x61\40\x63\145\162\x74\151\x66\151\143\x61\164\145");
SAMLSPUtilities::mo_saml_show_error_message();
return;
yt:
update_option("\163\x61\155\154\137\x78\x35\x30\x39\x5f\x63\x65\x72\x74\151\x66\x69\x63\141\x74\145", maybe_serialize($fK));
if (isset($_POST["\x73\141\155\154\137\162\145\x73\160\x6f\x6e\163\x65\137\163\151\x67\x6e\145\x64"])) {
goto zc;
}
update_option("\163\141\x6d\x6c\x5f\x72\145\163\160\157\x6e\163\145\x5f\163\151\x67\x6e\145\144", "\131\145\163");
goto Vb;
zc:
update_option("\163\141\x6d\x6c\137\x72\145\x73\x70\157\x6e\163\145\137\x73\151\147\x6e\x65\144", "\143\150\x65\x63\153\x65\144");
Vb:
if (isset($_POST["\163\x61\x6d\x6c\137\141\x73\163\145\x72\164\x69\x6f\x6e\x5f\x73\151\147\x6e\145\x64"])) {
goto Pe;
}
update_option("\163\x61\155\154\137\141\x73\163\x65\162\164\x69\x6f\156\137\x73\151\x67\156\145\x64", "\131\145\x73");
goto oz;
Pe:
update_option("\x73\x61\x6d\x6c\137\x61\x73\x73\145\162\x74\x69\x6f\x6e\x5f\x73\x69\147\x6e\145\x64", "\143\150\x65\143\x6b\x65\144");
oz:
if (isset($_POST["\145\x6e\141\142\154\145\137\x69\x63\157\x6e\x76"])) {
goto wO;
}
update_option("\155\x6f\137\x73\141\x6d\x6c\x5f\145\x6e\143\157\144\x69\x6e\x67\x5f\x65\156\141\x62\x6c\145\144", '');
goto a0;
wO:
update_option("\155\157\x5f\x73\x61\x6d\x6c\137\145\x6e\143\x6f\144\x69\156\147\x5f\x65\x6e\141\x62\154\x65\x64", "\143\150\145\x63\x6b\145\144");
a0:
update_option("\155\x6f\137\x73\x61\155\154\137\x6d\145\x73\163\141\x67\x65", "\111\144\x65\156\164\x69\164\x79\40\x50\162\157\x76\151\144\x65\x72\40\144\x65\x74\141\151\154\x73\40\163\141\x76\145\x64\x20\163\x75\x63\x63\x65\x73\163\146\x75\154\x6c\x79\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
cH:
if (!(self::mo_check_option_admin_referer("\155\157\137\x73\141\155\x6c\x5f\141\x64\144\137\163\163\x6f\x5f\142\165\164\x74\157\156\137\x77\x70\x5f\157\160\x74\151\x6f\156") && Mo_License_Service::is_customer_license_valid())) {
goto gS;
}
if (mo_saml_is_sp_configured()) {
goto Wd;
}
update_option("\x6d\x6f\x5f\163\141\x6d\x6c\x5f\x6d\x65\x73\163\x61\x67\145", "\x50\x6c\x65\x61\x73\x65\x20\x63\157\x6d\x70\154\145\164\145\40" . addLink("\x53\x65\x72\x76\x69\x63\145\x20\x50\162\157\166\151\x64\x65\x72", SAMLSPUtilities::mo_saml_add_query_arg(array("\x74\141\142" => "\163\x61\x76\145"), $_SERVER["\x52\105\x51\125\105\123\124\x5f\125\x52\111"])) . "\40\x63\x6f\x6e\146\x69\x67\x75\162\141\x74\x69\x6f\156\40\146\151\x72\163\x74\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto Ax;
Wd:
if (isset($_POST["\155\157\137\x73\x61\155\154\x5f\x61\x64\x64\137\x73\x73\157\x5f\x62\165\164\x74\x6f\156\x5f\x77\x70"])) {
goto kG;
}
$Ps = "\146\x61\x6c\x73\145";
goto pl;
kG:
$Ps = sanitize_text_field($_POST["\x6d\x6f\x5f\x73\x61\x6d\154\137\141\144\144\x5f\x73\163\x6f\137\x62\x75\x74\164\x6f\x6e\137\167\160"]);
pl:
update_option("\155\x6f\x5f\x73\x61\155\x6c\x5f\141\144\x64\137\x73\x73\x6f\137\x62\165\164\164\157\156\x5f\167\160", $Ps);
update_option("\x6d\x6f\137\163\141\x6d\154\x5f\x6d\x65\x73\163\141\x67\145", "\x53\x69\147\156\40\x69\156\x20\157\160\164\151\157\156\40\x75\160\144\141\164\145\x64\56");
SAMLSPUtilities::mo_saml_show_success_message();
Ax:
gS:
if (!(self::mo_check_option_admin_referer("\154\x6f\x67\x69\156\x5f\x77\151\144\147\145\x74\x5f\163\141\x6d\154\x5f\141\x74\164\162\x69\142\165\x74\145\x5f\155\x61\x70\x70\x69\x6e\147") && Mo_License_Service::is_customer_license_valid())) {
goto KJ;
}
if (mo_saml_is_extension_installed("\143\165\x72\154")) {
goto n4;
}
update_option("\x6d\x6f\x5f\x73\x61\x6d\154\x5f\155\x65\x73\163\x61\x67\145", "\105\x52\x52\117\122\72\120\x48\x50\x20\143\125\x52\x4c\x20\x65\x78\x74\x65\156\x73\151\x6f\156\40\151\x73\40\156\157\x74\x20\x69\156\x73\x74\x61\154\x6c\145\144\40\157\162\40\x64\x69\x73\141\x62\x6c\x65\144\x2e\40\x53\x61\x76\145\x20\x41\x74\x74\x72\151\142\165\x74\145\40\x4d\x61\x70\x70\x69\156\x67\x20\x66\141\151\x6c\x65\144\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
n4:
update_option("\x73\x61\155\154\x5f\x61\x6d\137\x75\x73\145\162\156\x61\155\145", sanitize_text_field($_POST["\x73\141\155\154\137\x61\x6d\137\x75\163\145\162\x6e\141\x6d\145"]));
update_option("\163\x61\155\154\x5f\141\155\137\x65\x6d\141\151\154", sanitize_text_field($_POST["\163\x61\x6d\154\137\x61\x6d\137\145\155\141\x69\154"]));
update_option("\163\141\x6d\154\x5f\x61\x6d\137\146\151\x72\x73\x74\x5f\156\x61\155\145", sanitize_text_field($_POST["\163\x61\155\x6c\137\x61\x6d\x5f\146\151\162\163\x74\137\156\141\x6d\x65"]));
update_option("\163\x61\x6d\x6c\137\x61\155\x5f\x6c\141\x73\164\137\156\x61\x6d\x65", sanitize_text_field($_POST["\x73\x61\155\154\137\x61\x6d\x5f\x6c\141\x73\x74\x5f\156\141\x6d\145"]));
update_option("\x73\141\x6d\154\137\141\155\137\x64\x69\163\x70\154\141\x79\x5f\156\x61\155\145", sanitize_text_field($_POST["\163\x61\x6d\x6c\x5f\x61\155\x5f\144\151\163\x70\154\x61\x79\x5f\156\x61\155\x65"]));
update_option("\x6d\x6f\x5f\163\x61\155\154\137\155\145\163\x73\141\x67\x65", "\101\164\x74\162\151\142\x75\x74\145\40\115\141\x70\x70\x69\x6e\147\40\x64\x65\x74\x61\151\x6c\163\40\163\x61\x76\x65\x64\x20\x73\x75\x63\143\x65\x73\163\146\x75\x6c\x6c\x79");
SAMLSPUtilities::mo_saml_show_success_message();
KJ:
if (!self::mo_check_option_admin_referer("\143\x6c\x65\x61\162\137\141\164\164\162\163\137\154\151\163\x74")) {
goto lq;
}
delete_option("\x6d\x6f\x5f\x73\x61\155\154\137\164\x65\x73\164\x5f\143\157\156\x66\151\x67\137\x61\x74\164\x72\x73");
update_option("\155\x6f\137\x73\141\x6d\154\137\x6d\x65\163\163\x61\147\145", "\x41\x74\164\162\151\x62\x75\164\x65\163\40\x6c\151\x73\164\x20\x72\145\x6d\x6f\x76\x65\144\x20\x73\x75\x63\143\x65\x73\163\x66\x75\154\x6c\171");
SAMLSPUtilities::mo_saml_show_success_message();
lq:
if (!(self::mo_check_option_admin_referer("\x6c\x6f\147\x69\x6e\x5f\x77\151\x64\x67\x65\164\137\163\141\155\154\x5f\162\x6f\154\x65\137\155\x61\160\x70\151\x6e\147") && Mo_License_Service::is_customer_license_valid())) {
goto nP;
}
if (mo_saml_is_extension_installed("\143\165\x72\154")) {
goto DE;
}
update_option("\x6d\x6f\x5f\163\141\x6d\x6c\x5f\155\145\x73\163\x61\147\145", "\105\122\x52\117\122\72\120\x48\x50\x20\x63\125\x52\114\40\145\x78\x74\x65\x6e\x73\x69\157\156\40\x69\x73\x20\x6e\157\x74\40\151\x6e\x73\164\x61\x6c\154\x65\x64\x20\x6f\162\x20\x64\151\x73\x61\142\x6c\x65\x64\56\40\123\x61\x76\x65\40\x52\x6f\154\145\40\115\141\x70\x70\151\156\x67\x20\146\x61\151\154\145\144\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
DE:
if (isset($_POST["\x6d\x6f\x5f\163\141\155\x6c\x5f\x64\157\x6e\x74\x5f\165\160\x64\x61\164\145\x5f\x65\x78\x69\x73\164\x69\156\147\x5f\165\x73\145\x72\137\x72\x6f\154\145"])) {
goto Tx;
}
update_option("\163\x61\155\154\137\141\155\x5f\x64\x6f\156\x74\137\165\160\144\141\164\x65\137\x65\170\x69\163\164\151\x6e\147\137\165\163\x65\162\x5f\x72\x6f\x6c\145", "\x75\156\x63\150\x65\x63\x6b\145\x64");
goto GS;
Tx:
update_option("\163\141\x6d\x6c\x5f\x61\x6d\137\x64\x6f\x6e\164\137\165\160\x64\x61\x74\x65\x5f\x65\170\151\163\164\151\x6e\x67\x5f\x75\163\145\x72\137\x72\x6f\x6c\145", "\x63\x68\x65\x63\153\145\x64");
GS:
if (!isset($_POST["\x73\x61\155\154\x5f\141\x6d\x5f\144\x65\x66\141\x75\154\164\x5f\x75\163\x65\162\137\162\x6f\154\x65"])) {
goto HN;
}
$ji = sanitize_text_field($_POST["\x73\141\x6d\x6c\x5f\141\155\137\144\x65\146\x61\165\x6c\164\x5f\x75\x73\145\x72\x5f\162\157\x6c\x65"]);
update_option("\163\x61\x6d\154\x5f\x61\155\137\144\145\146\x61\x75\154\164\x5f\165\163\145\162\137\162\157\x6c\145", $ji);
HN:
update_option("\x6d\157\x5f\x73\x61\155\x6c\x5f\x6d\x65\163\x73\141\147\x65", "\x52\157\x6c\145\40\115\141\160\160\151\x6e\147\40\x64\145\164\141\151\x6c\x73\x20\x73\141\166\145\144\40\163\165\143\x63\145\x73\163\x66\165\154\154\171\56");
SAMLSPUtilities::mo_saml_show_success_message();
nP:
if (!(self::mo_check_option_admin_referer("\x6d\157\x5f\x73\x61\155\x6c\137\x75\160\x64\x61\x74\145\x5f\x69\144\160\x5f\163\x65\x74\164\x69\x6e\147\x73\x5f\x6f\x70\x74\x69\x6f\x6e") && Mo_License_Service::is_customer_license_valid())) {
goto U9;
}
if (!(isset($_POST["\155\157\x5f\163\x61\155\x6c\x5f\x73\160\137\x62\141\163\x65\x5f\165\x72\154"]) && isset($_POST["\x6d\157\x5f\x73\x61\x6d\x6c\x5f\x73\160\x5f\145\156\x74\x69\164\171\x5f\x69\144"]))) {
goto xN;
}
$Tb = SAMLSPUtilities::mo_saml_sanitize_url($_POST["\155\x6f\x5f\163\141\x6d\x6c\137\163\x70\137\x62\141\163\x65\x5f\x75\x72\154"]);
$yX = sanitize_text_field($_POST["\155\157\137\x73\141\155\x6c\137\x73\x70\x5f\x65\x6e\x74\x69\164\171\x5f\x69\x64"]);
if (!(substr($Tb, -1) == "\x2f")) {
goto W8;
}
$Tb = substr($Tb, 0, -1);
W8:
update_option("\155\157\137\163\x61\155\154\x5f\163\160\x5f\x62\x61\163\x65\x5f\165\162\154", $Tb);
update_option("\x6d\157\x5f\163\141\155\154\x5f\x73\x70\x5f\145\156\164\151\x74\171\x5f\x69\144", $yX);
xN:
update_option("\x6d\x6f\137\x73\141\155\154\x5f\155\x65\163\x73\x61\x67\x65", "\x53\x65\x74\164\x69\x6e\147\163\40\x75\160\144\x61\x74\x65\x64\40\163\x75\x63\143\x65\163\x73\146\165\x6c\154\171\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
U9:
if (!(self::mo_check_option_admin_referer("\163\x61\155\154\x5f\165\x70\154\157\x61\144\137\155\145\164\x61\144\141\x74\141") && Mo_License_Service::is_customer_license_valid())) {
goto kv;
}
if (!function_exists("\x77\x70\x5f\x68\x61\x6e\x64\x6c\x65\137\x75\160\154\x6f\x61\x64")) {
require_once Mo_Saml_WordPress_Files::MO_SAML_WP_ADMIN_FILE;
}
$this->_handle_upload_metadata();
kv:
if (!self::mo_check_option_admin_referer("\x75\160\147\162\141\144\x65\x5f\x63\145\162\x74")) {
goto kJ;
}
$kK = file_get_contents(plugin_dir_path(__FILE__) . "\162\x65\x73\x6f\x75\162\x63\x65\x73" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Public_Certificate);
$zo = file_get_contents(plugin_dir_path(__FILE__) . "\162\x65\163\x6f\x75\162\x63\x65\163" . DIRECTORY_SEPARATOR . mo_options_enum_default_sp_certificate::SP_Private_Key);
update_option("\x6d\x6f\137\163\x61\155\154\137\x63\x75\x72\162\145\x6e\x74\x5f\x63\145\162\x74", $kK);
update_option("\155\157\x5f\163\141\x6d\154\x5f\x63\x75\x72\x72\x65\156\x74\x5f\143\x65\162\x74\x5f\x70\x72\151\166\x61\x74\x65\x5f\153\x65\171", $zo);
update_option("\155\x6f\137\x73\141\155\154\137\x63\x65\x72\164\x69\146\x69\x63\141\x74\x65\137\162\157\x6c\154\x5f\x62\141\143\x6b\x5f\141\166\x61\x69\154\x61\142\154\145", true);
update_option("\x6d\157\x5f\x73\x61\x6d\x6c\137\155\x65\x73\163\x61\x67\x65", "\103\x65\162\164\x69\x66\x69\143\x61\164\x65\40\x55\160\x67\162\x61\x64\x65\x64\x20\x73\165\143\143\x65\163\163\146\165\x6c\154\x79");
SAMLSPUtilities::mo_saml_show_success_message();
kJ:
if (!self::mo_check_option_admin_referer("\x72\157\154\x6c\x62\141\143\153\x5f\x63\x65\x72\x74")) {
goto SY;
}
$kK = file_get_contents(plugin_dir_path(__FILE__) . "\162\x65\163\x6f\x75\162\143\x65\163" . DIRECTORY_SEPARATOR . "\163\160\55\x63\x65\162\x74\x69\x66\151\x63\141\x74\145\x2e\x63\x72\x74");
$zo = file_get_contents(plugin_dir_path(__FILE__) . "\162\145\163\157\x75\162\143\145\163" . DIRECTORY_SEPARATOR . "\163\x70\55\153\x65\171\56\x6b\x65\x79");
update_option("\x6d\157\137\163\x61\155\x6c\137\143\x75\162\162\x65\x6e\164\137\x63\145\x72\x74", $kK);
update_option("\x6d\x6f\137\x73\141\155\154\137\143\165\162\162\x65\156\x74\137\143\145\x72\x74\x5f\x70\x72\x69\166\x61\164\145\137\x6b\x65\x79", $zo);
update_option("\155\157\x5f\x73\x61\x6d\x6c\137\155\145\x73\163\x61\147\145", "\x43\145\x72\x74\151\146\x69\143\141\164\145\40\122\157\154\x6c\55\x62\x61\143\x6b\145\x64\x20\163\165\143\x63\x65\163\163\146\x75\x6c\x6c\171");
delete_option("\155\x6f\x5f\x73\x61\x6d\154\137\x63\x65\x72\164\151\x66\151\143\141\164\145\137\162\x6f\x6c\154\x5f\142\x61\143\x6b\x5f\x61\166\141\x69\154\x61\x62\x6c\145");
SAMLSPUtilities::mo_saml_show_success_message();
SY:
if (!(self::mo_check_option_admin_referer("\x6d\157\137\x73\141\155\x6c\x5f\x72\145\154\x61\x79\137\x73\x74\141\164\145\137\x6f\160\164\151\x6f\156") && Mo_License_Service::is_customer_license_valid())) {
goto I4;
}
$XS = SAMLSPUtilities::mo_saml_sanitize_url($_POST["\155\x6f\137\x73\x61\x6d\x6c\137\x72\145\154\x61\171\137\x73\x74\141\x74\x65"]);
update_option("\x6d\157\137\x73\x61\x6d\154\137\162\x65\x6c\x61\x79\137\x73\164\x61\164\x65", $XS);
update_option("\x6d\x6f\x5f\x73\x61\x6d\154\x5f\155\145\163\x73\x61\147\x65", "\122\145\x6c\x61\x79\40\123\x74\x61\x74\145\40\x68\x61\x73\40\142\145\x65\156\40\x75\x70\144\141\164\145\144\x20\x73\x75\x63\x63\145\163\x73\146\x75\154\154\171\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
I4:
if (!(self::mo_check_option_admin_referer("\155\x6f\137\163\x61\155\x6c\x5f\x77\x69\144\x67\x65\x74\137\x6f\160\164\151\x6f\156") && Mo_License_Service::is_customer_license_valid())) {
goto Gj;
}
$fF = sanitize_text_field($_POST["\x6d\x6f\x5f\163\141\x6d\x6c\137\143\x75\163\x74\x6f\155\x5f\154\x6f\x67\151\156\x5f\164\x65\x78\x74"]);
update_option("\x6d\157\137\x73\141\x6d\x6c\x5f\x63\165\163\x74\157\x6d\x5f\154\x6f\x67\x69\156\137\164\145\170\x74", stripcslashes($fF));
$gP = sanitize_text_field($_POST["\155\157\137\x73\x61\x6d\154\x5f\x63\165\x73\164\157\155\137\147\x72\145\x65\x74\x69\156\x67\137\164\145\170\x74"]);
update_option("\x6d\157\137\163\141\x6d\154\x5f\x63\165\163\164\x6f\155\x5f\147\162\x65\x65\164\151\156\147\x5f\x74\145\x78\164", stripcslashes($gP));
$Lu = sanitize_text_field($_POST["\155\157\x5f\x73\141\155\x6c\x5f\x67\162\x65\145\x74\151\156\x67\x5f\156\141\155\145"]);
update_option("\x6d\157\x5f\163\141\155\x6c\137\147\x72\145\x65\164\151\x6e\147\x5f\x6e\141\155\145", stripcslashes($Lu));
$NE = sanitize_text_field($_POST["\155\157\x5f\163\x61\155\154\x5f\143\165\x73\164\x6f\x6d\137\x6c\x6f\147\157\165\164\x5f\164\x65\170\x74"]);
update_option("\x6d\157\x5f\163\x61\155\154\137\x63\165\163\164\157\155\x5f\154\157\x67\157\165\x74\137\x74\145\x78\164", stripcslashes($NE));
update_option("\x6d\157\137\163\x61\155\154\137\x6d\x65\163\163\141\147\145", "\127\151\x64\x67\145\164\40\x53\145\164\x74\151\156\x67\163\x20\x75\x70\144\x61\164\x65\144\40\163\165\x63\x63\145\163\x73\x66\x75\x6c\154\171\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
Gj:
if (!self::mo_check_option_admin_referer("\155\x6f\137\x73\141\155\154\137\x72\145\147\x69\x73\164\145\162\137\x63\165\x73\x74\x6f\155\x65\162")) {
goto tH;
}
if (mo_saml_is_extension_installed("\143\x75\x72\x6c")) {
goto gA;
}
update_option("\155\157\137\x73\141\155\154\x5f\x6d\x65\163\163\141\x67\145", "\105\122\x52\x4f\x52\72\40\x50\110\x50\40\143\125\x52\x4c\x20\x65\x78\164\145\x6e\x73\151\x6f\x6e\x20\x69\x73\x20\x6e\157\x74\40\151\156\163\x74\x61\154\154\145\x64\40\x6f\162\x20\x64\x69\x73\x61\142\154\145\x64\x2e\40\x52\145\147\x69\x73\164\162\x61\x74\x69\x6f\156\40\x66\141\151\x6c\145\144\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
gA:
$BK = '';
$FG = '';
$W7 = '';
$AT = '';
if ($this->mo_saml_check_empty_or_null($_POST["\145\x6d\x61\151\154"]) || $this->mo_saml_check_empty_or_null($_POST["\x70\x61\163\163\x77\x6f\x72\144"]) || $this->mo_saml_check_empty_or_null($_POST["\143\x6f\156\x66\x69\162\155\120\x61\x73\x73\167\157\x72\x64"])) {
goto la;
}
if (strlen($_POST["\160\141\x73\x73\x77\x6f\x72\144"]) < 6 || strlen($_POST["\143\157\x6e\146\151\x72\x6d\120\x61\x73\x73\x77\x6f\162\144"]) < 6) {
goto Jt;
}
if (!filter_var($_POST["\x65\x6d\141\151\x6c"], FILTER_VALIDATE_EMAIL)) {
goto Ng;
}
if ($this->checkPasswordPattern(strip_tags($_POST["\160\x61\163\x73\167\x6f\x72\x64"]))) {
goto w9;
}
$BK = sanitize_email($_POST["\x65\155\x61\x69\x6c"]);
$FG = sanitize_text_field($_POST["\160\150\x6f\x6e\145"]);
$W7 = sanitize_text_field($_POST["\x70\x61\x73\x73\167\x6f\x72\144"]);
$AT = sanitize_text_field($_POST["\143\x6f\156\x66\x69\x72\x6d\x50\x61\x73\x73\x77\x6f\x72\x64"]);
goto t4;
w9:
update_option("\155\157\x5f\x73\x61\155\x6c\x5f\155\145\163\163\141\x67\145", "\x4d\x69\156\151\155\x75\x6d\x20\x36\40\143\x68\141\162\x61\143\164\x65\162\163\40\163\x68\157\165\154\x64\40\x62\145\x20\x70\x72\x65\x73\x65\156\x74\x2e\x20\x4d\141\170\151\155\x75\155\x20\61\x35\x20\143\150\x61\x72\141\143\x74\x65\x72\163\40\x73\x68\157\165\154\x64\x20\x62\145\x20\x70\x72\145\x73\x65\156\x74\56\40\117\x6e\x6c\x79\40\x66\x6f\x6c\154\157\167\151\x6e\147\40\x73\171\x6d\x62\x6f\x6c\163\x20\x28\x21\x40\43\x2e\44\45\x5e\46\x2a\55\x5f\51\40\163\x68\x6f\x75\154\144\40\x62\145\x20\160\162\145\163\x65\x6e\x74\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
t4:
goto Dh;
Ng:
update_option("\155\157\x5f\163\x61\x6d\154\x5f\x6d\145\163\163\141\x67\x65", "\120\154\x65\x61\x73\145\x20\x65\x6e\x74\x65\x72\40\x61\x20\166\141\x6c\x69\x64\x20\145\x6d\x61\x69\x6c\40\x61\x64\x64\x72\x65\x73\163\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Dh:
goto aA;
Jt:
update_option("\x6d\x6f\x5f\x73\141\x6d\x6c\137\155\145\x73\x73\x61\x67\x65", "\x43\150\x6f\157\163\x65\40\141\x20\x70\141\x73\163\x77\x6f\x72\x64\x20\167\x69\164\x68\40\155\151\x6e\x69\155\x75\155\40\154\145\x6e\x67\164\x68\x20\x36\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
aA:
goto nL;
la:
update_option("\x6d\x6f\137\x73\141\x6d\x6c\x5f\155\x65\x73\163\141\x67\x65", "\x41\154\154\x20\164\150\x65\x20\x66\151\145\154\x64\x73\x20\141\x72\145\40\162\x65\x71\165\151\x72\x65\144\x2e\40\x50\x6c\145\x61\163\145\x20\x65\x6e\x74\x65\162\40\166\141\154\x69\144\40\145\x6e\x74\162\x69\145\x73\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
nL:
update_option("\155\157\x5f\x73\141\155\x6c\137\141\x64\155\x69\x6e\137\145\155\141\x69\x6c", $BK);
update_option("\155\x6f\x5f\163\x61\x6d\154\137\x61\x64\155\151\x6e\x5f\160\150\x6f\x6e\x65", $FG);
if (strcmp($W7, $AT) == 0) {
goto qd;
}
update_option("\x6d\157\137\x73\141\155\x6c\x5f\x6d\x65\163\163\141\x67\x65", "\x50\141\x73\x73\x77\x6f\162\x64\x73\40\x64\x6f\40\x6e\157\164\x20\155\x61\x74\143\150\x2e");
delete_option("\x6d\x6f\x5f\x73\141\x6d\154\x5f\166\x65\162\151\146\171\137\x63\165\x73\164\x6f\155\145\x72");
SAMLSPUtilities::mo_saml_show_error_message();
goto N9;
qd:
update_option("\x6d\x6f\137\163\141\x6d\154\x5f\141\144\x6d\x69\x6e\x5f\160\x61\x73\x73\167\157\x72\x64", $W7);
$BK = get_option("\155\x6f\137\163\141\x6d\x6c\137\x61\144\x6d\x69\156\137\x65\x6d\x61\151\154");
$fG = new CustomerSaml();
$IL = $fG->check_customer();
if ($IL) {
goto jr;
}
return;
jr:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\163\x74\141\x74\x75\x73"], "\x43\x55\123\124\117\x4d\105\x52\x5f\116\x4f\124\x5f\106\x4f\125\116\x44") == 0) {
goto L0;
}
$this->get_current_customer();
goto He;
L0:
$IL = $fG->send_otp_token($BK, '');
if ($IL) {
goto ZL;
}
return;
ZL:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\163\x74\x61\x74\x75\x73"], "\123\x55\x43\103\x45\x53\123") == 0) {
goto KH;
}
update_option("\x6d\157\137\163\141\155\154\x5f\155\x65\x73\163\x61\x67\145", "\x54\x68\x65\x72\x65\x20\167\x61\163\40\141\x6e\40\x65\x72\162\157\x72\40\x69\156\x20\163\x65\156\144\151\156\x67\40\x65\x6d\x61\151\154\56\x20\120\x6c\145\141\163\x65\40\166\145\x72\x69\x66\x79\x20\171\x6f\165\x72\x20\x65\155\x61\x69\154\x20\x61\x6e\x64\40\164\162\x79\40\x61\147\141\x69\x6e\x2e");
update_option("\155\157\x5f\163\x61\x6d\154\137\x72\145\147\x69\x73\164\x72\x61\x74\151\x6f\156\137\x73\x74\141\x74\x75\163", "\115\117\137\x4f\x54\120\137\104\x45\114\x49\x56\x45\122\x45\x44\x5f\x46\101\111\114\125\x52\x45\x5f\x45\x4d\101\x49\x4c");
SAMLSPUtilities::mo_saml_show_error_message();
goto mK;
KH:
update_option("\x6d\157\137\163\141\155\154\137\x6d\145\163\163\141\147\145", "\x20\101\40\x6f\x6e\145\x20\164\x69\155\x65\40\160\141\163\x73\x63\x6f\144\145\x20\x69\x73\x20\x73\145\156\164\40\x74\157\40" . get_option("\x6d\x6f\x5f\163\x61\x6d\x6c\x5f\x61\144\x6d\151\156\x5f\145\x6d\x61\x69\154") . "\56\40\120\154\145\141\163\145\x20\145\x6e\x74\x65\x72\x20\164\150\x65\x20\157\x74\x70\40\x68\x65\x72\145\x20\x74\157\40\x76\145\162\151\146\x79\x20\171\157\165\x72\x20\145\155\141\151\x6c\x2e");
update_option("\155\x6f\137\x73\x61\x6d\x6c\x5f\164\162\141\x6e\x73\x61\143\x74\x69\157\x6e\111\144", $IL["\x74\x78\111\x64"]);
update_option("\x6d\157\137\163\x61\155\154\137\162\x65\x67\x69\163\x74\x72\x61\x74\151\157\x6e\137\163\x74\141\164\x75\163", "\x4d\117\x5f\x4f\x54\120\137\104\105\x4c\111\126\x45\x52\x45\104\137\123\x55\x43\x43\105\123\123\137\105\x4d\101\111\x4c");
SAMLSPUtilities::mo_saml_show_success_message();
mK:
He:
N9:
tH:
if (self::mo_check_option_admin_referer("\155\157\137\163\x61\155\x6c\137\166\141\154\x69\144\x61\164\145\137\x6f\164\160")) {
goto iX;
}
if (self::mo_check_option_admin_referer("\x6d\x6f\x5f\163\141\155\154\137\x76\145\x72\x69\x66\171\137\x6c\x69\143\145\156\x73\x65")) {
goto Sl;
}
if (self::mo_check_option_admin_referer("\155\x6f\137\163\141\155\154\x5f\x63\157\x6e\x74\141\x63\x74\137\x75\x73\x5f\161\x75\x65\162\x79\x5f\x6f\160\164\151\157\156")) {
goto PQ;
}
if (self::mo_check_option_admin_referer("\155\x6f\137\163\141\155\x6c\137\x72\x65\x73\x65\156\144\x5f\157\x74\x70\137\x65\x6d\x61\x69\154")) {
goto AH;
}
if (self::mo_check_option_admin_referer("\155\157\x5f\x73\x61\x6d\x6c\137\x72\x65\163\145\156\144\x5f\x6f\164\x70\x5f\x70\150\x6f\x6e\x65")) {
goto gF;
}
if (self::mo_check_option_admin_referer("\x6d\157\x5f\x73\141\x6d\x6c\x5f\147\157\x5f\142\141\x63\x6b")) {
goto aP;
}
if (self::mo_check_option_admin_referer("\155\157\x5f\x73\x61\155\154\137\162\x65\147\151\163\164\x65\x72\x5f\167\x69\x74\x68\x5f\x70\x68\x6f\x6e\x65\x5f\157\x70\164\x69\x6f\x6e")) {
goto QK;
}
if (self::mo_check_option_admin_referer("\155\157\137\x73\x61\155\154\x5f\162\x65\x67\x69\x73\164\145\x72\x65\x64\137\x6f\x6e\x6c\171\137\x61\143\143\x65\x73\x73\x5f\157\x70\164\x69\x6f\x6e") && Mo_License_Service::is_customer_license_valid()) {
goto sg;
}
if (self::mo_check_option_admin_referer("\155\157\x5f\163\141\155\x6c\137\146\157\162\x63\145\x5f\141\x75\164\150\145\x6e\x74\151\143\141\x74\x69\x6f\x6e\x5f\x6f\160\x74\151\x6f\x6e") && Mo_License_Service::is_customer_license_valid()) {
goto jJ;
}
if (self::mo_check_option_admin_referer("\x6d\x6f\137\163\x61\155\x6c\137\x65\x6e\141\x62\154\145\x5f\162\163\163\x5f\x61\x63\143\x65\163\163\137\157\160\164\151\x6f\156") && Mo_License_Service::is_customer_license_valid()) {
goto Ct;
}
if (self::mo_check_option_admin_referer("\155\x6f\137\163\141\x6d\154\x5f\x65\x6e\x61\x62\x6c\x65\x5f\154\x6f\147\x69\156\x5f\x72\x65\144\x69\x72\x65\143\164\x5f\x6f\160\164\151\157\156") && Mo_License_Service::is_customer_license_valid()) {
goto Q5;
}
if (self::mo_check_option_admin_referer("\x6d\157\137\x73\141\x6d\154\x5f\141\154\154\157\167\x5f\167\x70\137\x73\151\147\x6e\x69\x6e\x5f\x6f\160\x74\151\x6f\156") && Mo_License_Service::is_customer_license_valid()) {
goto Oo;
}
if (isset($_POST["\157\160\164\151\x6f\156"]) && $_POST["\157\x70\164\151\x6f\156"] == "\155\x6f\x5f\x73\x61\155\x6c\x5f\x66\157\162\x67\x6f\x74\x5f\x70\141\163\x73\x77\x6f\x72\144\137\146\x6f\162\155\x5f\157\160\x74\151\157\156") {
goto iP;
}
if (!self::mo_check_option_admin_referer("\155\x6f\x5f\x73\141\155\x6c\137\166\145\x72\151\x66\171\137\x63\x75\163\164\x6f\x6d\x65\162")) {
goto JV;
}
if (mo_saml_is_extension_installed("\143\x75\162\x6c")) {
goto vc;
}
update_option("\x6d\x6f\137\163\141\x6d\x6c\x5f\155\145\163\163\141\147\x65", "\105\122\x52\117\122\72\x20\x50\x48\x50\40\143\x55\x52\x4c\x20\145\x78\x74\145\156\x73\x69\157\156\x20\x69\x73\x20\156\x6f\x74\40\x69\x6e\163\x74\141\x6c\154\x65\144\40\x6f\x72\x20\144\x69\x73\x61\x62\154\145\x64\56\40\114\157\x67\151\156\x20\146\x61\x69\x6c\x65\144\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
vc:
$BK = '';
$W7 = '';
if ($this->mo_saml_check_empty_or_null($_POST["\145\x6d\x61\x69\154"]) || $this->mo_saml_check_empty_or_null($_POST["\x70\141\163\163\x77\157\162\144"])) {
goto UC;
}
if ($this->checkPasswordPattern(strip_tags($_POST["\160\141\x73\163\167\157\162\x64"]))) {
goto pv;
}
$BK = sanitize_email($_POST["\145\155\141\x69\x6c"]);
$W7 = sanitize_text_field($_POST["\160\x61\x73\163\167\x6f\162\144"]);
goto E2;
pv:
update_option("\155\x6f\x5f\x73\141\x6d\154\x5f\155\145\x73\x73\x61\147\145", "\115\x69\156\151\155\165\x6d\x20\66\40\x63\x68\x61\162\141\x63\164\x65\162\163\x20\x73\150\157\165\154\144\x20\x62\145\40\x70\x72\x65\x73\145\156\x74\x2e\40\115\x61\x78\x69\x6d\165\155\x20\61\x35\x20\x63\150\141\162\141\143\x74\x65\x72\x73\x20\x73\x68\x6f\x75\154\144\x20\x62\x65\40\x70\x72\x65\163\145\x6e\x74\x2e\40\x4f\x6e\x6c\x79\40\x66\x6f\x6c\154\157\x77\x69\x6e\147\x20\x73\171\x6d\142\x6f\x6c\163\40\50\41\100\x23\56\x24\45\136\x26\52\55\137\x29\40\x73\150\x6f\165\x6c\144\40\142\x65\40\x70\162\x65\x73\x65\156\164\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
E2:
goto rK;
UC:
update_option("\x6d\157\x5f\x73\141\x6d\x6c\137\x6d\x65\163\x73\x61\x67\145", "\101\x6c\x6c\x20\164\150\x65\x20\146\151\x65\154\x64\163\x20\141\x72\x65\x20\x72\x65\161\x75\151\162\x65\x64\x2e\x20\x50\x6c\145\x61\x73\145\40\145\156\164\x65\x72\x20\166\141\154\151\x64\40\145\x6e\164\162\x69\x65\x73\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
rK:
update_option("\155\x6f\x5f\163\141\x6d\154\x5f\x61\x64\x6d\151\x6e\137\145\x6d\141\151\154", $BK);
update_option("\x6d\157\137\x73\x61\155\154\x5f\141\x64\155\151\156\137\160\141\163\163\x77\x6f\x72\x64", $W7);
$fG = new Customersaml();
$IL = $fG->get_customer_key();
if ($IL) {
goto l0;
}
return;
l0:
$ds = json_decode($IL, true);
if (json_last_error() == JSON_ERROR_NONE) {
goto NX;
}
update_option("\155\157\x5f\163\141\155\154\x5f\x6d\x65\x73\x73\141\x67\145", "\111\156\x76\x61\154\151\x64\40\x75\163\145\x72\156\x61\155\145\40\157\162\40\160\141\x73\163\167\x6f\x72\x64\56\x20\x50\x6c\x65\x61\x73\145\40\x74\x72\171\40\141\x67\141\x69\x6e\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto C8;
NX:
update_option("\x6d\x6f\137\x73\141\x6d\x6c\x5f\141\144\x6d\x69\156\137\143\165\x73\164\157\x6d\145\x72\137\153\x65\171", $ds["\151\x64"]);
update_option("\155\x6f\137\163\141\x6d\154\137\x61\144\155\151\x6e\x5f\141\160\151\137\x6b\x65\171", $ds["\141\160\x69\113\x65\x79"]);
update_option("\155\157\137\163\141\x6d\x6c\x5f\143\x75\163\x74\x6f\x6d\145\162\x5f\164\157\153\x65\x6e", $ds["\x74\x6f\x6b\x65\156"]);
if (empty($ds["\x70\x68\x6f\156\145"])) {
goto Cj;
}
update_option("\x6d\157\x5f\x73\141\155\x6c\x5f\x61\144\155\151\x6e\x5f\x70\150\157\x6e\x65", $ds["\x70\150\157\x6e\145"]);
Cj:
update_option("\x6d\157\x5f\163\141\155\x6c\137\141\x64\x6d\151\156\x5f\x70\141\163\x73\x77\x6f\x72\144", '');
update_option("\155\157\137\163\x61\155\x6c\137\x6d\x65\163\163\141\147\145", "\103\x75\163\164\x6f\155\145\x72\40\x72\x65\x74\162\151\x65\166\x65\x64\x20\x73\165\x63\x63\x65\163\x73\146\165\154\154\171");
update_option("\x6d\x6f\137\x73\x61\x6d\154\137\162\145\147\151\x73\164\x72\x61\x74\x69\x6f\x6e\x5f\x73\x74\x61\x74\x75\x73", "\x45\x78\151\163\164\x69\x6e\x67\40\x55\163\x65\162");
delete_option("\x6d\157\137\163\141\x6d\x6c\137\166\145\x72\x69\x66\x79\x5f\143\x75\x73\x74\x6f\155\145\162");
if (get_option("\163\155\x6c\137\x6c\153")) {
goto FU;
}
SAMLSPUtilities::mo_saml_show_success_message();
goto W7;
FU:
$Jp = get_option("\155\157\x5f\x73\x61\x6d\154\137\x63\165\163\164\x6f\x6d\145\x72\137\164\x6f\153\145\156");
$uk = AESEncryption::decrypt_data(get_option("\163\155\x6c\x5f\x6c\153"), $Jp);
$IL = $fG->mo_saml_vl($uk, false);
if ($IL) {
goto HE;
}
return;
HE:
$IL = json_decode($IL, true);
update_option("\166\154\137\x63\x68\145\x63\153\x5f\x74", time());
if (!empty($IL) && is_array($IL) && array_key_exists("\163\164\x61\164\x75\x73", $IL) && strcasecmp($IL["\x73\164\141\x74\165\x73"], "\123\x55\103\x43\105\123\x53") == 0) {
goto qq;
}
update_option("\155\x6f\x5f\163\141\x6d\154\137\x6d\x65\163\163\141\147\145", "\114\x69\x63\x65\x6e\x73\x65\40\x6b\145\171\40\146\x6f\162\x20\x74\x68\151\x73\40\151\x6e\163\x74\x61\x6e\x63\x65\x20\151\x73\x20\151\x6e\x63\x6f\162\x72\145\143\164\56\40\x4d\x61\153\145\40\x73\165\162\145\x20\171\157\x75\x20\150\x61\166\x65\40\x6e\x6f\x74\40\164\x61\x6d\x70\145\162\145\x64\40\167\151\164\150\x20\x69\164\x20\141\164\x20\x61\x6c\154\x2e\x20\120\x6c\x65\141\163\x65\x20\145\x6e\x74\x65\162\x20\x61\x20\166\x61\x6c\151\144\40\x6c\x69\x63\145\x6e\163\145\x20\153\x65\171\56");
delete_option("\x73\x6d\154\x5f\x6c\x6b");
SAMLSPUtilities::mo_saml_show_error_message();
goto GT;
qq:
$Xb = plugin_dir_path(__FILE__);
$PF = home_url();
$PF = trim($PF, "\x2f");
if (preg_match("\43\x5e\150\x74\164\160\50\x73\51\x3f\x3a\57\x2f\43", $PF)) {
goto V4;
}
$PF = "\x68\x74\x74\x70\72\57\x2f" . $PF;
V4:
$yy = parse_url($PF);
$m6 = preg_replace("\x2f\136\167\167\x77\134\56\x2f", '', $yy["\150\157\163\164"]);
$Sg = wp_upload_dir();
$cm = $m6 . "\55" . $Sg["\x62\141\163\145\x64\x69\162"];
$rg = hash_hmac("\163\150\141\x32\x35\66", $cm, "\x34\104\x48\x66\152\147\x66\152\x61\x73\156\x64\146\163\141\152\146\x48\x47\x4a");
$Sx = $this->djkasjdksa();
$co = round(strlen($Sx) / rand(2, 20));
$Sx = substr_replace($Sx, $rg, $co, 0);
$yY = base64_decode($Sx);
if (is_writable($Xb . "\154\x69\x63\x65\x6e\163\145")) {
goto Zo;
}
$Sx = str_rot13($Sx);
$jG = "\x62\x47\116\x6b\141\x6d\x74\150\x63\62\160\x6b\x61\63\116\x68\x59\62\x77\x3d";
$lX = base64_decode($jG);
update_option($lX, $Sx);
goto wk;
Zo:
file_put_contents($Xb . "\154\x69\x63\x65\156\163\145", $yY);
wk:
update_option("\x6c\143\167\162\164\154\146\x73\x61\155\154", true);
SAMLSPUtilities::mo_saml_show_success_message();
GT:
W7:
C8:
update_option("\155\x6f\x5f\163\x61\x6d\154\x5f\x61\144\155\151\156\137\160\141\163\163\x77\157\x72\x64", '');
JV:
goto UM;
iP:
if (mo_saml_is_extension_installed("\143\x75\162\x6c")) {
goto YG;
}
update_option("\x6d\x6f\x5f\x73\141\155\x6c\137\155\x65\x73\x73\x61\147\x65", "\x45\x52\122\x4f\122\x3a\x20\x50\110\x50\40\143\125\122\114\40\145\x78\164\145\156\163\x69\x6f\x6e\x20\151\163\x20\156\157\x74\40\x69\156\x73\164\x61\154\x6c\145\x64\x20\x6f\162\40\144\151\163\141\142\x6c\145\144\x2e\x20\x52\145\x73\145\156\144\x20\117\x54\x50\x20\146\141\x69\x6c\145\144\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
YG:
$BK = get_option("\155\x6f\x5f\163\141\155\154\x5f\x61\x64\155\151\x6e\x5f\145\155\141\x69\154");
$fG = new Customersaml();
$IL = $fG->mo_saml_forgot_password($BK);
if ($IL) {
goto XP;
}
return;
XP:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\163\164\x61\x74\x75\163"], "\x53\125\x43\103\x45\x53\x53") == 0) {
goto zK;
}
update_option("\155\x6f\137\x73\x61\155\154\x5f\155\x65\163\x73\141\x67\x65", "\x41\156\x20\145\x72\x72\157\x72\40\x6f\x63\143\x75\162\x65\x64\40\167\150\151\154\x65\x20\160\162\157\x63\x65\x73\x73\x69\156\x67\x20\x79\157\165\162\40\x72\145\x71\165\x65\x73\x74\x2e\x20\x50\154\x65\141\163\x65\x20\x54\162\171\40\x61\x67\x61\x69\156\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto e5;
zK:
update_option("\155\x6f\137\163\x61\x6d\x6c\137\155\x65\x73\x73\x61\x67\145", "\x59\157\165\162\x20\160\141\x73\163\x77\157\162\144\40\x68\141\x73\x20\x62\x65\145\x6e\x20\x72\145\x73\145\164\40\x73\x75\x63\x63\145\163\163\146\165\154\154\171\x2e\40\x50\154\145\141\x73\145\x20\145\x6e\164\145\x72\x20\164\x68\x65\x20\156\145\x77\40\160\141\163\x73\x77\x6f\162\144\x20\x73\145\x6e\x74\40\x74\x6f\x20" . $BK . "\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
e5:
UM:
goto Rk;
Oo:
$Fy = "\x66\141\x6c\x73\145";
if (isset($_POST["\x6d\x6f\x5f\163\141\155\154\x5f\x61\154\x6c\157\167\137\167\x70\137\163\151\147\156\x69\x6e"])) {
goto zQ;
}
$gZ = "\x66\141\x6c\163\145";
goto gR;
zQ:
$gZ = sanitize_text_field($_POST["\155\157\137\163\x61\155\154\x5f\141\154\154\x6f\167\137\x77\x70\137\163\x69\x67\156\x69\156"]);
gR:
if ($gZ == "\x74\162\x75\x65") {
goto ra;
}
update_option("\155\x6f\137\x73\141\x6d\154\x5f\141\154\154\157\167\x5f\167\x70\137\163\151\147\x6e\151\156", "\x46\x61\x6c\163\145");
goto kz;
ra:
update_option("\155\x6f\137\163\141\155\154\x5f\x61\x6c\154\157\x77\x5f\x77\x70\x5f\163\x69\x67\156\151\x6e", "\x74\162\165\x65");
kz:
if (!isset($_POST["\x6d\157\x5f\163\141\x6d\x6c\x5f\142\x61\x63\153\144\157\x6f\x72\x5f\x75\x72\154"])) {
goto B9;
}
$Fy = sanitize_text_field(trim($_POST["\155\x6f\137\163\141\x6d\154\x5f\142\141\143\x6b\144\157\x6f\x72\x5f\x75\x72\x6c"]));
B9:
update_option("\x6d\x6f\x5f\x73\x61\x6d\x6c\x5f\142\141\x63\x6b\144\157\157\162\137\165\x72\154", $Fy);
update_option("\x6d\x6f\137\163\141\155\x6c\x5f\x6d\145\163\163\141\x67\x65", "\123\x69\x67\x6e\40\x49\x6e\x20\x73\145\164\x74\x69\156\147\163\40\x75\160\x64\141\164\x65\x64\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
Rk:
goto Cv;
Q5:
if (mo_saml_is_sp_configured()) {
goto d2;
}
update_option("\x6d\x6f\x5f\163\x61\x6d\x6c\137\155\145\163\x73\x61\147\x65", "\120\x6c\145\141\x73\x65\40\x63\157\x6d\160\x6c\x65\x74\145\x20" . addLink("\123\145\162\166\x69\x63\x65\40\120\x72\x6f\x76\151\x64\x65\x72", SAMLSPUtilities::mo_saml_add_query_arg(array("\164\141\x62" => "\163\x61\166\145"), $_SERVER["\122\105\x51\125\105\123\124\137\125\122\x49"])) . "\40\x63\x6f\156\146\151\147\165\x72\x61\164\151\x6f\x6e\x20\x66\151\162\x73\x74\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto x0;
d2:
if (isset($_POST["\x6d\157\137\x73\141\x6d\154\137\145\156\x61\142\154\x65\x5f\154\x6f\147\x69\156\137\162\x65\x64\151\x72\x65\x63\x74"])) {
goto eV;
}
$vP = "\146\x61\x6c\163\145";
goto Qf;
eV:
$vP = sanitize_text_field($_POST["\155\157\x5f\x73\141\155\154\x5f\145\156\141\142\x6c\x65\x5f\x6c\x6f\x67\x69\x6e\x5f\x72\145\x64\x69\x72\145\143\164"]);
Qf:
if ($vP == "\x74\162\x75\145") {
goto vL;
}
update_option("\x6d\157\x5f\163\x61\155\154\137\145\156\x61\142\x6c\145\137\154\157\147\x69\x6e\137\x72\x65\144\x69\162\145\x63\x74", "\146\141\x6c\x73\x65");
update_option("\x6d\157\137\x73\x61\155\x6c\137\x61\x6c\154\157\x77\137\167\160\x5f\x73\151\147\156\x69\156", "\x46\141\x6c\163\x65");
goto Mz;
vL:
update_option("\155\x6f\x5f\x73\x61\x6d\154\137\145\156\x61\142\154\145\137\x6c\x6f\147\x69\156\x5f\x72\x65\144\151\x72\145\143\x74", "\164\162\x75\x65");
update_option("\x6d\x6f\x5f\x73\x61\155\x6c\x5f\x61\154\x6c\157\167\x5f\x77\x70\137\163\151\147\x6e\151\156", "\164\162\x75\x65");
Mz:
update_option("\155\157\x5f\163\x61\x6d\x6c\137\x6d\x65\163\163\x61\147\145", "\x53\151\x67\156\x20\151\x6e\40\x6f\160\164\x69\x6f\x6e\163\40\x75\160\x64\x61\x74\145\144\56");
SAMLSPUtilities::mo_saml_show_success_message();
x0:
Cv:
goto CY;
Ct:
if (mo_saml_is_sp_configured()) {
goto Rv;
}
update_option("\x6d\157\x5f\163\x61\155\x6c\137\x6d\145\163\163\x61\147\145", "\120\x6c\145\141\x73\x65\40\143\157\155\160\154\x65\x74\145\40" . addLink("\x53\x65\x72\x76\151\x63\x65\x20\x50\x72\x6f\x76\151\x64\x65\x72", SAMLSPUtilities::mo_saml_add_query_arg(array("\x74\141\x62" => "\163\141\166\x65"), $_SERVER["\x52\105\x51\125\105\x53\124\137\125\122\111"])) . "\40\x63\157\156\x66\151\147\165\162\141\x74\x69\157\156\x20\146\x69\162\163\164\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
goto PY;
Rv:
if (isset($_POST["\155\x6f\137\163\141\155\x6c\137\x65\x6e\141\x62\x6c\x65\137\x72\x73\163\x5f\x61\143\x63\x65\x73\x73"])) {
goto nO;
}
$VF = false;
goto bN;
nO:
$VF = sanitize_text_field($_POST["\155\x6f\x5f\x73\x61\155\x6c\x5f\x65\156\141\142\154\145\137\x72\163\163\137\x61\143\x63\145\163\163"]);
bN:
if ($VF == "\x74\x72\165\x65") {
goto vm;
}
update_option("\x6d\157\137\x73\141\155\154\137\145\156\x61\142\154\x65\x5f\x72\x73\x73\137\x61\143\143\145\163\x73", "\x66\x61\x6c\163\x65");
goto BA;
vm:
update_option("\155\157\x5f\x73\x61\x6d\x6c\137\x65\x6e\141\x62\x6c\x65\x5f\x72\163\163\x5f\x61\143\143\x65\163\x73", "\164\x72\x75\145");
BA:
update_option("\155\157\137\163\x61\155\x6c\x5f\x6d\145\x73\x73\141\147\x65", "\x52\x53\x53\x20\106\x65\145\144\40\157\160\164\151\x6f\x6e\40\x75\160\144\x61\x74\145\144\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
PY:
CY:
goto vx;
jJ:
if (mo_saml_is_sp_configured()) {
goto Gx;
}
update_option("\x6d\x6f\x5f\163\x61\155\x6c\x5f\x6d\145\163\x73\x61\x67\x65", "\x50\154\x65\x61\x73\145\40\x63\157\155\160\154\145\x74\145\40" . addLink("\x53\x65\162\166\x69\143\x65\40\x50\x72\x6f\x76\151\x64\x65\x72", SAMLSPUtilities::mo_saml_add_query_arg(array("\x74\x61\x62" => "\163\141\166\x65"), $_SERVER["\x52\x45\121\x55\x45\123\x54\x5f\x55\122\x49"])) . "\x20\x63\x6f\156\146\x69\x67\165\x72\141\x74\151\x6f\156\40\x66\x69\x72\x73\164\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto ls;
Gx:
if (isset($_POST["\x6d\157\x5f\163\141\155\x6c\137\146\x6f\162\143\145\x5f\x61\165\x74\150\x65\x6e\164\x69\143\x61\x74\x69\157\x6e"])) {
goto WC;
}
$vP = "\146\141\x6c\163\x65";
goto iO;
WC:
$vP = sanitize_text_field($_POST["\x6d\157\137\x73\x61\155\x6c\x5f\x66\157\162\x63\x65\137\141\x75\x74\150\145\156\164\x69\x63\141\x74\x69\157\156"]);
iO:
if ($vP == "\164\162\x75\x65") {
goto V5;
}
update_option("\x6d\x6f\137\163\141\155\x6c\137\x66\157\x72\143\x65\137\x61\x75\x74\x68\145\156\164\151\x63\141\x74\x69\157\156", "\146\x61\154\163\x65");
goto m8;
V5:
update_option("\155\x6f\137\x73\x61\155\x6c\137\x66\x6f\162\x63\x65\137\141\x75\x74\150\145\x6e\x74\151\143\141\164\151\157\156", "\x74\x72\x75\x65");
m8:
update_option("\155\x6f\x5f\163\x61\155\x6c\x5f\x6d\x65\163\163\141\x67\x65", "\x53\x69\147\x6e\x20\151\156\40\157\160\x74\x69\157\156\x73\x20\165\160\144\x61\164\145\144\56");
SAMLSPUtilities::mo_saml_show_success_message();
ls:
vx:
goto o7;
sg:
if (mo_saml_is_sp_configured()) {
goto J1;
}
update_option("\155\x6f\x5f\163\141\x6d\x6c\137\x6d\x65\163\163\141\x67\145", "\x50\x6c\145\x61\163\145\x20\x63\157\155\160\x6c\x65\x74\x65\40" . addLink("\x53\x65\x72\x76\x69\143\x65\x20\x50\162\157\x76\x69\x64\145\162", SAMLSPUtilities::mo_saml_add_query_arg(array("\x74\x61\142" => "\163\x61\166\145"), $_SERVER["\x52\x45\121\125\x45\123\124\137\125\122\111"])) . "\40\x63\x6f\156\x66\x69\x67\x75\162\x61\164\x69\157\x6e\40\146\151\x72\x73\x74\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
goto Pf;
J1:
if (isset($_POST["\x6d\x6f\137\163\x61\x6d\154\137\x72\x65\x67\151\163\164\x65\162\x65\144\x5f\x6f\x6e\154\x79\137\x61\143\x63\145\163\x73"])) {
goto pt;
}
$vP = "\146\141\154\x73\145";
goto jV;
pt:
$vP = sanitize_text_field($_POST["\x6d\x6f\137\163\141\155\154\137\162\145\147\151\x73\164\145\162\145\144\137\x6f\156\154\x79\x5f\141\143\x63\145\x73\x73"]);
jV:
if ($vP == "\x74\x72\165\145") {
goto l6;
}
update_option("\x6d\157\137\163\141\x6d\154\137\x72\145\x67\151\x73\x74\145\162\x65\144\x5f\157\x6e\154\x79\x5f\x61\143\143\x65\163\163", "\146\141\154\x73\x65");
goto u0;
l6:
update_option("\155\157\x5f\163\141\x6d\x6c\x5f\x72\x65\x67\x69\x73\164\145\162\x65\x64\x5f\x6f\156\x6c\x79\137\x61\143\x63\145\163\x73", "\164\x72\x75\x65");
u0:
update_option("\x6d\157\x5f\163\x61\155\x6c\x5f\155\x65\x73\x73\x61\147\145", "\123\151\x67\156\40\x69\156\x20\x6f\160\164\151\157\x6e\x73\x20\165\160\144\141\x74\x65\x64\56");
SAMLSPUtilities::mo_saml_show_success_message();
Pf:
o7:
goto cD;
QK:
if (mo_saml_is_extension_installed("\143\x75\162\154")) {
goto U2;
}
update_option("\x6d\157\x5f\163\x61\x6d\154\x5f\155\x65\x73\x73\x61\147\x65", "\105\122\122\x4f\122\x3a\x20\x50\110\x50\40\x63\125\122\114\x20\145\x78\x74\x65\x6e\163\151\157\156\40\x69\x73\x20\156\x6f\x74\x20\x69\x6e\x73\x74\141\154\x6c\x65\x64\x20\x6f\162\x20\x64\151\163\x61\142\x6c\145\x64\x2e\40\x52\x65\x73\x65\156\x64\x20\117\124\x50\40\x66\141\151\154\x65\x64\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
U2:
$FG = sanitize_text_field($_POST["\160\150\x6f\156\145"]);
$FG = str_replace("\x20", '', $FG);
$FG = str_replace("\x2d", '', $FG);
update_option("\155\157\137\x73\141\155\154\x5f\x61\x64\x6d\151\156\x5f\160\150\x6f\156\x65", $FG);
$fG = new CustomerSaml();
$IL = $fG->send_otp_token('', $FG, FALSE, TRUE);
if ($IL) {
goto kL;
}
return;
kL:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\163\x74\141\164\x75\x73"], "\123\x55\x43\103\x45\x53\x53") == 0) {
goto jG;
}
update_option("\x6d\157\137\163\141\155\x6c\137\155\145\163\163\x61\147\145", "\x54\x68\x65\x72\x65\40\x77\x61\163\x20\x61\x6e\x20\x65\162\x72\x6f\x72\40\x69\x6e\x20\163\x65\x6e\x64\151\x6e\147\x20\x53\x4d\x53\56\40\x50\154\145\x61\x73\x65\x20\x63\154\151\143\x6b\40\157\x6e\40\122\x65\x73\145\x6e\144\40\117\124\x50\40\x74\157\40\164\x72\171\x20\x61\x67\x61\151\x6e\56");
update_option("\155\x6f\x5f\163\x61\155\154\137\x72\x65\x67\151\163\164\x72\x61\164\151\x6f\x6e\137\163\164\x61\164\x75\x73", "\x4d\x4f\x5f\x4f\124\x50\137\x44\x45\x4c\x49\x56\x45\x52\105\104\x5f\106\101\111\x4c\125\122\105\137\x50\110\117\x4e\105");
SAMLSPUtilities::mo_saml_show_error_message();
goto Gq;
jG:
update_option("\155\157\137\x73\x61\x6d\x6c\x5f\155\145\x73\163\141\147\x65", "\x20\101\40\x6f\156\145\x20\x74\151\x6d\145\x20\x70\141\163\163\143\157\144\x65\40\151\x73\40\163\x65\156\x74\x20\164\157\x20" . get_option("\155\157\137\163\141\155\154\x5f\141\144\155\x69\156\137\x70\150\x6f\156\x65") . "\56\40\x50\154\145\x61\x73\145\x20\x65\156\x74\145\x72\x20\164\x68\145\x20\157\164\x70\40\x68\x65\162\x65\x20\164\157\40\x76\145\162\x69\x66\171\40\x79\x6f\x75\162\40\145\x6d\141\151\x6c\x2e");
update_option("\155\157\137\163\x61\x6d\154\x5f\164\x72\141\x6e\163\141\143\x74\151\157\156\x49\144", $IL["\164\x78\111\144"]);
update_option("\155\157\x5f\x73\x61\155\x6c\x5f\x72\145\x67\151\x73\x74\x72\x61\x74\151\x6f\156\x5f\163\164\x61\x74\165\163", "\x4d\117\137\x4f\124\120\137\104\x45\114\x49\126\105\122\x45\104\137\123\125\x43\x43\105\123\123\x5f\120\x48\x4f\x4e\105");
SAMLSPUtilities::mo_saml_show_success_message();
Gq:
cD:
goto Kq;
aP:
update_option("\x6d\157\137\163\141\155\154\137\x72\145\x67\151\x73\164\162\x61\x74\151\x6f\156\x5f\x73\x74\x61\x74\165\163", '');
update_option("\155\157\x5f\163\141\155\x6c\x5f\166\x65\x72\x69\146\x79\137\143\165\163\x74\157\155\145\162", '');
delete_option("\x6d\x6f\137\163\x61\x6d\x6c\137\x6e\145\x77\x5f\162\x65\147\x69\x73\164\x72\x61\164\151\x6f\x6e");
delete_option("\155\x6f\x5f\163\x61\155\x6c\x5f\x61\144\155\151\156\x5f\x65\155\x61\151\x6c");
delete_option("\155\157\137\163\141\x6d\x6c\137\x61\144\x6d\x69\x6e\137\160\150\157\x6e\x65");
delete_site_option("\163\x6d\154\x5f\x6c\153");
delete_site_option("\164\137\x73\151\x74\145\x5f\x73\x74\141\x74\x75\x73");
delete_site_option("\163\x69\164\x65\x5f\x63\x6b\137\154");
Kq:
goto gD;
gF:
if (mo_saml_is_extension_installed("\143\x75\162\x6c")) {
goto ju;
}
update_option("\x6d\x6f\x5f\x73\x61\155\x6c\x5f\x6d\145\163\x73\141\x67\x65", "\105\122\x52\x4f\x52\x3a\x20\x50\110\x50\x20\143\x55\x52\x4c\x20\x65\x78\164\x65\156\x73\151\157\x6e\40\x69\163\40\x6e\x6f\x74\x20\x69\x6e\163\x74\141\x6c\x6c\145\144\x20\157\162\40\x64\151\163\141\x62\154\x65\x64\56\x20\122\145\x73\145\x6e\x64\40\x4f\x54\x50\x20\146\x61\x69\x6c\145\x64\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
ju:
$FG = get_option("\x6d\x6f\x5f\x73\141\155\154\x5f\x61\144\155\x69\x6e\137\x70\150\x6f\156\145");
$fG = new CustomerSaml();
$IL = $fG->send_otp_token('', $FG, FALSE, TRUE);
if ($IL) {
goto aQ;
}
return;
aQ:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\x73\x74\141\x74\x75\163"], "\123\x55\x43\x43\105\123\x53") == 0) {
goto vf;
}
update_option("\155\157\x5f\x73\x61\x6d\x6c\x5f\x6d\145\x73\163\x61\x67\x65", "\x54\x68\x65\162\x65\x20\x77\141\163\40\x61\x6e\40\145\162\162\x6f\162\40\x69\156\x20\163\x65\x6e\144\x69\x6e\147\x20\145\155\141\151\x6c\x2e\x20\120\154\145\141\x73\145\40\143\154\x69\x63\x6b\40\x6f\x6e\x20\122\x65\163\145\156\144\x20\x4f\x54\120\x20\x74\157\40\x74\x72\x79\x20\x61\147\x61\151\156\x2e");
update_option("\155\x6f\x5f\x73\141\155\154\x5f\x72\145\x67\151\163\164\162\x61\164\151\x6f\x6e\137\163\164\x61\164\165\x73", "\x4d\x4f\x5f\x4f\x54\x50\x5f\x44\x45\x4c\x49\126\x45\122\x45\x44\x5f\x46\101\111\114\x55\x52\x45\x5f\x50\110\117\116\105");
SAMLSPUtilities::mo_saml_show_error_message();
goto y2;
vf:
update_option("\155\x6f\137\163\x61\x6d\x6c\137\155\145\163\x73\x61\x67\x65", "\40\101\40\x6f\156\x65\x20\164\151\x6d\x65\40\160\x61\x73\x73\x63\x6f\144\145\x20\x69\163\40\163\145\x6e\164\x20\164\157\40" . $FG . "\40\141\147\141\151\x6e\x2e\x20\120\154\145\141\163\145\40\x63\x68\x65\143\153\40\151\x66\x20\171\157\x75\40\x67\157\x74\x20\x74\150\145\x20\x6f\164\160\40\141\x6e\x64\x20\x65\156\x74\145\x72\40\x69\164\40\x68\x65\x72\x65\x2e");
update_option("\x6d\157\137\163\x61\155\154\137\x74\162\x61\156\x73\x61\x63\164\x69\157\156\x49\x64", $IL["\x74\170\x49\x64"]);
update_option("\155\x6f\137\x73\141\x6d\154\137\x72\145\147\151\163\164\x72\x61\x74\151\x6f\156\137\x73\164\x61\x74\165\x73", "\115\117\137\x4f\124\x50\137\104\105\114\111\x56\105\x52\x45\x44\137\123\125\x43\x43\x45\123\123\137\x50\110\117\x4e\105");
SAMLSPUtilities::mo_saml_show_success_message();
y2:
gD:
goto rW;
AH:
if (mo_saml_is_extension_installed("\143\x75\162\154")) {
goto px;
}
update_option("\x6d\x6f\137\163\x61\x6d\x6c\x5f\x6d\145\x73\163\141\x67\x65", "\x45\x52\122\x4f\122\x3a\x20\x50\110\x50\x20\x63\x55\122\x4c\x20\x65\x78\x74\145\x6e\x73\x69\157\x6e\40\x69\163\x20\x6e\157\x74\x20\151\x6e\163\x74\141\x6c\154\x65\144\40\x6f\162\x20\x64\x69\x73\x61\142\x6c\x65\144\x2e\40\x52\145\x73\145\156\144\x20\117\x54\120\40\x66\141\x69\x6c\x65\x64\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
px:
$BK = get_option("\x6d\157\137\x73\x61\155\x6c\137\141\x64\155\151\x6e\x5f\x65\155\x61\x69\x6c");
$fG = new CustomerSaml();
$IL = $fG->send_otp_token($BK, '');
if ($IL) {
goto Lq;
}
return;
Lq:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\x73\x74\141\164\165\163"], "\123\125\103\x43\x45\123\x53") == 0) {
goto Q3;
}
update_option("\155\x6f\137\x73\x61\x6d\x6c\137\x6d\145\163\163\141\x67\145", "\x54\150\145\162\145\x20\167\x61\163\x20\x61\x6e\x20\145\x72\162\157\x72\x20\x69\x6e\40\x73\145\156\x64\x69\x6e\x67\x20\x65\155\141\151\x6c\x2e\40\x50\x6c\145\141\163\x65\x20\x63\x6c\x69\x63\x6b\x20\x6f\x6e\40\x52\x65\x73\x65\156\144\x20\117\124\x50\x20\x74\x6f\40\x74\162\171\x20\x61\147\x61\x69\156\56");
update_option("\x6d\x6f\137\x73\141\155\154\137\162\145\x67\x69\163\x74\x72\141\x74\151\157\156\x5f\163\164\141\x74\x75\x73", "\x4d\x4f\137\x4f\124\x50\137\104\x45\x4c\x49\x56\x45\x52\x45\104\137\x46\101\x49\x4c\x55\x52\x45\x5f\105\x4d\x41\x49\114");
SAMLSPUtilities::mo_saml_show_error_message();
goto XC;
Q3:
update_option("\155\x6f\137\163\x61\x6d\x6c\137\155\145\163\x73\141\x67\145", "\x20\x41\40\157\156\145\x20\x74\151\x6d\x65\x20\160\141\163\163\x63\157\x64\x65\40\x69\x73\x20\x73\x65\x6e\x74\x20\x74\157\40" . get_option("\x6d\x6f\x5f\163\x61\x6d\154\x5f\141\x64\x6d\151\156\x5f\x65\155\x61\x69\x6c") . "\x20\141\147\x61\x69\156\56\x20\x50\x6c\x65\x61\x73\x65\40\x63\x68\145\x63\x6b\x20\151\146\x20\x79\x6f\x75\40\147\157\164\x20\x74\x68\145\40\157\x74\x70\x20\141\156\x64\40\x65\156\x74\x65\x72\x20\x69\164\40\x68\145\162\x65\56");
update_option("\x6d\157\137\163\141\x6d\x6c\137\x74\162\141\156\163\141\x63\x74\x69\157\156\111\x64", $IL["\x74\x78\x49\x64"]);
update_option("\155\x6f\x5f\163\141\155\154\137\162\145\147\151\163\164\162\x61\x74\x69\157\x6e\x5f\163\164\141\x74\165\163", "\x4d\117\137\117\x54\120\137\104\105\114\x49\126\105\x52\x45\x44\x5f\x53\x55\103\x43\105\123\123\x5f\x45\115\101\x49\x4c");
SAMLSPUtilities::mo_saml_show_success_message();
XC:
rW:
goto mX;
PQ:
if (mo_saml_is_extension_installed("\143\165\x72\154")) {
goto Eo;
}
update_option("\x6d\x6f\x5f\x73\x61\x6d\x6c\137\155\x65\163\x73\x61\147\x65", "\105\122\x52\x4f\x52\72\40\120\110\120\x20\x63\x55\x52\114\40\x65\170\164\145\x6e\163\151\157\156\40\151\x73\x20\156\x6f\164\40\x69\156\163\164\x61\x6c\154\x65\144\40\157\162\x20\144\151\163\x61\142\154\x65\144\x2e\x20\121\x75\x65\162\171\x20\x73\x75\x62\x6d\x69\x74\x20\x66\141\x69\x6c\x65\x64\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Eo:
$BK = sanitize_email($_POST["\155\157\137\x73\x61\155\x6c\x5f\143\157\x6e\x74\141\x63\164\137\x75\x73\137\145\155\x61\151\154"]);
$FG = sanitize_text_field($_POST["\x6d\157\x5f\x73\141\x6d\x6c\x5f\143\x6f\156\164\x61\x63\164\137\165\163\137\x70\x68\x6f\x6e\x65"]);
$wy = sanitize_text_field($_POST["\x6d\157\x5f\x73\x61\x6d\x6c\x5f\143\x6f\x6e\164\x61\x63\x74\137\x75\x73\137\161\x75\145\162\x79"]);
if (isset($_POST["\163\x65\x6e\144\x5f\x70\154\165\147\x69\x6e\x5f\x63\x6f\156\146\x69\147"]) === true) {
goto h4;
}
update_option("\163\145\x6e\x64\137\160\154\x75\x67\151\x6e\137\x63\157\x6e\x66\151\147", "\x6f\146\x66");
goto aI;
h4:
$yB = miniorange_import_export(true, true);
$wy .= $yB;
delete_option("\x73\x65\x6e\144\x5f\160\x6c\x75\147\x69\x6e\137\x63\157\156\x66\x69\147");
aI:
$fG = new CustomerSaml();
if ($this->mo_saml_check_empty_or_null($BK) || $this->mo_saml_check_empty_or_null($wy)) {
goto GN;
}
if (!filter_var($BK, FILTER_VALIDATE_EMAIL)) {
goto ur;
}
$Gl = $fG->submit_contact_us($BK, $FG, $wy);
if ($Gl) {
goto nI;
}
return;
nI:
update_option("\x6d\x6f\x5f\x73\x61\x6d\x6c\x5f\155\x65\163\163\x61\x67\x65", "\x54\x68\x61\156\x6b\x73\x20\146\x6f\162\40\147\x65\x74\x74\151\x6e\147\40\x69\x6e\x20\x74\x6f\165\143\150\x21\40\x57\145\40\163\150\x61\x6c\154\40\x67\145\164\40\142\141\x63\x6b\x20\x74\x6f\x20\171\x6f\x75\40\163\x68\157\x72\x74\154\x79\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
goto oA;
ur:
update_option("\x6d\157\137\163\141\155\154\137\x6d\145\163\x73\x61\x67\145", "\x50\154\145\x61\163\145\x20\x65\x6e\x74\145\162\x20\x61\40\x76\141\x6c\x69\144\x20\x65\x6d\141\151\154\x20\x61\144\x64\x72\x65\x73\x73\56");
SAMLSPUtilities::mo_saml_show_error_message();
oA:
goto dT;
GN:
update_option("\155\157\137\163\141\x6d\x6c\137\x6d\145\x73\163\x61\147\x65", "\120\x6c\145\141\x73\145\x20\x66\x69\x6c\x6c\x20\x75\160\x20\x45\x6d\x61\x69\x6c\x20\x61\x6e\x64\x20\121\165\145\162\171\40\146\x69\x65\154\144\x73\x20\x74\x6f\40\163\x75\142\x6d\151\164\40\171\x6f\x75\x72\40\x71\x75\x65\x72\x79\56");
SAMLSPUtilities::mo_saml_show_error_message();
dT:
mX:
goto Jf;
Sl:
if (!$this->mo_saml_check_empty_or_null($_POST["\x73\141\x6d\154\x5f\x6c\x69\x63\x65\156\x63\145\x5f\x6b\145\171"])) {
goto q8;
}
update_option("\155\x6f\x5f\163\141\155\154\x5f\x6d\x65\x73\x73\141\147\145", "\x41\154\154\x20\164\x68\x65\40\x66\x69\x65\x6c\144\x73\x20\141\162\145\x20\162\x65\x71\165\x69\x72\145\x64\56\x20\120\154\x65\141\163\x65\40\145\156\164\x65\162\x20\x76\x61\x6c\x69\x64\x20\x6c\151\x63\x65\x6e\163\145\x20\x6b\145\171\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
q8:
$uk = sanitize_text_field(trim($_POST["\x73\x61\x6d\x6c\x5f\x6c\151\x63\x65\156\143\x65\137\x6b\x65\171"]));
$fG = new Customersaml();
$Kt = json_decode($fG->mo_saml_vl($uk, false), true);
if (!empty($Kt["\163\x74\x61\x74\165\163"])) {
goto OD;
}
update_option("\155\157\x5f\x73\x61\x6d\x6c\137\x6d\x65\x73\x73\141\x67\x65", "\124\x68\x65\40\154\151\143\x65\156\163\x65\40\x6b\x65\x79\x20\x79\157\165\40\x68\141\166\x65\x20\145\x6e\164\145\162\145\x64\40\x69\163\x20\151\156\x76\141\154\151\144\x2e\40\x50\x6c\x65\141\x73\x65\40\x65\x6e\164\x65\162\x20\x61\40\x76\x61\154\151\x64\x20\x6c\151\x63\145\156\163\x65\x20\x6b\145\x79\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
OD:
$IL = $fG->check_customer_ln();
if ($IL) {
goto Et;
}
return;
Et:
$IL = json_decode($IL, true);
if (!(is_array($IL) && array_key_exists("\x6c\151\143\145\x6e\163\x65\105\x78\x70\x69\162\x79", $IL) && !empty($IL["\x6c\151\143\x65\156\x73\145\105\x78\160\x69\x72\x79"]))) {
goto AV;
}
$sY = $IL["\154\151\x63\145\x6e\163\x65\x45\170\160\151\162\x79"];
AV:
if (strcasecmp($IL["\163\164\141\164\x75\x73"], "\x53\125\103\103\x45\x53\123") == 0) {
goto lG;
}
$Jp = get_option("\155\157\137\x73\141\x6d\154\137\x63\x75\163\164\157\155\145\162\x5f\164\x6f\x6b\x65\156");
update_option("\x73\151\x74\x65\x5f\143\x6b\137\x6c", AESEncryption::encrypt_data("\x66\x61\154\x73\x65", $Jp));
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("\164\x61\142" => "\154\x69\x63\x65\x6e\163\151\x6e\147"), $_SERVER["\122\105\x51\125\105\123\x54\137\x55\122\x49"]);
update_option("\x6d\x6f\x5f\x73\141\155\x6c\x5f\155\145\x73\x73\141\x67\x65", "\x59\157\x75\x20\150\141\166\145\x20\156\x6f\x74\40\165\160\x67\x72\141\x64\x65\x64\x20\171\x65\164\x2e\x20" . addLink("\x43\154\x69\143\x6b\x20\x68\x65\x72\145", $Ug) . "\40\164\157\x20\x75\160\x67\x72\141\x64\x65\x20\164\x6f\40\160\x72\145\155\x69\x75\x6d\40\x76\x65\x72\163\151\x6f\156\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
goto QT;
lG:
$IL = json_decode($fG->mo_saml_vl($uk, false), true);
update_option("\166\154\137\143\x68\145\143\x6b\137\164", time());
if (is_array($IL) && strcasecmp($IL["\163\164\141\x74\165\163"], "\123\125\103\x43\105\x53\123") == 0) {
goto PW;
}
if (is_array($IL) && strcasecmp($IL["\x73\164\x61\x74\x75\163"], "\106\x41\111\x4c\105\104") == 0) {
goto Fa;
}
update_option("\x6d\x6f\137\x73\x61\x6d\154\137\155\x65\x73\x73\x61\147\x65", "\x41\156\40\145\x72\x72\157\162\x20\x6f\143\143\x75\162\x65\x64\40\x77\150\151\x6c\x65\x20\x70\x72\x6f\143\x65\163\x73\151\156\x67\40\x79\x6f\x75\x72\x20\162\145\x71\165\x65\x73\164\56\40\x50\x6c\145\141\163\x65\40\124\162\x79\40\141\147\x61\x69\156\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
goto XD;
Fa:
if (strcasecmp($IL["\155\145\x73\x73\141\147\145"], "\x43\x6f\144\145\40\150\141\x73\40\x45\x78\x70\151\162\x65\x64") == 0) {
goto tn;
}
update_option("\155\157\x5f\163\x61\x6d\154\137\x6d\x65\x73\163\x61\147\x65", "\x59\x6f\x75\40\x68\141\166\x65\x20\145\x6e\164\x65\162\x65\144\40\141\156\x20\151\156\166\141\x6c\151\x64\x20\154\x69\143\145\x6e\x73\145\x20\153\145\171\x2e\40\x50\154\145\x61\163\145\40\145\x6e\x74\145\x72\40\141\x20\166\141\154\x69\x64\x20\154\x69\x63\x65\156\163\145\x20\153\145\171\56");
goto vt;
tn:
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("\x74\x61\x62" => "\x6c\151\143\x65\x6e\163\151\x6e\147"), $_SERVER["\x52\x45\121\x55\x45\123\x54\137\125\122\x49"]);
update_option("\155\x6f\137\163\x61\x6d\154\137\155\x65\163\x73\141\147\x65", "\x4c\x69\143\145\x6e\163\145\x20\153\145\171\x20\171\x6f\165\40\150\x61\x76\x65\x20\x65\x6e\x74\x65\162\x65\x64\x20\x68\141\163\40\x61\x6c\162\x65\x61\x64\171\x20\142\x65\145\156\40\165\163\x65\x64\56\40\x50\154\x65\141\163\145\x20\x65\x6e\164\x65\162\40\x61\40\x6b\145\x79\40\167\150\151\x63\150\x20\150\x61\163\x20\x6e\157\164\40\x62\145\145\156\40\x75\x73\x65\x64\40\142\x65\146\x6f\x72\x65\40\157\x6e\x20\141\x6e\171\40\157\164\150\x65\162\x20\151\156\x73\x74\141\x6e\x63\145\40\157\162\x20\x69\x66\40\171\x6f\165\40\x68\141\166\x65\x20\x65\170\x61\165\163\164\145\144\x20\x61\x6c\154\40\x79\157\165\162\40\x6b\145\171\163\40\x74\x68\145\156\x20" . addLink("\103\x6c\x69\143\x6b\40\150\x65\x72\x65", $Ug) . "\x20\164\x6f\x20\142\165\x79\40\155\x6f\x72\x65\56");
vt:
SAMLSPUtilities::mo_saml_show_error_message();
XD:
goto eZ;
PW:
$Jp = get_option("\x6d\x6f\137\163\141\x6d\x6c\137\143\165\163\x74\157\155\x65\x72\x5f\x74\157\153\x65\156");
update_option("\x73\155\154\137\154\x6b", AESEncryption::encrypt_data($uk, $Jp));
$dq = "\131\x6f\165\162\40\154\x69\143\145\x6e\163\x65\40\x69\163\x20\x76\145\x72\x69\x66\x69\145\144\56\x20\131\x6f\x75\40\x63\x61\156\x20\156\x6f\x77\x20\163\x65\164\x75\160\40\x74\150\x65\x20\160\154\x75\x67\151\x6e\56";
update_option("\x6d\157\x5f\163\141\155\154\x5f\x6d\x65\x73\x73\141\147\x65", $dq);
$Jp = get_option("\x6d\x6f\137\163\x61\x6d\154\137\143\x75\163\x74\157\x6d\145\x72\137\164\157\153\x65\x6e");
update_option("\x73\x69\x74\x65\137\x63\x6b\x5f\154", AESEncryption::encrypt_data("\164\162\x75\145", $Jp));
update_option("\x74\137\x73\151\164\145\137\163\x74\141\164\x75\163", AESEncryption::encrypt_data("\x66\x61\x6c\x73\x65", $Jp));
$Xb = plugin_dir_path(__FILE__);
$PF = home_url();
$PF = trim($PF, "\x2f");
if (preg_match("\43\x5e\150\x74\164\x70\x28\163\x29\77\x3a\x2f\57\43", $PF)) {
goto A4;
}
$PF = "\x68\x74\x74\x70\x3a\x2f\x2f" . $PF;
A4:
$yy = parse_url($PF);
$m6 = preg_replace("\x2f\136\x77\167\167\134\56\57", '', $yy["\x68\x6f\x73\x74"]);
$Sg = wp_upload_dir();
$cm = $m6 . "\x2d" . $Sg["\x62\141\x73\x65\x64\151\x72"];
$rg = hash_hmac("\x73\x68\141\62\x35\x36", $cm, "\x34\x44\x48\146\x6a\x67\x66\x6a\141\163\156\x64\146\163\141\x6a\x66\110\107\x4a");
$Sx = $this->djkasjdksa();
$co = round(strlen($Sx) / rand(2, 20));
$Sx = substr_replace($Sx, $rg, $co, 0);
$yY = base64_decode($Sx);
if (is_writable($Xb . "\x6c\x69\143\145\x6e\x73\145")) {
goto iA;
}
$Sx = str_rot13($Sx);
$jG = "\x62\107\116\153\141\155\x74\x68\143\62\160\153\141\63\x4e\150\x59\x32\x77\x3d";
$lX = base64_decode($jG);
update_option($lX, $Sx);
goto me;
iA:
file_put_contents($Xb . "\154\151\x63\145\x6e\163\x65", $yY);
me:
update_option("\154\x63\x77\162\164\154\146\x73\x61\x6d\154", true);
if (empty($sY)) {
goto y0;
}
Mo_License_Service::update_license_expiry($sY);
y0:
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("\164\141\142" => "\147\145\x6e\x65\x72\141\154"), $_SERVER["\122\105\121\x55\105\x53\x54\137\125\122\111"]);
SAMLSPUtilities::mo_saml_show_success_message();
eZ:
QT:
Jf:
goto wx;
iX:
if (mo_saml_is_extension_installed("\143\x75\162\x6c")) {
goto xX;
}
update_option("\x6d\x6f\x5f\163\141\155\154\137\155\145\x73\x73\x61\x67\x65", "\105\x52\122\117\122\x3a\120\110\120\x20\x63\x55\x52\114\40\x65\x78\164\145\x6e\163\x69\x6f\x6e\x20\151\x73\x20\x6e\x6f\x74\40\151\x6e\x73\x74\x61\154\154\x65\x64\x20\x6f\162\x20\144\x69\163\x61\142\x6c\145\144\56\x20\x56\141\154\151\144\x61\x74\x65\40\x4f\124\120\x20\146\141\x69\x6c\x65\144\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
xX:
$Jb = '';
if ($this->mo_saml_check_empty_or_null($_POST["\157\x74\x70\x5f\164\x6f\153\145\x6e"])) {
goto dS;
}
$Jb = sanitize_text_field($_POST["\157\164\x70\x5f\x74\157\x6b\145\156"]);
goto MI;
dS:
update_option("\x6d\x6f\137\x73\x61\155\x6c\x5f\x6d\x65\163\163\x61\147\x65", "\120\154\145\141\163\145\40\145\x6e\164\x65\x72\x20\141\40\x76\141\154\165\145\x20\151\x6e\40\157\164\160\x20\x66\151\145\x6c\144\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
MI:
$fG = new CustomerSaml();
$IL = $fG->validate_otp_token(get_option("\x6d\157\x5f\163\x61\x6d\154\137\x74\x72\x61\x6e\163\141\143\x74\151\157\156\111\144"), $Jb);
if ($IL) {
goto KD;
}
return;
KD:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\x73\164\x61\164\x75\x73"], "\x53\x55\x43\x43\x45\123\x53") == 0) {
goto jO;
}
update_option("\155\157\137\163\141\155\x6c\x5f\x6d\x65\163\x73\x61\x67\x65", "\111\x6e\166\x61\x6c\x69\x64\40\x6f\x6e\x65\x20\x74\x69\155\x65\40\x70\x61\x73\163\143\x6f\144\x65\56\40\x50\154\145\141\x73\145\x20\145\x6e\x74\x65\162\x20\x61\40\x76\141\x6c\x69\144\x20\157\164\x70\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
goto ad;
jO:
$this->create_customer();
ad:
wx:
if (!self::mo_check_option_admin_referer("\x6d\x6f\x5f\163\141\155\154\x5f\x66\x72\145\145\137\x74\162\x69\x61\x6c")) {
goto C2;
}
if (decryptSamlElement()) {
goto u2;
}
$uk = postResponse();
$fG = new Customersaml();
$IL = $fG->mo_saml_vl($uk, false);
if ($IL) {
goto nF;
}
return;
nF:
$IL = json_decode($IL, true);
if (strcasecmp($IL["\163\164\141\164\165\163"], "\123\x55\103\103\105\x53\123") == 0) {
goto dc;
}
if (strcasecmp($IL["\163\x74\141\164\x75\x73"], "\x46\x41\111\114\105\x44") == 0) {
goto UH;
}
update_option("\x6d\x6f\137\163\141\x6d\154\x5f\x6d\145\163\x73\x61\x67\x65", "\101\156\x20\145\162\x72\x6f\162\40\x6f\143\143\165\x72\x65\x64\40\x77\x68\151\x6c\x65\x20\x70\x72\x6f\143\145\x73\163\151\156\147\x20\171\157\x75\162\40\162\x65\161\x75\x65\163\x74\x2e\x20\x50\154\145\x61\163\x65\40\x54\x72\x79\x20\x61\147\141\x69\156\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto W0;
UH:
update_option("\x6d\157\137\163\x61\x6d\x6c\x5f\x6d\145\x73\163\141\147\145", "\x54\150\x65\162\x65\40\167\x61\x73\40\141\156\x20\145\162\162\157\162\x20\141\143\x74\151\x76\141\x74\x69\156\x67\40\x79\x6f\x75\162\x20\124\122\x49\101\114\40\x76\145\x72\163\x69\x6f\x6e\x2e\x20\120\x6c\145\141\x73\x65\x20\143\x6f\x6e\x74\141\143\164\x20\x73\x61\155\x6c\163\x75\160\160\x6f\x72\164\100\170\145\x63\x75\162\x69\146\171\x2e\x63\157\x6d\x20\x66\157\x72\x20\x67\x65\164\x74\151\x6e\x67\40\156\x65\167\40\x6c\x69\x63\x65\x6e\163\145\x20\146\x6f\x72\40\164\x72\x69\141\154\40\x76\x65\162\163\151\157\x6e\56");
SAMLSPUtilities::mo_saml_show_error_message();
W0:
goto Lu;
dc:
$Jp = get_option("\155\157\137\x73\141\155\154\137\x63\165\x73\164\157\x6d\145\162\137\164\157\x6b\145\156");
$Jp = get_option("\x6d\157\x5f\x73\141\155\x6c\x5f\143\165\x73\x74\157\155\145\x72\137\164\x6f\x6b\x65\156");
update_option("\164\137\x73\x69\x74\x65\137\163\164\141\x74\x75\x73", AESEncryption::encrypt_data("\164\x72\165\145", $Jp));
update_option("\x6d\157\137\x73\141\155\154\x5f\x6d\145\163\x73\x61\147\x65", "\x59\157\165\162\x20\x35\x20\144\x61\171\x73\40\x54\x52\111\x41\x4c\40\151\163\x20\141\x63\x74\151\166\x61\x74\x65\144\x2e\x20\131\157\165\40\x63\141\x6e\x20\x6e\x6f\167\40\x73\x65\164\165\160\40\164\150\x65\x20\160\x6c\x75\147\151\x6e\56");
SAMLSPUtilities::mo_saml_show_success_message();
Lu:
goto NJ;
u2:
update_option("\155\157\x5f\163\x61\155\x6c\x5f\155\145\163\163\141\147\145", "\124\150\x65\162\145\40\x77\x61\x73\40\x61\x6e\40\145\x72\x72\157\x72\40\141\143\164\x69\166\x61\164\151\156\x67\x20\171\157\x75\162\x20\x54\122\x49\x41\x4c\40\x76\145\162\163\151\x6f\156\x2e\x20\105\151\x74\150\145\162\40\x79\157\165\162\40\164\162\x69\x61\154\x20\x70\x65\x72\x69\x6f\144\40\151\x73\40\x65\170\x70\x69\162\x65\x64\x20\157\162\x20\171\157\165\40\141\x72\x65\x20\165\x73\x69\156\147\40\167\x72\157\156\x67\x20\x74\x72\151\141\x6c\40\x76\145\x72\163\x69\157\156\x2e\x20\120\x6c\x65\141\163\x65\x20\143\157\156\x74\x61\x63\164\40\163\x61\155\x6c\163\x75\x70\x70\157\x72\164\100\x78\x65\x63\165\x72\x69\146\x79\x2e\143\x6f\155\x20\x66\157\162\40\x67\145\164\164\x69\156\147\40\156\x65\x77\x20\154\151\143\x65\156\163\x65\40\x66\x6f\x72\40\164\x72\x69\141\x6c\40\x76\x65\162\163\x69\157\156\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
NJ:
C2:
if (!self::mo_check_option_admin_referer("\x6d\x6f\137\x73\x61\155\x6c\137\143\150\145\x63\x6b\137\154\x69\143\x65\156\x73\145")) {
goto Sd;
}
$fG = new Customersaml();
$IL = $fG->check_customer_ln();
if ($IL) {
goto q5;
}
return;
q5:
$IL = json_decode($IL, true);
update_option("\x76\154\137\x63\x68\145\x63\153\x5f\x74", time());
if (strcasecmp($IL["\x73\x74\x61\x74\x75\163"], "\123\125\x43\103\x45\123\x53") == 0) {
goto wJ;
}
$Jp = get_option("\x6d\x6f\x5f\x73\141\x6d\x6c\137\143\x75\163\164\x6f\155\145\x72\137\164\157\x6b\145\156");
update_option("\x73\x69\x74\x65\137\143\153\137\154", AESEncryption::encrypt_data("\x66\x61\x6c\163\145", $Jp));
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("\164\x61\x62" => "\x6c\151\143\x65\156\163\151\x6e\147"), $_SERVER["\x52\105\121\x55\x45\x53\x54\x5f\x55\x52\x49"]);
update_option("\155\157\137\x73\141\x6d\154\137\x6d\145\x73\x73\x61\147\x65", "\131\157\x75\40\x68\141\166\145\x20\156\157\164\x20\x75\160\x67\162\141\144\x65\x64\x20\171\145\x74\x2e\x20" . addLink("\103\x6c\x69\x63\x6b\x20\x68\145\162\x65", $Ug) . "\40\164\157\x20\x75\160\x67\162\141\x64\x65\40\x74\157\x20\160\x72\145\x6d\151\x75\155\40\x76\145\x72\163\151\x6f\x6e\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto qS;
wJ:
if (!empty($IL["\154\x69\143\145\x6e\x73\145\120\154\141\156"]) && !$this->mo_saml_check_empty_or_null($IL["\x6c\151\143\x65\156\x73\145\120\154\x61\x6e"])) {
goto nt;
}
$Jp = get_option("\155\157\137\163\x61\155\x6c\x5f\143\x75\x73\x74\x6f\155\145\162\137\164\x6f\x6b\x65\x6e");
update_option("\x73\x69\x74\x65\137\143\153\x5f\154", AESEncryption::encrypt_data("\146\141\x6c\x73\145", $Jp));
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("\164\x61\142" => "\x6c\151\143\x65\x6e\x73\151\x6e\147"), $_SERVER["\x52\x45\x51\125\105\123\124\x5f\x55\122\111"]);
update_option("\x6d\157\x5f\163\x61\x6d\x6c\137\155\145\163\163\x61\x67\145", "\x59\x6f\165\x20\150\x61\166\x65\40\156\157\164\40\x75\x70\x67\162\141\144\145\x64\x20\171\x65\x74\x2e\40" . addLink("\103\154\x69\143\153\40\150\145\x72\x65", $Ug) . "\40\x74\x6f\x20\x75\x70\x67\x72\141\144\145\40\x74\157\40\x70\162\x65\155\151\x75\x6d\40\166\x65\x72\x73\151\x6f\x6e\56");
SAMLSPUtilities::mo_saml_show_error_message();
goto LC;
nt:
update_option("\155\x6f\x5f\x73\141\155\x6c\x5f\x6c\151\x63\x65\156\163\145\x5f\156\x61\x6d\145", base64_encode($IL["\154\151\x63\x65\x6e\x73\145\x50\x6c\x61\156"]));
$Jp = get_option("\155\x6f\x5f\x73\141\155\154\137\143\x75\x73\x74\157\155\145\162\137\164\157\153\145\156");
if (!(!empty($IL["\x6e\x6f\x4f\x66\125\x73\x65\162\x73"]) && !$this->mo_saml_check_empty_or_null($IL["\x6e\x6f\117\x66\x55\163\x65\162\x73"]))) {
goto iJ;
}
update_option("\x6d\x6f\137\x73\141\x6d\154\x5f\x75\163\162\137\x6c\155\x74", AESEncryption::encrypt_data($IL["\156\x6f\117\146\x55\163\145\162\x73"], $Jp));
iJ:
if (!(!empty($IL["\x6c\x69\143\x65\156\163\x65\x45\x78\160\x69\x72\171"]) && !$this->mo_saml_check_empty_or_null($IL["\154\151\x63\x65\156\x73\145\x45\170\160\x69\162\x79"]))) {
goto OY;
}
update_option("\155\x6f\137\163\x61\x6d\154\x5f\x6c\151\x63\x65\156\x73\145\137\x65\170\x70\151\x72\x79\x5f\144\141\x74\145", $this->mo_saml_parse_expiry_date($IL["\154\151\143\x65\x6e\163\145\105\170\x70\x69\x72\x79"]));
OY:
update_option("\163\151\164\x65\x5f\x63\x6b\137\154", AESEncryption::encrypt_data("\x74\x72\x75\145", $Jp));
$Xb = plugin_dir_path(__FILE__);
$PF = home_url();
$PF = trim($PF, "\x2f");
if (preg_match("\43\x5e\x68\x74\164\x70\50\x73\51\x3f\72\x2f\57\x23", $PF)) {
goto vi;
}
$PF = "\x68\164\164\x70\x3a\57\x2f" . $PF;
vi:
$yy = parse_url($PF);
$m6 = preg_replace("\x2f\136\167\x77\167\134\x2e\57", '', $yy["\150\157\x73\x74"]);
$Sg = wp_upload_dir();
$cm = $m6 . "\x2d" . $Sg["\142\141\x73\x65\144\x69\162"];
$rg = hash_hmac("\x73\x68\141\x32\65\66", $cm, "\x34\x44\x48\146\x6a\x67\x66\152\x61\163\156\144\x66\x73\x61\x6a\146\x48\x47\x4a");
$Sx = $this->djkasjdksa();
$co = round(strlen($Sx) / rand(2, 20));
$Sx = substr_replace($Sx, $rg, $co, 0);
$yY = base64_decode($Sx);
if (is_writable($Xb . "\x6c\x69\143\145\x6e\163\x65")) {
goto eH;
}
$Sx = str_rot13($Sx);
$jG = "\142\x47\116\x6b\x61\155\164\150\x63\x32\x70\153\141\x33\x4e\x68\131\x32\167\x3d";
$lX = base64_decode($jG);
update_option($lX, $Sx);
goto l1;
eH:
file_put_contents($Xb . "\154\151\143\x65\156\163\145", $yY);
l1:
update_option("\x6c\x63\167\x72\164\x6c\146\x73\141\x6d\154", true);
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("\164\x61\142" => "\147\145\156\x65\162\x61\x6c"), $_SERVER["\x52\105\x51\x55\105\123\x54\x5f\125\x52\111"]);
Mo_License_Service::refresh_license_expiry();
update_option("\155\x6f\137\x73\x61\x6d\154\137\155\x65\x73\x73\141\147\145", "\131\x6f\x75\40\x68\141\x76\145\40\x73\x75\x63\143\x65\x73\x73\146\165\x6c\154\171\x20\x73\x79\x6e\143\x65\144\40\x79\x6f\165\162\x20\154\151\x63\145\x6e\x73\x65\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
LC:
qS:
Sd:
if (!self::mo_check_option_admin_referer("\155\x6f\137\x73\141\x6d\154\x5f\162\x65\155\x6f\x76\145\137\141\143\143\x6f\165\x6e\164")) {
goto eT;
}
$this->mo_sso_saml_deactivate();
add_option("\x6d\x6f\137\163\x61\155\154\x5f\x72\145\x67\151\163\x74\x72\141\164\151\157\156\x5f\163\164\141\164\x75\163", "\x72\145\x6d\x6f\x76\145\144\137\141\143\x63\157\x75\156\x74");
$Ug = SAMLSPUtilities::mo_saml_add_query_arg(array("\164\141\142" => "\154\x6f\147\151\x6e"), $_SERVER["\x52\x45\121\x55\x45\x53\x54\x5f\125\x52\111"]);
header("\114\x6f\x63\141\164\151\157\156\72\40" . $Ug);
eT:
RE:
}
function create_customer()
{
$fG = new CustomerSaml();
$ds = $fG->create_customer();
if ($ds) {
goto KA;
}
return;
KA:
$ds = json_decode($ds, true);
if (strcasecmp($ds["\163\164\141\164\x75\x73"], "\103\125\x53\124\x4f\115\105\122\x5f\125\x53\105\122\x4e\x41\115\105\137\x41\x4c\x52\105\x41\104\x59\137\105\x58\x49\x53\x54\123") == 0) {
goto Sw;
}
if (!(strcasecmp($ds["\163\x74\141\x74\x75\x73"], "\123\x55\103\103\105\123\x53") == 0)) {
goto b8;
}
update_option("\155\157\137\163\x61\155\154\137\141\144\x6d\x69\x6e\137\x63\165\x73\164\157\155\x65\x72\137\x6b\x65\x79", $ds["\151\x64"]);
update_option("\x6d\x6f\x5f\x73\x61\x6d\154\137\141\x64\x6d\x69\156\x5f\x61\x70\151\x5f\x6b\145\x79", $ds["\141\x70\151\113\145\171"]);
update_option("\x6d\157\x5f\x73\x61\155\x6c\137\143\x75\163\164\x6f\155\x65\162\137\164\x6f\153\x65\156", $ds["\x74\157\x6b\145\x6e"]);
update_option("\155\x6f\x5f\x73\x61\155\154\x5f\141\144\155\x69\x6e\137\x70\141\163\163\167\157\x72\x64", '');
update_option("\155\157\137\163\x61\155\x6c\x5f\x6d\x65\163\x73\x61\x67\145", "\124\150\141\156\x6b\x20\x79\157\165\40\146\x6f\x72\x20\x72\x65\147\x69\163\x74\x65\162\x69\x6e\x67\x20\167\x69\x74\150\x20\x58\x65\143\x75\162\x69\146\x79\56");
update_option("\x6d\x6f\137\x73\141\155\x6c\x5f\x72\x65\x67\x69\x73\x74\x72\x61\x74\151\x6f\x6e\137\x73\164\141\164\165\163", '');
delete_option("\155\157\x5f\x73\x61\x6d\154\x5f\166\x65\162\151\146\171\137\143\x75\163\164\157\155\145\162");
delete_option("\x6d\157\x5f\x73\141\x6d\154\x5f\156\145\167\137\x72\145\x67\x69\x73\164\162\x61\164\151\x6f\156");
SAMLSPUtilities::mo_saml_show_success_message();
b8:
goto uC;
Sw:
$this->get_current_customer();
uC:
update_option("\x6d\157\x5f\163\x61\155\154\x5f\141\144\x6d\x69\x6e\x5f\x70\x61\163\x73\167\x6f\162\144", '');
}
function get_current_customer()
{
$fG = new CustomerSaml();
$IL = $fG->get_customer_key();
if ($IL) {
goto tr;
}
return;
tr:
$ds = json_decode($IL, true);
if (json_last_error() == JSON_ERROR_NONE) {
goto QM;
}
update_option("\x6d\x6f\137\163\x61\155\154\x5f\155\x65\x73\x73\141\147\x65", "\131\157\x75\x20\141\154\162\x65\x61\x64\171\x20\150\141\x76\145\x20\x61\156\40\141\143\x63\x6f\x75\156\x74\40\x77\151\164\150\40\155\151\x6e\151\x4f\x72\x61\156\147\x65\x2e\40\120\154\145\141\163\145\x20\x65\x6e\164\x65\162\x20\x61\x20\x76\x61\x6c\x69\x64\40\x70\x61\163\x73\167\157\x72\x64\56");
update_option("\155\x6f\137\163\141\155\154\x5f\x76\x65\x72\151\x66\x79\x5f\x63\165\163\x74\x6f\x6d\145\x72", "\x74\x72\165\145");
delete_option("\155\157\x5f\163\141\x6d\154\137\156\145\167\x5f\x72\x65\147\151\163\164\x72\141\164\x69\x6f\x6e");
SAMLSPUtilities::mo_saml_show_error_message();
goto tf;
QM:
update_option("\x6d\x6f\137\163\141\155\x6c\137\141\144\155\x69\x6e\137\143\x75\163\x74\157\x6d\145\162\137\x6b\x65\x79", $ds["\151\x64"]);
update_option("\155\157\x5f\163\x61\155\x6c\137\141\144\x6d\x69\x6e\137\141\x70\151\x5f\x6b\145\171", $ds["\x61\160\x69\113\x65\171"]);
update_option("\x6d\x6f\x5f\163\141\x6d\154\x5f\143\165\163\x74\x6f\x6d\x65\x72\137\164\x6f\153\x65\x6e", $ds["\164\157\x6b\145\x6e"]);
update_option("\155\157\137\x73\141\155\x6c\x5f\141\x64\155\151\156\x5f\x70\141\x73\163\167\x6f\x72\144", '');
update_option("\155\157\137\163\141\155\x6c\137\x6d\x65\x73\x73\x61\x67\145", "\131\157\x75\162\40\x61\143\143\x6f\165\156\164\40\150\141\163\x20\142\x65\145\156\40\x72\145\x74\x72\x69\145\166\145\x64\x20\163\165\143\143\145\x73\163\146\165\154\x6c\x79\x2e");
delete_option("\155\157\137\x73\x61\155\154\x5f\x76\x65\x72\x69\146\171\x5f\143\x75\163\164\157\x6d\x65\162");
delete_option("\155\157\137\163\141\155\154\137\x6e\145\x77\x5f\x72\145\x67\151\163\164\x72\141\164\151\x6f\156");
SAMLSPUtilities::mo_saml_show_success_message();
tf:
}
public function mo_saml_check_empty_or_null($lG)
{
if (!(!isset($lG) || empty($lG))) {
goto Mf;
}
return true;
Mf:
return false;
}
function miniorange_sso_menu()
{
$H_ = add_menu_page("\x4d\x4f\40\123\x41\x4d\114\40\123\145\x74\164\151\x6e\x67\163\40" . __("\103\157\156\x66\x69\x67\165\162\x65\x20\x53\x41\115\114\x20\x49\x64\x65\156\164\151\164\x79\x20\120\x72\157\x76\x69\x64\x65\162\x20\x66\157\x72\40\x53\x53\117", "\155\157\137\163\x61\x6d\154\137\163\145\164\x74\x69\156\x67\x73"), "\x6d\x69\x6e\151\117\162\141\x6e\x67\x65\x20\x53\101\115\114\40\62\56\x30\x20\x53\x53\117", "\x61\144\x6d\x69\x6e\x69\163\164\x72\x61\x74\157\162", "\x6d\157\x5f\163\x61\x6d\154\137\x73\145\x74\164\151\156\147\x73", array($this, "\155\x6f\137\x6c\x6f\147\151\x6e\x5f\167\x69\144\x67\145\x74\x5f\x73\x61\x6d\x6c\x5f\157\160\164\x69\157\156\163"), plugin_dir_url(__FILE__) . "\151\x6d\x61\x67\x65\163\57\x6d\x69\156\x69\x6f\162\x61\x6e\147\145\56\160\156\147");
add_submenu_page("\x6d\157\137\163\x61\x6d\154\x5f\x73\x65\164\x74\x69\x6e\x67\x73", "\105\x72\x72\x6f\x72\40\x43\x6f\x64\x65\163", "\x45\x72\162\x6f\162\40\x43\157\x64\145\x73", "\x61\144\x6d\151\x6e\151\x73\164\x72\x61\164\x6f\162", "\x6d\x6f\137\145\x72\x72\157\x72\x5f\x63\x6f\144\145\163", array("\115\157\x5f\123\x61\155\x6c\x5f\x45\x72\162\157\162\x5f\103\157\x64\145\x73\x5f\x56\x69\145\x77", "\x6d\x6f\x5f\163\141\155\x6c\137\147\145\164\137\145\x72\x72\157\162\137\x63\157\x64\x65\x73\x5f\x76\151\x65\x77"));
}
function mo_saml_redirect_for_authentication($XS)
{
if (!mo_saml_is_customer_license_key_verified()) {
goto eL;
}
if (!(get_option("\155\157\x5f\x73\141\x6d\154\137\x72\x65\147\x69\x73\164\x65\x72\145\144\x5f\x6f\x6e\x6c\171\x5f\x61\x63\143\x65\163\163") == "\164\162\165\x65")) {
goto WN;
}
$base_url = home_url();
echo "\x3c\x73\x63\162\151\160\164\76\x77\x69\156\144\157\167\56\x6c\x6f\x63\x61\164\x69\x6f\156\x2e\150\x72\x65\146\x3d\x27" . esc_url($base_url) . "\x2f\x3f\157\160\164\151\x6f\x6e\75\163\x61\155\x6c\x5f\165\163\x65\162\x5f\x6c\157\x67\151\x6e\x26\x72\x65\x64\x69\162\145\143\164\137\x74\157\x3d\x27\53\145\x6e\x63\157\x64\x65\125\x52\x49\x43\157\155\160\x6f\x6e\145\x6e\x74\50\x77\151\156\144\x6f\x77\x2e\154\x6f\x63\x61\x74\x69\x6f\156\x2e\x68\162\x65\x66\51\x3b\74\x2f\x73\143\162\x69\x70\164\x3e";
exit;
WN:
if (!(mo_saml_is_sp_configured() && Mo_License_Service::is_customer_license_valid() && get_option("\x6d\x6f\137\x73\141\x6d\154\137\x65\156\141\x62\x6c\x65\137\154\x6f\x67\151\156\137\x72\145\x64\x69\x72\145\143\164") == "\x74\162\x75\145")) {
goto lv;
}
$Tb = get_option("\x6d\x6f\x5f\163\141\x6d\x6c\137\163\x70\x5f\x62\x61\163\x65\137\165\x72\154");
if (!empty($Tb)) {
goto HL;
}
$Tb = home_url();
HL:
if (!(get_option("\155\x6f\x5f\x73\141\x6d\x6c\x5f\162\x65\154\x61\171\137\163\164\141\164\x65") && get_option("\x6d\157\x5f\x73\x61\x6d\154\137\162\145\x6c\141\171\x5f\163\x74\x61\164\x65") != '')) {
goto sk;
}
$XS = get_option("\155\157\137\x73\x61\x6d\154\x5f\162\x65\x6c\141\171\x5f\163\164\141\x74\x65");
sk:
$XS = mo_saml_get_relay_state($XS);
$Zi = empty($XS) ? "\x2f" : $XS;
$bL = htmlspecialchars_decode(get_option("\163\x61\x6d\154\137\154\x6f\x67\x69\156\137\165\x72\154"));
$Iy = get_option("\163\141\155\x6c\x5f\x6c\157\x67\151\156\x5f\142\151\x6e\144\151\x6e\x67\137\x74\x79\160\145");
$S7 = get_option("\155\x6f\x5f\x73\141\155\154\137\x66\157\162\x63\x65\x5f\x61\x75\x74\150\x65\x6e\x74\x69\x63\x61\x74\x69\157\156");
$f4 = $Tb . "\57";
$yX = get_option("\x6d\157\x5f\x73\141\155\x6c\137\x73\160\x5f\x65\156\x74\151\164\171\137\151\144");
$q2 = get_option("\163\141\x6d\x6c\137\x6e\x61\155\145\x69\x64\137\146\157\x72\x6d\141\164");
if (!empty($q2)) {
goto SG;
}
$q2 = "\x31\x2e\61\72\156\141\x6d\x65\x69\x64\55\146\x6f\x72\155\141\x74\x3a\x65\155\141\151\154\101\144\x64\162\145\163\x73";
SG:
if (!empty($yX)) {
goto pg;
}
$yX = $Tb . "\57\x77\x70\x2d\143\157\x6e\164\145\x6e\x74\x2f\x70\154\165\x67\151\156\x73\x2f\x6d\x69\x6e\151\157\162\141\156\x67\x65\55\x73\141\x6d\x6c\55\62\60\x2d\x73\151\x6e\147\154\x65\x2d\x73\x69\x67\x6e\x2d\157\x6e\x2f";
pg:
$LP = SAMLSPUtilities::createAuthnRequest($f4, $yX, $bL, $S7, $Iy, $q2);
if (empty($Iy) || $Iy == "\110\164\x74\x70\122\x65\144\x69\x72\x65\143\164") {
goto mU;
}
if (!(get_option("\163\x61\x6d\x6c\x5f\162\145\161\165\145\163\164\137\163\151\x67\156\x65\x64") == "\165\x6e\143\x68\x65\143\x6b\145\x64")) {
goto MM;
}
$Is = base64_encode($LP);
SAMLSPUtilities::postSAMLRequest($bL, $Is, $Zi);
exit;
MM:
$mC = '';
$Xu = '';
$Is = SAMLSPUtilities::signXML($LP, "\116\141\155\145\111\104\120\157\x6c\151\143\x79");
SAMLSPUtilities::postSAMLRequest($bL, $Is, $Zi);
goto cW;
mU:
$qU = $bL;
if (strpos($bL, "\77") !== false) {
goto aR;
}
$qU .= "\77";
goto Df;
aR:
$qU .= "\x26";
Df:
if (!(get_option("\163\x61\x6d\x6c\137\x72\145\x71\165\x65\x73\164\x5f\x73\x69\147\156\x65\144") == "\165\x6e\x63\150\x65\143\x6b\x65\144")) {
goto nG;
}
$qU .= "\x53\x41\x4d\x4c\x52\145\161\x75\x65\163\x74\x3d" . $LP . "\46\122\145\154\141\x79\123\x74\141\x74\145\x3d" . urlencode($Zi);
header("\x4c\x6f\x63\141\x74\x69\x6f\x6e\x3a\x20" . $qU);
exit;
nG:
$LP = "\123\x41\115\x4c\x52\x65\x71\165\145\163\164\x3d" . $LP . "\46\x52\x65\154\x61\171\x53\x74\141\x74\145\75" . urlencode($Zi) . "\46\123\151\147\x41\154\147\x3d" . urlencode(XMLSecurityKey::RSA_SHA256);
$AP = array("\164\x79\160\x65" => "\160\x72\x69\x76\141\x74\x65");
$Jp = new XMLSecurityKey(XMLSecurityKey::RSA_SHA256, $AP);
$Ha = get_option("\155\157\x5f\x73\x61\x6d\154\137\143\x75\162\x72\145\x6e\164\x5f\x63\145\162\x74\137\160\162\151\166\x61\x74\x65\x5f\153\x65\171");
$Jp->loadKey($Ha, FALSE);
$eR = new XMLSecurityDSig();
$FK = $Jp->signData($LP);
$FK = base64_encode($FK);
$qU .= $LP . "\46\123\151\147\156\141\164\x75\x72\x65\x3d" . urlencode($FK);
header("\x4c\x6f\143\141\x74\x69\157\x6e\x3a\40" . $qU);
exit;
cW:
lv:
eL:
}
function mo_saml_authenticate()
{
$WF = '';
if (!isset($_REQUEST["\x72\145\144\x69\x72\145\x63\164\x5f\164\x6f"])) {
goto cy;
}
$WF = SAMLSPUtilities::mo_saml_sanitize_url($_REQUEST["\162\145\x64\151\162\x65\143\164\x5f\x74\157"]);
cy:
if (!is_user_logged_in()) {
goto wu;
}
$this->mo_saml_login_redirect($WF);
wu:
if (!(get_option("\155\x6f\137\163\141\155\x6c\x5f\x65\x6e\141\142\154\145\x5f\x6c\x6f\x67\x69\156\137\x72\145\x64\151\x72\145\x63\164") == "\x74\x72\x75\145" && Mo_License_Service::is_customer_license_valid())) {
goto ba;
}
$bT = get_option("\x6d\157\137\163\141\155\x6c\x5f\142\141\x63\153\x64\157\x6f\x72\x5f\165\x72\x6c") ? trim(get_option("\x6d\157\137\163\x61\x6d\x6c\x5f\x62\141\143\x6b\x64\x6f\x6f\162\x5f\x75\x72\154")) : "\146\141\154\x73\145";
if (isset($_GET["\x6c\157\147\147\145\x64\x6f\x75\x74"]) && $_GET["\154\157\147\147\145\144\157\165\x74"] == "\x74\x72\165\x65") {
goto FC;
}
if (!(get_option("\155\157\x5f\x73\141\x6d\x6c\137\141\x6c\x6c\x6f\x77\x5f\x77\160\137\x73\x69\x67\156\151\x6e") == "\164\x72\x75\145")) {
goto IZ;
}
if (isset($_GET["\x73\141\x6d\154\137\163\163\157"]) && $_GET["\x73\x61\155\x6c\137\x73\x73\x6f"] == $bT || isset($_POST["\163\141\155\x6c\137\x73\x73\157"]) && $_POST["\x73\141\x6d\154\x5f\163\163\x6f"] == $bT) {
goto TR;
}
if (!isset($_REQUEST["\x72\145\x64\151\162\x65\x63\164\137\164\157"])) {
goto Vt;
}
$WF = SAMLSPUtilities::mo_saml_sanitize_url($_REQUEST["\x72\x65\144\x69\x72\145\x63\x74\x5f\x74\157"]);
if (!(strpos($WF, "\167\x70\x2d\x61\x64\155\151\x6e") !== false && strpos($WF, "\x73\141\x6d\154\x5f\x73\163\157\x3d" . $bT) !== false)) {
goto zn;
}
return;
zn:
Vt:
goto aL;
TR:
return;
aL:
IZ:
goto EP;
FC:
header("\x4c\157\143\x61\164\151\x6f\x6e\x3a\x20" . home_url());
exit;
EP:
$this->mo_saml_redirect_for_authentication($WF);
ba:
}
function mo_saml_login_redirect($WF)
{
$Lc = false;
if (!(strcmp(admin_url(), $WF) == 0 || strcmp(wp_login_url(), $WF) == 0)) {
goto NH;
}
$Lc = true;
NH:
if (!empty($WF) && !$Lc) {
goto CG;
}
header("\x4c\157\143\x61\x74\151\157\156\x3a\40" . site_url());
goto an;
CG:
header("\x4c\x6f\x63\x61\x74\x69\157\x6e\x3a\40" . htmlspecialchars_decode($WF));
an:
exit;
}
function mo_saml_auto_redirect()
{
if (!(current_user_can("\x72\145\141\x64") || is_user_logged_in())) {
goto TO;
}
return;
TO:
if (!(get_option("\x6d\x6f\x5f\x73\x61\155\154\x5f\x72\145\147\151\x73\164\145\x72\145\144\137\x6f\156\x6c\x79\x5f\x61\x63\143\x65\x73\x73") == "\x74\x72\x75\145")) {
goto Ca;
}
if (!(get_option("\x6d\157\x5f\163\141\x6d\x6c\137\145\156\141\142\154\145\x5f\x72\163\163\x5f\141\x63\x63\145\x73\x73") == "\164\x72\x75\x65" && is_feed())) {
goto hj;
}
return;
hj:
$XS = saml_get_current_page_url();
$this->mo_saml_redirect_for_authentication($XS);
Ca:
}
function mo_saml_modify_login_form()
{
if (!(get_option("\155\157\137\163\141\x6d\154\137\141\144\144\x5f\x73\x73\157\x5f\x62\165\x74\164\x6f\x6e\x5f\x77\x70") == "\164\162\165\145")) {
goto RS;
}
$this->mo_saml_add_sso_button();
RS:
$bT = get_option("\x6d\x6f\x5f\163\141\x6d\154\137\142\141\143\x6b\144\x6f\x6f\x72\137\165\162\x6c") ? trim(get_option("\x6d\x6f\137\163\x61\x6d\154\137\142\x61\143\153\x64\x6f\x6f\162\x5f\165\x72\154")) : "\146\141\x6c\x73\x65";
echo "\x3c\151\x6e\x70\x75\164\x20\x74\171\x70\x65\x3d\x22\150\x69\x64\144\145\x6e\x22\x20\156\x61\155\145\x3d\42\163\141\155\x6c\137\x73\x73\157\x22\40\x76\x61\x6c\165\x65\x3d\42" . esc_attr($bT) . "\x22\76" . "\xa";
}
function mo_saml_add_sso_button()
{
if (!(!is_user_logged_in() && Mo_License_Service::is_customer_license_valid(false, false))) {
goto Pu;
}
$Rk = get_option("\163\x61\x6d\x6c\x5f\151\x64\145\156\164\151\164\x79\x5f\156\x61\x6d\x65");
$r3 = $Rk ? "\x4c\x6f\x67\x69\156\40\x77\x69\x74\x68\x20" . $Rk : "\x4c\157\147\x69\x6e\40\167\x69\x74\x68\40\123\x53\x4f";
$Xz = "\xa\x20\x20\x20\40\40\40\40\x20\x20\x20\x20\40\x20\x20\x20\x20\x3c\x73\x63\162\151\160\164\76\xa\40\40\40\40\x20\40\40\40\x20\x20\40\40\40\40\x20\x20\167\151\156\144\157\167\x2e\x6f\x6e\x6c\157\141\144\x20\75\x20\146\165\156\143\x74\x69\157\x6e\x28\51\40\173\12\x9\x20\40\x20\40\x20\x20\x20\x20\40\x20\x20\40\40\x20\x20\40\x76\x61\162\40\x74\x61\x72\x67\x65\164\137\142\x74\156\40\75\x20\x64\157\x63\165\155\x65\156\164\56\147\145\x74\105\154\145\155\145\x6e\164\102\171\111\144\50\42\x6d\x6f\x5f\x73\141\155\154\137\142\165\x74\x74\157\x6e\x22\51\73\xa\x9\40\x20\40\x20\x20\40\x20\40\x20\x20\40\x20\40\40\x20\x20\x76\x61\162\40\142\145\x66\157\x72\x65\x5f\x65\154\x65\155\145\x6e\164\40\x3d\40\144\157\x63\165\155\x65\156\x74\56\x71\165\145\162\171\123\145\154\145\143\x74\x6f\162\x28\x22\x23\x6c\157\x67\x69\x6e\146\157\x72\x6d\40\x70\x22\x29\x3b\12\x9\x20\x20\40\x20\x20\x20\40\40\40\40\40\40\40\40\40\x20\142\x65\146\157\x72\x65\137\x65\154\145\155\x65\156\164\x2e\x62\x65\146\157\162\x65\x28\164\141\162\147\145\164\x5f\142\x74\x6e\51\x3b\xa\x20\x20\x20\x20\40\x20\40\40\40\40\40\40\40\x20\x20\40\x7d\73\xa\40\x20\x20\x20\40\40\x20\x20\x20\40\40\40\x20\40\40\x20\x20\x20\40\x20\x66\x75\156\143\x74\x69\x6f\156\40\154\157\x67\x69\x6e\127\151\x74\x68\123\123\x4f\x42\165\164\164\157\156\50\x69\144\51\x20\173\12\40\x20\x20\x20\40\40\40\40\x20\40\x20\40\x20\40\x20\x20\x20\x20\40\x20\x20\40\x20\x20\x69\x66\50\x20\151\x64\x20\x3d\75\x3d\x20\x22\155\157\x5f\163\x61\155\154\137\154\x6f\x67\x69\x6e\x5f\163\163\157\x5f\142\x75\164\164\157\x6e\42\51\12\x20\x20\40\40\40\40\40\40\x20\40\40\40\40\40\40\40\x20\x20\x20\40\40\40\40\x20\x20\40\40\x20\x64\157\x63\165\155\x65\x6e\164\56\x67\145\164\105\x6c\x65\155\145\156\164\x42\x79\111\144\50\42\x73\141\155\154\137\165\x73\145\x72\137\x6c\157\x67\x69\x6e\x5f\151\156\x70\x75\164\42\x29\56\x76\x61\x6c\165\145\x20\x3d\40\x22\163\x61\155\x6c\137\x75\163\145\162\137\154\157\147\x69\x6e\x22\73\xa\x20\x20\40\40\x20\40\x20\40\x20\x20\x20\40\x20\40\x20\40\40\40\40\40\40\40\40\x20\x64\157\143\x75\x6d\145\x6e\x74\56\147\x65\164\105\154\x65\155\x65\x6e\164\x42\x79\x49\144\50\x22\154\x6f\x67\151\156\146\x6f\162\x6d\42\51\x2e\x73\x75\142\x6d\151\164\50\51\73\x20\12\40\x20\x20\x20\40\40\40\40\40\40\40\40\x20\x20\40\x20\x20\40\x20\x20\175\12\11\x9\11\x9\x3c\57\163\x63\x72\x69\160\164\x3e\xa\x9\11\40\40\x20\x20\40\40\40\40\x3c\151\156\160\165\x74\40\151\x64\x3d\42\x73\141\155\154\x5f\x75\x73\145\x72\137\154\157\147\151\156\137\x69\x6e\160\165\164\x22\x20\x74\171\x70\145\x3d\x22\150\151\x64\144\145\x6e\42\x20\x6e\141\x6d\x65\75\42\x6f\160\x74\151\x6f\156\x22\40\166\x61\x6c\165\x65\75\42\42\40\x2f\x3e\12\40\40\x20\40\x20\x20\40\x20\40\40\x20\x20\x20\40\40\40\x3c\x64\x69\x76\x20\151\144\x3d\42\155\x6f\137\163\x61\155\x6c\x5f\142\165\x74\x74\x6f\x6e\42\40\163\164\171\x6c\145\75\x22\x68\145\x69\147\150\164\x3a\70\70\x70\170\73\x22\76\12\40\40\40\x20\40\x20\x20\x20\x20\x20\40\x20\x20\x20\40\x20\11\x3c\x64\151\166\x20\151\144\x3d\42\x6d\x6f\x5f\163\x61\155\154\137\154\157\x67\151\x6e\x5f\x73\x73\157\x5f\142\x75\164\164\x6f\x6e\42\40\x6f\x6e\143\x6c\x69\143\153\75\42\x6c\x6f\147\151\x6e\x57\151\164\x68\123\x53\117\x42\x75\x74\164\x6f\x6e\50\164\x68\151\163\x2e\x69\x64\51\42\40\163\x74\x79\154\145\75\x22\x77\x69\144\x74\150\72\x31\x30\60\45\x3b\144\x69\163\x70\x6c\141\x79\72\x66\154\x65\x78\x3b\152\165\163\164\x69\146\x79\x2d\143\x6f\156\164\x65\156\x74\72\143\145\156\164\x65\162\x3b\x61\x6c\151\x67\156\x2d\151\164\145\x6d\x73\x3a\143\x65\156\x74\145\162\73\146\157\156\164\55\x73\151\172\x65\x3a\61\x34\160\170\x3b\x6d\141\162\147\151\156\x2d\142\x6f\164\164\157\155\x3a\61\56\63\x72\145\155\x22\x20\x63\x6c\x61\163\163\x3d\42\142\x75\164\164\x6f\156\x20\x62\x75\x74\164\x6f\156\x2d\x70\x72\151\x6d\x61\x72\x79\42\76\12\11\x9\11\11\x9\74\151\x6d\147\x20\x73\164\x79\154\x65\75\x22\167\x69\144\x74\150\72\x32\x30\160\170\x3b\150\x65\x69\147\x68\164\72\x31\65\x70\x78\x3b\x70\141\144\x64\151\x6e\x67\55\162\x69\x67\x68\x74\x3a\61\x70\170\x22\x20\163\x72\143\75\42" . esc_url(plugin_dir_url(__FILE__)) . "\151\155\141\147\145\163\57\x6c\157\x63\153\55\x69\143\x6f\156\x2e\x70\156\x67\42\x3e" . esc_html($r3) . "\74\x2f\144\151\x76\x3e\xa\40\40\40\40\40\x20\40\40\x20\40\x20\40\x20\x20\x20\40\x20\40\x20\x20\x3c\144\x69\166\x20\x73\x74\171\x6c\145\75\x22\x70\x61\144\x64\x69\x6e\x67\x3a\x35\x70\x78\x3b\x66\157\156\x74\55\x73\x69\x7a\x65\x3a\61\64\160\x78\x3b\x68\145\x69\x67\x68\x74\72\x32\60\160\170\73\x74\145\x78\x74\x2d\141\x6c\151\x67\156\x3a\143\145\156\x74\x65\x72\x22\x3e\x3c\142\76\x4f\122\74\57\142\x3e\74\x2f\x64\x69\x76\x3e\xa\40\x20\40\x20\40\x20\x20\40\40\x20\x20\40\40\x20\x20\40\74\57\144\x69\166\76";
echo $Xz;
Pu:
}
function djkasjdksa()
{
$QJ = "\x21\176\x40\43\44\x25\x5e\46\x2a\50\51\137\x2b\x7c\x7b\x7d\74\x3e\77\60\x31\62\63\64\x35\66\x37\70\x39\141\142\x63\x64\145\146\147\150\x69\x6a\x6b\x6c\155\x6e\157\x70\161\x72\163\164\165\x76\x77\x78\171\x7a\101\x42\x43\x44\105\106\107\110\111\112\113\x4c\x4d\x4e\117\120\121\122\x53\x54\125\126\x57\x58\131\132";
$SU = strlen($QJ);
$ul = '';
$YE = 0;
Yy:
if (!($YE < 10000)) {
goto N3;
}
$ul .= $QJ[rand(0, $SU - 1)];
JJ:
$YE++;
goto Yy;
N3:
return $ul;
}
function mo_get_saml_shortcode()
{
if (Mo_License_Service::is_customer_license_valid(false, false)) {
goto ca;
}
$Xz = '';
goto EH;
ca:
if (!is_user_logged_in()) {
goto A2;
}
$current_user = wp_get_current_user();
$gP = "\x48\145\x6c\154\x6f\54";
if (!get_option("\x6d\157\137\x73\141\x6d\x6c\x5f\143\165\163\164\157\x6d\x5f\x67\x72\145\145\164\x69\156\147\137\164\145\170\164")) {
goto VS;
}
$gP = get_option("\155\x6f\137\x73\x61\x6d\x6c\x5f\143\165\x73\164\157\155\x5f\147\162\145\x65\x74\x69\156\147\137\164\x65\x78\164");
VS:
$Lu = '';
if (!get_option("\155\x6f\137\x73\141\155\x6c\x5f\147\x72\x65\145\x74\151\x6e\147\x5f\156\141\155\145")) {
goto qv;
}
switch (get_option("\155\157\x5f\163\x61\x6d\154\x5f\x67\x72\145\145\x74\151\156\x67\x5f\x6e\x61\x6d\145")) {
case "\125\123\105\x52\x4e\101\115\x45":
$Lu = $current_user->user_login;
goto sf;
case "\105\x4d\x41\x49\114":
$Lu = $current_user->user_email;
goto sf;
case "\106\116\x41\115\x45":
$Lu = $current_user->user_firstname;
goto sf;
case "\x4c\x4e\x41\115\x45":
$Lu = $current_user->user_lastname;
goto sf;
case "\x46\x4e\101\115\105\x5f\114\116\x41\x4d\x45":
$Lu = $current_user->user_firstname . "\x20" . $current_user->user_lastname;
goto sf;
case "\114\x4e\x41\x4d\x45\137\106\116\101\115\105":
$Lu = $current_user->user_lastname . "\40" . $current_user->user_firstname;
goto sf;
default:
$Lu = $current_user->user_login;
}
Oq:
sf:
qv:
if (!empty(trim($Lu))) {
goto SR;
}
$Lu = $current_user->user_login;
SR:
$Y9 = $gP . "\40" . $Lu;
$Qb = "\x4c\x6f\x67\x6f\165\x74";
if (!get_option("\x6d\157\137\x73\141\x6d\154\x5f\x63\165\x73\164\157\x6d\x5f\154\157\147\x6f\165\x74\x5f\164\145\170\164")) {
goto zu;
}
$Qb = get_option("\x6d\x6f\x5f\x73\141\155\154\137\143\x75\163\164\157\x6d\137\154\157\x67\157\x75\x74\x5f\x74\x65\x78\x74");
zu:
$Xz = $Y9 . "\40\174\40\74\x61\x20\x68\162\x65\x66\x3d\42" . wp_logout_url(home_url()) . "\x22\40\164\151\164\x6c\x65\75\x22\x6c\157\x67\157\165\x74\x22\x20\76" . $Qb . "\x3c\57\x61\76\x3c\x2f\154\151\x3e";
$Ug = saml_get_current_page_url();
update_option("\x6c\x6f\x67\157\165\164\137\162\x65\x64\x69\162\145\x63\164\x5f\x75\x72\x6c", $Ug);
goto EL;
A2:
$Tb = get_option("\x6d\x6f\137\x73\x61\155\x6c\x5f\163\x70\x5f\x62\x61\163\x65\x5f\x75\x72\x6c");
if (!empty($Tb)) {
goto kU;
}
$Tb = home_url();
kU:
if (mo_saml_is_sp_configured() && mo_saml_is_customer_license_key_verified()) {
goto ob;
}
$Xz = "\x53\x50\40\151\163\x20\156\x6f\164\40\143\157\156\146\151\147\165\162\x65\144\56";
goto C_;
ob:
$R_ = "\114\157\147\x69\156\x20\x77\x69\164\150\40" . get_option("\x73\x61\155\154\x5f\x69\x64\x65\156\x74\x69\164\171\x5f\156\x61\x6d\145");
if (!get_option("\x6d\x6f\137\163\141\x6d\x6c\137\143\165\163\164\x6f\155\x5f\x6c\x6f\x67\x69\x6e\137\x74\x65\x78\164")) {
goto Nv;
}
$R_ = get_option("\x6d\x6f\x5f\x73\x61\x6d\154\x5f\x63\x75\163\x74\157\x6d\137\154\157\x67\x69\x6e\x5f\164\x65\170\x74");
Nv:
$wP = get_option("\x73\x61\155\154\x5f\x69\144\145\156\164\151\164\x79\x5f\156\x61\x6d\145");
$R_ = str_replace("\x23\x23\111\104\x50\x23\43", $wP, $R_);
$WF = urlencode(saml_get_current_page_url());
$Xz = "\74\x61\40\x68\162\x65\146\75\x22" . $Tb . "\x2f\x3f\x6f\160\x74\x69\157\156\x3d\x73\x61\155\154\x5f\x75\x73\x65\x72\137\154\x6f\147\x69\156\x26\162\145\144\x69\162\145\143\164\x5f\164\157\75" . $WF . "\42\76" . $R_ . "\x3c\x2f\141\x3e";
C_:
EL:
EH:
return $Xz;
}
function _handle_upload_metadata()
{
if (!(isset($_FILES["\x6d\145\164\x61\x64\141\x74\141\137\x66\151\x6c\145"]) || isset($_POST["\x6d\145\164\141\144\141\x74\x61\137\165\162\154"]))) {
goto YL;
}
if (!empty($_FILES["\155\x65\x74\141\x64\141\x74\141\x5f\x66\151\x6c\145"]["\x74\155\160\137\x6e\141\155\145"])) {
goto eK;
}
if (mo_saml_is_extension_installed("\143\x75\x72\154")) {
goto Kw;
}
update_option("\155\157\x5f\x73\141\x6d\x6c\x5f\155\145\x73\163\141\147\145", "\x50\x48\120\40\x63\x55\x52\114\40\x65\x78\164\145\x6e\x73\151\x6f\156\40\x69\x73\40\156\x6f\164\40\x69\x6e\x73\x74\141\154\x6c\x65\144\40\x6f\162\x20\144\x69\163\141\142\154\x65\x64\x2e\40\103\141\156\x6e\157\x74\40\x66\145\x74\143\x68\40\x6d\145\x74\x61\144\141\x74\141\x20\146\x72\157\155\x20\125\x52\114\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Kw:
$Ug = filter_var(htmlspecialchars($_POST["\x6d\145\164\141\x64\x61\x74\141\137\165\x72\154"]), FILTER_SANITIZE_URL);
$HS = SAMLSPUtilities::mo_saml_wp_remote_call($Ug, array("\x73\163\154\x76\x65\x72\151\146\x79" => false), true);
if (!is_null($HS)) {
goto vz;
}
$rm = null;
goto u4;
vz:
$rm = $HS;
u4:
goto B7;
eK:
$rm = @file_get_contents(sanitize_text_field($_FILES["\x6d\x65\x74\x61\x64\141\x74\x61\137\146\151\x6c\x65"]["\x74\155\160\x5f\156\141\x6d\x65"]));
B7:
if (!is_null($rm)) {
goto U8;
}
update_option("\155\x6f\x5f\163\x61\155\x6c\137\x6d\x65\163\163\141\147\145", "\111\156\166\x61\x6c\x69\x64\40\115\x65\x74\141\144\141\x74\x61\40\x46\x69\x6c\x65\40\x6f\x72\x20\125\x52\114");
SAMLSPUtilities::mo_saml_show_error_message();
return;
goto lY;
U8:
$this->upload_metadata($rm);
lY:
YL:
}
function upload_metadata($rm)
{
if (!empty($rm)) {
goto j2;
}
update_option("\x6d\x6f\137\163\x61\155\154\137\155\x65\163\163\141\147\x65", "\105\x72\162\157\162\x3a\40\103\x6f\165\x6c\x64\x6e\x27\x74\x20\165\160\x6c\157\x61\x64\x20\x6d\x65\x74\141\x64\x61\164\141\x2e\x20\115\x65\x74\x61\x64\x61\x74\141\x20\x46\151\154\145\x20\x69\163\40\x65\x6d\x70\x74\x79\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
j2:
$Eo = set_error_handler(array($this, "\x68\141\x6e\x64\x6c\145\x58\x6d\154\105\x72\x72\157\x72"));
$cp = new DOMDocument();
$cp->loadXML($rm);
restore_error_handler();
$Ci = $cp->firstChild;
if (!empty($Ci)) {
goto w2;
}
if (!empty($_FILES["\155\145\164\x61\x64\141\x74\141\137\146\x69\154\145"]["\x74\x6d\160\x5f\x6e\x61\155\x65"])) {
goto Nq;
}
if (!empty($_POST["\x6d\x65\x74\141\x64\141\164\141\x5f\x75\162\154"])) {
goto B3;
}
update_option("\155\x6f\137\x73\x61\155\154\137\155\x65\x73\x73\141\x67\145", "\120\x6c\145\x61\163\145\40\160\x72\157\166\151\144\x65\40\x61\40\166\x61\x6c\x69\144\x20\155\x65\x74\x61\x64\x61\164\x61\40\x66\151\x6c\x65\x20\157\x72\x20\x61\x20\x76\141\x6c\151\x64\40\x55\122\x4c\56");
SAMLSPUtilities::mo_saml_show_error_message();
return;
goto k_;
B3:
update_option("\x6d\x6f\x5f\x73\x61\x6d\154\137\155\x65\163\163\141\147\x65", "\x50\154\x65\x61\163\145\40\160\162\x6f\x76\x69\144\145\40\141\x20\x76\141\x6c\x69\144\x20\x6d\145\164\x61\144\141\164\x61\40\x55\122\114\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
k_:
goto ps;
Nq:
update_option("\x6d\157\137\x73\141\x6d\154\x5f\155\x65\163\x73\x61\147\145", "\x50\154\x65\x61\x73\145\x20\x70\162\157\166\151\144\x65\40\x61\x20\x76\141\154\x69\144\40\x6d\x65\x74\141\144\141\164\141\40\x66\x69\154\145\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
ps:
goto TB;
w2:
$Al = new IDPMetadataReader($cp);
$NH = $Al->getIdentityProviders();
if (preg_match("\x2f\136\x5c\x77\x2a\44\57", $_POST["\163\x61\155\x6c\x5f\x69\144\x65\156\164\x69\x74\171\x5f\155\145\x74\141\144\x61\x74\141\x5f\x70\162\157\x76\x69\x64\145\x72"])) {
goto JW;
}
update_option("\x6d\x6f\x5f\163\x61\155\x6c\x5f\x6d\145\x73\163\141\147\145", __("\120\154\145\x61\163\x65\40\155\x61\164\143\150\x20\164\150\x65\x20\x72\145\161\x75\145\x73\x74\145\x64\40\146\157\x72\x6d\x61\x74\x20\146\157\162\x20\111\144\x65\156\x74\x69\164\171\x20\120\162\157\166\x69\x64\x65\x72\x20\116\x61\x6d\145\56\x20\117\x6e\x6c\171\x20\141\154\160\x68\141\142\145\x74\163\54\x20\x6e\165\155\x62\145\162\163\40\141\x6e\x64\40\x75\x6e\x64\x65\162\x73\x63\157\162\145\x20\x69\163\x20\141\154\x6c\157\x77\x65\144\x2e", "\155\151\x6e\x69\157\162\x61\156\x67\x65\x2d\163\141\155\x6c\x2d\x32\x30\55\x73\151\x6e\x67\x6c\145\x2d\x73\x69\147\x6e\55\157\156"));
SAMLSPUtilities::mo_saml_show_error_message();
return;
JW:
if (!(empty($NH) && !empty($_FILES["\x6d\145\x74\x61\x64\141\x74\x61\137\146\x69\154\x65"]["\164\x6d\x70\137\156\x61\x6d\x65"]))) {
goto sF;
}
update_option("\x6d\157\137\x73\141\155\154\137\x6d\x65\x73\163\141\x67\x65", "\120\x6c\x65\141\163\x65\40\160\162\x6f\x76\151\x64\x65\40\141\x20\166\141\x6c\x69\144\x20\155\145\164\x61\144\x61\x74\x61\x20\146\151\x6c\x65\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
sF:
if (!(empty($NH) && !empty($_POST["\x6d\x65\164\x61\x64\x61\164\x61\x5f\x75\162\x6c"]))) {
goto Ys;
}
update_option("\155\x6f\137\x73\141\155\154\x5f\155\x65\x73\163\x61\x67\x65", "\120\x6c\x65\141\163\x65\40\x70\x72\x6f\x76\151\144\x65\40\141\40\166\x61\154\151\x64\40\155\x65\x74\x61\144\141\164\141\x20\x55\122\114\x2e");
SAMLSPUtilities::mo_saml_show_error_message();
return;
Ys:
foreach ($NH as $Jp => $mi) {
$Nv = sanitize_text_field($_POST["\163\x61\155\154\x5f\x69\144\x65\156\x74\151\x74\x79\137\x6d\x65\164\x61\144\x61\164\x61\x5f\160\162\x6f\x76\151\x64\145\x72"]);
$Hv = "\x48\164\164\x70\122\145\x64\151\x72\x65\x63\x74";
$LO = '';
$bD = $mi->getLoginDetails();
$tY = $mi->getLogoutDetails();
if (!empty($bD["\110\124\124\120\x2d\x52\145\x64\151\x72\x65\143\164"])) {
goto H9;
}
if (empty($bD["\110\124\x54\120\x2d\x50\x4f\123\124"])) {
goto x4;
}
$Hv = "\110\164\164\160\120\157\163\x74";
$LO = $mi->getLoginURL("\x48\124\124\x50\x2d\x50\x4f\x53\x54");
x4:
goto Ie;
H9:
$LO = $mi->getLoginURL("\110\124\x54\120\x2d\x52\145\x64\151\x72\x65\x63\164");
Ie:
$Fw = $mi->getEntityID();
$fK = $mi->getSigningCertificate();
update_option("\x73\x61\155\x6c\137\151\x64\x65\x6e\x74\151\164\x79\x5f\156\141\155\145", $Nv);
update_option("\x73\x61\x6d\154\x5f\x6c\x6f\147\x69\x6e\x5f\142\x69\x6e\144\151\x6e\x67\137\164\x79\160\x65", $Hv);
update_option("\163\x61\155\x6c\x5f\x6c\157\147\x69\x6e\x5f\165\x72\154", $LO);
update_option("\163\141\x6d\154\x5f\x69\x73\x73\x75\145\162", $Fw);
update_option("\x73\141\x6d\x6c\x5f\x6e\141\155\145\151\144\x5f\146\x6f\162\x6d\x61\x74", "\x31\56\61\72\x6e\141\155\145\151\144\55\146\x6f\x72\x6d\141\x74\x3a\165\156\x73\x70\x65\143\x69\x66\x69\x65\144");
update_option("\x73\x61\155\x6c\x5f\x78\65\x30\71\137\143\x65\x72\164\151\146\x69\x63\141\164\145", maybe_serialize($fK));
goto RR;
fH:
}
RR:
update_option("\155\x6f\x5f\163\x61\155\x6c\x5f\x6d\x65\x73\163\x61\147\145", "\111\x64\145\156\x74\x69\164\x79\x20\120\162\x6f\x76\x69\144\145\x72\x20\144\145\x74\141\x69\x6c\163\x20\163\x61\166\145\144\40\x73\165\143\143\x65\x73\x73\x66\165\154\x6c\171\x2e");
SAMLSPUtilities::mo_saml_show_success_message();
TB:
}
function handleXmlError($YZ, $py, $Hb, $PX)
{
if ($YZ == E_WARNING && substr_count($py, "\104\117\x4d\104\x6f\143\x75\x6d\145\156\x74\x3a\72\154\157\141\x64\x58\x4d\x4c\50\x29") > 0) {
goto wn;
}
return false;
goto zP;
wn:
return;
zP:
}
function mo_saml_plugin_action_links($u2)
{
$u2 = array_merge(array("\x3c\x61\40\x68\162\145\146\x3d\42" . esc_url(admin_url("\141\144\155\151\156\x2e\160\150\160\x3f\x70\141\x67\x65\x3d\x6d\x6f\137\163\141\155\x6c\x5f\163\x65\x74\164\x69\x6e\147\x73")) . "\42\76" . __("\123\x65\164\x74\151\156\147\163", "\x74\145\x78\x74\144\157\x6d\141\x69\x6e") . "\x3c\x2f\x61\76"), $u2);
return $u2;
}
function checkPasswordPattern($W7)
{
$Fb = "\x2f\136\x5b\x28\x5c\x77\x29\52\x28\134\41\x5c\100\x5c\43\x5c\x24\134\45\x5c\136\x5c\46\x5c\52\134\56\134\55\134\137\x29\52\135\53\44\x2f";
return !preg_match($Fb, $W7);
}
function mo_saml_parse_expiry_date($yG)
{
$pe = new DateTime($yG);
$pN = $pe->getTimestamp();
return date("\x46\x20\152\54\40\x59", $pN);
}
}
new saml_mo_login();
Function Calls
None |
Stats
MD5 | e693451e34e2fa06baeb948b493d907b |
Eval Count | 0 |
Decode Time | 243 ms |