3 – open_basedir Protection

You are here:
< Back

In simple words, open_basedir protection forbids your PHP scripts to access file system beyond the specified path i.e.

 

open_basedir "/home/domain.com/"

If this path is specified for open_basdir, your PHP code cannot access file system beyond /home/domain.com/

Which basically helps in case a single site on the server is hacked.


How to enable open_basedir Protection

For open_basedir you need CyberPanel version 1.6.4 stable and OpenLiteSpeed version 1.4.32 stable.

While creating a site you can opt to enable open_basedir protection, if not opted this is disabled by default.

 


Enable/Disable open_basedir Protection

In case you forgot to enable open_basedir protection while creating a site you can do so later as well.

Open website launcher:

 

 

Once launcher is opened, scroll down to find open_basedir under Files.

 

 

From a drop-down, you can either select Enable or Disable and apply changes. Similarly, you can also control open_basedir for Child Domains through child domain launcher.

Author's page
Cyber Panel