View Revisions: Issue #954

Summary 0000954: script to bulk revoke weak keys
Revision 2011-06-28 14:33 by Uli60
Additional Information /pages/account/5.php lists current/valid certs
form submit revoke ->
$query = "select UNIX_TIMESTAMP(`emailcerts`.`created`) as `created`,
UNIX_TIMESTAMP(`emailcerts`.`expire`) - UNIX_TIMESTAMP() as `timeleft`,
UNIX_TIMESTAMP(`emailcerts`.`expire`) as `expired`,
`emailcerts`.`expire` as `expires`, `emailcerts`.`revoked` as `revoke`,
UNIX_TIMESTAMP(`emailcerts`.`revoked`) as `revoked`, `emailcerts`.`id`,
`emailcerts`.`CN`, emailcerts.disablelogin as `disablelogin`
from `emailcerts` where `emailcerts`.`memid`='".$_SESSION['profile']['id']."'";

<? if($verified != _("Pending") && $verified != _("Revoked")) { ?>
    <td class="DataTD"><input type="checkbox" name="revokeid[]" value="<?=$row['id']?>"></td>

<input type="submit" name="revoke" value="<?=_("Revoke/Delete")?>"></td>

<input type="hidden" name="oldid" value="<?=$id?>">
<input type="hidden" name="csrf" value="<?=make_csrf('clicerchange')?>" />

to script account.php

/www/account.php
include /includes/account.php
require_once /includes/loggedin.php

server key revoke see /includes/account.php l. 908 ff.
email cert revoke see /includes/account.php l. 1048 ff. (pending request)
orgemail certs revoke see /includes/account.php l. 1640 ff.


Revision 2011-06-28 14:26 by Uli60
Additional Information /pages/account/5.php lists current/valid certs
form submit revoke ->
$query = "select UNIX_TIMESTAMP(`emailcerts`.`created`) as `created`,
UNIX_TIMESTAMP(`emailcerts`.`expire`) - UNIX_TIMESTAMP() as `timeleft`,
UNIX_TIMESTAMP(`emailcerts`.`expire`) as `expired`,
`emailcerts`.`expire` as `expires`, `emailcerts`.`revoked` as `revoke`,
UNIX_TIMESTAMP(`emailcerts`.`revoked`) as `revoked`, `emailcerts`.`id`,
`emailcerts`.`CN`, emailcerts.disablelogin as `disablelogin`
from `emailcerts` where `emailcerts`.`memid`='".$_SESSION['profile']['id']."'";

<? if($verified != _("Pending") && $verified != _("Revoked")) { ?>
    <td class="DataTD"><input type="checkbox" name="revokeid[]" value="<?=$row['id']?>"></td>

<input type="submit" name="revoke" value="<?=_("Revoke/Delete")?>"></td>

<input type="hidden" name="oldid" value="<?=$id?>">
<input type="hidden" name="csrf" value="<?=make_csrf('clicerchange')?>" />

to script account.php

/www/account.php
include /includes/account.php
require_once /includes/loggedin.php

server key revoke see /includes/account.php l. 908 ff.
email cert revoke see /includes/account.php l. 1048 ff.

Revision 2011-06-28 14:07 by Uli60
Additional Information /pages/account/5.php lists current/valid certs
form submit revoke ->
$query = "select UNIX_TIMESTAMP(`emailcerts`.`created`) as `created`,
UNIX_TIMESTAMP(`emailcerts`.`expire`) - UNIX_TIMESTAMP() as `timeleft`,
UNIX_TIMESTAMP(`emailcerts`.`expire`) as `expired`,
`emailcerts`.`expire` as `expires`, `emailcerts`.`revoked` as `revoke`,
UNIX_TIMESTAMP(`emailcerts`.`revoked`) as `revoked`, `emailcerts`.`id`,
`emailcerts`.`CN`, emailcerts.disablelogin as `disablelogin`
from `emailcerts` where `emailcerts`.`memid`='".$_SESSION['profile']['id']."'";

<? if($verified != _("Pending") && $verified != _("Revoked")) { ?>
    <td class="DataTD"><input type="checkbox" name="revokeid[]" value="<?=$row['id']?>"></td>
    <td class="DataTD"><?=$verified?></td>
    <td class="DataTD"><a href="account.php?id=6&cert=<?=$row['id']?>"><?=(trim($row['CN'])=="" ? _("empty") : $row['CN'])?></a></td>

=> revokeid[] value row['id']
-> account.php?id=6&cert=row['id']

/pages/account/6.php

???
Revision 2011-06-28 12:08 by Uli60
Additional Information