summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-07-17 20:16:00 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-07-17 20:16:00 +0000
commit7e6d816a9324e975811a08220413e159a9fbac63 (patch)
tree7bef887eb57707751d4d7373d0fffbb09ff30f64
parentc3290534cb15c2f615699f68834947628cf94c38 (diff)
downloadpfsense-7e6d816a9324e975811a08220413e159a9fbac63.zip
pfsense-7e6d816a9324e975811a08220413e159a9fbac63.tar.gz
Use correct path. DOH!
-rwxr-xr-xetc/sshd6
1 files changed, 2 insertions, 4 deletions
diff --git a/etc/sshd b/etc/sshd
index 16e7a5e..69b3e71 100755
--- a/etc/sshd
+++ b/etc/sshd
@@ -34,8 +34,6 @@
function file_size($file) {
$size = filesize($file);
- if ( $size == 0)
- $size = exec("ls -l $file | awk '{print $5}'");
return $size;
}
@@ -44,8 +42,8 @@
*/
$files_to_check = array('ssh_host_dsa_key','ssh_host_dsa_key.pub','ssh_host_key','ssh_host_key.pub','ssh_host_rsa_key','ssh_host_rsa_key.pub','/root/.authorized_keys');
foreach($files_to_check as $f2c) {
- if(file_exists($f2c))
- if(file_size($f2c)==0) {
+ if(file_exists("/etc/ssh/{$f2c}"))
+ if(file_size("/etc/ssh/{$f2c}")==0) {
mwexec("rm /etc/ssh_host*");
}
}
OpenPOWER on IntegriCloud