403Webshell
Server IP : 46.105.57.169  /  Your IP : 216.73.216.67
Web Server : Apache
System : Linux webm002.cluster120.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64
User : verseaumee ( 152031)
PHP Version : 8.5.7
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/verseaumee/blueversion/wp-content/plugins/really-simple-ssl/tests/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/verseaumee/blueversion/wp-content/plugins/really-simple-ssl/tests/test-rename-admin-user.php
<?php

class RSSSLTestRenameAdminUser extends WP_UnitTestCase {

    /**
     * Set up the test environment.
     *
     * @return void
     */
    protected function setUp(): void {
        parent::setUp();
        require_once __DIR__ . '/../security/wordpress/rename-admin-user.php';
    }

    /**
     * Test if the rsssl_admin_username_changed function adds the expected
     * notice structure to the original notices array.
     *
     * @return void
     */
    public function test_rsssl_admin_username_changed() {
        $original_notices = array();

        $new_notices = rsssl_admin_username_changed($original_notices);
        $this->assertArrayHasKey('username_admin_changed', $new_notices);

        $username_admin_changed_notice = $new_notices['username_admin_changed'];
        $this->assertArrayHasKey('condition', $username_admin_changed_notice);
        $this->assertArrayHasKey('callback', $username_admin_changed_notice);
        $this->assertArrayHasKey('score', $username_admin_changed_notice);
        $this->assertArrayHasKey('output', $username_admin_changed_notice);
    }

    /**
     * Test if the rsssl_prevent_admin_user_add function adds the expected
     * user logins to the original illegal_user_logins array.
     *
     * @return void
     */
    public function test_rsssl_prevent_admin_user_add() {
        $original_illegal_user_logins = array('testuser');
        $new_illegal_user_logins = rsssl_prevent_admin_user_add($original_illegal_user_logins);

        $this->assertContains('admin', $new_illegal_user_logins);
        $this->assertContains('administrator', $new_illegal_user_logins);
        $this->assertEquals($original_illegal_user_logins, array('testuser'));
    }
}

Youez - 2016 - github.com/yon3zu
LinuXploit