xref: /freebsd/contrib/file/magic/Magdir/mmdf (revision f3087bef11543b42e0d69b708f367097a4118d24)
1
2#------------------------------------------------------------------------------
3# $File: mmdf,v 1.7 2024/02/29 03:40:37 christos Exp $
4# mmdf:  file(1) magic for MMDF mail files
5# Update:	Joerg Jenderek Feb 2024
6# URL:		https://en.wikipedia.org/wiki/MMDF
7# Reference:	https://docs.oracle.com/cd/E88353_01/html/E37852/mmdf-5.html
8# Note:		Multi-channel Memorandum Distribution Facility (MMDF) mailbox format is a legacy variant of mbox format
9#		(handled by ./mail.news); each message is surrounded by lines containing 4 control-A
10#
110	string	\001\001\001\001
12# GRR: MMDF mailbox (strength=70=70+0 ./mmdf) after D64 Image (strength=70=70+0 ./c64) Targa image data (strength=70=110-40 ./images)
13# and before "PDP-11 UNIX/RT ldp" (strength=50=50+0 ./pdp)
14#!:strength +0
15# skip few Commodore disc Image where first content are initialized with ^A like "The Great Gianna Sisters.d64"
16# by looking for following valid line terminator (10=0Ah~LineFeed or 13=0Dh~CarriageReturn)
17#>4		ubyte&0xF8	=0x08	MMDF mailbox
18# or by looking for MBOX Mailbox (/mail.news) characteristic like:
19# https://github.com/dfandrich/oldmailconvert/blob/master/testdata/uupc.input.1
20>5	search/610/b		From\ 	MMDF mailbox
21#!:mime	application/octet-stream
22!:mime	message/x-mmdf
23# https://github.com/dfandrich/oldmailconvert/blob/master/testdata/maillog.expected.2
24# but default mailbox name is like /usr/spool/mail/username
25!:ext	/mmdf
26