9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Skip Tavakkolian <9nut@9netics.com>
To: 9fans@9fans.net
Subject: Re: [9fans] smtpd integration with spamhaus
Date: Fri, 24 Sep 2010 14:27:34 -0700	[thread overview]
Message-ID: <16cb46287d02e72db4f9dc496c6ac6e0@9netics.com> (raw)

oops!  wasn't finished yet.  i guess i'm getting the hang of "publish
early and often"

it should be easy, as my unfinished shell is showing.  i'm not sure if
i understand the behavior of spammers function when the output is
piped to another program.  any ideas?

> has anyone noodled the idea? spamhaus provides a dns server that
> that can identify if an ip address is a known spammer[1]. i was thinking
> either directly in /sys/src/cmd/upas/smtp/spam.c or through a cs like
> program (parsing binary in shell?)
>
>
> cpue% whatis spammers
> fn spammers {@ {for(i in `{callers}){echo `{revip $i}^.zen.spamhaus.org ip}}|>[2]/dev/null aux/rdwr /net.alt/dns}
> cpue% whatis callers
> fn callers {netstat -n /net.alt|awk '$5 == "25" && $NF ~ /.*\..*\..*\./  {print $NF}'}
> cpue% whatis revip
> fn revip {@ {ifs=(.^'
>        ');i=`{echo $1};echo $i(4)^.^$i(3)^.^$i(2)^.^$i(1)}}
> cpue% spammers | grep 127
> cpue% spammers | sed 10q
> >
> cpue% spammers
> >
> >
> > 5.174.83.189.zen.spamhaus.org ip      127.0.0.11




             reply	other threads:[~2010-09-24 21:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-24 21:27 Skip Tavakkolian [this message]
2010-09-24 22:00 ` erik quanstrom
  -- strict thread matches above, loose matches on Subject: below --
2010-09-24 21:16 Skip Tavakkolian
2010-09-24 21:23 ` erik quanstrom

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=16cb46287d02e72db4f9dc496c6ac6e0@9netics.com \
    --to=9nut@9netics.com \
    --cc=9fans@9fans.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).