Skip to main content
Version: 4.4

File Analyzers

You can add a File Analyzer integration which will run the configured analyzers.

Analyzers​

Here is the list of available analyzers:

checksum​

This analyzer computes the checksum of a file using a specified hashing algorithm and can check for uniqueness of the file based on its checksum.

-
name: checksum # Required
max_severity: Critical # One of "debug"; "info"; "warning"; "error"; "critical"
# One of: quarantine, move_to_trash, delete
actions_on_reject: []
# The hashing algorithm to use.
algorithm: sha256
# Whether to strip metadata from the file before computing the checksum.
stripMetadata: true
# Whether to check for uniqueness of the file based on its checksum.
findDuplicates: true
# The maximum number of duplicates to check for. If more than this number of duplicates are found, only the first N will be returned.
duplicatesLimit: 10

debug​

This analyzer is used for debugging purposes. It allows you to specify errors, warnings, and additional data to be returned during the analysis of a file.

-
name: debug # Required
max_severity: Critical # One of "debug"; "info"; "warning"; "error"; "critical"
# One of: quarantine, move_to_trash, delete
actions_on_reject: []
# If no error or critical message is defined, then file will be accepted.
messages:
# Prototype
-
level: ~ # One of "debug"; "info"; "warning"; "error"; "critical"
type: ~
payload: []
data: []
duplicates: []

doc_unique_id​

This analyzer checks for a unique identifier in the file's metadata. If you enable this analyzer, the File Analyzer integration must then need a Read Metadata integration to be processed before it.

-
name: doc_unique_id # Required
max_severity: Critical # One of "debug"; "info"; "warning"; "error"; "critical"
# One of: quarantine, move_to_trash, delete
actions_on_reject: []
read_from:
# Defaults:
- XMP-exif:ImageUniqueID
- SigmaRaw:ImageUniqueID
- IPTC:UniqueDocumentID
- ExifIFD:ImageUniqueID
- Canon:ImageUniqueID
- XMP-xmpMM:DocumentID
# Store the document unique id in the file overridden metadata, so that it is embedded into renditions and exports.
write: true
write_to:
# Defaults:
- XMP-exif:ImageUniqueID
- SigmaRaw:ImageUniqueID
- IPTC:UniqueDocumentID
- ExifIFD:ImageUniqueID
- Canon:ImageUniqueID
- XMP-xmpMM:DocumentID
# Deprecated and ignored: a duplicate is always reported as a critical message.
treatDuplicateAsError: ~ # Deprecated (Since alchemy/databox 4.0: The "treatDuplicateAsError" option is deprecated and ignored.)
findDuplicates: true
# The maximum number of duplicates to check for. If more than this number of duplicates are found, only the first N will be returned.
duplicatesLimit: 10
generate: true

filename​

Analyzes the filename of the file and checks it against allowed/disallowed patterns, extensions, and MIME types.

-
name: filename # Required
max_severity: Critical # One of "debug"; "info"; "warning"; "error"; "critical"
# One of: quarantine, move_to_trash, delete
actions_on_reject: []
# One or more regex patterns that the filename must match (e.g. "^PHOTO_.*"). Delimiters are optional.
allowed_patterns: []
# One or more regex patterns that the filename cannot match (e.g. "\.tmp$"). Delimiters are optional.
disallowed_patterns: []
# One or more file extensions that are allowed.
allowed_extensions: []
# One or more file extensions that are not allowed.
disallowed_extensions: []
# One or more MIME types that are allowed.
allowed_mime_types: []
# One or more MIME types that are not allowed.
disallowed_mime_types: []

image_colorspace​

Analyzes the colorspace of an image file and rejects it if its colorspace is not in the allowed list or is in the disallowed list. Non-image files are skipped.

-
name: image_colorspace # Required
max_severity: Critical # One of "debug"; "info"; "warning"; "error"; "critical"
# One of: quarantine, move_to_trash, delete
actions_on_reject: []
# One or more colorspaces that are allowed (rgb, srgb, cmyk, grayscale, ycbcr, ycck, indexed, cielab, unknown).
allowed_colorspaces: []
# One or more colorspaces that are not allowed.
disallowed_colorspaces: []

image_dimension​

Analyzes the dimensions of an image file and rejects it if its width or height falls outside the configured minimum/maximum bounds. Non-image files are skipped.

-
name: image_dimension # Required
max_severity: Critical # One of "debug"; "info"; "warning"; "error"; "critical"
# One of: quarantine, move_to_trash, delete
actions_on_reject: []
# Minimum image width in pixels (inclusive).
min_width: ~
# Maximum image width in pixels (inclusive).
max_width: ~
# Minimum image height in pixels (inclusive).
min_height: ~
# Maximum image height in pixels (inclusive).
max_height: ~