FeatureFuel
1

Extend recoverable PDF handling to attachments

Source: paperless-ngx/paperless-ngx#14080 · opened by @reger-p
Description The mail consumer rejects PDF attachments when libmagic detects them as application/octet-stream, even though the normal document consumer explicitly supports recovering exactly this case using qpdf. The affected email attachment is correctly declared as a PDF in the MIME structure: Content-Type: application/pdf; name=sample.pdf Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename=sample.pdf However, content-based MIME detection identifies the extracted attachment as: application/octet-stream The affected PDF contains additional bytes before the PDF data/signature. The beginning of the original file is approximately: TEXTmdos\x00\x015 %PDF-1.4 Therefore, the PDF signature does not occur at byte offset 0. The affected real-world file identifies itself with the following PDF metadata: PDF version: 1.4 Creator: Omnis Studio v11.1 Producer: Brainy Data PDFDevice v5.2.1.0 for Win64 This appears to be why libmagic does not initially recognize th…

No pledges yet. Be the first to back this.

Make a pledge

Pledge your monetary support if this feature is added.

$

Comments

No comments yet.

Replying to

Add a comment

What do you think about this feature request?


Similar requests