Skip to content

Commit e14a827

Browse files
author
Till Brehm
committed
- Search in relative path for security settings if they were not found in the default location.
1 parent 8a3cd23 commit e14a827

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

interface/lib/classes/getconf.inc.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@ public function get_security_config($section = '') {
5959
global $app;
6060

6161
$app->uses('ini_parser');
62-
$security_config = $app->ini_parser->parse_ini_string(file_get_contents('/usr/local/ispconfig/security/security_settings.ini'));
62+
$security_config_path = '/usr/local/ispconfig/security/security_settings.ini';
63+
if(!is_file($security_config_path)) $security_config_path = realpath(ISPC_ROOT_PATH.'/../security/security_settings.ini');
64+
$security_config = $app->ini_parser->parse_ini_string(file_get_contents($security_config_path));
6365

6466
return ($section == '') ? $security_config : $security_config[$section];
6567
}

0 commit comments

Comments
 (0)