diff options
author | jim-p <jim@pingle.org> | 2009-10-11 19:25:15 -0400 |
---|---|---|
committer | jim-p <jim@pingle.org> | 2009-10-11 19:25:15 -0400 |
commit | 05cab845de13d8dbf482179af4e65780729a5d4a (patch) | |
tree | 12bfb8e106bef14c51b77cb40314265c0c65bb1d /config/freeradius.inc | |
parent | 9cc8c8747ae32097e296317df3c92fc7565da9ab (diff) | |
download | pfsense-packages-05cab845de13d8dbf482179af4e65780729a5d4a.tar.gz pfsense-packages-05cab845de13d8dbf482179af4e65780729a5d4a.tar.bz2 pfsense-packages-05cab845de13d8dbf482179af4e65780729a5d4a.zip |
Add some rw/ro calls to FreeRADIUS. May fix issues on nano
Diffstat (limited to 'config/freeradius.inc')
-rw-r--r-- | config/freeradius.inc | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/config/freeradius.inc b/config/freeradius.inc index 53a1d695..6e81f0a0 100644 --- a/config/freeradius.inc +++ b/config/freeradius.inc @@ -11,7 +11,7 @@ function freeradius_deinstall_command() { function freeradius_install_command() { global $config; - + conf_mount_rw(); $handle = opendir(RADDB); while (false != ($file = readdir($handle))) { if (false != ($pos = strpos($file, '.sample'))) { @@ -28,7 +28,9 @@ function freeradius_install_command() { $rcfile['file'] = 'radiusd.sh'; $rcfile['start'] = 'radiusd -s &'; $rcfile['stop'] = 'killall radiusd'; + conf_mount_rw(); write_rcfile($rcfile); + conf_mount_ro(); start_service("freeradius"); } @@ -430,7 +432,9 @@ post-proxy { } EOD; + conf_mount_rw(); file_put_contents(RADDB . '/radiusd.conf', $conf); + conf_mount_ro(); restart_service("freeradius"); } @@ -486,8 +490,10 @@ EOD; } } $filename = RADDB . '/users'; + conf_mount_rw(); file_put_contents($filename, $conf); chmod($filename, 0600); + conf_mount_ro(); restart_service('freeradius'); } @@ -521,7 +527,9 @@ client 127.0.0.1 { EOD; } + conf_mount_rw(); file_put_contents(RADDB . '/clients.conf', $conf); + conf_mount_ro(); restart_service("freeradius"); } ?> |