.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Mail::MIMEDefang::Utils 3" .TH Mail::MIMEDefang::Utils 3 2024-03-20 3.4.1 "Mail::MIMEDefang::Utils Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME Mail::MIMEDefang::Utils \- Support methods used internally or by email filters .SH DESCRIPTION .IX Header "DESCRIPTION" Mail::MIMEDefang::Utils are a set of methods that can be called from \fImimedefang-filter\fR or by other methods. .SH METHODS .IX Header "METHODS" .IP time_str 4 .IX Item "time_str" Method that returns a string representing the current time. .IP hour_str 4 .IX Item "hour_str" Method that returns a string representing the current hour. .IP synthesize_received_header 4 .IX Item "synthesize_received_header" Method that synthesizes a valid Received: header to reflect re-mailing. Needed by Apache SpamAssassin to correctly parse email messages. .IP copy_or_link 4 .IX Item "copy_or_link" Method that copies a file if it fails to create an hard link to the original file. .IP read_results 4 .IX Item "read_results" Method that extracts an array of command, key, values from RESULTS file, needed for regression tests. .IP re_match 4 .IX Item "re_match" Method that returns 1 if either Content\-Disposition.filename or Content\-Type.name matches the regexp; 0 otherwise. .IP re_match_ext 4 .IX Item "re_match_ext" Method that returns 1 if the EXTENSION part of either Content\-Disposition.filename or Content\-Type.name matches regexp; 0 otherwise. .IP re_match_in_rar_directory 4 .IX Item "re_match_in_rar_directory" Method that returns 1 if the EXTENSION part of any file in the rar archive matches regexp. .IP re_match_in_7zip_directory 4 .IX Item "re_match_in_7zip_directory" Method that returns 1 if the EXTENSION part of any file in the 7zip archive matches regexp. .IP re_match_in_zip_directory 4 .IX Item "re_match_in_zip_directory" Method that returns 1 if the EXTENSION part of any file in the zip archive matches regexp. .IP md_copy_orig_msg_to_work_dir_as_mbox_file 4 .IX Item "md_copy_orig_msg_to_work_dir_as_mbox_file" Method that copies original INPUTMSG file into work directory for virus-scanning as a valid mbox file. .IP gen_mx_id 4 .IX Item "gen_mx_id" Method that generates a random indentifier used by MIMEDefang to create temporary files.