diff --git a/Makefile b/Makefile index c0f659e5b..51f84ffa4 100644 --- a/Makefile +++ b/Makefile @@ -93,7 +93,6 @@ CORE_DEPENDS?= apinger \ openvpn \ opnsense-lang \ opnsense-update \ - p7zip \ pam_opnsense \ pecl-radius \ pftop \ @@ -133,7 +132,8 @@ CORE_DEPENDS?= apinger \ suricata \ syslogd \ unbound \ - wol + wol \ + zip WRKDIR?=${.CURDIR}/work WRKSRC?=${WRKDIR}/src diff --git a/src/www/vpn_openvpn_export.php b/src/www/vpn_openvpn_export.php index 69b3d1a4d..47b5102f2 100644 --- a/src/www/vpn_openvpn_export.php +++ b/src/www/vpn_openvpn_export.php @@ -370,7 +370,7 @@ function openvpn_client_export_config($srvid, $usrid, $crtid, $useaddr, $verifys } } $command = "cd " . escapeshellarg("{$tempdir}/..") - . " && /usr/local/bin/7z -tzip -y a " + . " && /usr/local/bin/zip -r " . escapeshellarg("/tmp/{$prefix}-config.zip") . " " . escapeshellarg($prefix); exec($command); @@ -563,7 +563,7 @@ EOF; exec("cd {$tempdir}/.. && /usr/bin/tar cfz {$outputfile} Viscosity.visc"); } else { $outputfile = "/tmp/{$uniq}-Viscosity.visc.zip"; - exec("cd {$tempdir}/.. && /usr/local/bin/7z -tzip -y a {$outputfile} Viscosity.visc"); + exec("cd {$tempdir}/.. && /usr/local/bin/zip -r {$outputfile} Viscosity.visc"); } // Remove temporary directory @@ -688,7 +688,7 @@ function openvpn_client_export_sharedkey_config($srvid, $useaddr, $proxy, $zipco file_put_contents("{$tempdir}/{$prefix}.ovpn", $conf); $shkeyfile = "{$tempdir}/{$shkeyfile}"; file_put_contents("{$shkeyfile}", base64_decode($settings['shared_key'])); - exec("cd {$tempdir}/.. && /usr/local/bin/7z -tzip -y a /tmp/{$prefix}-config.zip {$prefix}"); + exec("cd {$tempdir}/.. && /usr/local/bin/zip -r /tmp/{$prefix}-config.zip {$prefix}"); // Remove temporary directory exec("rm -rf {$tempdir}"); return "/tmp/{$prefix}-config.zip";