aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
authorAlexander Wilke <nachtfalkeaw@web.de>2012-02-20 22:28:24 +0100
committerAlexander Wilke <nachtfalkeaw@web.de>2012-02-20 22:28:24 +0100
commit35d5afc10c9da941ba13635336c8310bb3fc8a95 (patch)
treec585e8584bf60d9bf08685495ba2e8f056771e7d /config
parentda2ef840410ff50354b30c1deddda08dd325e34b (diff)
downloadpfsense-packages-35d5afc10c9da941ba13635336c8310bb3fc8a95.tar.gz
pfsense-packages-35d5afc10c9da941ba13635336c8310bb3fc8a95.tar.bz2
pfsense-packages-35d5afc10c9da941ba13635336c8310bb3fc8a95.zip
check simultaneous-use against NAS with other methods (SNMP)
Diffstat (limited to 'config')
-rw-r--r--config/freeradius2/freeradius.inc31
1 files changed, 21 insertions, 10 deletions
diff --git a/config/freeradius2/freeradius.inc b/config/freeradius2/freeradius.inc
index a5f8d15f..dbfee18a 100644
--- a/config/freeradius2/freeradius.inc
+++ b/config/freeradius2/freeradius.inc
@@ -789,6 +789,23 @@ function freeradius_clients_resync() {
$varrequiremessageauthenticator = $item['varrequiremessageauthenticator'];
$varclientnastype = $item['varclientnastype'];
$varclientmaxconnections = $item['varclientmaxconnections'];
+ $varclientlogininput = ($item['varclientlogininput']?$item['varclientlogininput']:'### login = !root ###');
+ $varclientpasswordinput = ($item['varclientpasswordinput']?$item['varclientpasswordinput']:'### password = someadminpass ###');
+
+ if ($item['varclientlogininput'] == '') {
+ $varclientlogin = '### login = !root ###';
+ }
+ else {
+ $varclientlogin = "login = $varclientlogininput";
+ }
+ if ($item['varclientpasswordinput'] == '') {
+ $varclientpassword = '### password = someadminpass ###';
+ }
+ else {
+ $varclientpassword = "password = $varclientpasswordinput";
+ }
+
+
$conf .= <<<EOD
client "$varclientshortname" {
@@ -799,10 +816,8 @@ client "$varclientshortname" {
max_connections = $varclientmaxconnections
shortname = $varclientshortname
nastype = $varclientnastype
- #login = !root
- #password = someadminpas
- #virtual_server = home1
- #coa_server = coa
+ $varclientlogin
+ $varclientpassword
}
EOD;
@@ -3952,12 +3967,8 @@ function freeradius_modulesmotp_resync() {
$conf .= <<<EOD
exec motp {
wait = yes
- program = "/usr/local/bin/bash /usr/local/etc/raddb/scripts/otpverify.sh %{User-Name} %{User-Password} %{reply:MOTP-Init-Secret} %{reply:MOTP-PIN} %{reply:MOTP-Offset}"
- input_pairs = reply
- #output_pairs = config
- }
-
-
+ program = "/usr/local/bin/bash /usr/local/etc/raddb/scripts/otpverify.sh %{request:User-Name} %{request:User-Password} %{reply:MOTP-Init-Secret} %{reply:MOTP-PIN} %{reply:MOTP-Offset}"
+ }
EOD;
$filename = RADDB . '/modules/motp';