squirrelmail-webmail
1.4.22
About: SquirrelMail is a standards-based webmail package with strong MIME support, address books, and folder manipulation (written in PHP4).
![]() ![]() |
Go to the source code of this file.
Namespaces | |
plugins | |
Functions | |
filters_SaveCache () | |
filters_LoadCache () | |
filters_bulkquery ($filters_spam_scan, $filters, $read) | |
start_filters () | |
user_filters ($imap_stream) | |
filter_search_and_delete ($imap, $where, $what, $where_to, $user_scan, $del_id) | |
spam_filters ($imap_stream) | |
filters_spam_check_site ($a, $b, $c, $d, &$filters) | |
load_filters () | |
load_spam_filters () | |
remove_filter ($id) | |
filter_swap ($id1, $id2) | |
update_for_folder ($args) | |
do_error ($string) | |
do_error | ( | $string | ) |
Display formated error message
string | $string | text message |
Definition at line 884 of file filters.php.
References $color.
filter_search_and_delete | ( | $imap, | |
$where, | |||
$what, | |||
$where_to, | |||
$user_scan, | |||
$del_id | |||
) |
Creates and runs the IMAP command to filter messages
string | $imap | TODO: Document this parameter |
string | $where | Which part of the message to search (TO, CC, SUBJECT, etc...) |
string | $what | String to search for |
string | $where_to | Folder it will move to |
string | $user_scan | Whether to search all or just unseen |
string | $del_id | TODO: Document this parameter @access private |
Definition at line 301 of file filters.php.
References $allow_charset_search, $id, $imap_server_type, $j, $languages, $message, $num, $r, $read, $squirrelmail_language, $uid_support, sqimap_mailbox_exists(), sqimap_msgs_list_move(), sqimap_run_command_list(), and sqimap_run_literal_command().
Referenced by user_filters().
filter_swap | ( | $id1, | |
$id2 | |||
) |
filters_bulkquery | ( | $filters_spam_scan, | |
$filters, | |||
$read | |||
) |
Uses the BulkQuery executable to query all the RBLs at once
array | $filters | Array of SPAM Filters |
array | $IPs | Array of IP Addresses |
array | $read | TODO: Document this parameter @access private |
Definition at line 88 of file filters.php.
References $attachment_dir, $filters, $read, $SpamFilters_BulkQuery, $SpamFilters_CacheTTL, $SpamFilters_DNScache, $SpamFilters_YourHop, and $username.
Referenced by spam_filters().
filters_LoadCache | ( | ) |
Loads the DNS Cache from disk @access private
Definition at line 63 of file filters.php.
References $data, $data_dir, and $SpamFilters_DNScache.
Referenced by spam_filters().
filters_SaveCache | ( | ) |
FIXME: Undocumented function @access private
Definition at line 32 of file filters.php.
References $data_dir, and $SpamFilters_DNScache.
Referenced by spam_filters().
filters_spam_check_site | ( | $a, | |
$b, | |||
$c, | |||
$d, | |||
& | $filters | ||
) |
Does the loop through each enabled filter for the specified IP address. IP format: $a.$b.$c.$d
int | $a | First subset of IP |
int | $b | Second subset of IP |
int | $c | Third subset of IP |
int | $d | Forth subset of IP |
array | $filters | The Spam Filters |
RFC allows . on end of hostname to force domain lookup to not use search domain from resolv.conf, i.e. to ensure search domain isn't used if no hostname is found
gethostbyname returns ip if resolved, or returns original host supplied to function if there is no resolution
Definition at line 505 of file filters.php.
References $filters, $SpamFilters_CacheTTL, and $SpamFilters_DNScache.
Referenced by spam_filters().
load_filters | ( | ) |
Loads the filters from the user preferences
Definition at line 550 of file filters.php.
References $data_dir, $filters, $username, and getPref().
Referenced by start_filters(), update_for_folder(), and user_filters().
load_spam_filters | ( | ) |
Loads the Spam Filters and checks the preferences for the enabled status
Definition at line 568 of file filters.php.
References $data_dir, $filters, $SpamFilters_ShowCommercial, $username, _(), and getPref().
Referenced by spam_filters(), and start_filters().
remove_filter | ( | $id | ) |
Removes a User filter
int | $id | ID of the filter to remove @access private |
Definition at line 817 of file filters.php.
References $data_dir, $id, $username, getPref(), removePref(), and setPref().
Referenced by update_for_folder().
spam_filters | ( | $imap_stream | ) |
Loops through all the Received Headers to find IP Addresses
stream | imap_stream the stream to read from @access private |
Definition at line 375 of file filters.php.
References $data_dir, $filters, $filters_spam_folder, $filters_spam_scan, $id, $imap_stream, $message, $read, $SpamFilters_BulkQuery, $SpamFilters_DNScache, $SpamFilters_SharedCache, $SpamFilters_YourHop, $uid_support, $username, filters_bulkquery(), filters_LoadCache(), filters_SaveCache(), filters_spam_check_site(), getPref(), load_spam_filters(), parseFetch(), sqimap_mailbox_exists(), sqimap_mailbox_expunge(), sqimap_mailbox_select(), sqimap_message_list_squisher(), sqimap_msgs_list_move(), sqimap_run_command(), sqimap_run_command_list(), and sqsession_register().
Referenced by start_filters().
start_filters | ( | ) |
Starts the filtering process @access private
Definition at line 182 of file filters.php.
References $AllowSpamFilters, $filters, $imap_stream, $imapConnection, $imapPort, $imapServerAddress, $mailbox, $stream, $username, $UseSeparateImapConnection, load_filters(), load_spam_filters(), SMPREF_ON, spam_filters(), SQ_COOKIE, SQ_SESSION, sqgetGlobalVar(), sqimap_login(), sqimap_logout(), sqimap_mailbox_select(), sqimap_status_messages(), and user_filters().
update_for_folder | ( | $args | ) |
This updates the filter rules when renaming or deleting folders
array | $args | @access private |
Definition at line 851 of file filters.php.
References $action, $data_dir, $filters, $plugins, $username, elseif, load_filters(), remove_filter(), and setPref().
user_filters | ( | $imap_stream | ) |
Does the loop through each filter
stream | imap_stream the stream to read from @access private |
Definition at line 249 of file filters.php.
References $data_dir, $filters, $filters_user_scan, $id, $imap_stream, $num, $username, filter_search_and_delete(), getPref(), load_filters(), sqimap_mailbox_exists(), sqimap_mailbox_expunge(), and sqimap_mailbox_select().
Referenced by start_filters().