How to Secure Your Server
General Recommendations
Often, standard hosting services have limited options for fine-tuning security, so we recommend hosting your exchange service on a Virtual Private Server (VPS/VDS) and configuring it to reduce the risk of hacking. Typically, hosting providers offer paid services for setting up virtual servers. You can hire external specialists for configuration, but only those you trust.
On the hosting service (billing for managing the service) where your site is hosted, enable SMS authorization for your account. Set up other access restrictions if your hosting provider offers them. For Reg.ru hosting, at a minimum, enable SMS authorization and email notifications for account logins.
Update the Ioncube Loader module to the latest version.
Install and configure the fail2ban module on the server.
Install antivirus software and a port scanner on the server. Set up regular scans of server files and ports.
Configure the firewall. Block ports for FTP, SSH, and various shell clients.
Block standard URLs for server login forms. For example, for Ispmanager, these are:
https://ip_address/manager
,https://ip_address/manager/ispmngr
,https://ip_address/ispmngr
.Change the default port for the server login form. For Ispmanager, the default port is usually 1500. Set it to any available port number.
Block access to phpMyAdmin. You can do this by setting the permissions of the phpMyAdmin folder to 444 on the server.
Block access to webmail clients. For example,
https://ip_address/webmail/
,https://ip_address/roundcube/
, etc. Again, set the permissions of the mail client folder to 444 on the server.For all server users, including root, set a password that is at least 15-25 characters long.
Do not store backups of files and databases on the server, especially in the root directory of the site.
Configuring Services and Options
Disable the use of web shells through the php.ini file (edit the existing directive or add a new one):
disable_functions = exec,system,passthru,shell_exec,proc_open,show_source
Disable file uploads through
allow_url_include
andallow_url_fopen
— this will reduce the risk of remote code execution:allow_url_fopen = Off allow_url_include = Off
Disable certain extensions (if they are not needed). For example:
extension = phar.so ; // if phar is not used
Restrict access to
php.ini
andwp-config.php
through the.htaccess
file:<FilesMatch "^(php\.ini|wp-config\.php)$"> Order deny,allow Deny from all </FilesMatch>
File Permissions Configuration

If a warning about file permission errors appears in the admin panel as an animated red circle, open the section with errors.
If the section displays an error about incorrect file permissions, change the permissions of the specified files to more secure settings (struck-through value — current permissions, after ➔ recommended permissions).
Official instructions from WordPress on configuring file permissions.
When using Ispmanager, go to the "Websites" section, select your website, and click the "Website Files" button.

Select the file with incorrect permissions and click the "Attributes" button.

Set the recommended permissions in the "Access Rights" field and save the changes.

After changing the permissions, the warning will disappear from the admin panel.
Last updated