From: kkalev Date: Wed, 2 Mar 2005 13:20:40 +0000 (+0000) Subject: Log somewhat more verbose error messages when the sql_command binary is not found... X-Git-Url: https://git.entuzijast.net/?a=commitdiff_plain;h=35992b1a219160f72d0948ae11a4a86c94796be5;p=freeradius-dialup-admin.git Log somewhat more verbose error messages when the sql_command binary is not found in the bin scripts --- diff --git a/Changelog b/Changelog index 17397e5..6b0725e 100644 --- a/Changelog +++ b/Changelog @@ -18,6 +18,7 @@ Ver 1.78: * Make all counter limits default to none so that people don't get confused * In clear_opensessions depending on sql type use either IS NULL or = 0 in the DELETE statement. We need to find a cleaner solution to this. This closes bug#175 +* Log somewhat more verbose error messages when the sql_command binary is not found in the bin scripts Ver 1.75: * A LOT of security related fixes. Now dialupadmin should hopefully be secure enough to be accessed by normal users (not administrators). diff --git a/bin/backup_radacct b/bin/backup_radacct index de873fd..b4b20f9 100755 --- a/bin/backup_radacct +++ b/bin/backup_radacct @@ -22,7 +22,7 @@ while(){ close CONF; die "sql_command directive is not set in admin.conf\n" if ($sqlcmd eq ''); -die "Could not find sql binary. Please make sure that the \$sqlcmd variable points to the right location\n" if (! -x $sqlcmd); +die "sql command '$sqlcmd' not found or does not seem to be executable\n" if (! -x $sqlcmd); if ($sql_type eq 'mysql'){ $sql_password = ($sql_password eq '') ? '' : "-p$sql_password"; } diff --git a/bin/clean_radacct b/bin/clean_radacct index e1a6607..168af3f 100755 --- a/bin/clean_radacct +++ b/bin/clean_radacct @@ -26,7 +26,7 @@ while(){ close CONF; die "sql_command directive is not set in admin.conf\n" if ($sqlcmd eq ''); -die "Could not find sql binary. Please make sure that the \$sqlcmd variable points to the right location\n" if (! -x $sqlcmd); +die "sql command '$sqlcmd' not found or does not seem to be executable\n" if (! -x $sqlcmd); if ($sql_type eq 'mysql'){ $sql_password = ($sql_password eq '') ? '' : "-p$sql_password"; diff --git a/bin/log_badlogins b/bin/log_badlogins index 408534e..0e0b55c 100755 --- a/bin/log_badlogins +++ b/bin/log_badlogins @@ -103,7 +103,7 @@ $pass =~ s/(\W)/\\$1/g; die "SQL server not defined\n" if ($sql_server eq ''); die "sql_command directive is not set in admin.conf\n" if ($sqlcmd eq ''); -die "Could not find sql binary. Please make sure that the \$sqlcmd variable points to the right location\n" if (! -x $sqlcmd); +die "sql command '$sqlcmd' not found or does not seem to be executable\n" if (! -x $sqlcmd); $opt = ""; $opt = "-O connect_timeout=$sql_timeout" if ($sql_timeout); diff --git a/bin/monthly_tot_stats b/bin/monthly_tot_stats index a1f25f6..20035f5 100755 --- a/bin/monthly_tot_stats +++ b/bin/monthly_tot_stats @@ -27,7 +27,7 @@ while(){ close CONF; die "sql_command directive is not set in admin.conf\n" if ($sqlcmd eq ''); -die "Could not find sql binary. Please make sure that the \$sqlcmd variable points to the right location\n" if (! -x $sqlcmd); +die "sql command '$sqlcmd' not found or does not seem to be executable\n" if (! -x $sqlcmd); if ($sql_type eq 'mysql'){ $sql_password = ($sql_password eq '') ? '' : "-p$sql_password"; diff --git a/bin/tot_stats b/bin/tot_stats index 0c945ea..ce72fd7 100755 --- a/bin/tot_stats +++ b/bin/tot_stats @@ -26,7 +26,7 @@ while(){ close CONF; die "sql_command directive is not set in admin.conf\n" if ($sqlcmd eq ''); -die "Could not find sql binary. Please make sure that the \$sqlcmd variable points to the right location\n" if (! -x $sqlcmd); +die "sql command '$sqlcmd' not found or does not seem to be executable\n" if (! -x $sqlcmd); if ($sql_type eq 'mysql'){ $sql_password = ($sql_password eq '') ? '' : "-p$sql_password"; diff --git a/bin/truncate_radacct b/bin/truncate_radacct index 3a09262..a6e25b9 100755 --- a/bin/truncate_radacct +++ b/bin/truncate_radacct @@ -26,7 +26,7 @@ while(){ close CONF; die "sql_command directive is not set in admin.conf\n" if ($sqlcmd eq ''); -die "Could not find sql binary. Please make sure that the \$sqlcmd variable points to the right location\n" if (! -x $sqlcmd); +die "sql command '$sqlcmd' not found or does not seem to be executable\n" if (! -x $sqlcmd); if ($sql_type eq 'mysql'){ $sql_password = ($sql_password eq '') ? '' : "-p$sql_password";