Table of Contents

Class SpamAssassinScannerProfile

Namespace
MailFathom.Infrastructure.Spam
Assembly
MailFathom.Infrastructure.dll

Where the spam daemon is and what a call to it is allowed to cost.

public sealed record SpamAssassinScannerProfile : IEquatable<SpamAssassinScannerProfile>
Inheritance
SpamAssassinScannerProfile
Implements
Inherited Members

Remarks

The daemon is expected to be deployment-local. Scanning is the one path that hands a whole message to a separate process, and what makes that acceptable is that the process is inside the same trust boundary; an address on the public internet sends the owner's mail, in full and unredacted, to somebody else in order to find out whether it is spam. Nothing here refuses one, because a deployment may legitimately run one daemon for several services on its own network and no rule about addresses tells the two apart, and the documentation states what is given up.

All three bounds are this adapter's rather than the caller's, because each is a property of the daemon rather than of classification: the size limit is what a rule corpus can usefully read, the timeout is how long one scan may take, and the concurrency is matched to the daemon's own child limit. A message that exceeds any of them leaves the classification with its deterministic verdict.

Fields

DefaultPort

The port a deployment that named none reaches the daemon on.

Properties

Endpoint

Gets the address this profile reaches, for a caller with somewhere safe to record it.

Host

Gets the daemon's host name or address.

MaximumConcurrentScans

Gets how many exchanges may be in flight at once.

MaximumMessageBytes

Gets the largest message that is sent to the daemon at all.

Port

Gets the TCP port it listens on.

ScanTimeout

Gets how long one exchange may take before it is abandoned.

Methods

Create(string, int, TimeSpan, int, int)

Composes the profile a configured daemon is reached under.