cvs: php-master-web /manage challenge-response.php users.php

From: Date: Fri, 20 Aug 2004 19:51:49 +0000
Subject: cvs: php-master-web /manage challenge-response.php users.php
Groups: php.mirrors 
Request: Send a blank email to php-mirrors+get-25897@lists.php.net to get a copy of this message
wez Fri Aug 20 15:51:49 2004 EDT Added files: /php-master-web/manage challenge-response.php Modified files: /php-master-web/manage users.php Log: Add a bit more explanation about anti-spam measures. Add a page to allow a user to review (and optionall punch an address through) the C/R. http://cvs.php.net/diff.php/php-master-web/manage/users.php?r1=1.37&r2=1.38&ty=u Index: php-master-web/manage/users.php diff -u php-master-web/manage/users.php:1.37 php-master-web/manage/users.php:1.38 --- php-master-web/manage/users.php:1.37 Fri Aug 6 05:29:19 2004 +++ php-master-web/manage/users.php Fri Aug 20 15:51:48 2004 @@ -203,9 +203,17 @@ </tr> <?php }?> <tr> - <th align="right">Use spam protection?</th> - <td><input type="checkbox" name="in[spamprotect]"<?php echo $row[spamprotect] ? " checked" : "";?> /><br/> - Spam Assassin threshold: <input type="text" name="in[use_sa]" value="<?php echo $row[use_sa] ?>" size="4" maxlength="4"/></td> + <th align="right">Use Challenge/Response spam protection?</th> + <td><input type="checkbox" name="in[spamprotect]"<?php echo $row[spamprotect] ? " checked" : "";?> /> + <?php if ($username == $user) { ?> + <br/> + <a href="challenge-response.php">Show people on my quarantine list</a> + <?php } ?> + </td> +</tr> +<tr> + <th align="right">SpamAssassin threshold</th> + <td>Block mail scoring <input type="text" name="in[use_sa]" value="<?php echo $row[use_sa] ?>" size="4" maxlength="4"/> or higher in SpamAssassin tests. Set to 0 to disable.</td> </tr> <tr> <th align="right">Verified?</th> http://cvs.php.net/co.php/php-master-web/manage/challenge-response.php?r=1.1&p=1 Index: php-master-web/manage/challenge-response.php +++ php-master-web/manage/challenge-response.php <?php # $Id: challenge-response.php,v 1.1 2004/08/20 19:51:48 wez Exp $ /* Show the list of people caught up in the CR system * for the current user. */ require_once 'login.inc'; require_once 'functions.inc'; require_once 'email-validation.inc'; head("challenge response anti-spam thingamy"); @mysql_connect("localhost","nobody","") or die("unable to connect to database"); @mysql_select_db("phpmasterdb"); if (isset($_POST['confirm_them']) && is_array($_POST['confirm'])) { foreach ($_POST['confirm'] as $address) { $addr = mysql_escape_string($address); db_query("insert into accounts.confirmed (email, ts) values ('$addr', NOW())"); } } $res = db_query("select distinct sender from phpmasterdb.users left join accounts.quarantine on users.email = rcpt where username='$user' order by sender"); ?> <h1>Addresses in quarantine for <?= $user ?>@php.net</h1> <form method="post"> <table> <tr> <td>&nbsp;</td> <td>Sender</td> </tr> <?php while ($row = mysql_fetch_array($res)) { ?> <tr> <td><input type="checkbox" name="confirm[]" value="<?= htmlentities($row[0]) ?>"/></td> <td><?= htmlentities($row[0]) ?></td> </tr> <?php } ?> </table> <p> If you see an address listed here that you are 100% sure is a legitimate sender, you may tick the appropriate box and confirm them. </p> <input type="submit" name="confirm_them" value="Confirm Ticked Senders"/> </form> <?php foot(); ?>

« previous php.mirrors (#25897) next »