|
List Info
Thread: hashcash addition for qmail scanner
|
|
| hashcash addition for qmail scanner |
  United States |
2007-05-30 14:15:53 |
Hello all,
First of all, I would like to extend thanks to Jason Haar
and the
community for such wonderful software.
I have been running qmail scanner for a while, and I had the
idea of using
it to add hashcash headers to outgoing emails. I got most
of the way
through creating the code to do this when I realized
spamassassin (with
some configuration) might already have a means of doing
this. Is this
indeed possible? If it is not, is anyone interested in
this
functionality?
I am just going to throw the additional function I added to
qmail-scanner-queue.pl here at the bottom of the email to
invite comment,
as I don't want to create a patch if I someone is going to
tell me I don't
need to.
This function is activated by adding "hashcash" to
the scanner_array
variable.
sub hashcash {
my $dohashcash = "1";
my $addhashcashheader = "1";
my $hashcashcmd = "/usr/bin/hashcash -m -X ";
if ($dohashcash) {
&debug("Starting HASHCASH creation
function");
#Don't bother if this is going to be quarantined
return if ($quarantine_event);
#grab all addresses that are not bound for this server
my ($hashaddr,$addr,$dom) = "";
# is this a safe way to split? It works so far for my
testcases...
my addrlist = split(/,/, $recips);
foreach $addr ( addrlist) {
foreach $dom ( local_domains_array) {
if (!($addr =~ /$dom$/i)) {
$hashaddr .= $addr . " ";
}
}
}
# only run hashcash if we have (an) address(es) not
bound for this
server
if ($hashaddr && $addhashcashheader) {
&debug("HASHCASH addresses:
$hashaddr");
my $hashheaders = `$hashcashcmd $hashaddr`;
&debug("HASHCASH headers:
$hashheaders");
}
# insert hash headers into email...
}
}
------------------------------------------------------------
-------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and
take
control of your XML. No limits. Just data. Click to get it
now.
http://sourcefor
ge.net/powerbar/db2/
_______________________________________________
Qmail-scanner-general mailing list
Qmail-scanner-general lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/q
mail-scanner-general
|
|
| Re: hashcash addition for qmail scanner |
  United States |
2007-05-30 14:39:29 |
Tomas Charvat said:
> JHolder wrote:
>> Hello all,
>>
>> First of all, I would like to extend thanks to
Jason Haar and the
>> community for such wonderful software.
>>
>> I have been running qmail scanner for a while, and
I had the idea of
>> using
>> it to add hashcash headers to outgoing emails. I
got most of the way
>> through creating the code to do this when I
realized spamassassin (with
>> some configuration) might already have a means of
doing this. Is this
>> indeed possible? If it is not, is anyone
interested in this
>> functionality?
><SNIP>
>
> I think that DK and DKIM would be more usefull in QSst
> Both sign and verify mechanism.
That is a good point. I must admit I have not looked into
that yet. My
thinking in adding hashcash is that spamassassin uses it by
default in
recent versions, and it didn't seem like it would be more
than 5 or 10
minutes of work to add it into the qmail-scanner script.
Rather than asking stupid questions about the status of
domain keys here,
I will go and do some research on it. Possibly it would be
an easy add as
well.
John
------------------------------------------------------------
-------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and
take
control of your XML. No limits. Just data. Click to get it
now.
http://sourcefor
ge.net/powerbar/db2/
_______________________________________________
Qmail-scanner-general mailing list
Qmail-scanner-general lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/q
mail-scanner-general
|
|
| Re: hashcash addition for qmail scanner |
  Czech Republic |
2007-05-30 14:32:02 |
I think that DK and DKIM would be more usefull in QSst
Both sign and verify mechanism.
bstrgds
Tomas
JHolder wrote:
> Hello all,
>
> First of all, I would like to extend thanks to Jason
Haar and the
> community for such wonderful software.
>
> I have been running qmail scanner for a while, and I
had the idea of using
> it to add hashcash headers to outgoing emails. I got
most of the way
> through creating the code to do this when I realized
spamassassin (with
> some configuration) might already have a means of doing
this. Is this
> indeed possible? If it is not, is anyone interested in
this
> functionality?
>
> I am just going to throw the additional function I
added to
> qmail-scanner-queue.pl here at the bottom of the email
to invite comment,
> as I don't want to create a patch if I someone is going
to tell me I don't
> need to.
>
> This function is activated by adding
"hashcash" to the scanner_array
> variable.
>
> sub hashcash {
> my $dohashcash = "1";
> my $addhashcashheader = "1";
> my $hashcashcmd = "/usr/bin/hashcash -m -X
";
>
> if ($dohashcash) {
> &debug("Starting HASHCASH creation
function");
>
> #Don't bother if this is going to be quarantined
> return if ($quarantine_event);
>
> #grab all addresses that are not bound for this
server
> my ($hashaddr,$addr,$dom) = "";
> # is this a safe way to split? It works so far
for my testcases...
> my addrlist = split(/,/, $recips);
> foreach $addr ( addrlist) {
> foreach $dom ( local_domains_array) {
> if (!($addr =~ /$dom$/i)) {
> $hashaddr .= $addr . " ";
> }
> }
> }
>
> # only run hashcash if we have (an) address(es)
not bound for this
> server
> if ($hashaddr && $addhashcashheader) {
> &debug("HASHCASH addresses:
$hashaddr");
> my $hashheaders = `$hashcashcmd $hashaddr`;
> &debug("HASHCASH headers:
$hashheaders");
> }
>
> # insert hash headers into email...
> }
> }
>
>
>
>
------------------------------------------------------------
-------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2
express and take
> control of your XML. No limits. Just data. Click to get
it now.
> http://sourcefor
ge.net/powerbar/db2/
> _______________________________________________
> Qmail-scanner-general mailing list
> Qmail-scanner-general lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/q
mail-scanner-general
>
------------------------------------------------------------
-------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and
take
control of your XML. No limits. Just data. Click to get it
now.
http://sourcefor
ge.net/powerbar/db2/
_______________________________________________
Qmail-scanner-general mailing list
Qmail-scanner-general lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/q
mail-scanner-general
|
|
| Re: hashcash addition for qmail scanner |
  United States |
2007-05-30 17:27:11 |
JHolder said:
<SNIP>
> I have been running qmail scanner for a while, and I
had the idea of using
> it to add hashcash headers to outgoing emails. I got
most of the way
> through creating the code to do this when I realized
spamassassin (with
> some configuration) might already have a means of doing
this. Is this
> indeed possible? If it is not, is anyone interested in
this
> functionality?
<SNIP>
I got back to look at this again this afternoon, and decided
to edit the
qmail_reque function instead. I have a couple of questions
if anyone is
willing to entertain me with answers.
First, is the method I used to split up addresses safe?
Second, is the place where I print out the hashcash headers
ok?
Please find attached patch which applies cleanly to
qmail-scanner-2.01:
------------------------------------------------------------
-------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and
take
control of your XML. No limits. Just data. Click to get it
now.
http://sourcefor
ge.net/powerbar/db2/
_______________________________________________
Qmail-scanner-general mailing list
Qmail-scanner-general lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/q
mail-scanner-general
|
|
|
[1-4]
|
|
|
about | contact Other archives ( Real Estate discussion Medical topics )
|