[Pkg-clamav-commits] [SCM] Debian repository for ClamAV branch, debian/unstable, updated. debian/0.95+dfsg-1-167-g4319a8f
acab
acab at 77e5149b-7576-45b1-b177-96237e5ba77b
Fri Jun 12 19:11:47 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit ca3d51eb2d956904111d5302a08622dd2c783279
Author: acab <acab at 77e5149b-7576-45b1-b177-96237e5ba77b>
Date: Fri Apr 24 13:21:56 2009 +0000
drop QuarantineReject
git-svn-id: http://svn.clamav.net/svn/clamav-devel/trunk@5055 77e5149b-7576-45b1-b177-96237e5ba77b
diff --git a/ChangeLog b/ChangeLog
index f28190e..4c6a1e4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Fri Apr 24 15:20:48 CEST 2009 (acab)
+....................................
+ * clamav-milter: drop support for QuarantineReject: it's a bad idea and
+ doesn't work anyway.
+
Thu Apr 23 16:54:54 EEST 2009 (edwin)
-------------------------------------
* clamav-config.h.in, clamd/thrmgr.c, configure, configure.in: errno
diff --git a/clamav-milter/clamfi.c b/clamav-milter/clamfi.c
index 69e31ad..cccc005 100644
--- a/clamav-milter/clamfi.c
+++ b/clamav-milter/clamfi.c
@@ -400,8 +400,6 @@ static int parse_action(char *action) {
return 3;
if(!strcasecmp(action, "Quarantine"))
return 4;
- if(!strcasecmp(action, "QuarantineReject"))
- return 5;
logg("!Unknown action %s\n", action);
return -1;
}
@@ -419,19 +417,14 @@ static sfsistat action_reject(_UNUSED_ SMFICTX *ctx) {
static sfsistat action_blackhole(_UNUSED_ SMFICTX *ctx) {
return SMFIS_DISCARD;
}
-static sfsistat quarantine_common(SMFICTX *ctx, sfsistat ret) {
+static sfsistat action_quarantine(SMFICTX *ctx) {
if(smfi_quarantine(ctx, "quarantined by clamav-milter") != MI_SUCCESS) {
logg("^Failed to quarantine message\n");
return SMFIS_TEMPFAIL;
}
- return ret;
-}
-static sfsistat action_quarantine(SMFICTX *ctx) {
- return quarantine_common(ctx, SMFIS_ACCEPT);
-}
-static sfsistat action_quarantine_reject(SMFICTX *ctx) {
- return quarantine_common(ctx, SMFIS_REJECT);
+ return SMFIS_ACCEPT;
}
+
static sfsistat action_reject_msg(SMFICTX *ctx) {
struct CLAMFI *cf;
char buf[1024];
@@ -493,9 +486,6 @@ int init_actions(struct optstruct *opts) {
case 4:
CleanAction = action_quarantine;
break;
- case 5:
- CleanAction = action_quarantine_reject;
- break;
default:
logg("!Invalid action %s for option OnClean\n", opt->strarg);
return 1;
@@ -516,9 +506,6 @@ int init_actions(struct optstruct *opts) {
case 4:
InfectedAction = action_quarantine;
break;
- case 5:
- InfectedAction = action_quarantine_reject;
- break;
case 2:
InfectedAction = action_reject_msg;
if((opt = optget(opts, "RejectMsg"))->enabled) {
diff --git a/etc/clamav-milter.conf b/etc/clamav-milter.conf
index 3314f69..1e3de4a 100644
--- a/etc/clamav-milter.conf
+++ b/etc/clamav-milter.conf
@@ -135,9 +135,6 @@ Example
# Like Accept but the message is sent to oblivion
# - Quarantine (not available for OnFail)
# Like Accept but message is quarantined instead of being delivered
-# - QuarantineReject (not available for OnFail)
-# like Reject but a copy of the message is also quarantined
-# Note: in Postfix this acts the same as Quarantine
#
# NOTE: In Sendmail the quarantine queue can be examined via mailq -qQ
# For Postfix this causes the message to be placed on hold
diff --git a/shared/optparser.c b/shared/optparser.c
index 9528589..d7dd452 100644
--- a/shared/optparser.c
+++ b/shared/optparser.c
@@ -373,9 +373,9 @@ const struct clam_option clam_options[] = {
{ "LocalNet", NULL, 0, TYPE_STRING, NULL, -1, NULL, FLAG_MULTIPLE, OPT_MILTER, "Messages originating from these hosts/networks will not be scanned\nThis option takes a host(name)/mask pair in CIRD notation and can be\nrepeated several times. If \"/mask\" is omitted, a host is assumed.\nTo specify a locally orignated, non-smtp, email use the keyword \"local\".", "local\n192.168.0.0/24\n1111:2222:3333::/48" },
- { "OnClean", NULL, 0, TYPE_STRING, "^(Accept|Reject|Defer|Blackhole|Quarantine|QuarantineReject)$", -1, "Accept", 0, OPT_MILTER, "Action to be performed on clean messages (mostly useful for testing).\nThe following actions are available:\nAccept: the message is accepted for delievery\nReject: immediately refuse delievery (a 5xx error is returned to the peer)\nDefer: return a temporary failure message (4xx) to the peer\nBlackhole: like Accept but the message is sent to oblivion\nQuarantine: like Accept but message is quarantined instead of being delivered\nQuarantineReject: like Reject but a copy of the message is also quarantined", "Accept" },
+ { "OnClean", NULL, 0, TYPE_STRING, "^(Accept|Reject|Defer|Blackhole|Quarantine)$", -1, "Accept", 0, OPT_MILTER, "Action to be performed on clean messages (mostly useful for testing).\nThe following actions are available:\nAccept: the message is accepted for delievery\nReject: immediately refuse delievery (a 5xx error is returned to the peer)\nDefer: return a temporary failure message (4xx) to the peer\nBlackhole: like Accept but the message is sent to oblivion\nQuarantine: like Accept but message is quarantined instead of being delivered", "Accept" },
- { "OnInfected", NULL, 0, TYPE_STRING, "^(Accept|Reject|Defer|Blackhole|Quarantine|QuarantineReject)$", -1, "Quarantine", 0, OPT_MILTER, "Action to be performed on clean messages (mostly useful for testing).\nThe following actions are available:\nAccept: the message is accepted for delievery\nReject: immediately refuse delievery (a 5xx error is returned to the peer)\nDefer: return a temporary failure message (4xx) to the peer\nBlackhole: like Accept but the message is sent to oblivion\nQuarantine: like Accept but message is quarantined instead of being delivered\nQuarantineReject: like Reject but a copy of the message is also quarantined", "Quarantine" },
+ { "OnInfected", NULL, 0, TYPE_STRING, "^(Accept|Reject|Defer|Blackhole|Quarantine)$", -1, "Quarantine", 0, OPT_MILTER, "Action to be performed on clean messages (mostly useful for testing).\nThe following actions are available:\nAccept: the message is accepted for delievery\nReject: immediately refuse delievery (a 5xx error is returned to the peer)\nDefer: return a temporary failure message (4xx) to the peer\nBlackhole: like Accept but the message is sent to oblivion\nQuarantine: like Accept but message is quarantined instead of being delivered", "Quarantine" },
{ "OnFail", NULL, 0, TYPE_STRING, "^(Accept|Reject|Defer)$", -1, "Defer", 0, OPT_MILTER, "Action to be performed on error conditions (this includes failure to\nallocate data structures, no scanners available, network timeouts, unknown\nscanner replies and the like.\nThe following actions are available:\nAccept: the message is accepted for delievery;\nReject: immediately refuse delievery (a 5xx error is returned to the peer);\nDefer: return a temporary failure message (4xx) to the peer.", "Defer" },
--
Debian repository for ClamAV
More information about the Pkg-clamav-commits
mailing list