diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2009-06-27 14:00:58 -0400 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2009-06-27 14:00:58 -0400 |
commit | 69769bcc26d2ba55970e26e16717a741b1e8fd3e (patch) | |
tree | ffd08c5bab67be26eb60d40c296e5f09d9be5f2c /usr/local | |
parent | e9f72992104d94ee736ed9bdcfb24b611789a401 (diff) | |
download | pfsense-69769bcc26d2ba55970e26e16717a741b1e8fd3e.zip pfsense-69769bcc26d2ba55970e26e16717a741b1e8fd3e.tar.gz |
Check $_FILES['ulfile']['name'] and not ['tmpname'] since it will not tell us
the original uploaded file name. Duhhhhhh.
Diffstat (limited to 'usr/local')
-rwxr-xr-x | usr/local/www/system_firmware.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr/local/www/system_firmware.php b/usr/local/www/system_firmware.php index 151ce28..45dd6fc 100755 --- a/usr/local/www/system_firmware.php +++ b/usr/local/www/system_firmware.php @@ -137,9 +137,9 @@ if ($_POST && !file_exists($d_firmwarelock_path)) { /* fire up the update script in the background */ touch($d_firmwarelock_path); $savemsg = "The firmware is now being updated. The firewall will reboot automatically."; - if(stristr($_FILES['ulfile']['tmp_name'],"nanobsd")) + if(stristr($_FILES['ulfile']['name'],"nanobsd")) mwexec_bg("/etc/rc.firmware pfSenseNanoBSDupgrade {$g['upload_path']}/firmware.tgz"); - else if(stristr($_FILES['ulfile']['tmp_name'],"bdiff")) + else if(stristr($_FILES['ulfile']['name'],"bdiff")) mwexec_bg("/etc/rc.firmware delta_update {$g['upload_path']}/firmware.tgz"); else mwexec_bg("/etc/rc.firmware pfSenseupgrade {$g['upload_path']}/firmware.tgz"); |