[Info-vax] Date field in MAIL.MAI record?

Hein RMS van den Heuvel heinvandenheuvel at gmail.com
Mon Jul 11 18:41:51 EDT 2011


On Jul 11, 10:44 am, Hein RMS van den Heuvel
<heinvandenheu... at gmail.com> wrote:
> On Jul 11, 7:36 am, gartm... at nonsense.immunbio.mpg.de (Christoph
>
> Gartmann) wrote:
> > Hello,
>
> > anyone out there familiar with the structure of MAIL.MAI records?

The mail HEADER record has a time&date as primary key starting at byte
0.
It is followed by a byte-count for the folder name and the foldername.
The 39 byte foldername is the alternate key, with null-key bye binary
0.
This is followed by a message number which is the word shifted date
again
with a two MSB bytes which are lower than any reasonable date (0005)

For short message the message number become the primary key for a
second
record in MAIL.MAI with all the text. The foldername is set to all
binary 0 in the message record, such that no alternate (folder) key
index entry is made.

For foreign messages and long message (> 1500 bytes) the message
number
becomes part of the file name for the external file.
This is how 'orphan' detectors can work, and how you can sort of
reconstruct an MAIL.MAI file from the raw messages.... or at least the
content + date.

Example data below.
Hth,
Hein

$ keys mail.mai

# LVL DB IB DTP TKS POS NUL  Root-VBN  Data-VBN Name
-- -- -- -- --- --- --- --- --------- --------- MAIL.MAI
 0  1  5  5 BN8   8   0            19         4
 1  1  3  3 STG  39   9   0        28        25

$ dump/reco=(start=278,count=1) [.vmsmail]mail.mai/wid=80

Record number 278 (00000116), 171 (00AB) bytes, RFA(0105,0000,0010)

 41424554 5341570B 00AA9E21 31810000 ...1!.ª..WASTEBA 000000
 00000000 00000000 00000000 54454B53 SKET............ 000010
 00000000 00000000 00000000 00000000 ................ 000020
 000500AA 9E213181 00000000 00000000 .........1!.ª... 000030
 00000000 00000000 00000000 00140007 ................ 000040
 4E534945 00280000 00000000 00000000 ..........(.EISN 000050

Now look at the "00AA 9E213181" pattern at offset 0 and 0x38
You'll see it as again, but shifted, in the (short) message record:

$ dump/reco=(start=102,count=1) [.vmsmail]mail.mai/wid=80

Record number 102 (00000066), 438 (01B6) bytes, RFA(012D,0000,0006)

 00000000 00000000 000500AA 9E213181 .1!.ª........... 000000
 00000000 00000000 00000000 00000000 ................ 000010
 00000000 00000000 00000000 00000000 ................ 000020
 6F6C206F 6E20756F 79206649 00460000 ..F.If you no lo 000030

Cheers!



More information about the Info-vax mailing list