bug fixes

pull/1/head
root 20 years ago
parent 63dae913aa
commit a11096a53d

@ -13,7 +13,7 @@
PARTICULAR PURPOSE. See the License for more details.
*/
if($_SERVER[HTTP_HOST] == "secure.cacert.org")
if($_SERVER['HTTP_HOST'] == "secure.cacert.org")
{
$query = "select * from `emailcerts` where `serial`='$_SERVER[SSL_CLIENT_M_SERIAL]' and `revoked`=0 and
UNIX_TIMESTAMP(`expire`) - UNIX_TIMESTAMP() > 0";
@ -38,23 +38,31 @@
}
$_SESSION['_config']['oldlocation'] = "account.php?".$_SESSION['_config']['oldlocation'];
header("location: https://$_SERVER[HTTP_HOST]/index.php?id=4");
header("location: https://".$_SERVER['HTTP_HOST']."/index.php?id=4");
exit;
}
} else if($_SERVER[HTTP_HOST] == "secure.cacert.org" && $_SESSION['profile']['id'] > 0) {
} else if($_SERVER['HTTP_HOST'] == "secure.cacert.org" && $_SESSION['profile']['id'] > 0) {
$_SESSION['profile'] = mysql_fetch_assoc(mysql_query("select * from `users` where `id`='".$_SESSION['profile']['id']."'"));
}
if($_SERVER[HTTP_HOST] == "secure.cacert.org" && ($_SESSION['profile']['id'] <= 0 || $_SESSION['profile']['loggedin'] == 0))
if($_SERVER['HTTP_HOST'] == "secure.cacert.org" && ($_SESSION['profile']['id'] <= 0 || $_SESSION['profile']['loggedin'] == 0))
{
header("location: https://www.cacert.org");
exit;
}
if($_SERVER['HTTP_HOST'] == "secure.cacert.org" && $_SESSION['profile']['id'] > 0)
{
$query = "select sum(`points`) as `total` from `notary` where `to`='".$_SESSION['profile']['id']."' group by `to`";
$res = mysql_query($query);
$row = mysql_fetch_assoc($res);
$_SESSION['profile']['points'] = $row['total'];
}
if($id == "logout")
{
$_SESSION['profile']['loggedin'] = 0;
header("location: https://$_SERVER[HTTP_HOST]/index.php");
header("location: https://".$_SERVER['HTTP_HOST']."/index.php");
exit;
}
@ -71,7 +79,7 @@
}
$_SESSION['_config']['oldlocation'] = "account.php?".$_SESSION['_config']['oldlocation'];
header("location: https://$_SERVER[HTTP_HOST]/index.php?id=4");
header("location: https://".$_SERVER['HTTP_HOST']."/index.php?id=4");
exit;
}

@ -80,6 +80,7 @@
case 'da': $_SESSION['_config']['language'] = "da_DK"; break;
case 'de': $_SESSION['_config']['language'] = "de_DE"; break;
case 'es': $_SESSION['_config']['language'] = "es_ES"; break;
case 'fr': $_SESSION['_config']['language'] = "fr_FR"; break;
case 'nl': $_SESSION['_config']['language'] = "nl_NL"; break;
case 'pt': $_SESSION['_config']['language'] = "pt_PT"; break;
case 'hu': $_SESSION['_config']['language'] = "hu_HU"; break;

@ -74,6 +74,7 @@ google_color_border = "FFFFFF";
<a href="index.php?id=<?=$id?>&lang=de_DE">Deutsch</a>
<a href="index.php?id=<?=$id?>&lang=en_EN">English</a>
<a href="index.php?id=<?=$id?>&lang=es_ES">Español</a>
<a href="index.php?id=<?=$id?>&lang=fr_FR">French</a>
<a href="index.php?id=<?=$id?>&lang=hu_HU">Magyar</a>
<a href="index.php?id=<?=$id?>&lang=nl_NL">Nederlands</a>
<a href="index.php?id=<?=$id?>&lang=pt_PT">Português</a>

@ -1,7 +1,7 @@
<?
if($process == "Confirm, I agree to these terms and conditions" && $iagree == "yes")
{
$output_file = $fname = "libressl-20040925.tar.bz2";
$output_file = $fname = "cacert-20041016.tar.bz2";
header('Pragma: public');
@ -12,8 +12,8 @@
header('Content-Type: application/octetstream; name="' . $output_file . '"'); //This should work for IE & Opera
header('Content-Type: application/octet-stream; name="' . $output_file . '"'); //This should work for the rest
header('Content-Disposition: inline; filename="' . $output_file . '"');
header("Content-length: ".intval(filesize("/home/duane/libressl/$fname")));
readfile("/home/duane/libressl/$fname");
header("Content-length: ".intval(filesize("/home/cacert/tarballs/$fname")));
readfile("/home/cacert/tarballs/$fname");
exit;
}
?>

Loading…
Cancel
Save