Revision: 8039
http://sourceforge.net/p/ipcop/svn/8039
Author: owes
Date: 2016-01-04 09:06:48 +0000 (Mon, 04 Jan 2016)
Log Message:
-----------
Fix upload of certificate for IPsec tunnel.
Modified Paths:
--------------
ipcop/trunk/html/cgi-bin/ipsec.cgi
ipcop/trunk/updates/2.2.0/ROOTFILES.i486-2.2.0
Modified: ipcop/trunk/html/cgi-bin/ipsec.cgi
===================================================================
--- ipcop/trunk/html/cgi-bin/ipsec.cgi 2016-01-04 08:08:07 UTC (rev 8038)
+++ ipcop/trunk/html/cgi-bin/ipsec.cgi 2016-01-04 09:06:48 UTC (rev 8039)
@@ -16,7 +16,7 @@
# along with IPCop. If not, see <http://www.gnu.org/licenses/>.
#
# Copyright (C) 2003-05-25 Mark Wormgoor <[email protected]>
-# (c) 2003-2014 The IPCop Team
+# (c) 2003-2016 The IPCop Team
#
# $Id$
#
@@ -26,8 +26,9 @@
use Net::DNS;
use File::Copy;
-use File::Temp qw/ tempfile tempdir /;
+use File::Temp qw(tempfile tempdir);
use POSIX();
+use Scalar::Util qw(blessed reftype);
use strict;
# enable only the following on debugging purpose
@@ -549,7 +550,7 @@
$errormessage .= "$Lang::tr{'cant change certificates'}<br />";
goto VPNCONF_ERROR;
}
- if (ref ($cgiparams{'FH'}) ne 'Fh') {
+ if (blessed($cgiparams{'FH'}) ne 'CGI::File::Temp') {
$errormessage .= "$Lang::tr{'there was no file upload'}<br />";
$error_auth = 'error';
goto VPNCONF_ERROR;
@@ -590,7 +591,7 @@
elsif ($cgiparams{'AUTH'} eq 'pkcs12') {
&General::log("ipsec", "Importing from p12...");
- if (ref ($cgiparams{'FH'}) ne 'Fh') {
+ if (blessed($cgiparams{'FH'}) ne 'CGI::File::Temp') {
$errormessage .= "$Lang::tr{'there was no file upload'}<br />";
$error_auth = 'error';
goto ROOTCERT_ERROR;
@@ -696,7 +697,7 @@
$error_auth = 'error';
goto VPNCONF_ERROR;
}
- if (ref ($cgiparams{'FH'}) ne 'Fh') {
+ if (blessed($cgiparams{'FH'}) ne 'CGI::File::Temp') {
$errormessage .= "$Lang::tr{'there was no file upload'}<br />";
$error_auth = 'error';
goto VPNCONF_ERROR;
Modified: ipcop/trunk/updates/2.2.0/ROOTFILES.i486-2.2.0
===================================================================
--- ipcop/trunk/updates/2.2.0/ROOTFILES.i486-2.2.0 2016-01-04 08:08:07 UTC
(rev 8038)
+++ ipcop/trunk/updates/2.2.0/ROOTFILES.i486-2.2.0 2016-01-04 09:06:48 UTC
(rev 8039)
@@ -2,6 +2,7 @@
##
/etc/rc.d/rc.red
/etc/rc.d/rc.sysinit
+/home/httpd/cgi-bin/ipsec.cgi
/home/httpd/cgi-bin/logfirewall.cgi
/home/httpd/cgi-bin/logproxy.cgi
/home/httpd/cgi-bin/logsummary.cgi
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
_______________________________________________
Ipcop-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ipcop-svn