aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/freeradius2/freeradius.inc5
-rw-r--r--config/freeradius2/freeradius_view_config.php7
2 files changed, 9 insertions, 3 deletions
diff --git a/config/freeradius2/freeradius.inc b/config/freeradius2/freeradius.inc
index 00076816..a094853a 100644
--- a/config/freeradius2/freeradius.inc
+++ b/config/freeradius2/freeradius.inc
@@ -48,7 +48,10 @@ require_once("services.inc");
// Check pfSense version
$pfs_version = substr(trim(file_get_contents("/etc/version")),0,3);
-define('FREERADIUS_BASE', '/usr/pbi/freeradius-' . php_uname("m"));
+if ($pfs_version == "2.1" || $pfs_version == "2.2")
+ define('FREERADIUS_BASE', '/usr/pbi/freeradius-' . php_uname("m"));
+else
+ define('FREERADIUS_BASE', '/usr/local');
$bash_path = FREERADIUS_BASE . "/bin/bash";
if ($pfs_version == "2.1") {
diff --git a/config/freeradius2/freeradius_view_config.php b/config/freeradius2/freeradius_view_config.php
index b2959783..0095b009 100644
--- a/config/freeradius2/freeradius_view_config.php
+++ b/config/freeradius2/freeradius_view_config.php
@@ -33,10 +33,13 @@
require("guiconfig.inc");
// Check to find out on which system the package is running
-if (substr(trim(file_get_contents("/etc/version")),0,3) == "2.1") {
+$pfs_version = substr(trim(file_get_contents("/etc/version")),0,3);
+if ($pfs_version == "2.1") {
define('RADDB', '/usr/pbi/freeradius-' . php_uname("m") . '/etc/raddb');
-} else {
+} else if ($pfs_version == "2.1") {
define('RADDB', '/usr/pbi/freeradius-' . php_uname("m") . '/local/etc/raddb');
+} else {
+ define('RADDB', '/usr/local/etc/raddb');
}
// End of system check