Bug 7598 - sa-learn should detect if mails are compressed without looking at the extension
Summary: sa-learn should detect if mails are compressed without looking at the extension
Status: RESOLVED FIXED
Alias: None
Product: Spamassassin
Classification: Unclassified
Component: Learner (show other bugs)
Version: 3.4.1
Hardware: All All
: P2 enhancement
Target Milestone: 4.0.0
Assignee: SpamAssassin Developer Mailing List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-08-21 20:35 UTC by Laurent Bigonville
Modified: 2022-04-14 11:50 UTC (History)
2 users (show)



Attachment Type Modified Status Actions Submitter/CLA Status

Note You need to log in before you can comment on or make changes to this bug.
Description Laurent Bigonville 2018-08-21 20:35:28 UTC
Hi,

dovecot allows you to compress the files in an IMAP Maildir, but these files don't have the (.gz,.bz2,.xz) extension

It would be nice if sa-learn was detecting that the file are compressed without looking at the file name

That would make it easier to learn a big quantity of files in a directory
Comment 1 Henrik Krohns 2022-04-14 11:03:45 UTC
ArchiveIterator cleanups
- Uncompress gzip regardless of extension (Bug 7598)
- Add .xz support

Sending        trunk/UPGRADE
Sending        trunk/lib/Mail/SpamAssassin/ArchiveIterator.pm
Sending        trunk/lib/spamassassin-run.pod
Sending        trunk/sa-learn.raw
Transmitting file data ....done
Committing transaction...
Committed revision 1899843.
Comment 2 Henrik Krohns 2022-04-14 11:50:45 UTC
Further ArchiveIterator improvements, all of gzip/bzip2/xz/lz4/lzip/lzo are now detected and uncompressed automatically.

Sending        trunk/lib/Mail/SpamAssassin/ArchiveIterator.pm
Sending        trunk/lib/spamassassin-run.pod
Sending        trunk/sa-learn.raw
Transmitting file data ...done
Committing transaction...
Committed revision 1899848.