Skip to content

Instantly share code, notes, and snippets.

@PWBENNETT
Created November 20, 2014 11:30
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save PWBENNETT/18970413677c5df79c6a to your computer and use it in GitHub Desktop.
Save PWBENNETT/18970413677c5df79c6a to your computer and use it in GitHub Desktop.
Synopsis for Net::Abuse::Reporter
#!/usr/bin/env perl
use 5.020;
use utf8;
use Net::Abuse::Reporter;
use My::Abuse::Log::Getter qw( get_log );
my $reporter = Net::Abuse::Reporter->new();
while (my $log = get_log()) {
$reporter->add_incident($log);
}
$reporter->send_reports();
@PWBENNETT
Copy link
Author

This is the Grand Master Plan for Net::Abuse::Reporter, assuming My::Abuse::Log::Getter is something the API user has defined to extract the plaintext logs for one "abuse incident" from wherever they keep their abuse logs.

Net::Abuse::Reporter will use things like Net::Abuse::Utils, XML::Generator, Mail::Box, Marpa::R2, and a bundle of internal modules such as Net::Abuse::Reporter::Reader::CLF, Net::Abuse::Reporter::Reader::IPTables, Net::Abuse::Reporter::Writer::MARF, Net::Abuse::Reporter::Writer::IODEF, which will be pluggable and extensible.

Sending abuse reports should not be hard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment