aboutsummaryrefslogtreecommitdiffstats
path: root/src/libserver
diff options
context:
space:
mode:
authorAndrew Lewis <nerf@judo.za.org>2016-09-30 15:13:38 +0200
committerAndrew Lewis <nerf@judo.za.org>2016-09-30 15:13:38 +0200
commitb561e9b9cbd86191aec1e51cc776d083b66b14b5 (patch)
tree75f11a5a2a4d4ea3ed65a8480d47d073395806e7 /src/libserver
parent81a01f43d3c1de562273b30025b018d38a5aadf6 (diff)
downloadrspamd-b561e9b9cbd86191aec1e51cc776d083b66b14b5.tar.gz
rspamd-b561e9b9cbd86191aec1e51cc776d083b66b14b5.zip
[Minor] Allow for re-enabling default-disabled checks
Diffstat (limited to 'src/libserver')
-rw-r--r--src/libserver/cfg_file.h2
-rw-r--r--src/libserver/cfg_rcl.c12
2 files changed, 14 insertions, 0 deletions
diff --git a/src/libserver/cfg_file.h b/src/libserver/cfg_file.h
index 9a0fa0d22..3bfeee98c 100644
--- a/src/libserver/cfg_file.h
+++ b/src/libserver/cfg_file.h
@@ -298,6 +298,8 @@ struct rspamd_config {
gboolean vectorized_hyperscan; /**< use vectorized hyperscan matching */
gboolean enable_shutdown_workaround; /**< enable workaround for legacy SA clients (exim) */
gboolean ignore_received; /**< Ignore data from the first received header */
+ gboolean check_local; /** Don't disable any checks for local networks */
+ gboolean check_authed; /** Don't disable any checks for authenticated users */
gsize max_diff; /**< maximum diff size for text parts */
gsize max_cores_size; /**< maximum size occupied by rspamd core files */
diff --git a/src/libserver/cfg_rcl.c b/src/libserver/cfg_rcl.c
index c89392207..8ada11f88 100644
--- a/src/libserver/cfg_rcl.c
+++ b/src/libserver/cfg_rcl.c
@@ -1837,6 +1837,18 @@ rspamd_rcl_config_init (struct rspamd_config *cfg)
0,
"Emit errors if there are unknown HTTP headers in a request");
rspamd_rcl_add_default_handler (sub,
+ "check_local",
+ rspamd_rcl_parse_struct_boolean,
+ G_STRUCT_OFFSET (struct rspamd_config, check_local),
+ 0,
+ "Don't disable any checks for local networks");
+ rspamd_rcl_add_default_handler (sub,
+ "check_authed",
+ rspamd_rcl_parse_struct_boolean,
+ G_STRUCT_OFFSET (struct rspamd_config, check_authed),
+ 0,
+ "Don't disable any checks for authenticated users");
+ rspamd_rcl_add_default_handler (sub,
"check_all_filters",
rspamd_rcl_parse_struct_boolean,
G_STRUCT_OFFSET (struct rspamd_config, check_all_filters),