Private
Server IP : 195.201.23.43  /  Your IP : 3.146.176.29
Web Server : Apache
System : Linux webserver2.vercom.be 5.4.0-192-generic #212-Ubuntu SMP Fri Jul 5 09:47:39 UTC 2024 x86_64
User : kdecoratie ( 1041)
PHP Version : 7.1.33-63+ubuntu20.04.1+deb.sury.org+1
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/share/webmin/spam/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /usr/share/webmin/spam/edit_procmail.cgi
#!/usr/bin/perl
# Allow changing of the rule for delivering spam

require './spam-lib.pl';
&ReadParse();
&set_config_file_in(\%in);
&can_use_check("procmail");
&ui_print_header(undef, $text{'procmail_title'}, "");

print &text('procmail_desc', "<tt>$pmrc</tt>"),"<p>\n";

# Find the existing recipe
&foreign_require("procmail", "procmail-lib.pl");
@pmrcs = &get_procmailrc();
$pmrc = $pmrcs[$#pmrcs];
@recipes = &procmail::parse_procmail_file($pmrc);
$spamrec = &find_file_recipe(\@recipes);

if (!$spamrec) {
	$mode = 4;
	}
elsif ($spamrec->{'action'} eq "\$DEFAULT") {
	$mode = 4;
	}
elsif ($spamrec->{'action'} eq "/dev/null") {
	$mode = 0;
	}
elsif ($spamrec->{'action'} =~ /^(.*)\/$/) {
	$mode = 2;
	$file = $1;
	}
elsif ($spamrec->{'action'} =~ /^(.*)\/\.$/) {
	$mode = 3;
	$file = $1;
	}
elsif ($spamrec->{'type'} eq '!') {
	$mode = 5;
	$email = $spamrec->{'action'};
	}
else {
	$mode = 1;
	$file = $spamrec->{'action'};
	}

print &ui_form_start("save_procmail.cgi", "post");
print &ui_table_start(undef, undef, 2);
print $form_hiddens;

# Spam destination inputs
print &ui_table_row($text{'setup_to'},
	&ui_radio_table("to", $mode,
	  [ [ 0, $text{'setup_null'} ],
	    [ 4, $text{'setup_default'} ],
	    [ 1, $text{'setup_file'},
		 &ui_textbox("mbox", $mode == 1 ? $file : "", 40) ],
	    [ 2, $text{'setup_maildir'},
		 &ui_textbox("maildir", $mode == 2 ? $file : "", 40) ],
	    [ 3, $text{'setup_mhdir'},
		 &ui_textbox("mhdir", $mode == 3 ? $file : "", 40) ],
	    [ 5, $text{'setup_email'},
		 &ui_textbox("email", $mode == 5 ? $email : "", 40) ] ]));

# Message about path
if ($module_info{'usermin'}) {
	$msg = "$text{'setup_rel'}<p>\n";
	}
else {
	$msg = "$text{'setup_home'}<p>\n";
	}
$msg .= "$text{'setup_head'}<p>\n";
print &ui_table_row(undef, $msg, 2);

print &ui_table_end();
print &ui_form_end([ [ undef, $text{'procmail_ok'} ] ]);

&ui_print_footer($redirect_url, $text{'index_return'});

Private