diff options
author | bmeeks8 <bmeeks8@bellsouth.net> | 2014-01-28 14:53:47 -0500 |
---|---|---|
committer | bmeeks8 <bmeeks8@bellsouth.net> | 2014-01-28 14:53:47 -0500 |
commit | 08a5e3a9d9ec1604302ee49fd1c6666897f2290b (patch) | |
tree | d87e359ce94b37789bbedeff7c6df04f74d44ba0 /config/snort | |
parent | e1e2edc25cdecd36af6f2bb2d1e75b7857cafaed (diff) | |
parent | 6857ff8505977e8898b93c28c394d73ffb167087 (diff) | |
download | pfsense-packages-08a5e3a9d9ec1604302ee49fd1c6666897f2290b.tar.gz pfsense-packages-08a5e3a9d9ec1604302ee49fd1c6666897f2290b.tar.bz2 pfsense-packages-08a5e3a9d9ec1604302ee49fd1c6666897f2290b.zip |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'config/snort')
-rw-r--r-- | config/snort/snort_log_view.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/config/snort/snort_log_view.php b/config/snort/snort_log_view.php index 4fc8d990..babae205 100644 --- a/config/snort/snort_log_view.php +++ b/config/snort/snort_log_view.php @@ -42,7 +42,10 @@ $contents = ''; // Read the contents of the argument passed to us. // Is it a fully qualified path and file? if (file_exists($_GET['logfile'])) - $contents = file_get_contents($_GET['logfile']); + if (substr(realpath($_GET['logfile']), 0, strlen(SNORTLOGDIR)) != SNORTLOGDIR) + $contents = gettext("\n\nERROR -- File: {$_GET['logfile']} can not be viewed!"); + else + $contents = file_get_contents($_GET['logfile']); // It is not something we can display, so print an error. else $contents = gettext("\n\nERROR -- File: {$_GET['logfile']} not found!"); |