Commit Graph

193 Commits

Author SHA1 Message Date
Matt Simerson
8795d4fd6e relay: use IETF IP testing addresses 2012-06-04 03:34:47 -04:00
Matt Simerson
974f1a95e8 new relay plugin, with tests!
replaces functionality of previous 3 relay plugins
2012-06-04 03:34:47 -04:00
Matt Simerson
57a0e4ba7b updated plugins to use QP::Plugins::is_immune 2012-06-04 03:26:16 -04:00
Matt Simerson
2a371a2c6e consolidated chunks of code duplicated 4x into log_and_deny and log_and_pass
in apr_*_handler subs, return DECLINED when connection is not available to read (like during tests)

added 23 tests

deprecate action argument
	'action log' did nothing, better logging controls available with loglevel
	'action deny'  ->  reject 1
	'action denysoft' =>  reject 1 reject_type temp

POD
use head2 for config options (instead of over, item, back)
added loglevel section
updated for replacement of action with reject options
2012-06-04 03:23:14 -04:00
Ask Bjørn Hansen
0e2384cceb Make all plugins use $self->connection rather than $self->qp->connection
Merge remote-tracking branch 'msimerson/connect'

Conflicts:
	plugins/async/require_resolvable_fromhost
	plugins/require_resolvable_fromhost
2012-06-03 23:53:43 -07:00
Matt Simerson
0a16621f02 connection consistency
-  $self->qp->connection->notes
+  $self->connection->notes

and all tests pass.
2012-06-02 00:46:33 -04:00
Matt Simerson
2f49cafcd6 resolvable_fromhost: refactored, added: POD, tests, reject, reject_type 2012-05-23 23:39:43 -04:00
Ask Bjørn Hansen
9e239fd83d Merge pull request #16 from msimerson/geoip
Geoip plugin improvements
2012-05-23 15:39:10 -07:00
Matt Simerson
e07488d4f6 hrmm, why didn't Test::Qpsmtpd::Plugin::log work? 2012-05-22 17:41:40 -04:00
Matt Simerson
2dcd34467e geoip: eval loading of Geo::IP, tests, enabled in config
eval Geo::IP and log an error if missing
added 2 tests
enabled in config/plugins
2012-05-22 17:40:02 -04:00
Matt Simerson
521aa4919f basicheaders, add reject option, loglevel
added reject option
document the existence of the loglevel option
factored date validity tests into their own sub
added tests
improved POD
2012-05-21 21:30:02 -04:00
Matt Simerson
9d0c2f8469 dnsbl, POD tweaks, DENY type tests
consolidated POD at top of file
added example options to reject_type POD head
added an example loglevel entry

consolidated DENY[SOFT|DISCONNECT] logic into get_reject_type
added tests for get_reject_type
2012-05-21 17:07:37 -04:00
Matt Simerson
51486d0b04 SPF plugin: refactored, tests, new config option
added POD description of spfquery note

changed spf_deny -> reject  (and offered 4 more options, see POD for reject)
	backwards compatible with old config settings
	replicates qmail-smtpd SPF patch behavior

improved logging (again)

uses a stringy eval 'use Mail::SPF' in the register sub. If missing, warn and log the error, and don't register any hooks. This is much nicer error than the current, "*** Remote host closed connection unexpectedly." broken mail server that results from enabling the SPF plugin without Mail::SPF installed.

background: I noticed I was deferring valid emails with the SPF plugin at 'spf_deny 1', and without changing the code, there wasn't a way to change how ~all records were handled. This provides that flexibility.
2012-05-21 04:19:45 -04:00
Matt Simerson
e8919beb0d increment test counter declaration 2012-05-20 23:40:39 -07:00
Matt Simerson
96144a6a16 improve portability of basicheader plugin tests
replaced `date` with POSIX qw(strftime);
2012-05-20 23:40:35 -07:00
Matt Simerson
49dc8bc117 basicheaders: added log messages, tests, named args
added log messages at each exit point
added tests
added reject_type option (defer -vs- deny)
added named argument parsing
2012-05-20 23:39:54 -07:00
Matt Simerson
f37fba7c2b badrcptto: merged plugins, refactored, tests
merged badrcptto_pattern into badrcptto
refactored into smaller methods
added unit tests for each method
2012-05-20 23:39:38 -07:00
Matt Simerson
e206763428 test hostname before failing the test.
Test machine might have qmail installed with another hostname configured.
2012-05-20 23:39:24 -07:00
Matt Simerson
be28372dca permit tests for async and ident plugins to work 2012-05-20 23:39:20 -07:00
Matt Simerson
19927a117e spamassassin: added spam status to log messages
added additional values to tests, to suppress test warnings
2012-05-20 23:39:03 -07:00
Matt Simerson
c3d1f6b16e p0f: tests, tests, tests, backward compat
minor changes to facilitate testing
improved error reporting of several failures
added p0f v2 compatibility to p0f v3 results: in addition to all the newer values, also report the old ones too.
2012-05-20 23:38:48 -07:00
Matt Simerson
25a099e20b dspam: added check for autolearn
don't try to use autolearn if it's not set
added tests that exercise and exorcise the bug
2012-05-20 23:38:42 -07:00
Matt Simerson
9b8c5a1be4 rcpt_ok: refactored and added tests 2012-05-20 23:37:37 -07:00
Matt Simerson
ae3fe2e4d5 cleanups for Auth::validate_password commit
one for testing to work again
and one to remove MD5 dependency in Plugin.pm
2012-05-20 23:37:16 -07:00
Matt Simerson
35e1ce9883 consolidate auth logic into Qpsmtpd::Auth
These 3 auth plugins all have a data store they fetch the reference
password or hash from. They then match the attemped password or hash
against the reference. This consolidates the latter portion (validating
the password/hash) into Auth.pm.

* less duplicated code in the plugins.
* Pass validation consistently handled for these 3 plugins.
* less work to create new auth plugins

Also caches the CRAM-MD5 ticket. It could also cache user/pass info if
this was desirable.
2012-05-20 23:37:06 -07:00
Matt Simerson
915b9830dc greylisting: reset transaction for immunity tests 2012-05-20 23:35:59 -07:00
Matt Simerson
6b9881c32e greylisting, refactored and many changes
fixed the vestiges of old plugin name 'denysoft_greylisting'

added ability to bypass greylisting based on geoip

deprecated 'mode [denysoft | testonly | off]
	off wasn't useful
	testonly & denysoft replaced by reject [ 0 | 1 ]

renamed DB from denysoft_greylist to greylist.dbm. Will use existing/legacy DB if present.

added DB pruning feature. Automatically prune the DB when qpsmtpd registers the plugin. Perhaps this should be a config option to enable?

added DB upgrade feature. Convert dotted quad IP addresses in DB to integers. Makes greylisting IPv6 compatible, since DB records are colon delimited.

exempt TLS connections from greylisting. The vast majority (perhaps all) of the SMTP clients that request encryption to my server are legit. We could add a config option for this, but this plugin already has a multitude of config options.

refactored much of the greylisting method into discreet subs

added 30 tests

added additional DEBUG level logging for p0f matches

POD changes:
	replaced over, item N, back, with head2 (better formatted output)
	better describe the current behavior of the plugin (some past behaviors no longer exist)
	added TRIPLET section with example
	added loglevel section
2012-05-20 23:35:46 -07:00
Matt Simerson
5e76d66c66 count_unrecognized_commands
simplified logic in a couple places
consolidated duplicated message
added 4 tests
2012-05-20 23:34:58 -07:00
Matt Simerson
99cf4e69d1 removed useless unused void constant 2012-05-08 22:55:16 -07:00
Matt Simerson
57d72b3cb4 auth_vpopmail_sql, refactor, log, tests
added strict and warnings pragma
refactored
added tests
added more logging
standard log prefixes
tests run pretests to assure tests can succeed
2012-05-07 09:53:03 -07:00
Matt Simerson
adbbfe6f67 auth_vpopmail: refactored, added tests, logging
added more logging
standard log prefixes
tests run a pretest to make sure tests have a chance to succeed
2012-05-07 09:52:46 -07:00
Matt Simerson
54f1a11b46 added logging and tests to auth_checkpassword 2012-05-07 09:47:15 -07:00
Matt Simerson
a1b073cfe2 refactored dnsbl, sprinkling logs and tests on it 2012-05-06 16:21:09 -07:00
Matt Simerson
77ff89d6ca only test POD for developers 2012-05-06 16:18:56 -07:00
Matt Simerson
205120f26f dspam: a batch of improvements:
expanded POD
cleaned up stray EOL spaces
added lots of logging, with standardized [ pass | fail | skip ] prefixes
added reject_type option
use split for parsing dspam headers
use SA note instead of parsing headers
added reject = agree option
store & fetch dspam results in a note
2012-05-06 16:18:38 -07:00
Matt Simerson
d644c24c83 spamassassin updates
refactored into small subs with unit tests.
parse SA header with split instead of regexp (more reliable)
store SA results in a 'spamassassin' transaction note
add strict and warnings pragma
renamed reject_threshold -> reject (backwards compatible)
added relayclient skip option and POD. Skips SA processing when relayclient is set
added MULTIPLE RECIPIENT BEHAVIOR topic to POD
2012-05-06 16:18:22 -07:00
Matt Simerson
5285774285 refactored Qpsmtpd::Auth::SASL
unit tests for new methods are in t/auth.t

added PLAIN and LOGIN tests in auth_flat_file

Most tests are disabled unless an interactive terminal is detected and $ENV{QPSMTPD_DEVELOPER} is set.
2012-05-06 16:17:02 -07:00
Matt Simerson
ccf166a7e9 extend syntax tests to test directory
lets see what Travis thinks of this...
2012-05-06 16:16:26 -07:00
Matt Simerson
eabc5429be instead of skipping test errors, handle them 2012-05-06 16:15:57 -07:00
Matt Simerson
0a49ea07cb more shebang fixes for tests 2012-05-06 16:11:54 -07:00
Matt Simerson
0c7ee4941b added logging and tests to check_badmailfrom
refactored several checks out of hook_mail and added LOGDEBUG

added tests for is_immune method
2012-05-06 16:08:28 -07:00
Matt Simerson
1910fabf0e badmailfromto: added strictures, tests, and
rearranged portionsn of logic for ease of reading
2012-05-06 16:02:43 -07:00
Matt Simerson
9b4a0de70a enable plugin syntax checks for developers 2012-05-06 15:49:34 -07:00
Ask Bjørn Hansen
275d3f18ab Fix tests for check_badmailfrom plugin 2012-04-29 02:46:03 -07:00
Ask Bjørn Hansen
45ebc51c02 Don't syntax check plugins in the automated tests
Too many plugins have dependencies we don't require, so they fail in travis-ci
2012-04-29 01:57:36 -07:00
Ask Bjørn Hansen
a23d4b3da9 Fix 01-syntax test failures
Exclude some tests with dependencies.

Remove -T from perl line in plugins
This makes it harder to test with PERL5LIB/perlbrew etc
2012-04-29 01:36:01 -07:00
Matt Simerson
368ce9401b merged check_badmailfrom_patterns into check_badmailfrom 2012-04-29 00:40:02 -07:00
Matt Simerson
3afcc92150 whitespace, copyright bump, simplify logic 2012-04-29 00:30:06 -07:00
Ask Bjørn Hansen
46701716b2 Make plugin syntax checks run with -T 2012-04-29 00:14:53 -07:00
Matt Simerson
dbaa9dbd6c POD corrections, additional tests, plugin consistency
on files in plugins dir:
  fixed a number of POD errors

  formatted some # comments into POD

  removed bare 1;  (these are plugins, not perl modules)
    most instances of this were copy/pasted from a previous plugin that had it

  removed instances of # vim ts=N ...
    they weren't consistent, many didn't match .perltidyrc

  on modules that failed perl -c tests, added 'use Qpsmtpd::Constants;'

Conflicts:

	plugins/async/check_earlytalker
	plugins/async/dns_whitelist_soft
	plugins/async/dnsbl
	plugins/async/queue/smtp-forward
	plugins/async/require_resolvable_fromhost
	plugins/async/rhsbl
	plugins/async/uribl
	plugins/auth/auth_checkpassword
	plugins/auth/auth_cvm_unix_local
	plugins/auth/auth_flat_file
	plugins/auth/auth_ldap_bind
	plugins/auth/auth_vpopmail
	plugins/auth/auth_vpopmail_sql
	plugins/auth/authdeny
	plugins/check_badmailfromto
	plugins/check_badrcptto_patterns
	plugins/check_bogus_bounce
	plugins/check_earlytalker
	plugins/check_norelay
	plugins/check_spamhelo
	plugins/connection_time
	plugins/dns_whitelist_soft
	plugins/dnsbl
	plugins/domainkeys
	plugins/greylisting
	plugins/hosts_allow
	plugins/http_config
	plugins/logging/adaptive
	plugins/logging/apache
	plugins/logging/connection_id
	plugins/logging/transaction_id
	plugins/logging/warn
	plugins/milter
	plugins/queue/exim-bsmtp
	plugins/queue/maildir
	plugins/queue/postfix-queue
	plugins/queue/smtp-forward
	plugins/quit_fortune
	plugins/random_error
	plugins/rcpt_map
	plugins/rcpt_regexp
	plugins/relay_only
	plugins/require_resolvable_fromhost
	plugins/rhsbl
	plugins/sender_permitted_from
	plugins/spamassassin
	plugins/tls
	plugins/tls_cert
	plugins/uribl
	plugins/virus/aveclient
	plugins/virus/bitdefender
	plugins/virus/clamav
	plugins/virus/clamdscan
	plugins/virus/hbedv
	plugins/virus/kavscanner
	plugins/virus/klez_filter
	plugins/virus/sophie
	plugins/virus/uvscan
2012-04-29 00:00:10 -07:00
Matt Simerson
38c74352d1 prepend auth_flat plugin name to $note
Makes it much easier to figure out where that log entry came from.
2012-04-28 20:19:30 -07:00
Matt Simerson
ed8eca0a63 fixed failing auths to auth/vpopmaild, added tests
Apparently the format of vpopmaild responses has been expanded and the responses
are conditional.

* Replaced the 'sometimes works' eq comparison with a regexp that always works.
* added tests for all 3 vpopmail plugins
* added cram-md5 auth support to auth_vpopmaild.
2012-04-07 17:52:44 -04:00
Matt Simerson
fa91764f88 renamed test from foo to rcpt_ok 2010-07-25 23:04:58 -07:00
Matt Simerson
0c4a76ffe7 add test name to test output 2010-07-25 22:52:36 -07:00
Matt Simerson
d11b87e050 give badrcptto a reasonable name
renamed check_badrcptto test from foo to test_check_badrcptto_ok
2010-07-25 22:52:32 -07:00
Matt Simerson
b81d464c87 added p0f support to greylist plugin
- these changes are in the previous TCPLOCAL patch. Documented here.
added p0f config option
added POD docs to explain usage
modified $dbdir selection logic. The previous logic failed when QPHOME was
 not selected (as is the case when tests are being run).
Added '.' as the dir of last resort for $dbdir selection (others $EMPTY/dir
 dumped greylisting database in / )

  - These changes are included in this patch -
Added t/plugin_tests/greylisting, with greylist logic testing (tests are
 disabled by default, as greylisting is disabled in config.sample/plugins)
Added example entry in config.sample/plugins

Signed-off-by: Robert <rspier@pobox.com>
2010-05-11 21:19:52 -07:00
Matt Simerson
8b892c33ad fix copy/paste error in auth_flat_file
correct copy/paste error, where auth_flat_file methods were named authsql in auth_flat plugin

Signed-off-by: Robert <rspier@pobox.com>
2010-05-11 21:08:50 -07:00
Matt Simerson
5f81fd7925 remove vestiges of a bygone RCS 2010-05-09 23:22:13 -07:00
Ask Bjørn Hansen
1ea8e79850 Add a few more tests and a 'testcover' make target 2009-04-02 23:30:20 -07:00
Henry Baragar
4bbdd551b4 Ignore leading/trailing whitespace in config files
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@966 958fd67b-6ff1-0310-b445-bb7760255be9
2009-01-02 20:41:00 +00:00
Jared Johnson
a248ed56ad Allow local sites to override the definition of an email address.
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@963 958fd67b-6ff1-0310-b445-bb7760255be9
2008-12-31 21:35:21 +00:00
Ask Bjørn Hansen
43924427fc we don't call the regular logging infrastructure from the Test module,
so trace level doesn't get set to the default anywhere.  Set it to a value
here to avoid the uninitialized warnings.


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@849 958fd67b-6ff1-0310-b445-bb7760255be9
2008-02-14 18:57:27 +00:00
Ask Bjørn Hansen
6a027f4839 add simple test of config("me")
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@848 958fd67b-6ff1-0310-b445-bb7760255be9
2008-02-14 18:56:33 +00:00
Matt Sergeant
ef7d885929 Allow plugin tests to be in subdir (as with plugins).
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@737 958fd67b-6ff1-0310-b445-bb7760255be9
2007-05-17 22:02:32 +00:00
Matt Sergeant
60b74decd9 More tests
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@736 958fd67b-6ff1-0310-b445-bb7760255be9
2007-05-17 22:00:55 +00:00
Ask Bjørn Hansen
313f285847 Added tests for the rcpt_ok plugin (Guy Hulbert, issue #4)
http://code.google.com/p/smtpd/issues/detail?id=4



git-svn-id: https://svn.perl.org/qpsmtpd/trunk@725 958fd67b-6ff1-0310-b445-bb7760255be9
2007-03-15 06:55:24 +00:00
Matt Sergeant
be67f02dd8 Fix tests (idea from Guy Hulbert, with tweak from me).
git-svn-id: https://svn.perl.org/qpsmtpd/branches/0.3x@706 958fd67b-6ff1-0310-b445-bb7760255be9
2007-01-11 23:52:51 +00:00
John Peacock
8fcb46177b Add Qpsmtpd::Command to gather all parsing logic in one place (Hanno
Hecker)


git-svn-id: https://svn.perl.org/qpsmtpd/branches/0.3x@631 958fd67b-6ff1-0310-b445-bb7760255be9
2006-04-07 18:58:02 +00:00
John Peacock
b89a6d9e4c * plugins/queue/smtp-forward
s/register/init/ to match new plugin style (jpeacock)

* lib/Qpsmtpd/Address.pm
  t/qpsmtpd-address.t
    Ill-formed addresses should return null not partial garbage.
    Resolves https://rt.perl.org/rt3/Ticket/Display.html?id=38746
    Patch by Hanno Hecker.

* plugins/virus/clamav
    Clamav alternate config file.
    Resolves https://rt.perl.org/rt3/Ticket/Display.html?id=38736
    Patch by Robin Bowes.

* lib/Qpsmtpd/SMTP.pm
  lib/Qpsmtpd.pm
    Return multiline responses from plugins.
    Resolves https://rt.perl.org/rt3/Ticket/Display.html?id=38741
    Patch by Charlie Brady.

git-svn-id: https://svn.perl.org/qpsmtpd/branches/0.3x@630 958fd67b-6ff1-0310-b445-bb7760255be9
2006-03-20 16:47:05 +00:00
John Peacock
8a18bb00a1 * lib/Qpsmtpd/Address.pm
RFC-2821 Section 4.5.1 specifically requires <postmaster> (without
    domain name) as a legal RCPT TO: address.

* t/qpsmtpd-address.t
    Test the above.

git-svn-id: https://svn.perl.org/qpsmtpd/branches/0.31@560 958fd67b-6ff1-0310-b445-bb7760255be9
2005-11-08 18:18:02 +00:00
John Peacock
37ec3b151e * lib/Qpsmtpd/Address.pm
Add POD to describe how to use the objects.  Make the addr_cmp 
    method private (no need to expose it).

* t/qpsmtpd-address.t
    Include tests of overloaded comparison, including sorting.

git-svn-id: https://svn.perl.org/qpsmtpd/branches/0.31@559 958fd67b-6ff1-0310-b445-bb7760255be9
2005-11-02 18:48:32 +00:00
John Peacock
e6efda626f * lib/Qpsmtpd/Address.pm
Convert objects to hash.  Neuter parse() to wrapper around new().
    Add overload stringify to $obj->format().

* t/qpsmtpd-address.t
    Remove tests specific to parse().  Add test for overloaded "".

git-svn-id: https://svn.perl.org/qpsmtpd/branches/0.31@552 958fd67b-6ff1-0310-b445-bb7760255be9
2005-10-10 15:49:50 +00:00
John Peacock
bfd72e8ade Fix test failures due to hook renames
git-svn-id: https://svn.perl.org/qpsmtpd/branches/0.31@504 958fd67b-6ff1-0310-b445-bb7760255be9
2005-07-14 10:38:11 +00:00
John Peacock
662003437d * qpsmtpd-forkserver
Create a single Qpsmtpd::TcpServer object in the parent process and
     then rely on fork to let each child have it's own copy
     
 *   lib/Qpsmtpd/Plugin.pm
     Add new pre-connection and post-connection hooks
     
 *   README.plugins
     Document the above new hooks

 *   lib/Qpsmtpd.pm
     No longer have local value for trace_level() the first time through, which 
     was masking the global value (due to stupid search/replace error).
     Don't call log() from trace_level() since it is only ever called from
     within the varlog() sub when no logging plugin is registered.

 *   plugins/dnsbl
     Config line option to use DENY_DISCONNECT instead of DENY (since any IP
     on a blacklist should not have a chance to send anything for now).
     Add POD to document the new disconnect behavior

 *   lib/Qpsmtpd.pm
     Compatibility changes so test files continue to work
 
 *   t/Test/Qpsmtpd.pm
     Compatibility sub for core subs which call varlog() directly


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@428 958fd67b-6ff1-0310-b445-bb7760255be9
2005-05-25 20:07:58 +00:00
John Peacock
bb36c60b6a Abstracted spool_dir creation and added temp_file() and temp_dir() subs to
make it easier for plugins to manage temporary workspace.  Also add POD and
tests for the new functions.  Still need to add tests to the temp_*() calls
from a plugin.


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@369 958fd67b-6ff1-0310-b445-bb7760255be9
2005-02-22 02:47:39 +00:00
John Peacock
d790bd519d rcpt_handler requires a Qpsmtpd::Address object not just the bare address
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@368 958fd67b-6ff1-0310-b445-bb7760255be9
2005-02-22 00:38:06 +00:00
John Peacock
d26cffdb5e * t/addresses.t
Only need to 'my' the $command scalar once


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@363 958fd67b-6ff1-0310-b445-bb7760255be9
2005-02-13 21:40:24 +00:00
John Peacock
dd7b8be78f * MANIFEST
Since the config/ folder was renamed, have to update this too

*   t/qpsmtpd-address.t
    New tests added so the count needs to be incremented, too


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@361 958fd67b-6ff1-0310-b445-bb7760255be9
2005-02-13 21:28:10 +00:00
John Peacock
c840a1d04f Changes by jpeacock@cpan.org (John Peacock)
o plugins/check_badmailfromto
    - New plugin in the style of check_badmailfrom, which matches a pair
      of FROM/TO and makes it seem like the recipient's address no longer
      exists (but only from the matching sender's point of view).  Useful
      for stalkers and other harassment cases.

o plugins/dns_whitelist_soft
    - New plugin to provide a DNS-based whitelist (good for distributed
      sites).

o various files
    - Replaced tab character with 8 spaces and adjusted line breaks for
      better readability.

Changes by mct@toren.net (Michael C. Toren)

o lib/Qpsmtpd/SMTP.pm

    - Assumes a MAIL FROM value of "<#@[]>" (utilized by qmail to
      indicate a null sender when generating a doublebounce message)
      is equivalent to "<>".  Previously qpsmtpd complained that the
      value could not be parsed.

    - Adds LOGIN to the default list of supported auth mechanisms.
      The documentation in Auth.pm indicated that auth-login was not
      currently supported due to lack of functionality, however I can
      confirm that LOGIN appears to work fine as tested by using msmtp
      (http://msmtp.sourceforge.net/).  Are there any indications that
      LOGIN support is actually broken in the current implementation?

    - Removes the "X-Qpsmtpd-Auth: True" header appended when a message
      has been sent by an authenticated user.  One problem with such a
      header is that it's impossible to say which SMTP hop added it,
      and it provides no information which could be used to backtrack
      the transaction.  I grepped through my mail archives a bit
      looking for how other MTAs handled the problem, and decided it
      would be best to place this information in the Received: header:

        Received: from remotehost (HELO remotehost) (192.168.42.42)
          (smtp-auth username foo, mechanism cram-md5)
          by mail.netisland.net (qpsmtpd/0.28) with ESMTP; <date>


o lib/Qpsmtpd/Auth.pm:

    - Documentation update for the arguments passed to an auth
      handler; previously the $mechanism argument was not mentioned,
      which threw off the argument offsets.

    - Documentation update for auth-login removing the warning
      that auth-login is not currently supported due to lack of
      functionality.

    - Fix to execute a generic auth hook when a more specific
      auth-$mechanism hook does not exist.  (Previously posted
      to the list last week.)

    - Upon authentication, sets $session->{_auth_user} and
      $session->{_auth_mechanism} so that SMTP.pm can include them
      in the Received: header.


o plugins/queue/qmail-queue

    - Added a timestamp and the qmail-queue qp identifier to the
      "Queued!" 250 message, for compatibility with qmail-smtpd, which
      can be very useful for tracking message delivery from machine to
      machine.  For example, the new 250 message might be:

        250 Queued! 1105927468 qp 3210 <1105927457@netisland.net>

      qmail-smtpd returns:

        250 ok 1106546213 qp 7129

      Additionally, for consistency angle brackets are placed around
      the Message-ID displayed in the 250 if they were missing in the
      message header.


o plugins/check_badmailfrom:

    - Changed the error message from "Mail from $bad not accepted
      here" to "sorry, your envelope sender is in my badmailfrom
      list", for compatibility with qmail-smtpd.  I didn't see any
      reason to share with the sender the value of $bad, especially
      for situations where the sender was rejected resulting from a
      wildcard.


o plugins/check_earlytalker:
o plugins/require_resolvable_fromhost:

    - No longer checks for earlytalkers or resolvable senders if the
      connection note "whitelistclient" is set, which is nice for
      helping backup MX hosts empty their queue faster.


o plugins/count_unrecognized_commands:

    - Return code changed from DENY_DISCONNECT, which isn't valid in
      an unrecognized_command hook, to DENY, which in this context
      drops the connection anyway.  (Previously posted to the list
      last week.)


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@356 958fd67b-6ff1-0310-b445-bb7760255be9
2005-01-28 03:30:50 +00:00
Ask Bjørn Hansen
e78ee79569 really really fix the parse test this time.
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@339 958fd67b-6ff1-0310-b445-bb7760255be9
2004-11-16 02:15:22 +00:00
Ask Bjørn Hansen
452c0746d0 fix test (thanks John & Peter)
update MANIFEST to not include files that are not included :-)


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@338 958fd67b-6ff1-0310-b445-bb7760255be9
2004-11-16 02:07:39 +00:00
Ask Bjørn Hansen
8c390be6be moved config to config.sample
minor test cleanups

updated Changes file in preperation for a release


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@336 958fd67b-6ff1-0310-b445-bb7760255be9
2004-11-09 15:25:52 +00:00
Matt Sergeant
86b15d8e0a Moved to attic
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@325 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-21 18:16:05 +00:00
Matt Sergeant
c341ff0d0f Initial stab at an outbound bounce_verp system.
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@321 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-20 08:09:02 +00:00
Ask Bjørn Hansen
eadaaf217c add tests for single character domains
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@317 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-14 19:34:19 +00:00
Matt Sergeant
069c5a6835 Apparently diag() doesn't do what I thought it did!
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@315 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-08 21:53:29 +00:00
Matt Sergeant
d811d6dbdd A real test (and a flaw in the harness fixed)
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@314 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-08 21:48:27 +00:00
Matt Sergeant
9224e436bb Plugin testing framework.
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@313 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-08 16:26:33 +00:00
Matt Sergeant
b26b79c6ca Only 20 tests defined.
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@302 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-05 16:32:35 +00:00
Matt Sergeant
325bb77713 command is in $command not $_
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@299 958fd67b-6ff1-0310-b445-bb7760255be9
2004-09-05 16:25:02 +00:00
Ask Bjørn Hansen
f31e4b1b6b 100% test coverage of Qpsmtpd::Address
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@265 958fd67b-6ff1-0310-b445-bb7760255be9
2004-07-16 02:51:39 +00:00
Ask Bjørn Hansen
7889fa6990 add basic tests (mail from and helo and ehlo)
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@264 958fd67b-6ff1-0310-b445-bb7760255be9
2004-07-16 02:22:27 +00:00
Ask Bjørn Hansen
87323ed62e Mail::Address does RFC822 addresses, we need SMTP addresses.
Replace Mail::Address with Peter J. Holzer's Qpsmtpd::Address module.


git-svn-id: https://svn.perl.org/qpsmtpd/trunk@261 958fd67b-6ff1-0310-b445-bb7760255be9
2004-07-14 23:58:47 +00:00