summaryrefslogtreecommitdiff
path: root/includes
diff options
context:
space:
mode:
authorINOPIAE <inopiae@cacert.org>2013-07-09 23:44:17 +0200
committerINOPIAE <inopiae@cacert.org>2013-07-09 23:44:17 +0200
commit2e6489775c62b7a0ef4e4bcbb0effc6c12c305a3 (patch)
tree2b508f9618be65116fb81536c03dd8b350f4fb29 /includes
parent22c48c06e0a6e83de1d85c3490bec60eeda55737 (diff)
downloadcacert-devel-2e6489775c62b7a0ef4e4bcbb0effc6c12c305a3.tar.gz
cacert-devel-2e6489775c62b7a0ef4e4bcbb0effc6c12c305a3.tar.xz
cacert-devel-2e6489775c62b7a0ef4e4bcbb0effc6c12c305a3.zip
bug 1136: updated routine so all certificates are revoked.
Diffstat (limited to 'includes')
-rw-r--r--includes/temp_functions.php9
1 files changed, 3 insertions, 6 deletions
diff --git a/includes/temp_functions.php b/includes/temp_functions.php
index 32041b5..c9eb020 100644
--- a/includes/temp_functions.php
+++ b/includes/temp_functions.php
@@ -204,9 +204,8 @@ function revoke_all_client_cert($mailid){
$mailid = intval($mailid);
$query = "select `emailcerts`.`id`
from `emaillink`,`emailcerts` where
- `emailid`='$mailid' and `emaillink`.`emailcertsid`=`emailcerts`.`id` and
- `revoked`=0 and UNIX_TIMESTAMP(`expire`)-UNIX_TIMESTAMP() > 0
- group by `emailcerts`.`id`";
+ `emailid`='$mailid' and `emaillink`.`emailcertsid`=`emailcerts`.`id` and `revoked`=0
+ group by `emailcerts`.`id`";
$dres = mysql_query($query);
while($drow = mysql_fetch_assoc($dres)){
mysql_query("update `emailcerts` set `revoked`='1970-01-01 10:00:01', `disablelogin`=1 where `id`='".$drow['id']."'");
@@ -229,9 +228,7 @@ function revoke_all_server_cert($domainid){
"update `domaincerts`
set `revoked`='1970-01-01 10:00:01'
where `id` = '".$drow['id']."'
- and `revoked` = 0
- and UNIX_TIMESTAMP(`expire`) -
- UNIX_TIMESTAMP() > 0");
+ and `revoked` = 0");
}
}