Common Macros

From ESM Wiki
(Difference between revisions)
Jump to: navigation, search
($attachment)
Line 94: Line 94:
 
<table cellspaceing="0" cellpadding="0">
 
<table cellspaceing="0" cellpadding="0">
 
   <tr>
 
   <tr>
     <td style="padding-right: 10px;">''Description:''</td>
+
     <td style="padding-right: 10px; vertical-align: top;">''Description:''</td>
     <td>Represents email attachment data. Attachment is every body part that is not body in body-attachments-view typical for MUA's.</td>
+
     <td style="vertical-align: top;">Email attachment data. Attachment is every body part that is not body in body-attachments-view typical for MUA's.</td>
 
   </tr>
 
   </tr>
 
   <tr>
 
   <tr>
     <td style="padding-right: 10px;">''Dimension:''</td>
+
     <td style="padding-right: 10px; vertical-align: top;">''Dimension:''</td>
     <td>$attachment</td>
+
     <td style="vertical-align: top;">$attachment</td>
 
   </tr>
 
   </tr>
 
   <tr>
 
   <tr>
     <td style="padding-right: 10px;">''Stage:''</td>
+
     <td style="padding-right: 10px; vertical-align: top;">''Stage:''</td>
     <td>smtp-end-of-data</td>
+
     <td style="vertical-align: top;">smtp-end-of-data</td>
 
   </tr>
 
   </tr>
 
</table>
 
</table>
  
 
==== $attachment.base64 ====
 
==== $attachment.base64 ====
 +
 +
<table cellspaceing="0" cellpadding="0">
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Description:''</td>
 +
    <td style="vertical-align: top;">Email attachment data encoded as base64. Using this macro may be more effective then using ${encode_base64 $attachment} in most cases because attachment data in email is likely to be already encoded as base64.</td>
 +
  </tr>
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Dimension:''</td>
 +
    <td style="vertical-align: top;">$attachment</td>
 +
  </tr>
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Stage:''</td>
 +
    <td style="vertical-align: top;">smtp-end-of-data</td>
 +
  </tr>
 +
</table>
 +
 
==== $attachment.headers ====
 
==== $attachment.headers ====
 +
 +
<table cellspaceing="0" cellpadding="0">
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Description:''</td>
 +
    <td style="vertical-align: top;">Email attachment headers as single string.</td>
 +
  </tr>
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Dimension:''</td>
 +
    <td style="vertical-align: top;">$attachment</td>
 +
  </tr>
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Stage:''</td>
 +
    <td style="vertical-align: top;">smtp-end-of-data</td>
 +
  </tr>
 +
</table>
 +
 
==== $attachment.text ====
 
==== $attachment.text ====
 +
 +
<table cellspaceing="0" cellpadding="0">
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Description:''</td>
 +
    <td style="vertical-align: top;">Text extracted from email attachment and converted to utf-8 encoding. This macro is intended to extract pure text from different types of documents for this text to be used in content analyzing tools. Though currently this macro is fully equivalent to $attachment it will be enhanced to support as much types of documents as possible.</td>
 +
  </tr>
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Dimension:''</td>
 +
    <td style="vertical-align: top;">$attachment</td>
 +
  </tr>
 +
  <tr>
 +
    <td style="padding-right: 10px; vertical-align: top;">''Stage:''</td>
 +
    <td style="vertical-align: top;">smtp-end-of-data</td>
 +
  </tr>
 +
</table>
 +
 
==== $attachment.malformed ====
 
==== $attachment.malformed ====
 
==== $attachment.multipart ====
 
==== $attachment.multipart ====

Revision as of 05:08, 10 October 2009

The following macros can be used in templates and conditions of all engines:

$attachment
$attachment.base64
$attachment.headers
$attachment.text
$attachment.malformed
$attachment.multipart
$attachment.resource_fork
$attachment.resource_fork.base64
$attachment.file_name
$attachment.mime_type
$body
$body.html
$body_part
$body_part.is_body
$body_part.is_attachment
$body_part.size
$body_part.headers
$body_part.text
$body_part.malformed
$body_part.multipart
$body_part.file_name
$body_part.digest
$body_part.resource_fork

$body_part.resource_fork.size
$body_part.resource_fork.digest
$data
$data.size
$data.digest
$decode_base64
$empty
$encode_base64
$json_escape
$headers
$headers.message_id
$headers.in_reply_to
$headers.references
$headers.from
$headers.sender
$headers.reply_to
$headers.to
$headers.cc
$headers.bcc
$headers.subject
$hmac
$host
$ip

$ip.dec
$ip.hex
$if_not_empty
$gethostname
$group
$message_id
$md5
$not_empty
$pid
$recipient
$recipient.local
$recipient.domain
$recipient.component
$sender
$sender.local
$sender.domain
$sender.component
$sha1
$size
$size_hex
$sp, $br, $cr, $lf, $crlf, $htab
$subject
$text_find_replace_all

$thread
$time
$time6
$uri_escape
$wrap
$xml_cdata
$xml_escape
$year, $month, $day, $hour, $minute, $second

$attachment

Description: Email attachment data. Attachment is every body part that is not body in body-attachments-view typical for MUA's.
Dimension: $attachment
Stage: smtp-end-of-data

$attachment.base64

Description: Email attachment data encoded as base64. Using this macro may be more effective then using ${encode_base64 $attachment} in most cases because attachment data in email is likely to be already encoded as base64.
Dimension: $attachment
Stage: smtp-end-of-data

$attachment.headers

Description: Email attachment headers as single string.
Dimension: $attachment
Stage: smtp-end-of-data

$attachment.text

Description: Text extracted from email attachment and converted to utf-8 encoding. This macro is intended to extract pure text from different types of documents for this text to be used in content analyzing tools. Though currently this macro is fully equivalent to $attachment it will be enhanced to support as much types of documents as possible.
Dimension: $attachment
Stage: smtp-end-of-data

$attachment.malformed

$attachment.multipart

$attachment.resource_fork

$attachment.resource_fork.base64

$attachment.file_name

$attachment.mime_type

$body

$body.html

$body_part

$body_part.is_body

$body_part.is_attachment

$body_part.size

$body_part.headers

$body_part.text]]

$body_part.malformed

$body_part.multipart

$body_part.file_name

$body_part.digest

$body_part.resource_fork

$body_part.resource_fork.size

$body_part.resource_fork.digest

$data

$data.size

$data.digest

$decode_base64

$empty

$encode_base64

$json_escape

$headers

$headers.message_id

$headers.in_reply_to

$headers.references

$headers.from

$headers.sender

$headers.reply_to

$headers.to

$headers.cc

$headers.bcc

$headers.subject

$hmac

$host

$ip

$ip.dec

$ip.hex

$if_not_empty

$gethostname

$group

$message_id

$md5

$not_empty

$pid

$recipient

$recipient.local

$recipient.domain

$recipient.component

$sender

$sender.local

$sender.domain

$sender.component

$sha1

$size

$size_hex

$sp, $br, $cr, $lf, $crlf, $htab

$subject

$text_find_replace_all

$thread

$time

$time6

$uri_escape

$wrap

$xml_cdata

$xml_escape

$year, $month, $day, $hour, $minute, $second

Personal tools