December 18, 2009

disable_boxtrapper

Disabling Boxtrapper for a cpanel server

Edit the /etc/exim.conf file with your favorite command-line text editor. Personally, I am partial to vim but a lot of people prefer pico or nano it really doesn't matter. Just open the /etc/exim.conf file in your favorite text editor.

boxtraper_autowhitelist:
driver = accept
condition = "${perl{checkbx_autowhitelist}{$authenticated_id}}"
require_files = "/usr/local/cpanel/bin/boxtrapper"
transport = boxtrapper_autowhitelist
unseen


Now just comment out these lines, by adding a # symbol at the beginning of each line. So that instead of the above lines you would see:

# boxtraper_autowhitelist:
# driver = accept
# condition = "${perl{checkbx_autowhitelist}{$authenticated_id}}"
# require_files = "/usr/local/cpanel/bin/boxtrapper"
# transport = boxtrapper_autowhitelist
# unseen


You are basically going to do this for all instances of the boxtrapper and the four sections.

Now search for boxtrapper again. This time you should see a section:

virtual_boxtraper_user:
driver = accept
condition = "${perl{checkbx_deliver}{$domain}{$local_part}}"
require_files = "/usr/local/cpanel/bin/boxtrapper"
domains = lsearch;/etc/userdomains
retry_use_local_part
transport = virtual_boxtrapper_userdelivery


And replace this with:

# virtual_boxtraper_user:
# driver = accept
# condition = "${perl{checkbx_deliver}{$domain}{$local_part}}"
# require_files = "/usr/local/cpanel/bin/boxtrapper"
# domains = lsearch;/etc/userdomains
# retry_use_local_part
# transport = virtual_boxtrapper_userdelivery


Search for boxtrapper again:

boxtrapper_localuser:
driver = accept
condition = "${perl{checkuserbx}{$local_part}}"
require_files = "/usr/local/cpanel/bin/boxtrapper"
check_local_user
domains = ! lsearch;/etc/userdomains
transport = local_boxtrapper_delivery


Change to:

# boxtrapper_localuser:
# driver = accept
# condition = "${perl{checkuserbx}{$local_part}}"
# require_files = "/usr/local/cpanel/bin/boxtrapper"
# check_local_user
# domains = ! lsearch;/etc/userdomains
# transport = local_boxtrapper_delivery


And finally, there is one more section that needs to be removed, so search for boxtrapper one more time:

boxtrapper_autowhitelist:
driver = pipe
command = /usr/local/cpanel/bin/boxtrapper --autowhitelist "${authenticated_id}"
user = ${perl{getemailuser}{$authenticated_id}}
group = mail
log_output = true
current_directory = "/tmp"
return_fail_output = true
return_path_add = false

local_boxtrapper_delivery:
driver = pipe
command = /usr/local/cpanel/bin/boxtrapper "${local_part}"
user = $local_part
group = mail
log_output = true
current_directory = "/tmp"
return_fail_output = true
return_path_add = false

virtual_boxtrapper_userdelivery:
driver = pipe
command = /usr/local/cpanel/bin/boxtrapper "${local_part}@${domain}"
user = "${lookup{$domain}lsearch* {/etc/userdomains}{$value}}"
group = mail
log_output = true
current_directory = "/tmp"
return_fail_output = true
return_path_add = false


And change this to read:

# boxtrapper_autowhitelist:
# driver = pipe
# command = /usr/local/cpanel/bin/boxtrapper --autowhitelist "${authenticated_id}"
# user = ${perl{getemailuser}{$authenticated_id}}
# group = mail
# log_output = true
# current_directory = "/tmp"
# return_fail_output = true
# return_path_add = false

# local_boxtrapper_delivery:
# driver = pipe
# command = /usr/local/cpanel/bin/boxtrapper "${local_part}"
# user = $local_part
# group = mail
# log_output = true
# current_directory = "/tmp"
# return_fail_output = true
# return_path_add = false

# virtual_boxtrapper_userdelivery:
# driver = pipe
# command = /usr/local/cpanel/bin/boxtrapper "${local_part}@${domain}"
# user = "${lookup{$domain}lsearch* {/etc/userdomains}{$value}}"
# group = mail
# log_output = true
# current_directory = "/tmp"
# return_fail_output = true
# return_path_add = false


That should be all of the boxtrapper sections in the /etc/exim.conf file. Now just save the file and restart exim:

/scripts/restartsrv_exim

No comments:

Post a Comment