ESMP09@SLACTWGM.BITNET (01/17/86)
The VMS MAIL program could be used to implement a primitive filing system, except for one significant defect: anyone who is allowed to read the files with MAIL is also allowed to delete them (or to delete entries therein). I have suggested to DEC that they supply a /READONLY qualifier for the MAIL> SET FILE command to get around this deficiency, and encourage you to do likewise if you can see a use for such functionality. Of course, some of us are not so patient, and might be tempted to tamper with MAIL.EXE to achieve the above end without waiting what could be an eternity for DEC to satisfy the request. It turns out that by patching a single word in MAIL.EXE, a read-only version of the MAIL program can be created which works satisfactorily for this purpose. Some characteristics of the patched program: It gains READONLY access to the input mail file (the user's default file, or the one specified with MAIL>SET FILE filename), but only if the process has READ privilege for that file. Commands which would modify the input file are effectively disabled; examples are DELETE, PURGE, and FILE (or COPY) to a folder in the same file. The commands FORWARD, COPY (to another file), EXTRACT, and PRINT still function normally, so the reader can get his own copies of entries as desired. My patch applies to VMS 4.2, but it should be easy to find the patch address in future versions, even without benefit of a source listing. (I have checked a VMS 4.4 test site copy of MAIL.EXE, and the patch address is unchanged.) Should anyone be interested in obtaining a copy of the patch information and other details, I would be happy to send it (mail systems willing). Ed Miller ESMP09@SLACTWGM.BITNET