Fix various paths (misc remove related)

This commit is contained in:
nemunaire 2015-01-14 11:10:55 +01:00 committed by Nemunaire
commit 428a1def46
3 changed files with 15 additions and 20 deletions

View file

@ -26,13 +26,13 @@ function new_client($name, $misc_dir)
{
//TODO handle if already exist
putenv("PKI_BASEDIR=$misc_dir");
return shell_exec("$misc_dir/../pki/CA.sh -newclient $name");
return shell_exec("$misc_dir/pki/CA.sh -newclient $name");
}
function revoke_client($name, $misc_dir)
{
putenv("PKI_BASEDIR=$misc_dir");
return shell_exec("$misc_dir/../pki/CA.sh -revoke $name");
return shell_exec("$misc_dir/pki/CA.sh -revoke $name");
}
if (!empty($p[2]))
@ -49,7 +49,7 @@ if (!empty($p[2]))
{
putenv("PKI_BASEDIR=$misc_dir");
$template->assign("output",
shell_exec("$misc_dir/../pki/CA.sh -newca"));
shell_exec("$misc_dir/pki/CA.sh -newca"));
return "admin/shell";
}
@ -63,7 +63,7 @@ if (!empty($p[2]))
{
putenv("PKI_BASEDIR=$misc_dir");
$template->assign("output",
shell_exec("$misc_dir/../pki/CA.sh -newserver"));
shell_exec("$misc_dir/pki/CA.sh -newserver"));
return "admin/shell";
}
@ -71,7 +71,7 @@ if (!empty($p[2]))
{
putenv("PKI_BASEDIR=$misc_dir");
$template->assign("output",
shell_exec("$misc_dir/../pki/CA.sh -revokeserver"));
shell_exec("$misc_dir/pki/CA.sh -revokeserver"));
return "admin/shell";
}
@ -108,7 +108,7 @@ if (!empty($p[2]))
$name = $_GET['name'];
if (isset($name))
{
$path = "$misc_dir/pki/pkcs/$name.p12";
$path = "$misc_dir/PKI/pkcs/$name.p12";
if (file_exists($path) && is_readable($path))
{
header("Content-Type: application/force-download");