Properties

$instance

$instance : null

Public static variable to hold the single instance of MainWP_Child_IThemes_Security.

Type

null

$is_plugin_installed

$is_plugin_installed : boolean

Type

boolean — Whether or not iThemes Plugin is installed or not. Default: false.

Methods

__construct()

__construct() 

MainWP_Child_IThemes_Security constructor.

Run any time class is called.

sync_others_data()

sync_others_data(array  $information, array  $data = array()) : array

Sync other data from $data[] and merge with $information[]

Parameters

array $information

Returned response array for MainWP BackWPup Extension actions.

array $data

Other data to sync to $information array.

Returns

array —

$information Returned information array with both sets of data.

set_showhide()

set_showhide() : array

Set show or hide UpdraftPlus Plugin from Admin & plugins list.

Returns

array —

$information Return results.

ithemes_init()

ithemes_init() 

Initiate iThemes settings.

admin_init()

admin_init() 

iThemes Security Admin initiation.

all_plugins()

all_plugins(array  $plugins) : array

Remove iThemes Security from plugins page.

Parameters

array $plugins

All plugins array.

Returns

array —

$plugins All plugins array with iThemes Security removed.

remove_menu()

remove_menu() 

Remove iThemes Security plugin from WP Admin menu.

custom_admin_css()

custom_admin_css() 

Custom admin CSS.

activate_network_brute_force()

activate_network_brute_force() : array

Activate network brute force.

Returns

array —

$information Results array.

backup_status()

backup_status() : integer

Backup status.

Returns

integer —

$status 1, 2, 3 or 4 (1) Is not a multisite installation, backupbuddy_api exists & Scheduled backups are >=1 (2) Is not multisite and backupbuddy_api exists (3) Has backup = true & schedualed backup = true (4) Has backup = true.

has_backup()

has_backup() : boolean

Check if backup exists.

Returns

boolean —

TRUE|FALSE

scheduled_backup()

scheduled_backup() : boolean

Check if there is a shedualed backup.

Returns

boolean —

TRUE|FALSE.

whitelist()

whitelist() : array|array<mixed,string>

Whitelist Dashboard IP address.

Returns

array|array<mixed,string> —

Response array.

whitelist_release()

whitelist_release() : string

Whitelist release.

Returns

string —

Return 'Success'.

backup_db()

backup_db() : array

Backup Database.

Returns

array —

$return Return results array.

file_change()

file_change() : array

Run File Change scanner.

Returns

array —

$return results array.

admin_user()

admin_user() : array

Update admin user.

Returns

array —

Return Success or Fail.

build_wpconfig_rules()

build_wpconfig_rules(array  $rules_array, null  $input = null) : array

Build WP_config rules.

Parameters

array $rules_array

Config rules array.

null $input

New directory input.

Returns

array —

Return $rules_array.

change_database_prefix()

change_database_prefix() : array

Change database prefix.

Returns

array —

$return Return response array.

api_key()

api_key() : array

Update API key.

Returns

array —

$return Return response array. Success or nochange.

reset_api_key()

reset_api_key() : array

Reset api key.

Returns

array —

$information Return response array.

malware_scan()

malware_scan() : array

Malware scan.

Returns

array —

$response Return response array.

malware_get_scan_results()

malware_get_scan_results() : array

Get malware scan results.

Returns

array —

$response Return response array.

purge_logs()

purge_logs() : array<mixed,string>

Purge logs.

Returns

array<mixed,string> —

Return response array.

get_lockouts()

get_lockouts(string  $type = 'all', boolean  $current = false) : array

Get lockouts.

Parameters

string $type

Type of lockout: Host, user, username, Default: all.

boolean $current

TRUE if current. Default: FALSE.

Returns

array —

$output Return response array.

release_lockout()

release_lockout() : array<mixed,string>

Release lockout.

Returns

array<mixed,string> —

Return results array.

update_module_status()

update_module_status() : array<mixed,string>

Update module status.

Returns

array<mixed,string> —

Return response array.

get_available_admin_users_and_roles()

get_available_admin_users_and_roles() : array<mixed,array>

Get available admin users and roles.

Returns

array<mixed,array> —

Return response array.phpdoc

validate_directory()

validate_directory(string  $name, string  $folder) : boolean|string

Validate directory.

Parameters

string $name

Input name.

string $folder

Folder.

Returns

boolean|string —

Return TRUE on success or Error message on failure.

activate_api_key()

activate_api_key(array  $settings) : array|boolean

Activate api key.

Parameters

array $settings

Setting array.

Returns

array|boolean —

Return $settings array or FALSE on failure.

wordpress_salts()

wordpress_salts() : array

Update WordPress Salts.

Returns

array —

$return Return results array.

file_permissions()

file_permissions() : array

Update file permissions.

Returns

array —

Return results table html.

change_admin_user()

change_admin_user(string  $username = null, boolean  $id = false) : boolean

Change admin user.

Parameters

string $username

Username to update to. Default: null.

boolean $id

User Id found. Default: false.

Returns

boolean —

Return TRUE on success and FALSE on failure.

get_lockouts_int()

get_lockouts_int(array  $results, string  $type) : array

Initiate get lockouts.

Parameters

array $results

Results from MainWP_Child_IThemes_Security::get_lockouts().

string $type

Type of lockout: Host, user, username, Default: all.

Returns

array —

$output Return response array.

reload_backup_exclude()

reload_backup_exclude() : array

Reload excluded backups table.

Returns

array —

Return response array.

get_excludable_tables()

get_excludable_tables() : array

Get excludable backups table.

Returns

array —

$excludes Return response array.

security_site()

security_site() : array

Get security check results.

Returns

array —

Return response array.