diff --git a/batch/batch.go b/batch/batch.go index d4c0d6d6d32b3fb02d09217c683bd0ee1ce55760..e22082baa387bc879e0f31f5921e2363c1e63664 100644 --- a/batch/batch.go +++ b/batch/batch.go @@ -20,9 +20,6 @@ import ( //go:embed crontab var crontabTemplate string -//go:embed announcement-2.06.txt -var announce206 string - // Reboot deletes all messages with `shutdown` set. func Reboot() int { ctx := storage.Context() @@ -73,7 +70,19 @@ func Install() int { q := storage.New(store.DB) // Create the initial users. + fmt.Println(`Welcome to the BULLETIN install process. This will create +the following files: + + * ~/.local/share/BULLETIN/bulletin.db - BULLETIN's folder and user db. + * ~/.bulletin-installed - A file to make sure install isn't run again. + * ~/.config/BULLETIN/* - history files for each user. + * ~/.ssh/authorized_keys - key lines to let users connect to BULLETIN + +To complete the installation, please enter the login, name and ssh key for +the first user. +`) login, err := ask.GetLine("Enter login of initial user: ") + login = strings.ToUpper(login) ask.CheckErr(err) name, err := ask.GetLine("Enter name of initial user: ") ask.CheckErr(err) @@ -81,21 +90,38 @@ func Install() int { ask.CheckErr(err) // Seed data. + seedMsgs, err := GetSeedMessages() + ask.CheckErr(err) ask.CheckErr(q.SeedUserSystem(ctx)) ask.CheckErr(q.SeedFolderGeneral(ctx)) ask.CheckErr(q.SeedGeneralOwner(ctx)) - ask.CheckErr(q.SeedCreateMessage(ctx, storage.SeedCreateMessageParams{ - Folder: "GENERAL", - Folder_2: "GENERAL", - Subject: "Announcing PFC BULLETIN 2.06", - Message: announce206, - Expiration: time.Now(), - })) _, err = q.AddUser(ctx, storage.AddUserParams{ Login: login, Name: name, }) key.Add(login, sshkey) + userCreated := map[string]bool{ + "SYSTEM": true, + login: true, + } + for i := range seedMsgs { + if !userCreated[seedMsgs[i].Login] { + _, err = q.AddUser(ctx, storage.AddUserParams{ + Login: seedMsgs[i].Login, + Name: seedMsgs[i].Name, + }) + ask.CheckErr(err) + userCreated[seedMsgs[i].Login] = true + } + ask.CheckErr(q.SeedCreateMessage(ctx, storage.SeedCreateMessageParams{ + Folder: "GENERAL", + Author: seedMsgs[i].Login, + Subject: seedMsgs[i].Subject, + Message: seedMsgs[i].Message, + CreateAt: seedMsgs[i].Date, + Expiration: time.Now(), + })) + } // Install crontab. bulletin, err := os.Executable() diff --git a/batch/messages.go b/batch/messages.go new file mode 100644 index 0000000000000000000000000000000000000000..cd6a6c329de4640e212ddf4f894a6b11d86d5c7d --- /dev/null +++ b/batch/messages.go @@ -0,0 +1,95 @@ +package batch + +import ( + "embed" + "fmt" + "io/fs" + "path" + "strings" + "time" +) + +//go:embed seed/* +var messagesFS embed.FS + +// SeedMessage is the struct version of the messages. +type SeedMessage struct { + Login string + Name string + Date time.Time + Subject string + Message string +} + +// GetSeedMessages gets the embedded seed messages and returns them in +// a data structure. +func GetSeedMessages() ([]SeedMessage, error) { + var messages []SeedMessage + + entries, err := fs.ReadDir(messagesFS, "seed") + if err != nil { + return nil, fmt.Errorf("reading directory: %w", err) + } + + for _, entry := range entries { + if entry.IsDir() { + continue + } + + data, err := fs.ReadFile(messagesFS, path.Join("seed", entry.Name())) + if err != nil { + return nil, fmt.Errorf("reading file %s: %w", entry.Name(), err) + } + + lines := strings.Split(string(data), "\n") + if len(lines) < 4 { + continue // skip malformed + } + + // Extract fields + var login, name, subj string + var date time.Time + + for i := 0; i < 3; i++ { + line := strings.TrimSpace(lines[i]) + switch { + case strings.HasPrefix(line, "From: "): + rest := strings.TrimPrefix(line, "From: ") + parts := strings.SplitN(rest, `"`, 2) + if len(parts) == 2 { + login = strings.TrimSpace(strings.TrimSuffix(parts[0], " ")) + name = strings.Trim(parts[1], `"`) + } else { + login = rest + } + case strings.HasPrefix(line, "Date: "): + datestr := strings.TrimPrefix(line, "Date: ") + // Expected format: 01-JAN-1982 12:00 + date, err = time.Parse("02-Jan-2006 15:04", datestr) + if err != nil { + return nil, fmt.Errorf("parsing date in %s: %w", entry.Name(), err) + } + case strings.HasPrefix(line, "Subj: "): + subj = strings.TrimPrefix(line, "Subj: ") + } + } + + // Find start of message body + bodyIndex := 3 + for bodyIndex < len(lines) && strings.TrimSpace(lines[bodyIndex]) != "" { + bodyIndex++ + } + body := strings.Join(lines[bodyIndex+1:], "\n") + + msg := SeedMessage{ + Login: login, + Name: name, + Date: date, + Subject: subj, + Message: body, + } + messages = append(messages, msg) + } + + return messages, nil +} diff --git a/batch/seed/1982b-aaareadme.txt b/batch/seed/1982b-aaareadme.txt new file mode 100644 index 0000000000000000000000000000000000000000..c03dad31fef7917a7de0dcf35d4eaa963706fcf8 --- /dev/null +++ b/batch/seed/1982b-aaareadme.txt @@ -0,0 +1,56 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1982 12:00 +Subj: BULLETIN utility. + + BULLETIN + + BULLETIN provides an effective means for the system +managers to disseminate information to users in a friendly +fashion. + + Features + + o Bulletins of general interest can be sent to all + users + o Bulletins can be filed by subject for perusal by + interested users + o Users are presented with bulletins only once + (unless they request old ones) + o Users are informed of new information on + specialized topics only once + o Users may optionally file or print bulletins + + + Setting up + +The nicest feature about bulletin is its friendly nature. +Unwanted and indecipherable information is not forced down a +users' throats, but is there for any interested user. Thus, +for example, if you file a bulletin under the subject of +PASCAL, all users will be informed (only once!) that there +is new information on PASCAL. Interested users can read the +new bulletins, while those not using PASCAL can ignore them. +There are three things to set up for most effective use of +the program. + + 1. Put the BULLETIN help file in your system help + file: + $ LIBR/HELP SYS$HELP:HELPLIB BULLETIN + + + 2. If you have a system wide login.com file, you + should enter the command: + $ if "''f$mode()" .eqs. "INTERACTIVE" then - + $bulletin + If you enter this command before enabling + control-Y, this will force users to read new + BULLETINS filed under the general interest + category. + + 3. Encourage users to place in their personal + LOGIN.COM files BULLETIN commands to read + information on subjects of interest to them. + + +Refer to the first bulletin and the HELP BULLETIN command +for more info. diff --git a/batch/seed/1982b-bcmail.txt b/batch/seed/1982b-bcmail.txt new file mode 100644 index 0000000000000000000000000000000000000000..1887b7ba38fb27476f6d3c93c40f628db3a86ca0 --- /dev/null +++ b/batch/seed/1982b-bcmail.txt @@ -0,0 +1,14 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1982 12:00 +Subj: BULLETIN utility. + + + Some users have missed bulletins of interest to them either because +they missed the announcement that there were new bulletins on a subject, or +for other reasons. I am sending you a list of subjects which contain bull- +etins you have not read as of this mailing. If you do not wish to read any +of them, please ignore this letter. You may read new bulletins on a given +subject by typing "BULL/SUB=subject". You should include this command for +subjects of interest in your login command file (login.com), so that you +will always get the lastest information. + diff --git a/batch/seed/1982b-bullintro.txt b/batch/seed/1982b-bullintro.txt new file mode 100644 index 0000000000000000000000000000000000000000..e4c4e92e992486101bd05e5cf86fd39c23e54b37 --- /dev/null +++ b/batch/seed/1982b-bullintro.txt @@ -0,0 +1,27 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1982 12:00 +Subj: BULLETIN utility. + +This program displays bulletins of general interest. You may get information +on how to use it by typing "HELP BULLETIN". When you log in, the program will +print messages you have not yet read (unless you ask for old messages). It +will also tell you when new messages have been added on possible topics of +interest, but you must specifically ask to read these messages. You may wish +to put "BULL/SUBJECT=subject" in your login.com file for those subjects in +which you are interested. Those subjects on which there are bulletins can be +listed by typing "BULL/DIRECTORY". + +At the end of each message (as below), the program will allow you to select +various options. Typing "Go" will cause all messages to be displayed without +further interruption (except at the bottom of the screen). Typing "Quit" will +discontinue the bulletins, but they will all be typed again the next time you +login (or ask for bulletins). Typing "File" will save the preceding message in +a file named "AAASYSBUL.BUL" or "subject.BUL" on your login directory, while +typing "Print" will print the bulletin. A carriage return will proceed to the +next message. + + *** NOTE *** + +Do not delete your file SYS$LOGIN:SYSBULL.DAT! This file remembers which +bulletins you have read and not read. Deleting it will cause BULLETIN to +recreate it next time, and assume you have read no bulletins! diff --git a/batch/seed/1985c-aaareadme.txt b/batch/seed/1985c-aaareadme.txt new file mode 100644 index 0000000000000000000000000000000000000000..015f9ada9abfe2f718d04f5e517f3a7efbdd7bee --- /dev/null +++ b/batch/seed/1985c-aaareadme.txt @@ -0,0 +1,24 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1982 12:00 +Subj: BULLETIN utility. + + + Mark London + MIT Plasma Fusion Center + 167 Albany St. NW16-262 + Cambridge, MA 02139 + MRL%PFCVAX@ZERMATT + + + This submission contains a new version of BULLETIN, a bulletin + board/announcement system for VMS. ANNOUNCE.MAI describes the + features added and bugs corrected, including a change to the BBOARD + feature which broke with VMS version 4. + + See AAAREADME.DOC for instructions on building BULLETIN. + + Librarian's note: This package was copied from the ARPANET and + put on the tape with the permission of the author. Since I have + expanded but not compiled and run the programs/procedures I am + including the raw mail files as I got them from the net in + [.NET_FILES]. diff --git a/batch/seed/1985c-announce.mai b/batch/seed/1985c-announce.mai new file mode 100644 index 0000000000000000000000000000000000000000..a95c8a70410ccdb744d5f163c71b60405a760722 --- /dev/null +++ b/batch/seed/1985c-announce.mai @@ -0,0 +1,79 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 10:58 +Subj: New version of BULLETIN + +A new version of BULLETIN is now available. BULLETIN is a bulletin program +that I wrote to use under VMS until DEC comes up with their own. (A +description follows after the next couple of paragraphs.) The new version +fixes the BBOARD feature, which breaks under VMS V4.0, plus a few random bugs. +Some of the new features are: + +The command /NODE has been created to the ADD command in order to add bulletins +to other DECNET nodes. All features of the ADD command will apply to the +bulletin added to the other DECNET nodes. (i.e. /BROADCAST, etc.) +The command /EDIT has been created to the ADD command (similar to SEND/EDIT in +MAIL). System bulletins displayed upon logging do not run off the end of screen +if they are too large. Instead, the output is stopped at the end of the screen +and awaits a prompt. +Bulletins written by the FILE command include a header comment (controlled +by the /HEADER qualifer). + +A few minor changes: +The /BELL qualifier has been added to make it optional whether to include a bell +with a broadcasted bulletin. +A user can now enable prompting for reading non-system bulletins by using +the SET READNEW command rather than adding a BULLETIN/READNEW line in his login, +thus eliminating an addition image execution. +BULLETIN/SYSTARTUP is no longer necessary. (SHUTDOWN bulletins are +automatically deleted). + +(Future plans: I'm in the process of modifying bulletin to work with multiple +bulletin boards files.) + +------------------------------------------------------------------------------ + +Description of BULLETIN utility: + +Easy to use utility to submit and read bulletins. Similar to mail utility. +Users are notified of bulletins only once. They're not forced into reading +them every time they log in. + +SYSTEM bulletins are displayed in full. Only privileged users can submit them. +Any non-privileged users can submit non-system bulletins. Only the "subjects" +of these bulletins are displayed at login. The user can decide if the +bulletins are worthwhile reading. (There is also an optional feature which, if +installed, will ask a user upon logging in whether he or she wants to read +the non-system bulletins or not, and if so, they are automatically displayed. +The alternative is to let the user manually enter the commands in order to read +the bulletins.) +Privileged users can broadcast their bulletin to users that are logged +in. This allows you to get your message across to both logged in users +and non-logged in users. +Bulletins have expiration dates and are deleted automatically. +Privileged users can specify "SHUTDOWN" bulletins, i.e. bulletins that get +deleted after a system shutdown has occurred. +An optional feature allows non-system bulletins to be created by users of +other systems connected via networks. This "Bulletin Board" feature is on +several computers on the ArpaNet. This is accomplished by sending mail +to the dummy user BBOARD. (These bulletins expire after 7 days). +There is also a much more sophisticated optional feature which allows adding +bulletins to DECNET nodes from within the BULLETIN the utility (see the +ADD command). +This bulletin program does not create lots of files. It needs only 3 data +files. Neither does it create any additional processes (all events are +triggered by people logging in). + +---------------------------------------------------------------------------- + +Our VAX is not directly on the ArpaNet, so if you desire the sources, send +me your request and I will send the sources via mail. + +There are some command procedures for installation included. However, they +are pretty crude, as I have not had time to write something more sophisticated. +(P.s. If you already have an old version of the bulletin utility, you should +create the version in a different directory, as the command procedure is not +smart enough to delete obsolete files.) + + Mark R. London + MRL%PFCVAX@MC + diff --git a/batch/seed/1985c-bullet.mai b/batch/seed/1985c-bullet.mai new file mode 100644 index 0000000000000000000000000000000000000000..ce0945eac3d9783783516bbc24027601cb4947ab --- /dev/null +++ b/batch/seed/1985c-bullet.mai @@ -0,0 +1,950 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 10:58 +Subj: BULLETIN + +The following are instructions for creating the BULLETIN executable and +installation of the utility. A brief explanation of how the internals +of the BULLETIN utility works can be found in BULLETIN.TXT . None of +the command procedures included here are sophisticated, so it is likely +that several modifications will have to be made by the installer. +The installer should enable all privileges before installation. + +1) CREATE.COM + This will compile and link the BULLETIN sources. Also, there are several + INCLUDE files for the fortran sources (.INC files). BULLFILES.INC must first + be modified before this procedure is run. It contains the names of data files + which BULLETIN creates. It also has the username for the BBOARD account. + BBOARD is an option by which mail sent to the specified username will be + converted into bulletins. This allows a user on a different system, which is + connected via a network, to be able to submit a bulletin. This feature can + be disabled if it is not desired by specifying the username NONE. In any + case, you should edit BULLFILES.INC and specify the appropriate device and + directories in which you desire that the files be located. (NOTE: Although + the BBOARD feature can be used over DECNET, a more sophisticated method + is available to easily allow one to add bulletins to other DECNET nodes + with all the features of BULLETIN. See below). + +2) STARTUP.COM + The data files that BULLETIN creates should be owned by a system UIC, + and MUST be protected from users being able to have access them. + STARTUP.COM sets the process UIC to [1,4] (you should change this if + you want something else), sets the WORLD and GROUP protection to NONE, + adds the bulletin found in the file INSTRUCT.TXT (it is added with + /PERMANENT, so it never expires), and then resets the UIC and PROTECTION + to what they were before running the procedure. + INSTRUCT.BUL contains a bulletin with instructions to the users as to + how to use the BULLETIN utility. You may want to modify it. + +3) INSTALL.COM + The following procedure copies the executable image to SYS$SYSTEM and + installs it with certain privileges. It also installs the necessary + help files in SYS$HELP. + +4) LOGIN.COM + This contains the comands that should be executed at login time + by SYS$MANAGER:SYLOGIN.COM. It defines the BULLETIN commands. + It also executes the command BULLETIN/LOGIN in order to notify + the user of new bulletins. If desired, the /READNEW qualifier + can also be added. If there are any new non-system bulletins, this + qualifier creates a prompt asking the user if the non-system + bulletins are to be displayed or not. Normally, only system bulletins + are displayed in full, and only the subjects of the non-system + bulletins are displayed. ( Some systems might have a lot of users + who are not interested in reading the non-system bulletins, in + which case /READNEW should probably not be added. Instead, you could + let users enable this feature by entering the BULLETIN utility and + typing the command SET READNEW ). (NOTE: Since /LOGIN and /READNEW + are system commands, they are not included in the help file). + +5) BULLSTART.COM + This procedure contains the commands that should be executed after + a system startup. It should be executed by SYS$MANAGER:SYSTARTUP.COM + as a batch job. It simply installs the BULLETIN utility with correct + privileges. + +6) BULLETIN.COM + If one wants the feature of using BULLETIN between DECNET nodes, + this file must be put in each node's DECNET default user's directory + (usually [DECNET]). Once this is done, the /NODE qualifer for the + ADD command can be used. + NOTE: Presently, privileged functions such as /SYSTEM will work + on other nodes only if you have an account on the other node with + the same username, and with appropriate privileges. You will be + prompted for the password for the account on the remote node. However, + due to unknown reasons, the software I have to check the password will + only work for passwords that have been set under V4.x. If the password + was created under V3.x, the program will not work, and you password will + be treated as invalid. +$ SET PROTECT=(W:RWED)/DEFAULT +$ MAIL +READ +EXTRACT/ALL USRD$:[BBOARD]BBOARD.MAI +DELETE/ALL + MODULE BULLETIN_SUBCOMMANDS + + DEFINE VERB ADD + PARAMETER P1, LABEL = FILESPEC, VALUE(TYPE=$FILE) + QUALIFIER BELL + QUALIFIER BROADCAST + QUALIFIER EDIT + QUALIFIER NODES, LABEL=NODES, VALUE(REQUIRED,LIST) + QUALIFIER PASSWORD, LABEL=PASSWORD, VALUE(REQUIRED) + QUALIFIER PERMANENT + QUALIFIER SHUTDOWN + QUALIFIER SYSTEM + QUALIFIER USERNAME, LABEL=USERNAME, VALUE(REQUIRED) + DEFINE VERB BACK + DEFINE VERB DELETE + PARAMETER P1, LABEL = BULLETIN_NUMBER, VALUE(TYPE=$FILE) + DEFINE VERB DIRECTORY + DEFINE VERB EXIT + DEFINE VERB FILE + PARAMETER P1, LABEL = FILESPEC, VALUE(TYPE=$FILE,REQUIRED), + PROMPT="File" + QUALIFIER HEADER, DEFAULT + DEFINE VERB HELP + PARAMETER P1, LABEL = HELP_TOPIC, VALUE(TYPE=$REST_OF_LINE) + DEFINE VERB NEXT + DEFINE VERB READ + PARAMETER P1, LABEL = BULLETIN_NUMBER, VALUE(TYPE=$NUMBER) + DEFINE VERB REPLACE + PARAMETER P1, LABEL = FILESPEC, VALUE(TYPE=$FILE) + QUALIFIER EXPIRATION + QUALIFIER HEADER + QUALIFIER NUMBER, VALUE(TYPE=$NUMBER,REQUIRED) + QUALIFIER TEXT + DEFINE VERB SET + PARAMETER P1, LABEL = SET_PARAM1, VALUE(REQUIRED), + PROMPT="What" +1 ADD +Adds a bulletin to the bulletin file. A file can be specified which +contains the bulletin. Otherwise, BULLETIN will prompt for the text. +BULLETIN will ask for an expiration date and a header to contain the +topic of the bulletin. + +Format + ADD [file-name] + +All the qualifiers except for /EDIT and /NODES are restricted to users +with SETPRV privileges. +2 /BELL +This option is restricted to privileged users. It is used in conjunction +with the /BROADCAST qualifier. If specified, the bell is rung on the +terminals when the bulletin is broadcasted. +2 /BROADCAST +This option is restricted to privileged users. If specified, bulletin +is both saved in the bulletin file and broadcasted to all users logged +in at the time. +2 /EDIT +Determines whether or not the EDT editor is invoked to edit the bulletin +you are sending. +2 /NODES=(nodes[,...]) +Specifies to send the bulletin to other DECNET nodes. The BULLETIN utility +must be installed properly on the other nodes. You will prompted for the +username to use at the other node. If you give a different username than +that of the local node, or if privileged qualifiers are specified, you will +be prompted for the password of your account on the other nodes. At +present, if the password is invalid, the bulletin will be rejected on the +node, but no error message will be displayed on the local node that this +happened. +2 /PERMANENT +This option is restricted to privileged users. If specified, bulletin +will be a permanent bulletin and will never expire. +2 /SHUTDOWN +This option is restricted to privileged users. If specified, bulletin +will be automatically deleted after a computer shutdown has occurred. +2 /SYSTEM +This option is restricted to privileged users. If specified, bulletin +is both saved in the bulletin file and displayed in full as a system +notice when a user logs in. System notices should be as brief as possible +to avoid the possibility that system notices could scroll off the screen. +1 BACK +Displays the bulletin preceding the current bulletin. +1 DELETE +Deletes the specified bulletin. If no bulletin is specified, the current +bulletin is deleted. Only the original owner or a privileged user can +delete a bulletin. + +Format + DELETE [bulletin-number] + +The bulletin's relative number is found by the DIRECTORY command. +1 DIRECTORY +Lists a summary of the bulletins. The bulletin number, submitter's name, +date, and subject of each bulletin is displayed. +1 EXIT +Exits the BULLETIN program. +1 FILE +Copies the current bulletin to the named file. The file-name parameter +is required, and consists of up to 9 alpha-numeric characters in length. + +Format: + FILE file-name +2 /HEADER + +/[NO]HEADER + +Controls whether a header containing the owner, subject, and date of the +bulletin is written in the file. The default is to write the header. +1 Bulletin +The BULLETIN utility permits a user to create a bulletin for reading by +all users. Users are notified upon logging in that new bulletins have +been added, and what the topic of the bulletins are. Actual reading of +the bulletins is optional. (See the command SET READNEW for info on +automatic reading.) Bulletins are automatically deleted when their +expiration date has passed. + +1 HELP +To obtain help on any topic, type: + + HELP topic +1 NEXT +Skips to the next bulletin and displays it. This is useful when paging +through the bulletins and you encounter a particularly long bulletin +that you would like to skip over. +1 READ +Displays the specified bulletin. If you do not specify a bulletin, then +the first time you enter the command, the oldest bulletin will be +displayed. However, if there are new bulletins, the first new bulletin +will be displayed. Each time you enter the command, the next page, or if +there are no more pages, the next bulletin will be displayed. + +Format + READ [bulletin-number] + +The bulletin's relative number is found by the DIRECTORY command. + +Pressing just <RETURN> performs the same as the READ command. +1 REPLACE +Replaces an existing bulletin in the bulletin file. This is for changing +part or all of a bulletin without causing users who have already seen the +bulletin to be notified of it a second time. If the text of the bulletin +is to be changed, a file can be specified which contains the text. +Otherwise, BULLETIN will prompt for the text. The expiration date and +header can also be changed. If neither /EXPIRATION, /HEADER, nor /TEXT +are specified, it is assumed the whole bulletin will be replaced. + +Format + REPLACE [file-name] +2 /EXPIRATION +Specifies that the bulletin expiration date is to be replaced. +2 /HEADER +Specifies that the bulletin header is to be replaced. +2 /NUMBER=n +Specifies the bulletin number to be replaced. If this qualifier is +omitted, the bulletin that is presently being read will be replaced. +2 /TEXT +Specifies that the bulletin text is to be replaced. +1 SET +Defines or changes characteristics associated with automatic reading +of bulletins. + +Format: + + SET option +2 READNEW +Controls whether you will be prompted upon logging in if you wish to read +new non-system bulletins (if any exist). The default is that you are not +prompted. (Previously this was done by including the BULLETIN/READNEW +command in one's login command procedure). + + Format: + + SET [NO]READNEW + COMMON /BULL_DIR/ DESCRIP,FROM,DATE,TIME,BLOCK,LENGTH,EXDATE + & ,NEWEST_EXDATE,NEWEST_DATE,NEWEST_TIME,SYSTEM,NBULL,NBLOCK + & ,SHUTDOWN,SHUTDOWN_DATE,SHUTDOWN_TIME + CHARACTER*53 DESCRIP + CHARACTER*12 FROM + CHARACTER*11 DATE,EXDATE,NEWEST_EXDATE,NEWEST_DATE,SHUTDOWN_DATE + CHARACTER*8 TIME,NEWEST_TIME,SHUTDOWN_TIME + LOGICAL SYSTEM +$ DEFINE SYS$INPUT SYS$NET +$ BULLETIN +1 BULLETIN +Invokes the PFC BULLETIN Utility. This utility is used for reading, adding +and deleting bulletins. Any user can submit a bulletin. Users are +notified at login time that new bulletins have been added and the topics of +those bulletins are displayed. Reading of those bulletins is optional. +(Use the command SET READNEW while in BULLETIN for setting automatic +reading.) Privileged users can add system bulletins that are displayed +in full at login time. These bulletins are also saved, and can be read +by BULLETIN. Bulletins are automatically deleted after a specified +expiration date, or they can manually be deleted by either the submitter +of the bulletin or a privileged user. + +BULLETIN has an interactive help available while using the utility. + + Format: + + BULLETIN +$ LINK/NOTRACE BULLETIN,HPWD,BULLSUBS,BULLCOM,BULLMAIN,CLIDEF,USEROPEN,SETUSER,SETUIC,- +SYS$SYSTEM:SYS.STB/SEL +This file describes the general operation of the BULLETIN utility. + +BULLETIN uses 3 files to store its data: BULLETIN.DAT, BULLDIR.DAT, & +BULLUSER.DAT. These files are opened with the shared attribute as much as +possible to allow simultaneous operations on the files. However, when a +bulletin is added or deleted, the file cannot be shared, as this might cause +the file to be corrupted. Because of this problem, files are closed as soon as +possible so that it may be quickly opened for adding and deleting files. +During read operations, the information is passed to temporary storage, the +file is closed, and then the information is sent to the terminal. This avoids a +possible problem where the terminal output is stopped by the user, therefore +delaying the closing of the file. Also, the use of CTRL-Y & CTRL-C is disabled +while the file is opened to avoid lockout problems. + +BULLETIN.DAT stores the actual bulletins in a fixed 80 character length file. +Bulletins are store sequentially datewise. New bulletins are appended to the +end of the file. When a bulletin is deleted, all the following bulletins are +moved up in the file to remove the gap, and the file is then truncated to +remove the unused space. + +BULLDIR.DAT is a fixed record length file storing directory entries for each +bulletin in BULLETIN.DAT. Each entry contains the header information, length, +and starting record position in BULLETIN.DAT. The first line of BULLDIR.DAT is +a header containing the date of the next expiration that will occur, the date +of the latest sumbitted bulletin, the number of bulletins, and the total size +of BULLETIN.DAT. The last two numbers make it easier to add bulletins. The +directory entries then follow, again stored sequentially datewise. + +NOTE: There are several advantages to keeping a seperate directory file versus +storing the header information with the actual bulletin. Obviously, it avoids +having to scan through a large bulletin file just to extract header +information. This operation is done when a DIRECTORY listing is requested in +BULLETIN. More importantly when a login occurs, non-system bulletins just +require that the header information be displayed. Having a file with pointers +to where the bulletin is stored also avoids requiring the software to read all +the previous bulletins in order to arrive at the desired bulletin. The main +disadvantage is the extra time spent on locating the second file. This time +appears to be minimal. In all the software, the convention is to open the +directory file first, and then if needed to open the bulletin file. When +adding and delete files, this becomes important, as files are opened unshared. +A deadlock might occur if one user opens the bulletin file first while another +user opens the directory file, and then each try to open the alternate file. + +BULLUSER.DAT is a relative indexed file, where the keyword is the username of +the user. Each entry contains the latest time that the user logged in, plus +the latest time that the BULLETIN utility was used to read bulletins. A header +entry with a blank username stores the latest bulletin date. The information +in this file is used for checking to see if the user should be alerted to new +bulletins or not. +C +C THE FIRST 3 FILES ARE FILES CREATED AND USED BY BULLETIN. +C SEE BULLETIN.TXT FOR MORE INFORMATION. SPECIFY THE DEVICE/DIRECTORY +C IN WHICH YOU DESIRE THAT THEY BE KEPT. THE FOURTH FILE IS SIMPLY +C THE MAIL FILE FROM WHICH MESSAGES ARE CONVERTED TO NON-SYSTEM +C BULLETINS (AFTER WHICH THE MAIL IS DELETED.) IF YOU DO NOT WISH +C THE BBOARD OPTION, CHANGE THE DEFINITION FOR BBOARD TO BE: /'NONE'/. +C IF IT IS NOT SELECTED, YOU DO NOT HAVE TO MODIFY THE REST OF THE +C BBOARD VARIABLES. IF IT IS SELECTED, YOU MUST SPECIFY THE UIC +C NUMBER OF THE BBOARD ACCOUNT. YOU MUST ALSO SPECIFY BBOARD_FILE, +C WHICH IS A TEMPORARY FILE WHICH IS USED TO CONVERT THE BBOARD MAILn +C TO A SEQUENTIAL FILE. +Cn + COMMON /FILES/ BULLDIR_FILE,BULLETIN_FILE,BULLUSER_FILE,BBOARD_USER + COMMON /FILES/ BBOARD_UIC,BBOARD_FILE,BBOARD_COMMANDt + CHARACTER*80 BULLDIR_FILE /'IML$EXE:BULLDIR.DAT'/ + CHARACTER*80 BULLETIN_FILE /'IML$EXE:BULLETIN.DAT'/ + CHARACTER*80 BULLUSER_FILE /'IML$EXE:BULLUSER.DAT'/ + CHARACTER*12 BBOARD_USER /'BBOARD'/,BBOARD_UIC/'[330,5]'/ + CHARACTER*80 BBOARD_FILE/'USRD$:[BBOARD]BBOARD.MAI'/ +CT +C THE BBOARD.COM IS INCLUDED WITH THE SOURCES AND IS USED IF THE BBOARD +C FEATURE IS DESIRED. IT IS NOT CREATED, SO YOU MUST MOVE IT TO THEs +C DESIRED DIRECTORY. YOU MUST ALSO EDIT IT SO THAT THE FILE SPECIFIEDm +C IN THE 'EXTRACT' LINE MATCHES THE FILE SPECIFIED BY BBOARD_FILE. +C + CHARACTER*80 BBOARD_COMMAND/'IML$EXE:BBOARD.COM'/ + PARAMETER ADD_FLAG = '1'X + PARAMETER BACK_FLAG = '2'Xt + PARAMETER DELETE_FLAG = '4'X + PARAMETER DIRECTORY_FLAG = '8'X + PARAMETER EXIT_FLAG = '10'X + PARAMETER FILE_FLAG = '20'X + PARAMETER HELP_FLAG = '40'X + PARAMETER NEXT_FLAG = '80'X + PARAMETER READ_FLAG = '100'XN + PARAMETER SYSTEM_FLAG = '200'Xd + PARAMETER BROADCAST_FLAG = '400'X + PARAMETER BADSWITCH_FLAG = '800'X + PARAMETER REPLACE_FLAG = '1000'X + PARAMETER EXPIRE_FLAG = '2000'X + PARAMETER HEADER_FLAG = '4000'X + PARAMETER TEXT_FLAG = '8000'X + PARAMETER NUMBER_FLAG = '10000'Xo + PARAMETER SHUTDOWN_FLAG = '20000'XT + PARAMETER PERMANENT_FLAG = '40000'X + + COMMON /BULLPAR/ FLAGS,BULL_PARAMETER,LEN_P,NUMBER_PARAMt + CHARACTER*64 BULL_PARAMETER + INTEGER FLAGS + MODULE BULLETIN_MAINCOMMANDSf + DEFINE VERB BULLETIN + QUALIFIER READNEW + QUALIFIER LOGINh +$ RUN SYS$SYSTEM:INSTALL +SYS$SYSTEM:BULLETIN/SHARE/OPEN/HEAD/PRIV=(OPER,SYSPRV,CMKRNL) +/EXITn + + COMMON /BULL_USER/ USERNAME,LOGIN_DATE,LOGIN_TIME,READ_DATE,i + & READ_TIME,FLAGSd + CHARACTER*12 USERNAME + CHARACTER*11 LOGIN_DATE,READ_DATE + CHARACTER*8 LOGIN_TIME,READ_TIMEh + DIMENSION FLAGS(2)u + + .LIBRARY /SYS$LIBRARY:LIB.MLB/U + $CLIDEF GLOBALe + .ENDh +$ FORTRAN BULLETIN +$ FORTRAN BULLSUBS +$ MAC CLIDEF +$ MAC HPWD +$ MAC SETUIC +$ MAC SETUSERt +$ MAC USEROPEN +$ SET COMMAND/OBJ BULLCOMe +$ SET COMMAND/OBJ BULLMAIN +$ @BULLETIN.LNKM +.TITLE HPWD - hash user password +.IDENT 'V02-002' + +; This code was gotten by disassembling the AUTHORIZE program. +; It is quite shameful that DEC has not seen fit to provide +; this as a system service.: + +; If you want lots of good comments, see the fiche. + +; e _lib$code:_lib$code+68 + + +; Inputs: PWDDSC -- Addres of password descriptore +; ENCRYPT -- Encryption algorithm index (byte) +; SALT - random number (word) +; USRDSC - Address of username descriptorc + +; output: OUTDSC -- Address of encrypted output descriptor + +OUTDSC=4 +PWDDSC=OUTDSC+4 +ENCRYPT=PWDDSC+4 +SALT=ENCRYPT+4 +USRDSC=SALT+4d + +.PSECT _LIB$CODE RD,NOWRT,PIC,SHR,BYTE,EXE + +; AUTODIN-II polynomial table used by CRC algorithm +AUTODIN: + .LONG ^X000000000,^X01DB71064,^X03B6E20C8,^X026D930AC,^X076DC4190 + .LONG ^X06B6B51F4,^X04DB26158,^X05005713C,^X0EDB88320,^X0F00F9344 + .LONG ^X0D6D6A3E8,^X0CB61B38C,^X09B64C2B0,^X086D3D2D4,^X0A00AE278 + .LONG ^X0BDBDF21C + +; Purdy polynomial coefficients. Prime, but don't need to beR +Purdy_Poly:e +c: + .LONG -83,-1h + .LONG -179,-1 + .LONG -257,-1 + .LONG -323,-1 + .LONG -363,-1 + +.ENTRY LGI$HPWD,^M<R2,R3,R4> + MOVAQ @outdsc(AP),R4e + MOVAQ @4(R4),R4 + TSTB encrypt(AP) + BGTRU 10$ + MNEGL #1,R0 + MOVAQ @pwddsc(AP),R1 + CRC autodin,R0,(R1),@4(R1)E + CLRL R1i + MOVQ R0,(R4) + BRB 20$ + +10$: CLRQ (R4) + MOVAQ @pwddsc(AP),R3u + BSBB COLLAPSE_R2 + ADDW2 salt(AP),3(R4)i + MOVAQ @usrdsc(AP),R3d + BSBB COLLAPSE_R2 + PUSHAQ (R4) + CALLS #1,PURDY] + +20$: MOVL #1,R0 + RET + + +COLLAPSE_R2: + MOVZWL (R3),R0 + BEQL 20$ + MOVAL @4(R3),R2 + PUSHR #^M<R1,R2>c + MOVL R0,R1 +5$: CMPB (R2)+,#32 + BNEQ 7$ + DECL R1 +7$: SOBGTR R0,5$c + MOVL R1,R0o + POPR #^M<R1,R2> +10$: BICL3 #-8,R0,R1 + ADDB2 (R2)+,(R4)[R1]e + SOBGTR R0,10$ +20$: RSB + +a=59 +n0=1@24-3d +n1=1@24-63 + + +.ENTRY PURDY,^M<r2,r3,r4,r5> + MOVQ @4(AP),-(SP) + BSBW PQMOD_R0 + MOVAQ (SP),R4 + MOVAQ PURDY_POLY,R5 + MOVQ (R4),-(SP)p + PUSHL #n1 + BSBB PQEXP_R3 + MOVQ (R4),-(SP)d + PUSHL #n0-n1u + BSBB PQEXP_R3r + MOVQ (R5)+,-(SP) + BSBW PQADD_R0 + BSBW PQMUL_R2v + MOVQ (R5)+,-(SP) + MOVQ (R4),-(SP)A + BSBW PQMUL_R2L + MOVQ (R5)+,-(SP) + BSBW PQADD_R0M + MOVQ (R4),-(SP)M + BSBB PQMUL_R2B + MOVQ (R5)+,-(SP) + BSBW PQADD_R0A + MOVQ (R4),-(SP)U + BSBB PQMUL_R2L + MOVQ (R5)+,-(SP) + BSBW PQADD_R0L + BSBW PQADD_R0N + MOVQ (SP)+,@4(AP)S + MOVL #1,R0 + RET + +PQEXP_R3:S + POPR #^M<r3> + MOVQ #1,-(SP)E + MOVQ 8+4(SP),-(SP) + TSTL 8+8(SP) + BEQL 30$ +10$: BLBC 8+8(SP),20$ + MOVQ (SP),-(SP)D + MOVQ 8+8(SP),-(SP) + BSBB PQMUL_R2 + MOVQ (SP)+,8(SP) + CMPZV #1,#31,8+8(SP),#0 + BEQL 30$ +20$: MOVQ (SP),-(SP)F + BSBB PQMUL_R2F + EXTZV #1,#31,8+8(SP),8+8(SP)A + BRB 10$ + +30$: MOVQ 8(SP),8+8+4(SP) + MOVAQ 8+8+4(SP),SPL + JMP (R3)E + +u=0 +v=u+4 +y=u+8L +z=y+4A + +PQMOD_R0:A + POPR #^M<R0> + CMPL v(SP),#-1 + BLSSU 10$ + CMPL u(SP),#-a + BLSSU 10$ + ADDL2 #a,u(SP)E + ADWC #0,v(SP), +10$: JMP (R0)) + +PQMUL_R2:B + POPR #^M<r1> + MOVL SP,R2 + PUSHL z(R2) + PUSHL v(R2) + BSBB EMULQ + BSBB PQMOD_R0E + BSBB PQLSH_R0U + PUSHL y(R2) + PUSHL v(R2) + BSBB EMULQ + BSBB PQMOD_R0S + PUSHL z(R2) + PUSHL u(R2) + BSBB EMULQ + BSBB PQMOD_R0= + BSBB PQADD_R0s + BSBB PQADD_R0b + BSBB PQLSH_R0 + PUSHL y(R2) + PUSHL u(R2) + BSBB EMULQb + BSBB PQMOD_R0, + BSBB PQADD_R0 + MOVQ (SP)+,Y(R2) + MOVAQ Y(R2),SPn + JMP (R1)e + +EMULQ: + EMUL 4(SP),8(SP),#0,-(SP)e + CLRL -(SP) + TSTL 4+8+4(SP) + BGEQ 10$ + ADDL2 4+8+8(SP),(SP)E +10$: TSTL 4+8+8(SP) + BGEQ 20$ + ADDL2 4+8+4(SP),(SP) +20$: ADDL2 (SP)+,4(SP) + MOVQ (SP)+,4(SP) + RSB + +PQLSH_R0: +.ENABLE LSB + POPR #^M<r0> + PUSHL v(SP) + PUSHL #ah + BSBB EMULQ + ASHQ #32,Y(SP),Y(SP) + BRB 10$ + +PQADD_R0:d + POPR #^M<R0> +10$: ADDL2 u(SP),y(SP) + ADWC v(SP),z(SP) + BLSSU 20$ + CMPL z(SP),#-1 + BLSSU 30$ + CMPL y(SP),#-a + BLSSU 30$ +20$: ADDL2 #a,y(SP) + ADWC #0,z(SP)e +30$: MOVAQ Y(SP),SP + JMP (R0)i +.END +$ COPY BULLETIN.EXE SYS$SYSTEM: +$ SET FILE SYS$SYSTEM:BULLETIN.EXE/OWN=[1,4] +$ RUN SYS$SYSTEM:INSTALL +SYS$SYSTEM:BULLETIN/SHARE/OPEN/HEAD/PRIV=(OPER,SYSPRV,CMKRNL)r +/EXITh +$ LIB/CREATE/HELP SYS$HELP:BULL +$ LIB/HELP SYS$HELP:BULL BULLCOMSh +$ LIB/HELP SYS$HELP:HELPLIB BULLETIN +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. System messages, such as this +one, are displayed in full. Only topics will be displayed for non-system +messages. Messages are submitted using the BULLETIN command. Any user mayp +submit a non-system message. Only privileged users can submit a systems +message. For more information, see the on-line help (via HELP BULLETIN). +$ BULL*ETIN :== $SYS$SYSTEM:BULLETIN +$ BULLETIN/LOGIN +; +; Name: SETUIC.MARn +;i +; Type: Integer*4 Function (MACRO)o +;t +; Author: M. R. London +; +; Date: May 31, 1983s +;s +; Purpose: To set the UIC of the current process (which turns out +; to be the process running this program.) +; +; Usage:i +; status = SETUIC(group number, user number) +; +; status - $CMKRNL status return. 0 if arguments wrong. +; group number - longword containing UIC group numbers +; user number - longword containing UIC user numberE +; +; NOTES: +; Must link with SS:SYS.STBl +;i + + .Title SETUIC Set uic + .IDENT /830531/ +;e +; Libraries:i +;a + .LIBRARY /SYS$LIBRARY:LIB.MLB/ +;e +; Global variables: +; + $PCBDEF +;l +; Executable: +; + .PSECT SETUIC_CODE,EXE,NOWRT ; Executable codeO + + .ENTRY SETUIC,^M<R2,R3> + CLRL R0 ; 0 is error codes + MOVZBL (AP),R2 ; Get number of arguments + CMPL R2,#2 ; Are there 2 arguments + BNEQ 5$ ; If not, return + MOVL @4(AP),R3 ; Group number into R3 + ROTL #16,R3,R3 ; Move to upper half of R3 + ADDL2 @8(AP),R3 ; User number to top half of R3 + $CMKRNL_S ROUTIN=10$ ; Must run in kernel modeE +5$: RETe +10$: .WORD ^M<> ; Entry masko + MOVL SCH$GL_CURPCB,R2 ; Address of current process + MOVL R3,PCB$L_UIC(R2) ; Set UIC to specified + MOVZWL #SS$_NORMAL,R0 ; Normal ending + RET + .END +; +; Name: SETUSER.MAR +;a +; Type: Integer*4 Function (MACRO)g +; +; Author: M. R. Londono +;i +; Date: Jan 26, 1983 +; +; Purpose: To set the Username of the current process (which turns outu +; to be the process running this program.) +; +; Usage: +; status = SETUSER(username) +;i +; status - $CMKRNL status return. 0 if arguments wrong. +; username - Character string containing usernamei +;e +; NOTES:o +; Must link with SS:SYS.STB +;T + + .Title SETUSER Set uicn + .IDENT /830531/ +;i +; Libraries:n +;g + .LIBRARY /SYS$LIBRARY:LIB.MLB/o +;n +; Global variables: +;n + $PCBDEF + $JIBDEF +;u +; local variables: +; + + .PSECT SETUSER_DATA,NOEXEl + +NEWUSE: .BLKB 12 ; Contains new username +OLDUSE: .BLKB 12 ; Contains old usernamee +;b +; Executable: +;i + .PSECT SETUSER_CODE,EXE,NOWRT ; Executable code + + .ENTRY SETUSER,^M<R2,R3,R4,R5,R6,R7,R8> + CLRL R0 ; 0 is error code + MOVZBL (AP),R8 ; Get number of arguments + CMPL R8,#1 ; Correct number of arguments + BLSS 5$ ; If not, return + MOVZBL @4(AP),R6 ; Get size of string + MOVL 4(AP),R7 ; Get address of descriptor + MOVL 4(R7),R7 ; Get address of string + MOVC5 R6,(R7),#32,#12,NEWUSE ; Get new username string + CMPL R8,#2 ; Old username given? + BLSS 2$ ; No + MOVZBL @8(AP),R6 ; Get size of string + MOVL 8(AP),R7 ; Get address of descriptor + MOVL 4(R7),R7 ; Get address of string + MOVC5 R6,(R7),#32,#12,OLDUSE ; Get old username string + $CMKRNL_S ROUTIN=20$ ; Must run in kernel mode + TSTL R0 ; If old username is checks with + BEQL 2$ ; present process name, change + MOVL #2,R0 ; to new username, else flage + RET ; error and returnm +2$: $CMKRNL_S ROUTIN=10$ ; Must run in kernel mode +5$: RETb +10$: .WORD ^M<> ; Entry maskr + MOVL SCH$GL_CURPCB,R7 ; Address of current process + MOVL PCB$L_JIB(R7),R7 ; Address of Job Info Blocku + ; NOTE: MOVC destroys r0-r5h + MOVC3 #12,NEWUSE,JIB$T_USERNAME(R7) ; change username JIBn + MOVC3 #12,NEWUSE,CTL$T_USERNAME ; change username in P1 + MOVZWL #SS$_NORMAL,R0 ; Normal ending + RET +20$: .WORD ^M<> ; Entry maski + MOVL SCH$GL_CURPCB,R7 ; Address of current process + MOVL PCB$L_JIB(R7),R7 ; Address of Job Info Blocke + ; NOTE: MOVC destroys r0-r5s + CMPC R6,OLDUSE,JIB$T_USERNAME(R7) ; change username JIBe + RET + .END +$ UIC := 'F$GETJPI("","UIC") +$ SET UIC [1,4]o +$ SET PROTECT=(SYSTEM:RWE,OWNER:RWE,WORLD,GROUP)/DEFAULT +$ RUN BULLETIN +ADD/PERMANENT/SYSTEM INSTRUCT.TXT] +INFORMATION ON HOW TO USE THE BULLETIN UTILITY.M +EXIT +$ SET UIC 'UIC' +$ DEFAULT := 'F$FILE("SYS$LOGIN:LOGIN.COM","PRO")M +$ SET PROTECT=('DEFAULT')/DEFAULTH +;------------------------------------------------------------------------------R +; +; Name: USER_OPEN +;T +; Type: Multilple Function (MACRO)T +;8 +; Author: T.W.FredianM +; MIT Plasma Fusion Center +;S +; Date: January 26, 1983 +;U +; Version:h +;F +; Purpose: Used to permit qio access to files with fortran. +; Returns channel and file size information and +; provides file truncation capability. Files opened +; with these useopens cannot be accessed using fortrani +; reads and writes and the dispose= keyword on thee +; close of the file will have no effect. To make thet +; logical unit reuseable for normal RMS access you must +; deassign the channel using SYS$DASSGN(%VAL(channel))n +; and then use the close (unit= ) statement. +;l +; Types of useropens provided: +; +; USER_OPEN$OLD - open old file +; USER_OPEN$NEW - open new file +; USER_OPEN$TRUNCATE - open old file and truncate it +; to the size specified by the, +; INITIALSIZE keyword of the open +;e +; To receive the channel, open RMS status and size of the filee +; include a common USER_OPEN as follows:L +;R +; Common /USER_OPEN/ CHANNEL,STATUS,SIZE +; Integer*4 CHANNEL - I/O channel assigned to the fileH +; Integer*4 STATUS - RMS status return of open +; Integer*4 SIZE - Size of the file opened in blocks +;s +;------------------------------------------------------------------------------ +; +; Call seqence: NONE - USEROPEN keyword of fortran OPEN statemento +; for example: +; +; External USER_OPEN$NEW +; . +; .h +; .o +; OPEN (UNIT=lun,FILE=filename,....,USEROPEN=USER_OPEN$NEW)o +; +;------------------------------------------------------------------------------ +;l +; Description:n +;t +; Entry mask for USER_OPEN$OLD +; Get the FAB addressc +; Set the user file open bit +; Open old filei +; Save the channel +; Save the sizey +; Save the statusl +; Return + +; Entry mask for USER_OPEN$NEW +; Get the FAB addressl +; Set the user file open bit +; Open new filep +; Save the channel +; Save the sizeh +; Save the statusc +; Return + +; Entry mask for USER_OPEN$TRUNCATEA +; Get the FAB addressg +; Get the RAB addressr +; Save the sizeh +; Open old fileL +; Connect file to record stream +; Load the size of the file in the RAB +; Set the access mode to relative file address +; Find the last record in the file +; Place the end of file marker at this location +; Mark the file to be truncated on close +; Close the file +; Return + +; Endd +;e +;+-----------------------------------------------------------------------------i + + .TITLE USER_OPENn + .IDENT /V_830128/ + +;s +;------------------------------------------------------------------------------ +;e +; Global variables:e +;s + .PSECT USER_OPEN LONG,PIC,OVR,GBL,SHR,NOEXE + +CHANNEL: .BLKL 1 ; Channel numberi +STATUS: .BLKL 1 ; Status return of open +SIZE: .BLKL 1 ; Size of file. + +;s +;------------------------------------------------------------------------------o +;n +; Executable:n +;c + .PSECT $CODE LONG,PIC,USR,CON,REL,LCL,SHR,EXE,RD,NOWRT,NOVECt + + .ENTRY USER_OPEN$OLD,^M<R2> ; Entry mask for USER_OPEN$OLD + MOVL 4(AP),R2 ; Get the FAB addressa + INSV #1,#FAB$V_UFO,#1,FAB$L_FOP(R2) ; Set the user file open bits + $OPEN FAB=(R2) ; Open old filea + MOVL FAB$L_STV(R2),CHANNEL ; Save the channel + MOVL FAB$L_ALQ(R2),SIZE ; Save the sizeh + MOVL R0,STATUS ; Save the status + RET ; Returne + + .ENTRY USER_OPEN$NEW,^M<R2> ; Entry mask for USER_OPEN$NEW + MOVL 4(AP),R2 ; Get the FAB address + INSV #1,#FAB$V_UFO,#1,FAB$L_FOP(R2) ; Set the user file open bito + INSV #0,#FAB$V_CBT,#1,FAB$L_FOP(R2) ; Disable contiguous best try + $CREATE FAB=(R2) ; Open new filea + MOVL FAB$L_STV(R2),CHANNEL ; Save the channel + MOVL FAB$L_ALQ(R2),SIZE ; Save the sizeh + MOVL R0,STATUS ; Save the statuss + RET ; Returnr + + .ENTRY USER_OPEN$TRUNCATE,^M<R2,R3,R4,R5> ; Entry mask for USER_OPEN$TRUNCATE + MOVL 4(AP),R2 ; Get the FAB addresst + MOVL 8(AP),R3 ; Get the RAB address + MOVL FAB$L_ALQ(R2),R4 ; Save the sizen + INCL R4 ; Increment the size + INSV #0,#FAB$V_SQO,#1,FAB$L_FOP(R2) ; Clear the sequential only bit + $OPEN FAB=(R2) ; Open old fileE + BLBC R0,CLOSE ; If unsuccessful branch to close + $CONNECT RAB=@8(AP) ; Connect file to record stream + BLBC R0,CLOSE ; If unsuccessful branch to closeS + MOVL R4,RAB$L_RFA0(R3) ; Load the size of the file in the RABA + MOVW #0,RAB$W_RFA4(R3)O + MOVB #RAB$C_RFA,RAB$B_RAC(R3) ; Set the access mode to relative file addressE + $FIND RAB=(R3) ; Find the last record in the file + BLBC R0,CLOSE ; If unsuccessful branch to close + $TRUNCATE RAB=(R3) ; Place the end of file marker at this location + INSV #1,#FAB$V_TEF,#1,FAB$L_FOP(R2) ; Mark the file to be truncated on closeT +CLOSE: PUSHL R0 ; Save error status + $CLOSE FAB=(R2) ; Close the fileL + POPL R0 ; Restore error status + MOVL R0,STATUS ; Return the status + RET ; ReturnO + + .END ; End8 + diff --git a/batch/seed/1985c-bulletin.txt b/batch/seed/1985c-bulletin.txt new file mode 100644 index 0000000000000000000000000000000000000000..a8c211260cb20f14129d02b947dda3611a62a734 --- /dev/null +++ b/batch/seed/1985c-bulletin.txt @@ -0,0 +1,53 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 10:58 +Subj: BULLETIN operation + +This file describes the general operation of the BULLETIN utility. + +BULLETIN uses 3 files to store its data: BULLETIN.DAT, BULLDIR.DAT, & +BULLUSER.DAT. These files are opened with the shared attribute as much as +possible to allow simultaneous operations on the files. However, when a +bulletin is added or deleted, the file cannot be shared, as this might cause +the file to be corrupted. Because of this problem, files are closed as soon as +possible so that it may be quickly opened for adding and deleting files. e +During read operations, the information is passed to temporary storage, thes +file is closed, and then the information is sent to the terminal. This avoids at +possible problem where the terminal output is stopped by the user, therefore +delaying the closing of the file. Also, the use of CTRL-Y & CTRL-C is disablede +while the file is opened to avoid lockout problems.c + +BULLETIN.DAT stores the actual bulletins in a fixed 80 character length file.k +Bulletins are store sequentially datewise. New bulletins are appended to thet +end of the file. When a bulletin is deleted, all the following bulletins arei +moved up in the file to remove the gap, and the file is then truncated toi +remove the unused space. u + +BULLDIR.DAT is a fixed record length file storing directory entries for each +bulletin in BULLETIN.DAT. Each entry contains the header information, length,L +and starting record position in BULLETIN.DAT. The first line of BULLDIR.DAT ist +a header containing the date of the next expiration that will occur, the datef +of the latest sumbitted bulletin, the number of bulletins, and the total size +of BULLETIN.DAT. The last two numbers make it easier to add bulletins. Thet +directory entries then follow, again stored sequentially datewise. r + +NOTE: There are several advantages to keeping a seperate directory file versus +storing the header information with the actual bulletin. Obviously, it avoids +having to scan through a large bulletin file just to extract headert +information. This operation is done when a DIRECTORY listing is requested inu +BULLETIN. More importantly when a login occurs, non-system bulletins just +require that the header information be displayed. Having a file with pointers +to where the bulletin is stored also avoids requiring the software to read all +the previous bulletins in order to arrive at the desired bulletin. The main +disadvantage is the extra time spent on locating the second file. This time +appears to be minimal. In all the software, the convention is to open theI +directory file first, and then if needed to open the bulletin file. Wheno +adding and delete files, this becomes important, as files are opened unshared. d +A deadlock might occur if one user opens the bulletin file first while another +user opens the directory file, and then each try to open the alternate file. + +BULLUSER.DAT is a relative indexed file, where the keyword is the username ofe +the user. Each entry contains the latest time that the user logged in, plus +the latest time that the BULLETIN utility was used to read bulletins. A headere +entry with a blank username stores the latest bulletin date. The information +in this file is used for checking to see if the user should be alerted to newf +bulletins or not.� diff --git a/batch/seed/1985c-file1.mai b/batch/seed/1985c-file1.mai new file mode 100644 index 0000000000000000000000000000000000000000..7525540b7ccf5bc916dcae20a65f4fda7a85948d --- /dev/null +++ b/batch/seed/1985c-file1.mai @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 10:58 +Subj: BULLETIN utility. + +You will be receiving 4 files for the BULLETIN facility. The first file is +BULLETIN.FOR. The second file is BULLSUBS.FOR. The third file is BULLET.COM . +The 4th is BULLET.MAI . BULLETIN.FOR and BULLSUBS.FOR are seperate files. +BULLET.MAI contains many individual files that appended into one large file +(in order so I don't have to send them individually). BULLET.COM is a command +procedure to separate BULLET.MAI into individual files. This takes several +minutes. Afterwards, you can delete BULLET.MAI. Read AAAREADME.TXT for +instructions. + Mark London + MRL%PFCVAX@ZERMATT + +NOTE: You can use the old DAT files with the new version of BULLETIN. However, +when you run the new version of BULLETIN for the first time, it will create a +new copy of BULLUSER.DAT from the old copy, as the length of the records have +to be increased. After you have confirmed that the new BULLETIN is running +properly, you can delete the old version of BULLUSER.DAT. diff --git a/batch/seed/1985c-file2.mai b/batch/seed/1985c-file2.mai new file mode 100644 index 0000000000000000000000000000000000000000..267774bf1fb305a667b7eda2285480f8306d8864 --- /dev/null +++ b/batch/seed/1985c-file2.mai @@ -0,0 +1,1831 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 11:00 +Subj: BULLETIN.FOR + +Return-Path: <@MIT-ZERMATT.ARPA:MRL%MIT-PFC-VAX@MIT-MC.ARPA> +Received: from MIT-ZERMATT.ARPA by ari-hq1.ARPA ; 30 Oct 85 10:59:27 EST +Received: from MIT-PFC-VAX by ZERMATT via CHAOS with CHAOS-MAIL id 15462; Wed 30-Oct-85 10:53:42-EST +Date: 30 Oct 85 10:54:51 EST +From: MRL%PFCVAX@ZERMATT +Sender: MRL@MIT-PFC-VAX +To: BINGHAM@ARI-HQ1@ZERMATT +Subject: BULLETIN.FOR + +C +C BULLETIN.FOR, Version P850716 +C Purpose: Facility for reading, adding, and delete bulletins. +C Environment: MIT PFC VAX-11/780, VMS +C Usage: Invoked by the BULLETIN command. +C Programmer: Mark R. London +C +C NOTES: See BULLETIN.TXT for general info. +C + IMPLICIT INTEGER (A - Z) + + INCLUDE 'BULLDIR.INC' + + INCLUDE '($RMSDEF)' + + COMMON /BULLPAR/ BULL_PARAMETER,LEN_P + CHARACTER*64 BULL_PARAMETER + + COMMON /POINT/ BULL_POINT + + COMMON /READIT/ READIT + + COMMON /PAGE/ PAGE_LENGTH + + COMMON /CTRLY/ CTRLY + + COMMON /TERM_CHAN/ TERM_CHAN + + EXTERNAL BULLETIN_SUBCOMMANDS,LIB$GET_INPUT,CLI$_NOCOMD,CLI$_ABSENT + EXTERNAL BULLETIN_MAINCOMMANDS + + PARAMETER PCB$M_BATCH = '4000'X + PARAMETER LIB$M_CLI_CTRLY = '2000000'X + + CHARACTER*32 INLINE + + CHARACTER*11 UPTIME_DATE + CHARACTER*8 UPTIME_TIME + +C +C Check to see if CONTROL Y disabled. If so, then never disable CONTROL Y. +C Disabling and enabling CONTROL Y is done so that a person can not break +C while one of the data files is opened, as that would not allow anyone +C else to modify the files. However, if CONTROL Y is already disabled, +C this is not necessary, and should not be done! +C + + CALL LIB$DISABLE_CTRL(LIB$M_CLI_CTRLY,CTRLY) ! Disable CTRL-Y & -C + CTRLY = CTRLY .AND. LIB$M_CLI_CTRLY + CALL GETPRIV(ALLOW) ! Check privileges + IF (ALLOW.EQ.0) THEN ! If no SETPRV privileges... + CALL CHECK_PRIV_IO(ERR) ! check privileges on output I/O + ELSE + ERR = 0 ! Else we don't have to check them. + END IF + CALL LIB$ENABLE_CTRL(CTRLY,) ! Renable CTRLY-Y & -C + + IF (ERR.EQ.1) CALL EXIT ! I/O privilege error, so exit + +C +C Delete any expired bulletins (normal or shutdown ones). +C + + CALL OPEN_FILE(2) + CALL READDIR(0,IER) ! Get header info from BULLDIR.DAT + IF (IER.EQ.1) THEN ! Is header present? + IER = COMPARE_DATE(NEWEST_EXDATE,' ') ! Yes. Any expired bulls? + IF (SHUTDOWN.GT.0) THEN ! Do shutdown bulletins exist? + CALL GET_UPTIME(UPTIME_DATE,UPTIME_TIME) + IER1 = COMPARE_DATE(SHUTDOWN_DATE,UPTIME_DATE) + IF (IER1.EQ.0) IER1 = COMPARE_TIME(SHUTDOWN_TIME,UPTIME_TIME) + IF (IER1.LE.0) SHUTDOWN = 0 + END IF + IF (IER.LE.0.OR.IER1.LE.0) CALL UPDATE ! Need to update + END IF + CALL CLOSE_FILE(2) + +C +C Test for /READ & /LOGIN switches. +C + + CALL LIB$GET_FOREIGN(INLINE) + + IER = CLI$DCL_PARSE('BULLETIN'//INLINE,BULLETIN_MAINCOMMANDS) + + READIT = 0 + IF (CLI$PRESENT('READNEW')) READIT = 1 ! Test for /READ switch. + LOGIT = 0 + IF (CLI$PRESENT('LOGIN')) LOGIT = 1 ! Test for /LOGIN switch. + +C +C Ignore BULLETIN/READ or BULLETIN/LOGIN if this is a batch process. +C + + IF (READIT.GT.0.OR.LOGIT.GT.0) THEN + CALL GETSTS(STS) ! Get process status word + IF ((STS.AND.PCB$M_BATCH).GT.0) CALL EXIT ! If BATCH, exit + END IF + + IER = SYS$ASSIGN('TT',TERM_CHAN,,) ! Assign terminal +C +C Get page length for the terminal. +C + + CALL GETPAGLEN(PAGE_LENGTH) + +C +C If /LOGIN, display SYSTEM bulletins and subject of non-SYSTEM bulletins. +C + + IF (LOGIT.GT.0) THEN ! Is /LOGIN present? + CALL LOGIN(READIT) ! Display SYSTEM bulletins + IF (READIT.EQ.0) CALL EXIT ! If not /READ, exit program + END IF + +C +C Update user's last read bulletin date. If new bulletins have been +C added since the last time bulletins have been read, position bulletin +C pointer so that next bulletin read is the first new bulletin, and +C alert user. If /READ switch and no new bulletins, just exit. +C + + CALL UPDATE_READ ! Bulletins added since last read? + IF (BULL_POINT.EQ.-1) THEN ! BULL_POINT would be bulletin # -1 + BULL_POINT = 0 ! Since its -1, no new bulletins + IF (READIT.GT.0) CALL EXIT ! If /READ, just exit + ELSE IF (READIT.EQ.0) THEN ! There are new bulletins + WRITE(6,1000) ! Alert user of the fact + END IF ! if not in /READ mode + + IF (READIT.GT.0) CALL READNEW ! /READ mode. READNEW exits the program + +C +C The MAIN loop for processing bulletin commands. +C + + DIR_COUNT = 0 ! # directory entry to continue bulletin read from + READ_COUNT = 0 ! # block that bulletin READ is to continue from + + DO WHILE (1) + + IER = CLI$DCL_PARSE(%VAL(0),BULLETIN_SUBCOMMANDS,LIB$GET_INPUT, + & LIB$GET_INPUT,'BULLETIN> ') + + IF (IER.EQ.RMS$_EOF) THEN + GO TO 999 ! If no command, exit + ELSE IF (IER.EQ.%LOC(CLI$_NOCOMD)) THEN ! If just RETURN entered + LEN_P = 0 ! Indicate no parameter in command + IF (DIR_COUNT.GT.0) THEN ! If still more dir entries + CALL DIRECTORY(DIR_COUNT) ! continue outputting them + ELSE ! Else try to read next bulletin + CALL READ(READ_COUNT,BULL_POINT+1) ! or finish old one + END IF + GO TO 100 ! Loop to read new command + ELSE IF (.NOT.IER) THEN ! If command has error + GO TO 100 ! ask for new command + END IF + + DIR_COUNT = 0 ! Reinit dir and read pointers + READ_COUNT = 0 + +80 CALL CLI$GET_VALUE('$VERB',INLINE) ! Get the VERB command + IF (INLINE(1:3).EQ.'ADD') THEN ! ADD bulletin command? + CALL ADD ! Go add bulletin + ELSE IF (INLINE(1:4).EQ.'BACK') THEN ! BACK command? + IF (BULL_POINT.LE.1) THEN + WRITE(6,1060) + ELSE + CALL READ(READ_COUNT,BULL_POINT-1) ! Try to read previous bull + END IF + ELSE IF (INLINE(1:4).EQ.'DELE') THEN ! DELETE command? + CALL DELETE ! Go delete bulletin + ELSE IF (INLINE(1:4).EQ.'DIRE') THEN ! DIRECTORY command? + CALL DIRECTORY(DIR_COUNT) ! Get directory of bulletins + ELSE IF (INLINE(1:4).EQ.'EXIT') THEN ! EXIT command? + CALL EXIT ! Exit from program + ELSE IF (INLINE(1:4).EQ.'FILE') THEN ! FILE command? + CALL FILE ! Copy bulletin to file + ELSE IF (INLINE(1:4).EQ.'HELP') THEN ! HELP command? + CALL HELP('BULL.HLB') ! Get help + ELSE IF (INLINE(1:4).EQ.'NEXT') THEN ! NEXT command? + CALL READ(READ_COUNT,BULL_POINT+1) ! Read next bulletin + ELSE IF (INLINE(1:4).EQ.'READ') THEN ! READ command? + IER = CLI$GET_VALUE('BULLETIN_NUMBER',BULL_PARAMETER,LEN_P) + IF (IER.NE.%LOC(CLI$_ABSENT)) THEN ! Bulletin specified? + DECODE(LEN_P,'(I<LEN_P>)',BULL_PARAMETER) BULL_READ ! Yes + CALL READ(READ_COUNT,BULL_READ) + ELSE + CALL READ(READ_COUNT,BULL_POINT+1) + END IF + ELSE IF (INLINE(1:4).EQ.'REPL') THEN ! REPLACE command? + CALL REPLACE ! Replace old bulletin + ELSE IF (INLINE(1:3).EQ.'SET') THEN ! SET command? + CALL CLI$GET_VALUE('SET_PARAM1',INLINE) + IF (INLINE(1:4).EQ.'READ') THEN ! SET READNEW? + CALL SET_READNEW(1,1) + ELSE IF (INLINE(1:4).EQ.'NORE') THEN + CALL SET_READNEW(0,1) + END IF + ELSE ! Else bad parameter + WRITE(6,1020) ! Inform user of it + ENDIF + +100 CONTINUE + + END DO + +999 CALL EXIT + +1000 FORMAT(' Type READ to read new bulletins.') +1010 FORMAT(Q,A) +1020 FORMAT(' ERROR: Unknown command. Please retype.') +1060 FORMAT(' ERROR: There are no more bulletins.') + + END + + + + + SUBROUTINE ADD +C +C SUBROUTINE ADD +C +C FUNCTION: Adds bulletin to bulletin file. +C + IMPLICIT INTEGER (A - Z) + + COMMON /POINT/ BULL_POINT + + COMMON /BULLPAR/ BULL_PARAMETER,LEN_P + CHARACTER*64 BULL_PARAMETER + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLUSER.INC' + + INCLUDE '($SSDEF)' + + CHARACTER*11 INEXDATE,TODAY + CHARACTER*80 INDESCRIP,INPUT + + INTEGER TIMADR(2) + + DIMENSION SETPRV(2) + DATA SETPRV/Z10000000,0/ ! SYSPRV privileges + +C +C The largest message that can be broadcasted is dependent on system +C and user quotas. The following limit is 12 lines of ( 80 characters + +C CR/LF ) + 2 bells. This should be more than enough room, as broadcasts +C shouldn't be too large anyway.% +C- + + PARAMETER BRDCST_LIMIT = 82*12 + 2T + CHARACTER*(BRDCST_LIMIT) BROAD0 + CHARACTER*1 CR/13/,LF/10/,BELL/7/ + + COMMON /TERM_CHAN/ TERM_CHAN + + COMMON /CTRLY/ CTRLY + + EXTERNAL CLI$_ABSENTT + EXTERNAL IO$_READVBLK,IO$M_NOECHO,IO$M_PURGEX + + CHARACTER*80 MAILEDIT,INLINE + CHARACTER*32 NODES(10)M + CHARACTER PASSWORD*31,TEMPUSER*12 + + CALL LIB$DISABLE_CTRL(CTRLY,) ! Disable CTRL-Y & -C + + IER = CLI$GET_VALUE('FILESPEC',BULL_PARAMETER,LEN_P)I + IF (IER.NE.%LOC(CLI$_ABSENT)) THENo + CALL GETPRIV(ALLOW) ! Does user have SETPRV privileges? + IF (ALLOW.EQ.0) THEN ! If not, then remove SYSPRV + CALL SYS$SETPRV(%VAL(0),SETPRV,,) ! privileges when trying to + END IF ! create new file.T + OPEN (UNIT=3,FILE=BULL_PARAMETER(1:LEN_P),STATUS='OLD',READONLY, + & SHARED,ERR=920,FORM='FORMATTED') ! Try opening the file + CALL SYS$SETPRV(%VAL(1),SETPRV,,) ! Reset SYSPRV privilegesU + END IFB + + IER = SYS_TRNLNM('SYS$NET',INLINE,1)B + IF (IER.EQ.SS$_NORMAL) THEN ! Running via DECNET?P + IER = CLI$GET_VALUE('USERNAME',USERNAME) + IF (CLI$GET_VALUE('PASSWORD',PASSWORD).EQ.SS$_NORMAL) THEN + CALL CONFIRM_PRIV(USERNAME,PASSWORD,ALLOW) + END IF + ELSEs + CALL GETPRIV(ALLOW) ! Check privileges + END IFi + + IF (CLI$PRESENT('SYSTEM')) THEN ! Is /SYSTEM switch present? + IF (ALLOW.EQ.0) THEN ! If no privilegesa + WRITE(6,1070) ! Tell user + RETURN ! and abort + END IF + SYSTEM = 1 ! Set system bit + ELSEa + SYSTEM = 0 ! Clear system bit + END IFI + + IF (CLI$PRESENT('BROADCAST')) THEN ! Is /BROADCAST switch present?Y + IF (ALLOW.EQ.0) THEN ! If no privileges! + WRITE(6,1080) ! Tell user + RETURN ! and abort + END IF + END IFK + + IF (CLI$PRESENT('PERMANENT')) THEN ! Is /PERMANENT switch present? + IF (CLI$PRESENT('SHUTDOWN')) THEND + WRITE(6,1083) + RETURN! + ELSE IF (ALLOW.EQ.0) THEN ! If no privileges + WRITE(6,1081) ! Tell user + RETURN ! and abort + ELSE + SYSTEM = SYSTEM.OR.2 ! Set permanent bit + INEXDATE = 'PERMANENT'd + GO TO 8 ! Skip expiration date question + END IF + END IF + + IF (CLI$PRESENT('SHUTDOWN')) THEN ! Is /SHUTDOWN switch present? + IF (CLI$PRESENT('PERMANENT')) THEN + WRITE(6,1083) + RETURNE + ELSE IF (ALLOW.EQ.0) THEN ! If no privilegesA + WRITE(6,1082) ! Tell user + RETURN ! and abort + ELSE + SYSTEM = SYSTEM.OR.4 ! Set shutdown bitH + INEXDATE = 'SHUTDOWN' + GO TO 8 ! Skip expiration date questiona + END IF + END IFL + + NODE_NUM = 0 ! Initialize number of nodesi + IF (CLI$PRESENT('NODES')) THEN ! Decnet nodes specified? + LEN = 0 ! GET_VALUE crashes if LEN<0A + DO WHILE (CLI$GET_VALUE('NODES',NODES(NODE_NUM+1),LEN) + & .EQ.SS$_NORMAL) ! Get the specified nodes + NODE_NUM = NODE_NUM + 1 + IF (NODES(NODE_NUM)(LEN-1:LEN).EQ.'::') THEN ! Remove :: ifi + LEN = LEN - 2 ! added + END IF. + POINT_NODE = NODE_NUM + OPEN (UNIT=9+NODE_NUM,NAME=NODES(NODE_NUM)(1:LEN)//'""::'// + & '"TASK=BULLETIN"',ACCESS='SEQUENTIAL',FORM='FORMATTED',T + & CARRIAGECONTROL='NONE',TYPE='NEW',ERR=940) + END DO + END IFa + +5 IER = SYS$ASCTIM(,TODAY,,) ! Get today's date + WRITE(6,1030) TODAY ! Prompt for expiration dateY + CALL GET_LINE(INEXDATE,LEN) ! Get input line + IF (LEN.LE.0) GO TO 910 + DECODE(LEN,'(I<LEN>)',INEXDATE,IOSTAT=IER) NDAYS ! Is it # days? + IF (IER.EQ.0) THEN ! If so, + IF (NDAYS.LE.0) THEN ! Is # days not in future + WRITE(6,1045) ! tell user + GO TO 5 ! and re-request datee + ELSE + CALL GET_EXDATE(INEXDATE,NDAYS) ! Get expiration date + END IF + END IFw + IF (INEXDATE(2:2).EQ.'-') INEXDATE = '0'//INEXDATEo + CALL STR$UPCASE(INEXDATE,INEXDATE) ! Convert to upper for BINTIMd + IER = SYS$BINTIM(INEXDATE,TIMADR(1)) ! Is real date?L + IF (IER.NE.1) THEN ! If not, +7 WRITE(6,1040) ! tell user input is wrong + GO TO 5 ! and re-request date + END IFx + IER = SYS$ASCTIM(,INEXDATE,TIMADR(1),)a + IER = COMPARE_DATE(INEXDATE,TODAY) ! Compare date with today'sE + IF (IER.LE.0) THEN ! If expiration date not futureA + WRITE(6,1045) ! tell usere + GO TO 5 ! and re-request date + END IFo + +8 WRITE(6,1050) ! Request header for bulletin + CALL GET_LINE(INDESCRIP,LENDES) ! Get input line + IF (LENDES.LE.0) GO TO 910b + IF (LENDES.GT.53) THEN ! If too many characters + WRITE(6,1060) ! tell user, + WRITE(6,2020) INDESCRIP(1:53) ! Show how much would fitB + GO TO 8 ! and re-request header + END IF + +CG +C If file specified in ADD command, read file to obtain bulletin. +C Else, read the bulletin from the terminal.P +C0 + ! + ICOUNT = 0 ! Line count for bulletin + + IF (CLI$PRESENT('EDIT')) THEN ! If /EDIT specified, then + LEN = 0I + IER = LIB$SYS_TRNLOG('MAIL$EDIT',LEN,MAILEDIT) + IF (IER.NE.SS$_NORMAL) MAILEDIT = 'SYS$SYSTEM:MAILEDIT'U + IF (LEN_P.EQ.0) THEN ! If no file param specifiedG + CALL LIB$SPAWN('$@'//MAILEDIT//' "" SYS$LOGIN:BULL.SCR')E + OPEN (UNIT=3,FILE='SYS$LOGIN:BULL.SCR',STATUS='OLD', + & DISPOSE='DELETE',ERR=920,FORM='FORMATTED')d + LEN_P = 1 + ELSE + CLOSE (UNIT=3)A + CALL LIB$SPAWN('$@'//MAILEDIT//' '//BULL_PARAMETER(1:LEN_P) + & //' SYS$LOGIN:BULL.SCR')e + OPEN (UNIT=3,FILE='SYS$LOGIN:BULL.SCR',STATUS='OLD',I + & DISPOSE='DELETE',ERR=920,FORM='FORMATTED') + END IF + END IFT + + IF (LEN_P.GT.0) THEN ! If file param in ADD command + DO WHILE(1) ! Read until end of file to + READ (3,2000,END=10) ! get record countE + ICOUNT = ICOUNT + 1 + END DO + ELSE ! If no input file + OPEN (UNIT=3,STATUS='SCRATCH',FILE='SYS$LOGIN:BULL.SCR', + & FORM='FORMATTED') ! Sratch file to save bulletino + WRITE (6,1000) ! Request bulletin input from terminal + LEN = 81 ! Length of input line + DO WHILE (LEN.GE.0) ! Input until no more input + CALL GET_LINE(INPUT,LEN) ! Get input linen + IF (LEN.GE.0) THEN ! If good input line enteredP + ICOUNT = ICOUNT + 1 ! Increment record count + WRITE(3,2010) INPUT(1:LEN) ! Save line in scratch filed + END IFR + END DO + IF (LEN.EQ.-1) GO TO 910 ! CTRL_C entered, error out( +10 IF (ICOUNT.EQ.0) GO TO 910 ! No lines entered, error outE + ENDIF + + REWIND (UNIT=3) + + IF (NODE_NUM.GT.0) THEN + INLINE = 'ADD' + IF (CLI$PRESENT('SYSTEM')) + & INLINE = INLINE(1:STR$POSITION(INLINE,' ')-1)//'/SYSTEM' + IF (CLI$PRESENT('BROADCAST')) + & INLINE = INLINE(1:STR$POSITION(INLINE,' ')-1)//'/BROADCAST' + IF (CLI$PRESENT('PERMANENT')) + & INLINE = INLINE(1:STR$POSITION(INLINE,' ')-1)//'/PERMANENT' + IF (CLI$PRESENT('SHUTDOWN')) + & INLINE = INLINE(1:STR$POSITION(INLINE,' ')-1)//'/SHUTDOWN'I + IF (CLI$PRESENT('BELL')) + & INLINE = INLINE(1:STR$POSITION(INLINE,' ')-1)//'/BELL'Q + + IO_READ = %LOC(IO$_READVBLK)+%LOC(IO$M_NOECHO)+%LOC(IO$M_PURGE)! + + DO POINT_NODE=1,NODE_NUM ! Write out command to nodes + WRITE (6,'('' Enter username at node '',A)') NODES(POINT_NODE)R + WRITE (6,'('' Hit RETURN to use username of local node.'')')A + READ (5,'(Q,A)',ERR=910,END=910) LEN,TEMPUSER + IF (INLINE.NE.'ADD'.OR.LEN.GT.0) THEN + WRITE(6,'('' Enter password for node '',2A)') + & NODES(POINT_NODE),CHAR(10)l + IER=SYS$QIOW(,%VAL(TERM_CHAN),%VAL(IO_READ),,,,T + & %VAL(%LOC(PASSWORD)),%VAL(31),,,,)A + INLINE = INLINE(1:STR$POSITION(INLINE,' ')-1)//'/PASSWORD=' + & //PASSWORD(1:STR$POSITION(PASSWORD,CHAR(13))-1) + END IFA + IF (LEN.EQ.0) TEMPUSER = USERNAME + INLINE = INLINE(1:STR$POSITION(INLINE,' ')-1) + & //'/USERNAME='//TEMPUSERe + WRITE (POINT_NODE+9,'(A)',ERR=940) INLINE + WRITE (POINT_NODE+9,'(A)',ERR=940) INEXDATE + WRITE (POINT_NODE+9,'(A)',ERR=940) INDESCRIP(1:LENDES)T + DO I=1,ICOUNT + READ (3,'(Q,A)') LEN,INPUT + WRITE (POINT_NODE+9,'(A)',ERR=940) INPUT(1:LEN) + END DOA + WRITE (6,'('' Bulletin successfully sent to node '',A)') + & NODES(POINT_NODE)A + REWIND (UNIT=3) + END DO + END IF$ + +CN +C Add bulletin to bulletin file and directory entry for to directory file.I +CN + + CALL OPEN_FILE(2) ! Prepare to add dir entryR + + DESCRIP=INDESCRIP(1:LENDES) ! Description header + EXDATE=INEXDATE ! Expiration dateT + LENGTH = ICOUNT ! Number of records, + FROM = USERNAME ! Username + + CALL OPEN_FILE(1) ! Prepare to add bulletin + + CALL READDIR(0,IER) ! Get NBLOCKe + IF (IER.EQ.0) NBLOCK = 0 ! If new file, NBLOCK is 0( + + CALL COPY_BULL(3,1,NBLOCK+1,IER) ! Add the new bulletin + IF (IER.NE.0) GO TO 930 ! Error in creating bulletiny + + CLOSE (UNIT=1) ! Finished adding bulletin) + + CALL ADD_ENTRY ! Add the new directory entry + + CLOSE (UNIT=2) ! Totally finished with add + +CI +C Broadcast the bulletin if requested.T +CL + + IF (CLI$PRESENT('BROADCAST')) THEN ! Should we broadcast the bull?! + REWIND (UNIT=3) ! Yes, rewind the input file + IF (CLI$PRESENT('BELL')) THEN ! Include BELL in message? + BROAD(1:36) = ! Say who the bulletin is fromN + & BELL//BELL//CR//LF//LF//'NEW BULLETIN FROM: '//FROMM + START = 37 ! Start adding next line hereE + ELSE + BROAD(1:34) = ! Say who the bulletin is fromS + & CR//LF//LF//'NEW BULLETIN FROM: '//FROMU + START = 35 ! Start adding next line hereB + END IF + DO I=1,ICOUNT ! Stuff bulletin into string + READ(3,2000) LEN,INPUT ! Read input line + END = START + LEN - 1 + 2 ! Check how long string will beO + IF (END.GT.BRDCST_LIMIT) GO TO 90 ! If too much for string, exitV + BROAD(START:END) = CR//LF//INPUT(1:LEN) ! Else add new input + START = END + 1 ! Reset pointer + END DO +90 CALL SYS$BRDCST(BROAD(1:START-1)//CR,,,) ! Do the BROADCAST + END IFR + + CLOSE (UNIT=3) ! Close the input file + +100 CALL LIB$ENABLE_CTRL(CTRLY,) ! Enable CTRL-Y & -Cy + DO I=10,NODE_NUM+9 + CLOSE (UNIT=I) + END DO) + RETURNs + +910 WRITE(6,1010)e + CLOSE (UNIT=3,ERR=100)0 + GOTO 100I + +920 WRITE(6,1020) + CALL SYS$SETPRV(%VAL(1),SETPRV,,) ! Reset SYSPRV privileges + GOTO 100 + +930 WRITE (6,1025) + CALL CLOSE_FILE(3)T + CLOSE (UNIT=3)N + GO TO 100 + +940 WRITE (6,1015) NODES(POINT_NODE) + CLOSE (UNIT=3)I + GO TO 100 + +1000 FORMAT (' Enter bulletin: End with ctrl-z, cancel with ctrl-c') +1010 FORMAT (' No bulletin was added.')T +1015 FORMAT (' ERROR: Unable to reach node ',A)T +1020 FORMAT (' ERROR: Unable to open specified file.') +1025 FORMAT (' ERROR: Unable to add bulletin to bulletin file.') +1030 FORMAT (' Today is ',A11, + &'. Specify when the bulletin should expire:',/,1x, + &'Enter specific date, dd-mmm-yyyy, or number of days from today.') +1040 FORMAT (' ERROR: Invalid date format specified.') +1045 FORMAT (' ERROR: Specified date has already passed.') +1050 FORMAT (' Enter description header. Limit header to 53 + & characters.') +1060 FORMAT (' ERROR: Header > 53 characters. Header would beN + & truncated to:') +1070 FORMAT (' ERROR: SETPRV privileges are needed for systemE + & bulletins.')o +1080 FORMAT (' ERROR: SETPRV privileges are needed to broadcast + & bulletins.')U +1081 FORMAT (' ERROR: SETPRV privileges are needed to permanentG + & bulletins.')s +1082 FORMAT (' ERROR: SETPRV privileges are needed to shutdown + & bulletins.') +1083 FORMAT (' ERROR: Permanent and shutdown cannot be specified + & simultaneously.') +2000 FORMAT(Q,A) +2010 FORMAT(A) +2020 FORMAT(1X,A)M + + END + + + SUBROUTINE DELETE +CB +C SUBROUTINE DELETE +CI +C FUNCTION: Deletes a bulletin entry from the bulletin file. +CR + IMPLICIT INTEGER (A - Z)a + + CHARACTER*107 DIRLINE + + COMMON /POINT/ BULL_POINT + + COMMON /BULLPAR/ BULL_PARAMETER,LEN_P + CHARACTER*64 BULL_PARAMETER + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLUSER.INC' + + EXTERNAL CLI$_ABSENTE + + CHARACTER*1 ANSWER + +C +C Get the bulletin number to be deleted. +C + + IER = CLI$GET_VALUE('BULLETIN_NUMBER',BULL_PARAMETER,LEN_P) + IF (IER.NE.%LOC(CLI$_ABSENT)) THEN ! Was bulletin specified? + DECODE(LEN_P,5,BULL_PARAMETER,ERR=920) BULL_DELETE ! Yes +5 FORMAT(I<LEN_P>)E + ELSE IF (BULL_POINT.EQ.0) THEN ! No. Have we just read a bulletin? + GO TO 910 ! No, then error.r + ELSEp + BULL_DELETE = BULL_POINT ! Delete the file we are reading + END IFI + +CR +C Check to see if specified bulletin is present, and if the usert +C is permitted to delete the bulletin.s +Ca + + CALL OPEN_FILE(2) + + CALL READDIR(BULL_DELETE,IER) ! Get info for specified bulletin + + IF (IER.NE.BULL_DELETE+1) THEN ! Was bulletin found?f + WRITE(6,1030) ! If not, then error out5 + GOTO 100 + END IFO + + IF (USERNAME.NE.FROM) THEN ! If doesn't match owner of bulletin,e + CALL GETPRIV(ALLOW) ! then see if owner has privileges. + IF (ALLOW.EQ.0) THEN ! If owner doesn't have privileges,T + WRITE(6,1040) ! Then error out.( + GO TO 100 + ELSE + CALL CLOSE_FILE (2) + WRITE (6,1050) ! Make sure user wants to delete it + READ (5,'(A)',IOSTAT=IER) ANSWERi + CALL STR$UPCASE(ANSWER,ANSWER)n + IF (ANSWER.NE.'Y') GO TO 100n + CALL OPEN_FILE(2) + CALL READDIR(BULL_DELETE,IER) ! Get info for specified bulletin + IF (IER.NE.BULL_DELETE+1) THEN ! Was bulletin found?I + WRITE(6,1030) ! If not, then error out. + GOTO 100 + END IFE + END IF + END IF( + +C. +C Delete the bulletin from the bulletin file. +CC + + CALL OPEN_FILE(1) ! Open BULLETIN file + + CALL COPY_BULL(1,BLOCK+LENGTH,BLOCK,IER)! Delete the bulletin byL + ! overwriting rest of file + + CLOSE (UNIT=1)E + +C +C Delete the bulletin directory entry.( +CT + + CALL DELETE_ENTRY(BULL_DELETE) ! Delete the directory entry: + + TRUNC_SIZE = (NBLOCK*80)/512 + 1 ! Truncate bulletin file + CALL TRUNCATE_FILE(TRUNC_SIZE) ! To remove extra space + + IF ((SYSTEM.AND.4).EQ.4) THEN ! Was entry shutdown bulletin? + SHUTDOWN = SHUTDOWN - 1 ! Decrement shutdown count + END IF1 + + CALL UPDATE ! Somewhat a kludgey way of updating latest + ! bulletin and expired dates. + +100 CALL CLOSE_FILE(2) +900 RETURN + +910 WRITE(6,1010) + GO TO 900 + +920 WRITE(6,1020)E + GO TO 900 + +1010 FORMAT(' ERROR: You are not reading any bulletin.') +1020 FORMAT(' ERROR: Specified bulletin number has incorrect format.') +1030 FORMAT(' ERROR: Specified bulletin was not found.') +1040 FORMAT(' ERROR: Specified bulletin is not owned by you.') +1050 FORMAT(' Bulletin is not owned by you.',T + & ' Are you sure you want to delete it? ',$) + +2000 FORMAT(A107)c + + END + + + + + SUBROUTINE DIRECTORY(DIR_COUNT) +Cr +C SUBROUTINE DIRECTORYR +C +C FUNCTION: Display directory of bulletins. +Ce + IMPLICIT INTEGER (A - Z)F + + INCLUDE 'BULLDIR.INC' + + COMMON /PAGE/ PAGE_LENGTH + + DATA SCRATCH_D1/0/I + + CALL LIB$ERASE_PAGE(1,1) ! Clear the screenD + + IF (DIR_COUNT.GT.0) GO TO 50 ! Skip init steps if this isE + ! not the 1st page of directoryM + +C +C Directory listing is first buffered into temporary memory storage before( +C being outputted to the terminal. This is to be able to quickly close the +C directory file, and to avoid the possibility of the user holding the screen,( +C and thus causing the directory file to stay open. The temporary memory +C is structured as a linked-list queue, where SCRATCH_D1 points to the header +C of the queue. See BULLSUBS.FOR for more description of the queue.( +CM + + IF (SCRATCH_D1.EQ.0) THEN ! Is queue empty?, + CALL LIB$GET_VM(100,SCRATCH_D) ! If so, allocated memory + CALL MAKE_CHAR(%VAL(SCRATCH_D),88) ! Form a character string + SCRATCH_D1 = SCRATCH_D ! Init header pointer' + ELSE ! Else queue is not emptyE + SCRATCH_D = SCRATCH_D1 ! so reinit queue pointer. + END IF ! to the header. + + CALL OPEN_FILE_SHARED(2) ! Get directory fileD + + CALL READDIR(0,IER) ! Does directory header exist?R + IF (IER.EQ.1) THEN ! If so, there are bulletins + DO I=1,NBULL ! Copy all bulletins from file + CALL READDIR(I,IER) ! Into the queue + CALL WRITE_DIR(%VAL(SCRATCH_D),SCRATCH_D) + END DO + END IFD + + CALL CLOSE_FILE(2) ! We don't need file anymore + +CN +C Directory entries are now in queue. Output queue entries to screen.U +Ce + + SCRATCH_D = SCRATCH_D1 ! Init queue pointer to header + + DIR_COUNT = 1 ! Init directory number counteri + +50 DISPLAY = MIN(NBULL-DIR_COUNT+1,PAGE_LENGTH-6) + ! If more entries then page size, truncate output + WRITE(6,1000) ! Write header + DO I=DIR_COUNT,DIR_COUNT+DISPLAY-1 + CALL READ_DIR(%VAL(SCRATCH_D),SCRATCH_D) ! Get entry from queue + WRITE(6,2010) I,DESCRIP,FROM,DATE(1:7)//DATE(10:11)R + END DOh + + DIR_COUNT = DIR_COUNT + DISPLAY ! Update directory counter + + IF (DIR_COUNT.GT.NBULL) THEN ! Outputted all entries? + DIR_COUNT = 0 ! Yes. Set counter to 0. + ELSE + WRITE(6,1010) ! Else say there are more + END IFB + + RETURNe + +1000 FORMAT(' #',1X,'DESCRIPTION',43X,'FROM',9X,'DATE',/)T +1010 FORMAT(1X,/,' Press RETURN for more...',/)( + +2000 FORMAT(A53,A12,A11) +2010 FORMAT(1X,I3,1X,A53,1X,A12,1X,A9) + + END + l + + SUBROUTINE FILE +C +C SUBROUTINE FILE +CS +C FUNCTION: Copies a bulletin to a file. +CL + IMPLICIT INTEGER (A - Z) + CHARACTER*107 DIRLINE + CHARACTER*80 INPUTd + + COMMON /POINT/ BULL_POINT + + COMMON /BULLPAR/ BULL_PARAMETER,LEN_P + CHARACTER*64 BULL_PARAMETER + + INCLUDE 'BULLDIR.INC' + + EXTERNAL CLI$_ABSENT3 + + DIMENSION SETPRV(2) + DATA SETPRV/Z10000000,0/ ! SYSPRV privileges + + IER = CLI$GET_VALUE('FILESPEC',BULL_PARAMETER,LEN_P)! + + IF (IER.EQ.%LOC(CLI$_ABSENT)) THEN ! If no file name was specifiedr + WRITE(6,1020) ! Write error + RETURN ! And returno + END IFr + + IF (BULL_POINT.EQ.0) THEN ! If no bulletin has been read) + WRITE(6,1010) ! Write error + RETURN ! And returnt + END IFN + + CALL OPEN_FILE_SHARED(2)R + + CALL READDIR(BULL_POINT,IER) ! Get info for specified bulletinT + + IF (IER.NE.BULL_POINT+1) THEN ! Was bulletin found? + WRITE(6,1030)T + CALL CLOSE_FILE(2) ! If not, then error out + RETURN + END IFs + + CALL CLOSE_FILE(2) + + CALL OPEN_FILE_SHARED(1) ! Open BULLETIN file + + CALL GETPRIV(ALLOW) ! Does user have SETPRV privileges?r + IF (ALLOW.EQ.0) THEN ! If not, then remove SYSPRV + CALL SYS$SETPRV(%VAL(0),SETPRV,,) ! privileges when trying toS + END IF ! create new file. + + OPEN(UNIT=3,FILE=BULL_PARAMETER(1:LEN_P),ERR=900, + & STATUS='NEW',CARRIAGECONTROL='LIST') + CALL SYS$SETPRV(%VAL(1),SETPRV,,) ! Reset SYSPRV privileges + + IF (CLI$PRESENT('HEADER')) THEN ! Printout header? + WRITE(3,1050) DESCRIP ! Output bulletin header info + WRITE(3,1060) FROM,DATER + END IFd + + DO I=BLOCK,BLOCK+LENGTH-1 ! Copy bulletin into file + READ(1'I,2010,ERR=100) INPUT + CALL STR$TRIM(INPUT,INPUT,LEN) + WRITE(3,2010) INPUT(1:LEN) + END DO + + CLOSE (UNIT=3) ! Bulletin copy completed' + + WRITE(6,1040) BULL_POINT,BULL_PARAMETER(1:LEN_P)R + ! Show name of file created.i +100 CALL CLOSE_FILE(1) + RETURNr + +900 WRITE(6,1000)E + CALL SYS$SETPRV(%VAL(1),SETPRV,,) ! Reset BYPASS privileges + GO TO 100 + +1000 FORMAT(' ERROR: Error in opening file.')f +1010 FORMAT(' ERROR: You have not read any bulletin.') +1020 FORMAT(' ERROR: No file name was specified.') +1030 FORMAT(' ERROR: Specified bulletin was not found.') +1040 FORMAT(' Bulletin ',I3,' written to ',A)2 +1050 FORMAT('DESCRIPTION: ',A53) +1060 FORMAT('FROM: ',A12,' DATE: ',A11,/)' + +2000 FORMAT(A107)R +2010 FORMAT(A) + + END + + + + + SUBROUTINE LOGIN(READIT)l +Ce +C SUBROUTINE LOGIN( +C) +C FUNCTION: Alerts user of new bulletins upon logging in. +C Also saves latest login time, which is accessed by FINGER. +Cu + IMPLICIT INTEGER (A - Z)t + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLUSER.INC'R + + CHARACTER*23 TODAY + + COMMON/INPUT_BULL/INPUT + CHARACTER*80 INPUTM + + COMMON /PAGE/ PAGE_LENGTH + + COMMON /TERM_CHAN/ TERM_CHANN + + CHARACTER BBOARD_DATE*11,BBOARD_TIME*8 + + LOGICAL*1 CTRL_G/7/ + + EXTERNAL IO$_READVBLK,IO$M_NOECHO,IO$M_PURGE + + INCLUDE '($FORIOSDEF)'C + + CALL SYS$ASCTIM(,TODAY,,) ! Get the present time + +CI +C Find user entry in BULLUSER.DAT to update information and +C to get the last date that bulletins were read.! +Cs + + CALL OPEN_FILE_SHARED(4) ! Open user fileE + +10 READ (4,1000,KEY=' ',IOSTAT=IER) ! Get the headero + & USERNAME,NEWEST_DATE,NEWEST_TIME,BBOARD_DATE,BBOARD_TIME,FLAGS + IF (IER.EQ.FOR$IOS_SPERECLOC) GO TO 10 ! If locked record,try again + IF (IER.EQ.0) UNLOCK 4 ! If no error, unlock read + + CALL GETUSER(USERNAME) ! Get present username + + READ (4,1000,KEY=USERNAME,ERR=20,IOSTAT=IER1) USERNAME, + & LOGIN_DATE,LOGIN_TIME,READ_DATE,READ_TIME,FLAGS + ! Find if there is an entryo + + REWRITE (4,1000) USERNAME,TODAY(1:11),TODAY(13:20), + & READ_DATE,READ_TIME,FLAGS ! Update login dateG + + IF (FLAGS(1).AND.1) READIT = 1h + + GO TO 30. + +20 READ_DATE = ' 5-NOV-1956' ! No entry, so make new one + READ_TIME = '11:05:56' ! Fake a read date. Set to the past.0 + FLAGS(1) = 0 + FLAGS(2) = 0I + WRITE (4,1000,IOSTAT=IER) USERNAME,TODAY(1:11),TODAY(13:20), + & READ_DATE,READ_TIME,FLAGS) + IF (IER.NE.0) THEN ! Error in writing to user file + WRITE (6,1070) ! Tell user of the error + CALL CLOSE_FILE(4) ! Close the user fileE + CALL EXIT ! Go away... + END IF + CALL CLEANUP_LOGIN ! Good time to delete dead usersd + DIFF = -1 ! Force us to look at the bulletins + +30 IF (IER.EQ.0.AND.(BBOARD_DATE.NE.TODAY(1:11).OR.! Look for BBOARD mailt + & BBOARD_TIME(1:2).NE.TODAY(13:14)) ) THEN ! when hour changes + READ (4,1000,KEY=' ') ! Get the headerR + & USERNAME,NEWEST_DATE,NEWEST_TIME,BBOARD_DATE,BBOARD_TIME,FLAGS + REWRITE (4,1000) ! Rewrite headero + & USERNAME,NEWEST_DATE,NEWEST_TIME,TODAY(1:11),TODAY(13:20),FLAGSr + CALL CLOSE_FILE(4) + CALL BBOARD ! Convert any BBOARD mail to bulletins + ELSEN + CALL CLOSE_FILE(4) + IF (IER.NE.0) CALL EXIT ! If no header, no bulletins + END IFl + IF (IER1.NE.0) GO TO 40 ! Skip date comparison if new entry + +CD +C Compare and see if bulletins have been added since the last time +C that the user has logged in or used the BULLETIN facility. +CU + + DIFF = COMPARE_DATE(LOGIN_DATE,READ_DATE) + IF (DIFF.EQ.0) DIFF = COMPARE_TIME(LOGIN_TIME,READ_TIME)t + IF (DIFF.LT.0) THEN ! If read bulletins since last login,e + LOGIN_TIME = READ_TIME ! then use the read date to compare + LOGIN_DATE = READ_DATE ! with the latest bulletin date + END IF ! to see if should alert user.A + + DIFF = COMPARE_DATE(LOGIN_DATE,NEWEST_DATE) + IF (DIFF.EQ.0) DIFF = COMPARE_TIME(LOGIN_TIME,NEWEST_TIME)( + +Cc +C If there are new bulletins, look for them in BULLDIR.DATB +C Save all new entries in the SCRATCH_D file BULLCHECK.SCR so +C that we can close BULLDIR.DAT as soon as possible.I +CN + +40 IF (DIFF.LE.0) THEN ! Are there new unread bulletins?C + CALL OPEN_FILE_SHARED(2) ! Yes, so go get bulletin directory + NEW_BULLS = 0 ! Number of new bulletins + NSYS = 0 ! Number of system bulletins + CALL READDIR(0,IER) ! Get header info + CALL LIB$GET_VM(100,SCRATCH_D) + CALL MAKE_CHAR(%VAL(SCRATCH_D),88) + SCRATCH_D1 = SCRATCH_D + DO ICOUNT = NBULL,1,-1 + CALL READDIR(ICOUNT,IER)u + IF (IER1.EQ.0) THEN ! Is this a totally new user? + ! No. Is bulletin system or from same user?t + DIFF = COMPARE_DATE(LOGIN_DATE,DATE) ! No, so compare date + IF (DIFF.EQ.0) DIFF = COMPARE_TIME(LOGIN_TIME,TIME)e + IF (DIFF.GT.0) GO TO 100D + IF (USERNAME.NE.FROM.OR.SYSTEM) THENL + IF (DIFF.LE.0) THEN ! Is bulletin new? + CALL WRITE_DIR(%VAL(SCRATCH_D),SCRATCH_D) + NEW_BULLS = NEW_BULLS + 1 ! Yep, so save itn + IF (SYSTEM) NSYS = NSYS + 1e + END IF + END IF + ELSE ! Totally new user, save all bulletins + CALL WRITE_DIR(%VAL(SCRATCH_D),SCRATCH_D) + NEW_BULLS = NEW_BULLS + 1 + IF (SYSTEM) NSYS = NSYS + 1 + END IFR + END DO +100 CALL CLOSE_FILE(2)a + +Cl +C Review new directory entries. If there are system bulletins, +C copy the system bulletin into SCRATCH_D file BULLSYS.SCR for outputting +C to the terminal. If there are simple bulletins, just output thet +C header information. +C + + IF (NEW_BULLS.EQ.0) CALL EXIT + IO_READ = %LOC(IO$_READVBLK)+%LOC(IO$M_NOECHO)+%LOC(IO$M_PURGE)n + PAGE = 0 + NEW_BULLS = NEW_BULLS - NSYS + IF (NSYS.GT.0) THEN ! Are there any system bulletins? + WRITE (6,1026) CTRL_G ! Yep...e + PAGE = PAGE + 1 + CTRL_G = 0 ! Don't ring bell for non-system bullsI + CALL OPEN_FILE_SHARED(1) + CALL LIB$GET_VM(92,SCRATCH_B) + CALL MAKE_CHAR(%VAL(SCRATCH_B),80)0 + SCRATCH_B1 = SCRATCH_BE + SCRATCH_D = SCRATCH_D1T + DO WHILE (NSYS.GT.0) ! Find which new bulls are systemC + CALL READ_DIR(%VAL(SCRATCH_D),SCRATCH_D) + IF (SYSTEM) THEN ! If it is a system bulletin + INPUT = ' ' + CALL WRITE_BULL(%VAL(SCRATCH_B),SCRATCH_B) + DO I=BLOCK,BLOCK+LENGTH-1 ! Copy the bulletin to SCRATCH_D + READ(1'I,1050,ERR=999) INPUT + CALL WRITE_BULL(%VAL(SCRATCH_B),SCRATCH_B)M + END DO + NSYS = NSYS - 1 ! Decrement system bulletin count + END IFE + END DOH + CALL CLOSE_FILE(1) + PAGE = 1 + SCRATCH_B = SCRATCH_B1e + DO WHILE (SCRATCH_B.NE.0) ! Write out the system bulletinsE + CALL READ_BULL(%VAL(SCRATCH_B),SCRATCH_B) + CALL STR$TRIM(INPUT,INPUT,LEN) + IF (SCRATCH_B.NE.0) THEN + IF (PAGE.EQ.PAGE_LENGTH-2) THEN ! If at end of screen + WRITE(6,1080) ! Ask for input to proceed to next page5 + IER = SYS$QIOW(,%VAL(TERM_CHAN),%VAL(IO_READ),,,, + & %VAL(%LOC(INREAD)),%VAL(1),,,,) + CALL LIB$ERASE_PAGE(1,1) ! Clear the screen + WRITE(6,1065) INPUT(1:LEN) + PAGE = 1 + ELSE + WRITE(6,1060) INPUT(1:LEN) + PAGE = PAGE + 1R + END IFA + END IFL + END DOI +150 WRITE(6,1050) ! Write delimiting blank line + END IF + SCRATCH_D = SCRATCH_D1 + IF (NEW_BULLS.GT.0) THEN ! Are there new non-system bulletins? + IF (PAGE.NE.0) THEN ! Yep..._ + WRITE(6,1080) ! Ask for input to proceed to next page, + IER = SYS$QIOW(,%VAL(TERM_CHAN),%VAL(IO_READ),,,, + & %VAL(%LOC(INREAD)),%VAL(1),,,,)e + CALL LIB$ERASE_PAGE(1,1) ! Clear the screen + WRITE(6,1028) CTRL_G + ELSE + WRITE(6,1027) CTRL_G + END IFL + WRITE(6,1020) + WRITE(6,1025) + PAGE = 3. + DO WHILE (SCRATCH_D.NE.0) + CALL READ_DIR(%VAL(SCRATCH_D),SCRATCH_D) + IF (.NOT.SYSTEM.AND.SCRATCH_D.NE.0) THEN + IF (PAGE.EQ.PAGE_LENGTH-2) THEN ! If at end of screen + WRITE(6,1080) ! Ask for input to proceed to next pagel + IER = SYS$QIOW(,%VAL(TERM_CHAN),%VAL(IO_READ),,,,V + & %VAL(%LOC(INREAD)),%VAL(1),,,,)l + CALL LIB$ERASE_PAGE(1,1) ! Clear the screen( + PAGE = 1 + WRITE(6,1045) DESCRIP,FROM,DATEG + ELSEI + PAGE = PAGE + 1A + WRITE(6,1040) DESCRIP,FROM,DATEE + END IF) + END IFr + END DO + END IF + IF (NEW_BULLS.GT.0.AND.READ_DATE.EQ.' 5-NOV-1956') THEN0 + WRITE (6,1035) ! Tell novice how to read the non-system bulls + ELSE + WRITE(6,1030) + END IF + END IFS + +998 RETURN + +999 CALL CLOSE_FILE(1) ! Just in case bulletins gets deleted + GO TO 998 ! while we are trying to read it (unlikely)L + +1000 FORMAT(A12,A11,A8,A11,A8,2A4) +1005 FORMAT(A53,A12,A11,A8,A4,A11,A4)L +1020 FORMAT(' DESCRIPTION',43X,'FROM',9X,'DATE') +1025 FORMAT(' -----------',43X,'----',9X,'----') +1026 FORMAT(' ',33('*'),'SYSTEM NOTICES',33('*'),A1) +1027 FORMAT(' ',33('*'),'NEW BULLETINS',34('*'),A1)e +1028 FORMAT('+',33('*'),'NEW BULLETINS',34('*'),A1) +1030 FORMAT(' ',80('*')) +1035 FORMAT(' ',14('*'), + & 'USE THE BULLETIN COMMAND TO READ THE ABOVE BULLETINS',14('*')) +1040 FORMAT(' ',A53,1X,A12,1X,A11) +1045 FORMAT(' ',A53,1X,A12,1X,A11) +1050 FORMAT(A) +1060 FORMAT(1X,A)A +1065 FORMAT('+',A) +1070 FORMAT(' ERROR: Cannot add new entry to BULLETIN user file.') +1080 FORMAT(' ',/,' HIT any key for next page....') + + END + + + + + SUBROUTINE READ(READ_COUNT,BULL_READ) +C +C SUBROUTINE READ +CA +C FUNCTION: Reads a specified bulletin. +C' + IMPLICIT INTEGER (A - Z)R + + COMMON /POINT/ BULL_POINT + + INCLUDE 'BULLDIR.INC' + + COMMON/INPUT_BULL/INPUT + CHARACTER*80 INPUTR + + COMMON /READIT/ READITA + + COMMON /PAGE/ PAGE_LENGTH + + DATA SCRATCH_B1/0/_ + + CALL LIB$ERASE_PAGE(1,1) ! Clear screen$ + END = 0 ! Nothing outputted on screen + + IF (READ_COUNT.GT.0) GO TO 100 ! Skip init steps if this isr + ! not first page of bulletin + + IF (BULL_READ.GT.0) THEN ! Valid bulletin number?r + CALL OPEN_FILE_SHARED(2) + CALL READDIR(BULL_READ,IER) ! Get bulletin directory entry + CALL CLOSE_FILE(2) + ELSEo + IER = 0E + END IFE + + IF (IER.NE.BULL_READ+1) THEN ! Was bulletin found? + WRITE(6,1030) ! If not, then error out + GOTO 900 + END IF + + BULL_POINT = BULL_READ ! Update bulletin counterL + + WRITE(6,1040) BULL_POINT ! Output bulletin header info + WRITE(6,1050) DESCRIP + WRITE(6,1060) FROM,DATE,EXDATEI + + END = 4 ! Outputted 4 lines to screen + + READ_COUNT = BLOCK ! Init bulletin record counter + +CA +C Each page of the bulletin is buffered into temporary memory storage befored +C being outputted to the terminal. This is to be able to quickly close the +C bulletin file, and to avoid the possibility of the user holding the screen, +C and thus causing the bulletin file to stay open. The temporary memory= +C is structured as a linked-list queue, where SCRATCH_B1 points to the header +C of the queue. See BULLSUBS.FOR for more description of the queue. +Ce + + IF (SCRATCH_B1.NE.0) THEN ! Is queue empty?l + SCRATCH_B = SCRATCH_B1 ! No, set queue pointer to headC + ELSE ! Else if queue is empty + CALL LIB$GET_VM(92,SCRATCH_B) ! Allocate first recordl + CALL MAKE_CHAR(%VAL(SCRATCH_B),80) ! Form into character stringo + SCRATCH_B1 = SCRATCH_B ! Init header pointerA + END IF + +100 SCRATCH_B = SCRATCH_B1 ! Init queue pointer to header) + IF (READIT.GT.0) END = END - 2 ! /READ can output 2 more lines + DISPLAY = MIN(LENGTH,PAGE_LENGTH-END-4) ! Figure how much can output + CALL OPEN_FILE_SHARED(1) ! Get bulletin file + DO I=READ_COUNT,READ_COUNT+DISPLAY-1 ! Get page full from bulletin + READ(1'I,2000,IOSTAT=IER) INPUT ! Read bulletin record + IF (IER.NE.0) GO TO 105 + CALL WRITE_BULL(%VAL(SCRATCH_B),SCRATCH_B) ! Save record in queue + END DOp + GO TO 107 + +105 DISPLAY = I - READ_COUNT ! If read error, output only this muche + LENGTH = DISPLAY ! This forces the bulletin read to ends + +107 CALL CLOSE_FILE(1) ! End of bulletin file read + +CD +C Bulletin page is now in temporary memory, so output to terminal.I +C Note that if this is a /READ, the first line will have problems withO +C the usual FORMAT statement. It will cause a blank line to be outputted +C at the top of the screen. This is because of the input QIO at the +C end of the previous page. The output gets confused and thinks it must0 +C end the previous line. To prevent that, the first line of a new page +C in a /READ must use a different FORMAT statement to surpress the CR/LF. +CH + + SCRATCH_B = SCRATCH_B1 ! Reinit queue pointer to head + DO I=READ_COUNT,READ_COUNT+DISPLAY-1 ! Output page to terminale + CALL READ_BULL(%VAL(SCRATCH_B),SCRATCH_B) ! Get the queue record + CALL STR$TRIM(INPUT,INPUT,LEN) ! Strip leading blanks + IF (I.EQ.READ_COUNT.AND.I.NE.BLOCK.AND.READIT.GT.0) THEN + WRITE(6,2020) INPUT(1:LEN) ! (See above comments) + ELSE + WRITE(6,2010) INPUT(1:LEN)8 + END IF + END DOS + +110 READ_COUNT = READ_COUNT + DISPLAY ! Update bull record counter + + LENGTH = LENGTH - DISPLAY ! Length of remaining records + IF (LENGTH.EQ.0) THEN ! If no more recordst + READ_COUNT = 0 ! init bulletin record counter, + ELSE IF (READIT.EQ.0) THEN ! Else if this is not /READ + WRITE(6,1070) ! say there is more of bulletin + END IFE + +900 RETURN + +910 WRITE(6,1010) + GO TO 900 + +1010 FORMAT(' ERROR: You are not reading any bulletin.') +1030 FORMAT(' ERROR: Specified bulletin was not found.') +1040 FORMAT('+BULLETIN NUMBER: ',I3) +1050 FORMAT(' DESCRIPTION: ',A53)D +1060 FORMAT(' FROM: ',A12,' DATE: ',A11,' EXPIRES: ',A11,/)b +1070 FORMAT(1X,/,' Press RETURN for more...',/)C + +2000 FORMAT(A) +2010 FORMAT(1X,A) +2020 FORMAT('+',A) + + END + + + + + SUBROUTINE READNEW +C +C SUBROUTINE READNEW +Cl +C FUNCTION: Displays new non-system bulletins with prompts between bulletins. +Ct + + IMPLICIT INTEGER (A-Z)f + + COMMON /BULLPAR/ BULL_PARAMETER,LEN_P + CHARACTER*64 BULL_PARAMETER + + INCLUDE 'BULLDIR.INC' + + COMMON /POINT/ BULL_POINT + + COMMON /TERM_CHAN/ TERM_CHANE + + EXTERNAL IO$_READVBLK,IO$M_NOECHO,IO$M_PURGEN + + CHARACTER*1 INREADn + + LEN_P = 0 ! Tells read subroutine there is + ! no bulletin paramter' + IO_READ = %LOC(IO$_READVBLK)+%LOC(IO$M_NOECHO)+%LOC(IO$M_PURGE) + WRITE(6,1000) ! Ask if want to read new bulletins + IER=SYS$QIOW(,%VAL(TERM_CHAN),%VAL(IO_READ),,,, ! Use QIOsL + & %VAL(%LOC(INREAD)),%VAL(1),,,,) ! So no prompt is needed + CALL STR$UPCASE(INREAD,INREAD) ! Make input upper case + IF (INREAD.EQ.'N') CALL EXIT ! If NO, exit + +5 CALL READ(READ_COUNT,BULL_POINT+1) ! Read next bulletinR + IF (READ_COUNT.EQ.0) THEN ! Is full bulletin displayed?D + CALL OPEN_FILE_SHARED(2) ! If so, see if more new bulls +10 CALL READDIR(BULL_POINT+1,IER) + IF (IER.NE.BULL_POINT+2) THEN ! If no new bulls, exit. + CALL CLOSE_FILE(2) + IF (INREAD.EQ.'N') WRITE (6,1010) + CALL EXIT + ELSE IF (SYSTEM) THEN ! If bull is system + BULL_POINT = BULL_POINT + 1 ! If so, just skip it.$ + GO TO 10! + END IF + CALL CLOSE_FILE(2) + END IFU + + IF (READ_COUNT.EQ.0) THEN ! Prompt user in between + WRITE(6,1020) ! full screens or end of bull. + ELSE + WRITE(6,1030)E + END IF5 + + IER=SYS$QIOW(,%VAL(TERM_CHAN),%VAL(IO_READ),,,, ! Use QIOsF + & %VAL(%LOC(INREAD)),%VAL(1),,,,) ! So no prompt is needed + CALL STR$UPCASE(INREAD,INREAD) ! Convert input to upper case. + + IF (INREAD.EQ.'Q') THEN ! If Q , then QUIT + CALL EXIT + ELSE IF (INREAD.EQ.'N'.AND.READ_COUNT.GT.0) THEN, + ! If NEXT and last bulletins not finishede + READ_COUNT = 0 ! Reset read bulletin counter + CALL OPEN_FILE_SHARED(2) ! Look for NEXT bulletin +20 CALL READDIR(BULL_POINT+1,IER) + IF (IER.NE.BULL_POINT+2) THEN ! If no NEXT bulletin. + CALL CLOSE_FILE(2) ! Exit + WRITE(6,1010) + CALL EXIT + ELSE IF (SYSTEM) THEN ! Else if NEXT bulletin SYSTEMH + BULL_POINT = BULL_POINT + 1 ! Skip it + GO TO 20 ! Look for more bulletins + END IF + CALL CLOSE_FILE(2) + END IFE + GO TO 5 + +1000 FORMAT(' Read new bulletins? Type N(No) or any otherO + & key for yes',$) +1010 FORMAT(' No more messages.')E +1020 FORMAT(1X,80('-'),/,' Type Q(Quit) or any other key for + & next message.',$) +1030 FORMAT(1X,80('-'),/,' Type Q(Quit), N(Next message), or + & any other key for MORE... ',$)D + + END + + + + + SUBROUTINE REPLACE +CD +C SUBROUTINE REPLACEF +CE +C FUNCTION: Replaces existing bulletin to bulletin file.W +CE + IMPLICIT INTEGER (A - Z) + + COMMON /POINT/ BULL_POINT + + COMMON /BULLPAR/ BULL_PARAMETER,LEN_P + CHARACTER*64 BULL_PARAMETER + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLUSER.INC'l + + CHARACTER*11 INEXDATE + CHARACTER*80 INDESCRIP,INPUTe + CHARACTER*1 ANSWER1 + + INTEGER TIMADR(2) + + COMMON /TERM_CHAN/ TERM_CHAN, + + COMMON /CTRLY/ CTRLYI + + EXTERNAL CLI$_ABSENTE + + DIMENSION SETPRV(2) + DATA SETPRV/Z10000000,0/ ! SYSPRV privileges + + LOGICAL*1 DOALL + +C( +C Get the bulletin number to be replaced. +CS + IF (.NOT.CLI$PRESENT('NUMBER')) THEN ! No number has been specified + IF (BULL_POINT.EQ.0) THEN ! If no bulletin has been read + WRITE (6,1005) ! Tell user of the errorI + RETURN ! and return + END IF + NUMBER_PARAM = BULL_POINT ! Replace the bulletin we are readingA + ELSEA + CALL CLI$GET_VALUE('NUMBER',BULL_PARAMETER,LEN_P)e + DECODE(LEN_P,'(I<LEN_P>)',BULL_PARAMETER) NUMBER_PARAM + END IF + +Cp +C Check to see if specified bulletin is present, and if the user +C is permitted to replace the bulletin. +Cs + + CALL OPEN_FILE_SHARED(2)I + + CALL READDIR(NUMBER_PARAM,IER) ! Get info for specified bulletinU + + IF (IER.NE.NUMBER_PARAM+1) THEN ! Was bulletin found? + WRITE (6,1015) ! If not, tell the person/ + GOTO 100 ! and error out + END IFC + + IF (USERNAME.NE.FROM) THEN ! If doesn't match owner of bulletin,u + CALL GETPRIV(ALLOW) ! then see if owner has privileges. + IF (ALLOW.EQ.0) THEN ! If owner doesn't have privileges,B + WRITE(6,1090) ! Then error out.b + GO TO 100 + ELSE + CALL CLOSE_FILE(2) ! Let go of the file + WRITE (6,1100) ! Make sure user wants to delete it + READ (5,'(A)',IOSTAT=IER) ANSWER ! Get his answer + CALL STR$UPCASE(ANSWER,ANSWER) ! Convert input to uppercase + IF (ANSWER.NE.'Y') GO TO 100 ! If not Yes, then exitl + END IF + END IFI + + CALL CLOSE_FILE(2)! + +Cu +C If no switches were given, replace the full bulletin1 +C) + + DOALL = .FALSE. + + IF ((.NOT.CLI$PRESENT('EXPIRATION')).AND. + & (.NOT.CLI$PRESENT('HEADER')).AND.d + & (.NOT.CLI$PRESENT('TEXT'))) THEN + DOALL = .TRUE. + END IFe + + CALL LIB$DISABLE_CTRL(CTRLY,) ! Disable CTRL-Y & -C + +5 IF (CLI$PRESENT('EXPIRATION').OR.DOALL) THEN + WRITE(6,1030) ! Prompt for expiration date + READ(5,2000,END=910,ERR=7) LEN,INEXDATEh + CALL STR$UPCASE(INEXDATE,INEXDATE) ! Convert to upper for BINTIM + IF (LEN.EQ.0) GO TO 910e + IER = SYS$BINTIM(INEXDATE,TIMADR(1)) ! Is date format valid? + IF ((IER.AND.1).NE.1) THEN ! If not, +7 WRITE(6,1040) ! tell usere + GO TO 5 ! and re-request date + END IF + IER = SYS$ASCTIM(,INEXDATE,TIMADR(1),) + IER = COMPARE_DATE(INEXDATE,' ') ! Compare date with today's + IF (IER.LE.0) THEN ! If expiration date not future + WRITE(6,1045) ! tell user + GO TO 5 ! and re-request date + END IF + END IFC + +8 IF (CLI$PRESENT('HEADER').OR.DOALL) THEN + WRITE(6,1050) ! Request header for bulletin + READ(5,2000,END=910,ERR=910) LEN,INDESCRIP + IF (LEN.EQ.0) GO TO 910 ! If no header, don't add bull + IF (LEN.GT.53) THEN ! If too many characters + WRITE(6,1060) ! tell user + WRITE(6,2020) INDESCRIP(1:53) ! Show how much would fit + GO TO 8 ! and re-request headerI + END IF + END IFB + + + IF (CLI$PRESENT('TEXT').OR.DOALL) THENp +CG +C If file specified in REPLACE command, read file to obtain bulletin. +C Else, read the bulletin from the terminal.b +Ce + + ICOUNT = 0 ! Line count for bulletin + + IER = CLI$GET_VALUE('FILESPEC',BULL_PARAMETER,LEN_P)t + IF (IER.NE.%LOC(CLI$_ABSENT)) THEN ! If file param in ADD command + + CALL GETPRIV(ALLOW) ! Does user have SETPRV privileges? + IF (ALLOW.EQ.0) THEN ! If not, then remove SYSPRV + CALL SYS$SETPRV(%VAL(0),SETPRV,,) ! privileges when trying to + END IF ! create new file. + + OPEN (UNIT=3,FILE=BULL_PARAMETER(1:LEN_P),STATUS='OLD',READONLY, + & SHARED,ERR=920,FORM='FORMATTED') ! Try opening the file + + CALL SYS$SETPRV(%VAL(1),SETPRV,,) ! Reset SYSPRV privilegesH + + DO WHILE(1) ! Read until end of file to + READ (3,2000,END=10) ! get record countg + ICOUNT = ICOUNT + 1 + END DO + ELSE ! If no input file + OPEN (UNIT=3,STATUS='SCRATCH',FILE='SYS$LOGIN:BULL.SCR', + & FORM='FORMATTED') ! Scratch file to save bulletin + WRITE (6,1000) ! Request bulletin input from terminal + LEN = 81 ! Length of input line + DO WHILE (LEN.GE.0) ! Input until no more inputT + CALL GET_LINE(INPUT,LEN) ! Get input liner + IF (LEN.GE.0) THEN ! If good input line enteredo + ICOUNT = ICOUNT + 1 ! Increment record count + WRITE(3,2010) INPUT(1:LEN) ! Save line in scratch fileE + END IFE + END DO + IF (LEN.EQ.-1) GO TO 910 ! CTRL_C entered, error out +10 IF (ICOUNT.EQ.0) GO TO 910 ! No lines entered, error out + ENDIF + + REWIND (UNIT=3) + END IFa + +Ct +C Add bulletin to bulletin file and directory entry for to directory file.n +C) + + CALL OPEN_FILE(2) ! Prepare to add dir entry( + + CALL READDIR(NUMBER_PARAM,IER) ! Get info for bulletin + CALL READDIR(0,IER) ! Get directory headere + + IF (CLI$PRESENT('TEXT').OR.DOALL) THEN ! If text has been replacedF + CALL OPEN_FILE(1) ! Prepare to add bulletin + IF (ICOUNT.LT.LENGTH) THEN ! If new bulletin smaller... + CALL COPY_BULL(3,1,BLOCK,IER) ! Replace old bulletinI + CALL COPY_BULL(1,BLOCK+LENGTH,BLOCK+ICOUNT,IER) + ! Move up any future bulletins + ELSE IF (ICOUNT.EQ.LENGTH) THEN ! If new bulletin same sizeT + CALL COPY_BULL(3,1,BLOCK,IER) ! Replace old bulletin$ + ELSE ! If new bulletin is larger...0 + IF (NBULL.GT.NUMBER_PARAM) THEN ! If there are future bulletins + DO I=NBLOCK,BLOCK+LENGTH,-1 ! Move future bulletins down + READ (1'I,'(A80)') INPUTl + WRITE (1'I+ICOUNT-LENGTH,'(A80)') INPUTR + END DO + END IFV + CALL COPY_BULL(3,1,BLOCK,IER) ! Replace old bulletin + END IF + + CLOSE (UNIT=1) + + IF (ICOUNT.NE.LENGTH) THEN ! If new bull different size + DIFF = ICOUNT - LENGTH ! Get difference in sizei + CALL READDIR(NUMBER_PARAM,IER) ! Get directory entryD + LENGTH = ICOUNT ! Update size + CALL WRITEDIR(NUMBER_PARAM,IER) ! Write new directory entry + DO I=NUMBER_PARAM+1,NBULL ! Fix sizes of future bulletins- + CALL READDIR(I,IER) + BLOCK = BLOCK + DIFFE + CALL WRITEDIR(I,IER)B + END DOE + NBLOCK = NBLOCK + DIFF ! Update NBLOCK + IF (DIFF.LT.0) THEN ! If bulletin file smaller + TRUNC_SIZE = (NBLOCK*80)/512 + 1 ! Truncate file! + CALL TRUNCATE_FILE(TRUNC_SIZE)L + END IFR + CALL WRITEDIR(0,IER)n + END IF + END IFI + + CALL READDIR(NUMBER_PARAM,IER)n + IF (CLI$PRESENT('HEADER').OR.DOALL) DESCRIP=INDESCRIP(1:53) + ! Update description headerl + IF (CLI$PRESENT('EXPIRATION').OR.DOALL) EXDATE=INEXDATE + ! Update expiration date + CALL WRITEDIR(NUMBER_PARAM,IER) + + DIFF = COMPARE_DATE(EXDATE,NEWEST_EXDATE) ! Compare expirationu + IF (DIFF.LT.0) THEN ! If it's the oldest expiration bull + NEWEST_EXDATE = EXDATE ! Update the header in + CALL WRITEDIR(0,IER) ! the directory file + END IFo + + CALL CLOSE_FILE(2) ! Totally finished with replaceI + + CLOSE (UNIT=3)E + +100 CALL LIB$ENABLE_CTRL(CTRLY,) ! Enable CTRL-Y & -CO + RETURN) + +910 WRITE(6,1010) + CLOSE (UNIT=3,ERR=100)T + GOTO 100R + +920 WRITE(6,1020) + CALL SYS$SETPRV(%VAL(1),SETPRV,,) ! Reset SYSPRV privileges + GOTO 100 + +1000 FORMAT (' Enter bulletin: End with ctrl-z, cancel with ctrl-c') +1005 FORMAT (' ERROR: You are not reading any bulletin.') +1010 FORMAT (' No bulletin was replaced.') +1015 FORMAT (' ERROR: Specified bulletin was not found.')D +1020 FORMAT (' ERROR: Unable to open specified file.') +1030 FORMAT (' Enter expiration date of bulletin: dd-mmm-yyyy') +1040 FORMAT (' ERROR: Invalid date format specified.') +1045 FORMAT (' ERROR: Specified date has already passed.') +1050 FORMAT (' Enter description header. Limit header to 53 + & characters.') +1060 FORMAT (' ERROR: Header > 53 characters. Header would ben + & truncated to:') +1090 FORMAT(' ERROR: Specified bulletin is not owned by you.') +1100 FORMAT(' Bulletin is not owned by you.',u + & ' Are you sure you want to replace it? ',$)R +2000 FORMAT(Q,A) +2010 FORMAT(A) +2020 FORMAT(1X,A) + + END + + + + + SUBROUTINE UPDATE +C +C SUBROUTINE UPDATE +CN +C FUNCTION: Searches for bulletins that have expired and deletes them. +Cl +C NOTE: Assumes directory file is already opened.Z +C + IMPLICIT INTEGER (A - Z)T + CHARACTER*107 DIRLINE + + INCLUDE 'BULLDIR.INC' + + CHARACTER*11 TEMP_DATE/'5-NOV-2000'/ ! Default exp date if no bulls + CHARACTER*11 TEMP_EXDATEA + CHARACTER*8 TEMP_TIME + + NEW_EX = 0 ! Init expiration flagG + + CALL OPEN_FILE(1) ! Open both bulletin filesC + + BULL_ENTRY = 1 ! Init bulletin pointer + UPDATE_DONE = 0 ! Flag showing bull has been deletedS + + DO WHILE (1) + CALL READDIR(BULL_ENTRY,IER) ! Get next directory entry + IF (IER.EQ.BULL_ENTRY) GO TO 100 ! ERROR: Not founde + IF (SYSTEM.LE.1.OR.(SHUTDOWN.EQ.0 ! If not permanent, or shutdowns + & .AND.(SYSTEM.AND.4).EQ.4)) THEN ! bulletin and /SHUT specified? + IF ((SYSTEM.AND.4).EQ.4) THEN ! Shutdown bulletin? + DIFF = 0 ! If so, delete it + ELSEA + DIFF = COMPARE_DATE(EXDATE,' ') ! Has expiration date passed?L + END IFP + IF (DIFF.LE.0) THEN ! If so then delete bulletinf + CALL COPY_BULL(1,BLOCK+LENGTH,BLOCK,IER) ! Delete the bulletin by + ! rewriting rest of file + CALL DELETE_ENTRY(BULL_ENTRY) ! Delete bulletin entry + UPDATE_DONE = 1 ! Set bulletin deleted flag + ELSE IF (SYSTEM.LE.1) THEN ! Expiration date hasn't passed + ! If a bulletin is deleted, we'll have to update the latestN + ! expiration date. The following does that.u + IF (DIFF.LT.NEW_EX.OR.NEW_EX.EQ.0) THEN + TEMP_EXDATE = EXDATE ! If this is the latest expd + NEW_EX = DIFF ! date seen so far, save it. + END IF + BULL_ENTRY = BULL_ENTRY + 1 ! Increment bulletin counter + TEMP_DATE = DATE ! Keep date so when we quitd + TEMP_TIME = TIME ! search, we'll have the + END IF ! latest bulletin dateA + ELSE + BULL_ENTRY = BULL_ENTRY + 1 + END IF + END DO' + +100 DATE = NEWEST_DATE + TIME = NEWEST_TIME + CALL READDIR(0,IER) + NEWEST_EXDATE = TEMP_EXDATE + NEWEST_DATE = TEMP_DATE + NEWEST_TIME = TEMP_TIME + CALL WRITEDIR(0,IER) + CLOSE(UNIT=1) + + IF (UPDATE_DONE.EQ.1) THEN ! If any deletions occurred + TRUNC_SIZE = (NBLOCK*80)/512 + 1 ! truncate bulletin file. + CALL TRUNCATE_FILE(TRUNC_SIZE) + END IFT + + IF (TEMP_DATE.NE.DATE.OR.TEMP_TIME.NE.TIME) THEN( + NEWEST_DATE = TEMP_DATE ! If the newest bulletin date + NEWEST_TIME = TEMP_TIME ! has been changed, it must + CALL UPDATE_LOGIN ! be changed in BULLUSER.DAT + END IFe + + RETURNM + +1000 FORMAT(A11,A11,A8,A4,A4) +1020 FORMAT(A107)I + + END + + + + SUBROUTINE UPDATE_READi +C +C SUBROUTINE UPDATE_READH +C +C FUNCTION: +C Store the latest date that user has used the BULLETIN facility.e +C If new bulletins have been added, alert user of the fact and +C set the next bulletin to be read to the first new bulletin.y +C +C OUTPUTS:E +C BULL_POINT - If -1, no new bulletins to read, else there are.! +Cl + + IMPLICIT INTEGER (A - Z)n + + COMMON /POINT/ BULL_POINT + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLUSER.INC'H + + CHARACTER*23 TODAY + + INCLUDE '($FORIOSDEF)'i + + BULL_POINT = -1 ! Init bulletin pointerR + +C +C Update user's latest read time in his entry in BULLUSER.DAT.F +CE + + CALL OPEN_FILE_SHARED(4) ! Get BULLUSER.DAT file + +10 READ (4,1000,KEY=' ',IOSTAT=IER) ! Get newest bulletin + & USERNAME,NEWEST_DATE,NEWEST_TIME + IF (IER.EQ.FOR$IOS_SPERECLOC) GO TO 10 ! If record locked, retry) + + IF (IER.NE.0) THEN ! If header not present, exito + CALL CLOSE_FILE(4) + RETURN + END IF, + + UNLOCK 4 ! Release header record for other users to read + + CALL SYS$ASCTIM(,TODAY,,) ! Get today's time + + CALL GETUSER(USERNAME) ! Get users name + + READ (4,1000,KEY=USERNAME,IOSTAT=IER1) USERNAME, ! Find user's + & LOGIN_DATE,LOGIN_TIME,READ_DATE,READ_TIME,FLAGS ! info entry + + IF (IER1.EQ.0) THEN ! If entry found, update it + REWRITE (4,1000) USERNAME,LOGIN_DATE,LOGIN_TIME, + & TODAY(1:11),TODAY(13:20),FLAGS + ELSE ! else create a new entryR + WRITE (4,1000) USERNAME,TODAY(1:11),TODAY(13:20),, + & TODAY(1:11),TODAY(13:20),FLAGS + END IF + + CALL CLOSE_FILE(4) ! All finished with BULLUSER + +Ci +C Now see if bulletins have been added since the user's previousA +C read time. If they have, then search for the first new bulletin. +C Ignore new bulletins that are owned by the user or system notices +C that have not been added since the user has logged in. +CS + + DIFF = COMPARE_DATE(READ_DATE,NEWEST_DATE)) + IF (DIFF.EQ.0) DIFF = COMPARE_TIME(READ_TIME,NEWEST_TIME) + + IF (DIFF.LE.0.OR.IER1.NE.0) THEN ! New bulls or New user? + CALL OPEN_FILE_SHARED(2) ! Yep, so get directory file + CALL READDIR(0,IER) ! Get # bulletins from headern + IF (IER.EQ.1) THEN ! If header present + DO ICOUNT=1,NBULL ! Get each bulletin to comparer + CALL READDIR(ICOUNT,IER) ! its date with last read date + IF (FROM.NE.USERNAME) THEN ! Ignore bull if owner is user9 + DIFF = COMPARE_DATE(READ_DATE,DATE) + IF (DIFF.EQ.0) DIFF = COMPARE_TIME(READ_TIME,TIME)e + IF (DIFF.LE.0.OR.IER1.NE.0) THEN ! If new bull or new user + IF (SYSTEM) THEN ! If system bulletinR + DIFF = COMPARE_DATE(LOGIN_DATE,DATE) + IF (DIFF.EQ.0) DIFF = COMPARE_TIME(LOGIN_TIME,TIME) + IF (DIFF.LE.0) THEN ! If system bull, make it + BULL_POINT = ICOUNT - 1 ! the first new bull only. + GO TO 100 ! if added since user logged inL + END IF ! else he's read it already.l + ELSEC + BULL_POINT = ICOUNT - 1 ! If not system bull then + GO TO 100 ! make it the new bull + END IF + END IF + END IF + END DO) + END IF + END IFi + +100 CALL CLOSE_FILE(2) ! Its time for this program + RETURN ! to go home...H + +1000 FORMAT(A12,A11,A8,A11,A8,2A4) +1005 FORMAT(A53,A12,A11,A8,A4,A11,A4,A4) + + END + diff --git a/batch/seed/1985c-file3.mai b/batch/seed/1985c-file3.mai new file mode 100644 index 0000000000000000000000000000000000000000..96ff8676e0194efb52779b5ef8d4d1357a744ec8 --- /dev/null +++ b/batch/seed/1985c-file3.mai @@ -0,0 +1,1436 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 11:01 +Subj: [TCP/IP Mail From: MRL%PFCVAX@ZERMATT] BULLSUBS.FOR + + +Return-Path: <@MIT-ZERMATT.ARPA:MRL%MIT-PFC-VAX@MIT-MC.ARPA> +Received: from MIT-ZERMATT.ARPA by ari-hq1.ARPA ; 30 Oct 85 11:00:54 EST +Received: from MIT-PFC-VAX by ZERMATT via CHAOS with CHAOS-MAIL id 15463; Wed 30-Oct-85 10:54:56-EST +Date: 30 Oct 85 10:56:04 EST +From: MRL%PFCVAX@ZERMATT +Sender: MRL@MIT-PFC-VAX +To: BINGHAM@ARI-HQ1@ZERMATT +Subject: BULLSUBS.FOR + + SUBROUTINE BBOARD +C +C SUBROUTINE BBOARD +C +C FUNCTION: Converts mail to BBOARD into non-system bulletins. +C + + IMPLICIT INTEGER (A-Z) + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLFILES.INC' + + CHARACTER*11 INEXDATE + CHARACTER*80 INDESCRIP,INFROM,INPUT + + COMMON /CTRLY/ CTRLY + + CHARACTER*12 USERNAME + + IF (BBOARD_USER.EQ.'NONE') RETURN ! BBOARD disabled? + + CALL LIB$DISABLE_CTRL(CTRLY,) ! Disable CTRL-Y & -C + +C +C The process is set to the BBOARD uic and username in order to create +C a spawned process that is able to read the BBOARD mail (a real kludge). +C + + CALL GETUSER(USERNAME) ! Get present username + CALL GETUIC(GROUP,USER) ! Get present uic + IER = SETUSER(BBOARD_USER,USERNAME) ! Set to BBOARD username + IF (IER.EQ.2) GO TO 910 ! Can't set username. New VMS version? + READ(BBOARD_UIC(2:INDEX(BBOARD_UIC,',')-1),'(O)') GROUPB + READ(BBOARD_UIC(INDEX(BBOARD_UIC,',')+1:INDEX(BBOARD_UIC,']')-1) + & ,'(O)') USERB + CALL SETUIC(GROUPB,USERB) ! Set to BBOARD uic + IER = LIB$SPAWN('$@'//BBOARD_COMMAND,'NL:','NL:') + ! Create sequential mail file + CALL SETUSER(USERNAME) ! Reset to original username + CALL SETUIC(GROUP,USER) ! Reset to original uic + + OPEN (UNIT=3,FILE=BBOARD_FILE,STATUS='OLD',ERR=100) + +5 LEN = 1 + DO WHILE (LEN.GT.0) + READ (3,'(Q,A)',END=100) LEN,INPUT ! Read next line from mail + IF (INPUT(1:5).EQ.'From:') THEN + INFROM = INPUT(7:) ! Store username + ELSE IF (INPUT(1:5).EQ.'Subj:') THEN + INDESCRIP = INPUT(7:) ! Store subject + END IF + END DO + + +C +C Add bulletin to bulletin file and directory entry to directory file. +C + +10 CALL OPEN_FILE(2) ! Prepare to add dir entry + + READ (3,'(Q,A)',IOSTAT=IER) LEN,INPUT ! Read first line + IF (IER.NE.0) GO TO 100 ! If end of file, exit + IF (LEN.EQ.1.AND.INPUT(1:1).EQ.CHAR(12)) GO TO 5 + ! If line is just form feed, the message is empty + + CALL OPEN_FILE(1) ! Prepare to add bulletin + + CALL READDIR(0,IER) ! Get NBLOCK + IF (IER.EQ.0) NBLOCK = 0 ! If new file, NBLOCK is 0 + + ICOUNT = 0 ! Initialize line count + + SPACE = INDEX(INFROM,' ') - 1 ! Strip off the date + IF (SPACE.GT.0) INFROM = INFROM(1:SPACE)! From the "From:" line + + CALL STR$TRIM(INFROM,INFROM,LEN) ! Get length of From line + IF (LEN.GT.12) THEN ! Is it > allowable username length? + ICOUNT = ICOUNT + 1 ! If so, put From line in bulletin text + WRITE(1'NBLOCK+ICOUNT,'(A80)',ERR=930) 'From: '//INFROM(1:74) + IF (INDEX(INFROM,'::').GT.0) ! Strip off node name + & INFROM = INFROM(INDEX(INFROM,'::')+2:) + I = 12 ! Trim username to first non-alpha character + DO WHILE (I.GT.1.AND. + & ((INFROM(I:I).GE.'A'.AND.INFROM(I:I).LE.'Z').OR. + & (INFROM(I:I).GE.'a'.AND.INFROM(I:I).LE.'z')) ) + I = I - 1 + END DO + IF (I.GT.1) INFROM = INFROM(1:I-1) + END IF + + CALL STR$TRIM(INDESCRIP,INDESCRIP,LEN) ! Get length of Subj line + IF (LEN.GT.53) THEN ! Is it > allowable subject length? + ICOUNT = ICOUNT + 1 ! If so, put Subj line in bulletin text + WRITE(1'NBLOCK+ICOUNT,'(A80)',ERR=930) 'Subj: '//INDESCRIP(1:74) + I = 53 ! Trim subject to first space + DO WHILE (I.GT.1.AND.INDESCRIP(I:I).NE.' ') + I = I - 1 + END DO + IF (I.GT.1) INDESCRIP = INDESCRIP(1:I-1) + END IF + + DO WHILE (INPUT(1:1).NE.CHAR(12)) ! Move text to bulletin file + ICOUNT = ICOUNT + 1 + WRITE(1'NBLOCK+ICOUNT,'(A80)',ERR=930) INPUT + READ (3,'(A)',END=25) INPUT + END DO + +25 CLOSE (UNIT=1) ! Finished adding bulletin + + DESCRIP = INDESCRIP(1:53) ! Description header + FROM = INFROM(1:53) ! Username + CALL GET_EXDATE(EXDATE,7) ! Expires after a week + LENGTH = ICOUNT ! Number of records + + CALL ADD_ENTRY ! Add the new directory entry + +30 CLOSE (UNIT=2) ! Totally finished with add + + GO TO 5 ! See if there is more mail + +100 CLOSE (UNIT=3,STATUS='DELETE') ! Close the input file + CALL LIB$ENABLE_CTRL(CTRLY,) ! Enable CTRL-Y & -C + RETURN + +910 WRITE (6,1010) + GO TO 100 + +930 CLOSE (UNIT=3) + CALL CLOSE_FILE(3) + WRITE (6,1030) + GO TO 100 + +1010 FORMAT (' ERROR: Install BULLETIN with CMKRNL privileges or relink.') +1030 FORMAT (' ERROR: Alert system programmer. BULLETIN file problems.') + + END + + + + SUBROUTINE CLEANUP_LOGIN +C +C SUBROUTINE CLEANUP_LOGIN +C +C FUNCTION: Removes entries in user file of users that no longer exist. +C + CHARACTER*12 USERNAME + + OPEN (UNIT=7,FILE='SYS$SYSTEM:SYSUAF.DAT',SHARED,STATUS='OLD', + & ACCESS='KEYED',FORM='FORMATTED',ORGANIZATION='INDEXED',READONLY, + & ERR=30) + + READ (4,'(A12)',ERR=20,KEYGE=' ') USERNAME + ! Move pointer to top of file + +5 READ (4,'(A12)',ERR=20) USERNAME ! Get user entry + READ (7,'(A12)',KEY=USERNAME,ERR=10) USERNAME ! See if user exists + GO TO 5 ! If so, get next user entry + +10 DELETE(UNIT=4) ! Delete non-existant user + GO TO 5 ! Go get next user entry + +20 CLOSE (UNIT=7) ! All done... + +30 RETURN + END + + + + + SUBROUTINE CLOSE_FILE(INPUT) +C +C SUBROUTINE CLOSE_FILE +C +C FUNCTION: To close out the bulletin files and enable CTRL-C & -Y +C +C INPUT: +C INPUT - Unit number of file to close out. (EXCEPT FOR 3) +C 1 = BULLETIN.DAT +C 2 = BULLDIR.DAT +C 3 = Close out both 1 & 2 +C 4 = BULLUSER.DAT +C + + COMMON /CTRLY/ CTRLY + + CALL LIB$ENABLE_CTRL(CTRLY,) ! Re-enable breaks + + IF (INPUT.NE.3) THEN + CLOSE (UNIT=INPUT) + ELSE + CLOSE (UNIT=2) + CLOSE (UNIT=1) + END IF + + RETURN + END + + + + + SUBROUTINE COPY_BULL(INLUN,IBLOCK,OBLOCK,IER) +C +C SUBROUTINE COPY_BULL +C +C FUNCTION: To copy data to the bulletin file. +C +C INPUT: +C INLUN - Input logical unit number +C IBLOCK - Input block number in input file to start at +C OBLOCK - Output block number in output file to start at +C +C OUTPUT: +C IER - If error in writing to bulletin, IER will be <> 0. +C +C NOTES: Input file is accessed using sequential access. This is +C to allow files which have variable records to be read. The +C bulletin file is assumed to be opened on logical unit 1. +C + + IMPLICIT INTEGER (A - Z) + + CHARACTER*80 INPUT + + IF (INLUN.GT.1) THEN + DO I=1,IBLOCK-1 + READ(INLUN,1000) + END DO + END IF + + OCOUNT = OBLOCK + ICOUNT = IBLOCK + + DO WHILE (1) + IF (INLUN.EQ.1) THEN + READ(INLUN'ICOUNT,1000,ERR=100) INPUT + ICOUNT = ICOUNT + 1 + ELSE + LEN = 0 + DO WHILE (LEN.EQ.0) + READ(INLUN,'(Q,A)',END=100) LEN,INPUT + IF (LEN.EQ.0) THEN + INPUT(1:) = ' ' + LEN = 1 + ELSE IF (ICHAR(INPUT(LEN:LEN)).EQ.10) THEN + INPUT(LEN-1:LEN-1) = CHAR(32) + INPUT(LEN:LEN) = CHAR(32) + LEN = LEN - 2 + END IF + END DO + END IF + WRITE(1'OCOUNT,1000,IOSTAT=IER,ERR=100) INPUT + OCOUNT = OCOUNT + 1 + END DO + +100 RETURN + +1000 FORMAT(A80) + + END + + + + + + SUBROUTINE DELETE_ENTRY(BULL_ENTRY) +C +C SUBROUTINE DELETE_ENTRY +C +C FUNCTION: +C To delete a directory entry. +C +C INPUTS: +C BULL_ENTRY - Bulletin entry number to delete +C + + IMPLICIT INTEGER (A-Z) + + INCLUDE 'BULLDIR.INC' + + OFFSET = LENGTH + DO I=BULL_ENTRY+1,NBULL + CALL READDIR(I,IER) + BLOCK = BLOCK - OFFSET + CALL WRITEDIR(I-1,IER) + END DO + + DELETE(UNIT=2,REC=NBULL+1) + + CALL READDIR(0,IER) + NBULL = NBULL - 1 + NBLOCK = NBLOCK - OFFSET + CALL WRITEDIR(0,IER) + + RETURN + END + + + + + SUBROUTINE GET_EXDATE(EXDATE,NDAYS) +C +C SUBROUTINE GET_EXDATE +C +C FUNCTION: Computes expiration date giving number of days to expire. +C + IMPLICIT INTEGER (A-Z)R + + CHARACTER*11 EXDATE + + CHARACTER*3 MONTHS(12)T + DIMENSION LENGTH(12)C + DATA MONTHS/'JAN','FEB','MAR','APR','MAY','JUN','JUL','AUG','SEP',- + & 'OCT','NOV','DEC'/ + DATA LENGTH/31,27,31,30,31,30,31,31,30,31,30,31/1 + + CALL SYS$ASCTIM(,EXDATE,,) ! Get the present dateH + + DECODE(2,'(I2)',EXDATE(1:2)) DAY ! Get day5 + DECODE(4,'(I4)',EXDATE(8:11)) YEAR ! Get year + + MONTH = 1 + DO WHILE (MONTHS(MONTH).NE.EXDATE(4:6)) ! Get month + MONTH = MONTH + 1. + END DOS + + IF (MOD(YEAR,4).EQ.0) THEN ! Correct February length + LENGTH(2) = 28 ! if we're in a leap year + ELSE + LENGTH(2) = 27 + END IF + + NUM_DAYS = NDAYS ! Put number of days into buffer variableA + + DO WHILE (NUM_DAYS.GT.0)8 + IF (NUM_DAYS+DAY.GT.LENGTH(MONTH)) THENT + ! If expiration date exceeds end of monthS + NUM_DAYS = NUM_DAYS - (LENGTH(MONTH) - DAY + 1) + ! Decrement # of days by days left in month + DAY = 1 ! Reset day to first of monthe + MONTH = MONTH + 1 ! Increment month pointer + IF (MONTH.EQ.13) THEN ! Moved into next year? + MONTH = 1 ! Reset month pointer + YEAR = YEAR + 1 ! Increment year pointer + IF (MOD(YEAR,4).EQ.0) THEN ! Correct February length + LENGTH(2) = 28 ! if we're in a leap year + ELSE + LENGTH(2) = 27R + END IF + END IFA + ELSE ! If expiration date is within the month, + DAY = DAY + NUM_DAYS ! Find expiration day + NUM_DAYS = 0 ! Force loop exitS + END IF + END DOM + + ENCODE(2,'(I2)',EXDATE(1:2)) DAY ! Put day into new dateE + ENCODE(4,'(I4)',EXDATE(8:11)) YEAR ! Put year into new date + EXDATE(4:6) = MONTHS(MONTH) ! Put month into new dateE + + RETURNE + END + + + + + SUBROUTINE GET_LINE(INPUT,LEN_INPUT)G +C) +C SUBROUTINE GET_LINE +C0 +C FUNCTION: +C Gets line of input from terminal.N +C( +C OUTPUTS:: +C LEN_INPUT - Length of input line. If = -1, CTRLC entered. +C if = -2, CTRLZ entered. +C +C NOTES:P +C Assumes terminal assigned to TERM_CHAN in common /TERM_CHAN/.A +C Also, on first call, set LEN_INPUT to 1+LENGTH OF INPUT CHARCTER +C for initializing the CTRLC AST.e +Ce + + IMPLICIT INTEGER (A-Z) + LOGICAL*1 DESCRIP(8),DTYPE,CLASSR + INTEGER*2 LENGTH + CHARACTER*(*) INPUT + EQUIVALENCE (DESCRIP(1),LENGTH),(DESCRIP(3),DTYPE)) + EQUIVALENCE (DESCRIP(4),CLASS),(DESCRIP(5),POINTER) + EXTERNAL IO$_SETMODE,IO$M_CTRLCAST,CTRLC_ROUTINEe + COMMON /TERM_CHAN/ TERM_CHANE + + INCLUDE '($RMSDEF)' + + LIMIT = LEN(INPUT) ! Get input line size limitK + +C +C Initialize CTRL-C AST with AST routine CTRLC_ROUTINE andI +C AST parameter FLAG. When CTRLC occurs, FLAG is set to 1 +CN + + FLAG = 0 ! Yep, init CTRL-C flag + IO_CTRLC = %LOC(IO$_SETMODE)+%LOC(IO$M_CTRLCAST) ! Set AST code + IER=SYS$QIOW(,%VAL(TERM_CHAN),%VAL(IO_CTRLC),,,, ! for QIOC + & CTRLC_ROUTINE,FLAG,,,,) ! Enable the AST + + LEN_INPUT = 0 ! Nothing inputted yet + + LENGTH = 0 ! Init special variable + DTYPE = 0 ! descriptor so we won't + CLASS = 2 ! run into any memory limit: + POINTER = 0 ! during input.m + +Cf +C LIB$GET_INPUT is nice way of getting input from terminal, +C as it handles such thing as accidental wrap around to next line.( +CR + + IER = LIB$GET_INPUT(DESCRIP) ! Get line from terminal1 + + IF (FLAG.EQ.0) THEN ! If no CTRL-C has occurred + IER1 = SYS$CANCEL(%VAL(TERM_CHAN)) ! Cancel CTRL-C AST + IF (IER.NE.RMS$_EOF) THEN ! See if CTRL-Z is in input + LEN_INPUT = MIN(LIMIT,LENGTH) ! Yep. Get length of line + DO I=0,LEN_INPUT-1 ! Extract from descriptor, + CALL GET_VAL(INPUT(I+1:I+1),%VAL(POINTER+I)) + END DOt + ELSE + LEN_INPUT = -2 ! If CTRL-Z, say so' + END IF + ELSE1 + LEN_INPUT = -1 ! If CTRL-C, say so + END IF( + RETURNE + END + + SUBROUTINE GET_VAL(OUTPUT,INPUT) ! Used to convert logicalf + CHARACTER*(*) OUTPUT ! byte to character valueI + LOGICAL*1 INPUT + OUTPUT = CHAR(INPUT), + RETURN= + END + + SUBROUTINE CTRLC_ROUTINE(FLAG) ! CTRL-C AST routineb + IMPLICIT INTEGER (A-Z) ! If CTRL-C, come here + FLAG = 1 ! to set flag + RETURNU + END + + + + + + + + + SUBROUTINE GETPAGLEN(PAGE_LENGTH) +C +C SUBROUTINE GETPAGLENb +Co +C FUNCTION: +C Gets page length of the terminal.c +Cy +C OUTPUTS:C +C PAGE_LENGTH - Page length of the terminal. +C + IMPLICIT INTEGER (A-Z)s + PARAMETER DVI$_DEVDEPEND = 'A'X + INTEGER ITMLST(3) + LOGICAL*1 DEVDEPEND(4) + ITMLST(1) = ISHFT(DVI$_DEVDEPEND,16).OR.4 + ITMLST(2) = %LOC(DEVDEPEND(1)) + ITMLST(3) = LEN + ITMLST(4) = 0 + CALL SYS$GETDVIW(,,'TT',ITMLST,,,,) + PAGE_LENGTH = DEVDEPEND(4)' + RETURNn + END + + + + + + + SUBROUTINE GETPRIV(ALLOW) +C) +C SUBROUTINE GETPRIV +Cr +C FUNCTION: +C To check if process has SETPRV capabilities. +C OUTPUTS:L +C ALLOW - Set to 0 if no privileges, set to 1 if privileges. +CR + + IMPLICIT INTEGER (A-Z) + + INTEGER*4 ITMLST(4) ! Item list for SYS$GETJPI +CA +C ITMLST is the ITEMLIST for the SYS$GETJPI system service. +C It has the following format:F +C ITMLST(1) Top 16 bits = Item code (found in macro $JPIDEF= +C in SYS$LIBRARY:STARTLET.MLB).G +C Bottom 16 bits = length of buffer in bytes to +C receive the device information.= +C ITMLST(2) Address of buffer to receive device information. +C ITMLST(3) Address of buffer to receive the length of the +C information. 0 indicates no such buffer desired. +C ...x +C ITMLST(N) The last longword in an item list must be 0. +CO + DATA ITMLST/4*0/l + PARAMETER JPI$_PROCPRIV='204'X ! Item code to get JPI$_PROCPRIV + PARAMETER PRV$M_SETPRV='4000'X ! Mask for SETPRV privileges + + ITMLST(1) = ISHFT(JPI$_PROCPRIV,16).OR.4 ! Move JPI$_PROCPRIV to uppern + ! word & fill bottom word with # bytes. + ITMLST(2) = %LOC(PROCPRIV) ! PROCPRIV is buffer to receive info.e + + IER = SYS$GETJPIW(,,,ITMLST,,,,) ! Get info + + IF ((PROCPRIV.AND.PRV$M_SETPRV).NE.0) THEN( + ALLOW = 1a + ELSEa + ALLOW = 0T + END IFE + + RETURNS + END + + + + + + + + SUBROUTINE GETUSER(USERNAME) +CI +C SUBROUTINE GETUSERR +C +C FUNCTION: +C To get username of present process.C +C OUTPUTS: +C USERNAME - Username owner of present process. +Ct + + IMPLICIT INTEGER (A-Z)I + + INTEGER*4 ITMLST(4) ! Item list for SYS$GETJPI +C- +C ITMLST is the ITEMLIST for the SYS$GETJPI system service. +C It has the following format:o +C ITMLST(1) Top 16 bits = Item code (found in macro $JPIDEFl +C in SYS$LIBRARY:STARTLET.MLB).T +C Bottom 16 bits = length of buffer in bytes to. +C receive the device information.v +C ITMLST(2) Address of buffer to receive device information. +C ITMLST(3) Address of buffer to receive the length of the +C information. 0 indicates no such buffer desired. +C ... +C ITMLST(N) The last longword in an item list must be 0. +C + DATA ITMLST/4*0/ + PARAMETER JPI$_USERNAME='202'X ! Item code to get JPI$_USERNAME + CHARACTER*(*) USERNAME ! Limit is 12 characters + + ITMLST(1) = ISHFT(JPI$_USERNAME,16).OR.12 ! Move JPI$_USERNAME to upper + ! word & fill bottom word with # bytes. + ITMLST(2) = %LOC(USERNAME) ! USERNAME is buffer to receive info. + + IER = SYS$GETJPIW(,,,ITMLST,,,,) ! Get info + + RETURN + END + + + + + SUBROUTINE GETSTS(STS) +C +C SUBROUTINE GETSTS +C +C FUNCTION: +C To get status of present process. This tells if its a batch process. +C OUTPUTS:T +C STS - Status word of present process. +CE + + IMPLICIT INTEGER (A-Z)0 + + INTEGER*4 ITMLST(4) ! Item list for SYS$GETJPI +CY +C ITMLST is the ITEMLIST for the SYS$GETJPI system service. +C It has the following format: +C ITMLST(1) Top 16 bits = Item code (found in macro $JPIDEFe +C in SYS$LIBRARY:STARTLET.MLB). +C Bottom 16 bits = length of buffer in bytes to= +C receive the device information.I +C ITMLST(2) Address of buffer to receive device information. +C ITMLST(3) Address of buffer to receive the length of the +C information. 0 indicates no such buffer desired. +C ...R +C ITMLST(N) The last longword in an item list must be 0. +CA + DATA ITMLST/4*0/ + PARAMETER JPI$_STS='305'X ! Item code to get JPI$_USERNAMEt + INTEGER STS + + ITMLST(1) = ISHFT(JPI$_STS,16).OR.4 ! Move JPI$_STS to upperA + ! word & fill bottom word with # bytes. + ITMLST(2) = %LOC(STS) ! STS is buffer to receive info. + + IER = SYS$GETJPIW(,,,ITMLST,,,,) ! Get info + + RETURN, + END + + + + + SUBROUTINE HELP(LIBRARY), + + IMPLICIT INTEGER (A-Z)Y + EXTERNAL LIB$PUT_OUTPUT,LIB$GET_INPUT + CHARACTER*(*) LIBRARY + + COMMON /BULLPAR/ BULL_PARAMETER,LEN_P + CHARACTER*64 BULL_PARAMETER + + IER = CLI$GET_VALUE('HELP_TOPIC',BULL_PARAMETER,LEN_P)) + + CALL LBR$OUTPUT_HELP(LIB$PUT_OUTPUT,,BULL_PARAMETER(1:LEN_P)P + & ,LIBRARY,,LIB$GET_INPUT) + + RETURNo + END + + + SUBROUTINE OPEN_FILE(INPUT) + + IMPLICIT INTEGER (A-Z)e + + INCLUDE 'BULLFILES.INC' + + INCLUDE '($FORIOSDEF)' + + EXTERNAL BULLDIR_ERR,BULLETIN_ERR,BULLUSER_ERR, + + PARAMETER TIMEOUT = -10*1000*1000*30I + DIMENSION TIMEBUF(2)P + DATA TIMEBUF /TIMEOUT,-1/ + PARAMETER TIMEEFN = 1 + + COMMON /CTRLY/ CTRLYT + + CALL LIB$DISABLE_CTRL(CTRLY,) ! No breaks while file is openR + + IF (INPUT.EQ.3.OR.INPUT.EQ.2) THEN( + IER = SYS$SETIMR(%VAL(TIMEEFN),TIMEBUF,BULLDIR_ERR,) +20 OPEN (UNIT=2,FILE=BULLDIR_FILE,STATUS='UNKNOWN', + 1 RECORDTYPE='FIXED',RECORDSIZE=107,ACCESS='DIRECT',ERR=20,Y + 1 ORGANIZATION='RELATIVE',DISPOSE='KEEP',FORM='FORMATTED') + END IF + + IF (INPUT.EQ.3.OR.INPUT.EQ.1) THENE + IER = SYS$SETIMR(%VAL(TIMEEFN),TIMEBUF,BULLETIN_ERR,)N +10 OPEN (UNIT=1,FILE=BULLETIN_FILE,STATUS='UNKNOWN',r + 1 ACCESS='DIRECT',RECORDTYPE='FIXED',RECORDSIZE=80,e + 1 FORM='FORMATTED',ERR=10) + END IFN + + IF (INPUT.EQ.4) THENh + IER = SYS$SETIMR(%VAL(TIMEEFN),TIMEBUF,BULLUSER_ERR,)e +30 OPEN (UNIT=4,FILE=BULLUSER_FILE,STATUS='UNKNOWN',R + 1 ACCESS='KEYED',RECORDTYPE='FIXED',RECORDSIZE=58,IOSTAT=IER,C + 1 FORM='FORMATTED',ORGANIZATION='INDEXED', + 1 KEY=(1:12:CHARACTER)) + IF (IER.EQ.FOR$IOS_INCRECLEN) THEN + CALL CONVERT_USERFILE + GO TO 30I + ELSE IF (IER.NE.0) THENh + GO TO 30D + END IF + END IF! + + IER = SYS$CANTIM(,) ! Successful, so cancel timer. + + RETURN + END + + SUBROUTINE TIMER_ERR( + + IMPLICIT INTEGER (A-Z) + + COMMON /CTRLY/ CTRLYD + + ENTRY BULLDIR_ERR + WRITE (6,'('' ERROR: Unable to open BULLDIR.DAT after 30 seconds.'')')t + GO TO 10d + + ENTRY BULLETIN_ERR + WRITE (6,'('' ERROR: Unable to open BULLETIN.DAT after 30 seconds.'')') + GO TO 10N + + ENTRY BULLUSER_ERRi + WRITE (6,'('' ERROR: Unable to open BULLUSER.DAT after 30 seconds.'')') + GO TO 101 + +10 CALL LIB$ENABLE_CTRL(CTRLY,) ! No breaks while file is open + CALL EXIT + END + + + + SUBROUTINE OPEN_FILE_SHARED(INPUT)A + + INCLUDE '($FORIOSDEF)', + + INCLUDE 'BULLFILES.INC' + + COMMON /CTRLY/ CTRLYn + + CALL LIB$DISABLE_CTRL(CTRLY,) ! No breaks while file is openC + + IF (INPUT.EQ.3.OR.INPUT.EQ.2) THEN2 +20 OPEN (UNIT=2,FILE=BULLDIR_FILE,STATUS='OLD', + 1 RECORDTYPE='FIXED',RECORDSIZE=107,ACCESS='DIRECT',IOSTAT=IER,P + 1 ORGANIZATION='RELATIVE',DISPOSE='KEEP',FORM='FORMATTED', + 1 SHARED,READONLY) + + IF (IER.EQ.FOR$IOS_FILNOTFOU) GO TO 100 + IF (IER.NE.0) GO TO 20 + + END IF + + IF (INPUT.EQ.3.OR.INPUT.EQ.1) THEN +10 OPEN (UNIT=1,FILE=BULLETIN_FILE,STATUS='OLD',C + 1 ACCESS='DIRECT',RECORDTYPE='FIXED',RECORDSIZE=80,R + 1 FORM='FORMATTED',IOSTAT=IER,SHARED,READONLY) + + IF (IER.EQ.FOR$IOS_FILNOTFOU) GO TO 100A + IF (IER.NE.0) GO TO 10 + + END IF& + + IF (INPUT.EQ.4) THEN, +30 OPEN (UNIT=4,FILE=BULLUSER_FILE,STATUS='UNKNOWN',u + 1 ACCESS='KEYED',RECORDTYPE='FIXED',RECORDSIZE=58,IOSTAT=IER,c + 1 FORM='FORMATTED',ORGANIZATION='INDEXED',SHARED,i + 1 KEY=(1:12:CHARACTER))t + IF (IER.EQ.FOR$IOS_INCRECLEN) THEN + CALL CONVERT_USERFILE + GO TO 30s + ELSE IF (IER.NE.0) THENp + GO TO 30i + END IF + END IFB + + RETURND + +100 CALL OPEN_FILE(INPUT)i + + RETURN + END + + + + SUBROUTINE CONVERT_USERFILE +Cd +C SUBROUTINE CONVERT_USERFILE +CH +C FUNCTION: Converts user file to new format which has 8 bytes added. +C + + IMPLICIT INTEGER (A-Z)= + + INCLUDE 'BULLFILES.INC' + + CHARACTER*58 BUFFER + DIMENSION ZERO(2) + DATA ZERO/2*0/d + +10 OPEN (UNIT=4,FILE=BULLUSER_FILE,STATUS='UNKNOWN', + 1 ACCESS='KEYED',RECORDTYPE='FIXED',RECORDSIZE=50,ERR=10,C + 1 FORM='FORMATTED',ORGANIZATION='INDEXED',SHARED,I + 1 KEY=(1:12:CHARACTER))R + + OPEN (UNIT=8,FILE=BULLUSER_FILE,STATUS='NEW', + 1 ACCESS='KEYED',RECORDTYPE='FIXED',RECORDSIZE=58,IOSTAT=IER,u + 1 FORM='FORMATTED',ORGANIZATION='INDEXED', + 1 KEY=(1:12:CHARACTER))T + + DO WHILE (1)- + READ (4,'(A50)',END=20) BUFFER + WRITE (8,'(A50,2A4)') BUFFER,(ZERO(I),I=1,2) + END DOR + +20 CLOSE (UNIT=4) + CLOSE (UNIT=8)N + + RETURN( + END + + + SUBROUTINE READDIR(BULLETIN_NUM,ICOUNT) +CT +C SUBROUTINE READDIRh +C +C FUNCTION: Finds the entry for the specified bulletin in the +C directory file and returns the information for that entry. +CE +C INPUTS: +C BULLETIN_NUM - Bulletin number. Starts with 1.M +C If 0, gives header info, i.e number of bulls, +C number of blocks in bulletin file, etc. +C OUTPUTS:L +C ICOUNT - The last record read by this routine. +CE + + IMPLICIT INTEGER (A - Z) + + INCLUDE 'BULLDIR.INC' + O + ICOUNT = BULLETIN_NUM + + IF (ICOUNT.EQ.0) THEN + READ (2'1,1000,ERR=999) NEWEST_EXDATE,NEWEST_DATE,NEWEST_TIME, + & NBULL,NBLOCK,SHUTDOWN,SHUTDOWN_DATE,SHUTDOWN_TIME + ELSEI + READ(2'ICOUNT+1,1010,ERR=999)M + & DESCRIP,FROM,DATE,TIME,LENGTH,EXDATE,SYSTEM,BLOCKE + END IF + + ICOUNT = ICOUNT + 1 + +999 RETURN + +1000 FORMAT(A11,A11,A8,A4,A4,A4,A11,A8) +1010 FORMAT(A53,A12,A11,A8,A4,A11,A4,A4) + + END + + + SUBROUTINE WRITEDIR(BULLETIN_NUM,IER) +Ci +C SUBROUTINE WRITEDIR +Ct +C FUNCTION: Writes the entry for the specified bulletin in the +C directory file.e +Cv +C INPUTS: +C BULLETIN_NUM - Bulletin number. Starts with 1.n +C If 0, write the header of the directory file. +C OUTPUTS: +C IER - Error status from WRITE. +Cr + + IMPLICIT INTEGER (A - Z) + + INCLUDE 'BULLDIR.INC' + M + IF (BULLETIN_NUM.EQ.0) THEN + WRITE (2'1,1000,IOSTAT=IER) NEWEST_EXDATE,NEWEST_DATE,NEWEST_TIME, + & NBULL,NBLOCK,SHUTDOWN,SHUTDOWN_DATE,SHUTDOWN_TIMEO + ELSEo + WRITE(2'BULLETIN_NUM+1,1010,IOSTAT=IER)l + & DESCRIP,FROM,DATE,TIME,LENGTH,EXDATE,SYSTEM,BLOCKR + END IF + + RETURNe + +1000 FORMAT(A11,A11,A8,A4,A4,A4,A11,A8)T +1010 FORMAT(A53,A12,A11,A8,A4,A11,A4,A4) + + END + + + SUBROUTINE TRUNCATE_FILE(TRUNC_SIZE) + + IMPLICIT INTEGER (A-Z)T + + INCLUDE 'BULLFILES.INC' + + COMMON /USER_OPEN/ CHANNEL,STATUS,SIZEO + + EXTERNAL USER_OPEN$TRUNCATE + + INCLUDE '($RMSDEF)' + + COMMON /CTRLY/ CTRLYU + + CALL LIB$DISABLE_CTRL(CTRLY,) ! No breaks while file is open + +10 OPEN (UNIT=1,FILE=BULLETIN_FILE,STATUS='OLD', + 1 RECORDTYPE='FIXED',RECORDSIZE=80,INITIALSIZE=TRUNC_SIZE, + 1 FORM='FORMATTED',ERR=20,USEROPEN=USER_OPEN$TRUNCATE) + +15 CLOSE (UNIT=1) + CALL LIB$ENABLE_CTRL(CTRLY,)I + RETURN + +20 IF ((STATUS.AND.1).EQ.1.OR.STATUS.EQ.RMS$_EOF) THEN + GO TO 15 + ELSEt + GO TO 10 + END IFi + + END + + + SUBROUTINE UPDATE_LOGIN +Cb +C SUBROUTINE UPDATE_LOGIN +Ct +C FUNCTION: Updates the login file when a bulletin has been deleted. +Cm + IMPLICIT INTEGER (A - Z)b + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLUSER.INC'r + + CHARACTER*12 TEMP_USER. + CHARACTER*11 TEMP_DATE,BBOARD_DATEJ + CHARACTER*8 TEMP_TIME,BBOARD_TIME + + CALL OPEN_FILE(4) + + READ (4,1000,KEY=' ',ERR=10) + & TEMP_USER,TEMP_DATE,TEMP_TIME,BBOARD_DATE,BBOARD_TIMEE + REWRITE (4,1000) + & TEMP_USER,NEWEST_DATE,NEWEST_TIME,BBOARD_DATE,BBOARD_TIME + CLOSE (UNIT=4)u + RETURNe + +10 WRITE (4,1000) ' ',NEWEST_DATE,NEWEST_TIME + CLOSE (UNIT=4)D + RETURN + +1000 FORMAT(A12,A11,A8,A11,A8) + + END + + + S + SUBROUTINE ADD_ENTRYo +Ct +C SUBROUTINE ADD_ENTRYs +Ch +C FUNCTION: Enters a new directory entry in the directory file. +Cr + IMPLICIT INTEGER (A - Z) + I + INCLUDE 'BULLDIR.INC' + I + CHARACTER*23 TODAY_TIME + + CALL SYS$ASCTIM(,TODAY_TIME,,) + DATE = TODAY_TIME(1:11) + TIME = TODAY_TIME(13:20) + + CALL READDIR(0,IER) + IF (IER.EQ.1) GO TO 206 + +10 NEWEST_EXDATE = DATE + NBULL = 0 + NBLOCK = 0S + SHUTDOWN = 0E + +20 NEWEST_DATE = DATEi + NEWEST_TIME = TIME + + DIFF = COMPARE_DATE(NEWEST_EXDATE,EXDATE) + IF (DIFF.GT.0) NEWEST_EXDATE = EXDATE + + NBULL = NBULL + 1 + BLOCK = NBLOCK + 1r + NBLOCK = NBLOCK + LENGTHe + + IF ((SYSTEM.AND.4).EQ.4) THEN + SHUTDOWN = SHUTDOWN + 1i + SHUTDOWN_DATE = DATE + SHUTDOWN_TIME = TIME + END IF + + CALL WRITEDIR(0,IER)L + + CALL UPDATE_LOGIN + + CALL WRITEDIR(NBULL,IER) + + RETURNE + END + + + + + S + INTEGER FUNCTION COMPARE_DATE(DATE1,DATE2)L +CP +C FUNCTION COMPARE_DATE +C_ +C FUCTION: Compares dates to see which is farther in future.I +CI +C INPUTS: +C DATE1 - First date (dd-mm-yy) +C DATE2 - Second date (If is equal to ' ', then use present date)U +C OUTPUT: +C Returns the difference in days between the two dates.F +C If the DATE1 is farther in the future, the output is positive, +C else it is negative. +CI + IMPLICIT INTEGER (A - Z) + + CHARACTER*(*) DATE1,DATE2 + INTEGER USER_TIME(2)T + + CALL SYS$BINTIM(DATE1,USER_TIME)A + CALL LIB$DAY(DAY1,USER_TIME)) + + IF (DATE2.NE.' ') THENU + CALL SYS$BINTIM(DATE2,USER_TIME) + ELSED + CALL SYS$GETTIM(USER_TIME) + END IFT + + CALL LIB$DAY(DAY2,USER_TIME)N + + COMPARE_DATE = DAY1 - DAY2= + + RETURN) + END + + + + + INTEGER FUNCTION COMPARE_TIME(TIME1,TIME2) +CY +C FUNCTION COMPARE_TIME +CF +C FUCTION: Compares times to see which is farther in future.' +CN +C INPUTS: +C TIME1 - First time (hh:mm:ss)I +C TIME2 - Second time +C OUTPUT: +C Outputs 1 if time1 greater in future, outputs -1 if time2E +C greater in future. If exactly the same, output 0. +C + + IMPLICIT INTEGER (A-Z)R + CHARACTER*(*) TIME1,TIME2 + CHARACTER*23 TODAY_TIME + CHARACTER*8 TIME2_TEMPE + + IF (TIME2.EQ.' ') THEN + CALL SYS$ASCTIM(,TODAY_TIME,,) + TIME2_TEMP = TODAY_TIME(13:20) + ELSE + TIME2_TEMP = TIME2 + END IFN + + COMPARE_TIME = 0_ + + DO J=1,7,3 + DO I=J,J+1 + IF (TIME1(I:I).GT.TIME2_TEMP(I:I)) THEN + COMPARE_TIME = 1I + RETURNN + ELSE IF (TIME1(I:I).LT.TIME2_TEMP(I:I)) THENE + COMPARE_TIME = -1 + RETURNI + END IF + END DO + END DOR + + RETURN + END + +C------------------------------------------------------------------------- +C. +C The following are subroutines to create a linked-list queue for b +C temporary buffer storage of data that is read from files to beY +C outputted to the terminal. This is done so as to be able to close +C the file as soon as possible. +CL +C Each record in the queue has the following format. The first two +C words are used for creating a character variable. The first word +C contains the length of the character variable, the second containsI +C the address. The address is simply the address of the 3rd word of. +C the record. The last word in the record contains the address of the, +C next record. Every time a record is written, if that record has aR +C zero link, it adds a new record for the next write operation. D +C Therefore, there will always be an extra record in the queue. To +C check for the end of the queue, the last word (link to next record) +C is checked to see if it is zero. +C= +C There are 2 seperate queues. One for directory listings, and one E +C for bulletins reads. The bulletin queue is made of character +C variables of length 80. The directory listings contain character +C variables of length 88. Although BULLETIN does not use all the +C info that is stored, (SYSTEM,BLOCK,LENGTH), that info is used byR +C BULLCHECK.D +CE +C------------------------------------------------------------------------- + + SUBROUTINE WRITE_DIR(RECORD,NEXT) + INTEGER RECORD(1) + CALL WRITE_DIR_CHAR(%VAL(%LOC(RECORD))) + NEXT = RECORD(25) + IF (NEXT.NE.0) RETURN + CALL LIB$GET_VM(100,NEXT) + CALL MAKE_CHAR(%VAL(NEXT),88) + RECORD(25) = NEXT + RETURNE + END + + SUBROUTINE WRITE_DIR_CHAR(SCRATCH) + CHARACTER*(*) SCRATCH + INCLUDE 'BULLDIR.INC' + WRITE(SCRATCH,1035) DESCRIP,FROM,DATE,SYSTEM,BLOCK,LENGTH + RETURNe +1035 FORMAT(A53,A12,A11,A4,A4,A4) + END + + SUBROUTINE READ_DIR(RECORD,NEXT) + INTEGER RECORD(1) + CALL READ_DIR_CHAR(%VAL(%LOC(RECORD)))= + NEXT = RECORD(25) + RETURNU + END + + SUBROUTINE READ_DIR_CHAR(SCRATCH) + CHARACTER*(*) SCRATCH + INCLUDE 'BULLDIR.INC' + READ(SCRATCH,1035) DESCRIP,FROM,DATE,SYSTEM,BLOCK,LENGTH + RETURN) +1035 FORMAT(A53,A12,A11,A4,A4,A4)I + END + + SUBROUTINE WRITE_BULL(RECORD,NEXT)C + INTEGER RECORD(1) + CALL WRITE_BULL_CHAR(%VAL(%LOC(RECORD)))M + NEXT = RECORD(23) + IF (NEXT.NE.0) RETURN + CALL LIB$GET_VM(92,NEXT) + CALL MAKE_CHAR(%VAL(NEXT),80) + RECORD(23) = NEXT + RETURN' + END + + SUBROUTINE WRITE_BULL_CHAR(SCRATCH) + CHARACTER*(*) SCRATCH + COMMON/INPUT_BULL/INPUT + CHARACTER*80 INPUTN + SCRATCH = INPUT + RETURNN + END + + SUBROUTINE READ_BULL(RECORD,NEXT) + INTEGER RECORD(1) + CALL READ_BULL_CHAR(%VAL(%LOC(RECORD))) + NEXT = RECORD(23) + RETURNf + END + + SUBROUTINE READ_BULL_CHAR(SCRATCH)U + CHARACTER*(*) SCRATCH + COMMON/INPUT_BULL/INPUT + CHARACTER*80 INPUTe + INPUT = SCRATCH + RETURN, + END + + + SUBROUTINE MAKE_CHAR(IARRAY,LEN). + DIMENSION IARRAY(1) + IARRAY(1) = LEN + IARRAY(2) = %LOC(IARRAY(3)) + IARRAY(LEN/4+3) = 0 + RETURN + END + + + + SUBROUTINE CHECK_PRIV_IO(ERROR) +CN +C SUBROUTINE CHECK_PRIV_IO +C +C FUNCTION: Checks SYS$OUTPUT and SYS$ERROR to see if they need +C privileges to output to. +CT + + IMPLICIT INTEGER (A-Z)E + + DIMENSION SETPRV(2) + DATA SETPRV/Z10000000,0/ ! SYSPRV privileges + + CALL SYS$SETPRV(%VAL(0),SETPRV,,) ! Disable SYSPRV + + OPEN (UNIT=6,FILE='SYS$OUTPUT',IOSTAT=IER,STATUS='NEW') + CLOSE (UNIT=6,STATUS='DELETE')A + + OPEN (UNIT=4,FILE='SYS$ERROR',IOSTAT=IER1,STATUS='NEW') + IF (IER.NE.0.OR.IER1.NE.0) THEN + IF (IER1.EQ.0) WRITE (4,100) + IF (IER.EQ.0) WRITE (6,200) + ERROR = 1i + ELSEv + CLOSE (UNIT=4,STATUS='DELETE') + ERROR = 0S + END IFh + + CALL SYS$SETPRV(%VAL(1),SETPRV,,) ! Enable SYSPRV . + +100 FORMAT(1X,'ERROR: SYS$OUTPUT cannot be opened.') +200 FORMAT(1X,'ERROR: SYS$ERROR cannot be opened.') + + RETURNL + END + + + + SUBROUTINE GETUIC(GRP,MEM), +CT +C SUBROUTINE GETUIC(UIC)T +CT +C FUNCTION: +C To get UIC of process submitting the job., +C OUTPUT: +C GRP - Group number of UIC +C MEM - Member number of UICC +C, + + IMPLICIT INTEGER (A-Z)E + + INTEGER*4 ITMLST(7) ! Item list for SYS$GETJPI +C, +C ITMLST is the ITEMLIST for the SYS$GETJPI system service. +C It has the following format:N +C ITMLST(1) Top 16 bits = Item code (found in macro $JPIDEFE +C in SYS$LIBRARY:STARTLET.MLB).P +C Bottom 16 bits = length of buffer in bytes toN +C receive the device information.O +C ITMLST(2) Address of buffer to receive device information. +C ITMLST(3) Address of buffer to receive the length of the +C information. 0 indicates no such buffer desired. +C ...I +C ITMLST(N) The last longword in an item list must be 0. +C_ + DATA ITMLST/7*0/5 + PARAMETER JPI$_GRP='308'X ! Item code to get JPI$_GRP + PARAMETER JPI$_MEM='307'X ! Item code to get JPI$_MEM + + ITMLST(1) = ISHFT(JPI$_GRP,16).OR.4 ! Move JPI$_GRP to upperS + ! word & fill bottom word with # bytes. + ITMLST(2)=%LOC(GRP) ! GRP is buffer to receive info. + ITMLST(4) = ISHFT(JPI$_MEM,16).OR.4 ! Move JPI$_MEM to upper + ! word & fill bottom word with # bytes. + ITMLST(5)=%LOC(MEM) ! MEM is buffer to receive info. + + IER = SYS$GETJPIW(,,,ITMLST,,,,) ! Get Info command.L + + RETURN( + END + + + + + SUBROUTINE GET_UPTIME(UPTIME_DATE,UPTIME_TIME)E +CE +C SUBROUTINE GET_UPTIME +C, +C FUNCTION: Gets time of last reboot. +CT + + IMPLICIT INTEGER (A-Z)_ + + EXTERNAL EXE$GL_ABSTIME + INTEGER UPTIME(2),SYSTIME(2),UPSINCE(2), + CHARACTER*(*) UPTIME_TIME,UPTIME_DATE + CHARACTER ASCSINCE*23 + + UPTIME(1) = GET_L_VAL(EXE$GL_ABSTIM) ! Up time (sec) + + CALL LIB$EMUL(10000000,UPTIME,0,UPTIME) ! 64 bit format + CALL SYS$GETTIM(SYSTIME)t + CALL LIB$SUBX(SYSTIME,UPTIME,UPSINCE) + CALL SYS$ASCTIM(,ASCSINCE,UPSINCE,) ! Up since' + + UPTIME_DATE = ASCSINCE(1:11) + UPTIME_TIME = ASCSINCE(13:20) + + RETURN + END + + INTEGER FUNCTION GET_L_VAL(I) + INTEGER I + GET_L_VAL = I + RETURNE + END + + + SUBROUTINE SET_READNEW(CMD,TOPIC) +CL +C SUBROUTINE SET_READNEWW +C +C FUNCTION: Sets readnew for specified topic (TOPIC = 1 is general topic).W +C_ +C INPUTS: +C CMD - LOGICAL*4 value. If TRUE, set readnew. +C If FALSE, clear readnew. +C TOPIC - TOPIC number, corresponding to bit number. +CN + IMPLICIT INTEGER (A - Z) + + INCLUDE 'BULLDIR.INC' + + INCLUDE 'BULLUSER.INC'E + + LOGICAL CMD + +CR +C Find user entry in BULLUSER.DAT to update information.L +CR + + CALL OPEN_FILE_SHARED(4) ! Open user fileT + + READ (4,1000,KEY=USERNAME) USERNAME, ! Read old entry + & LOGIN_DATE,LOGIN_TIME,READ_DATE,READ_TIME,FLAGSr + + F_POINT = TOPIC/32 + 1: + IF (CMD) THEN + I = IBSET(FLAGS(F_POINT),TOPIC-1)d + ELSEI + I = IBCLR(FLAGS(F_POINT),TOPIC-1)e + END IFT + + REWRITE (4,1000) USERNAME, ! Write modified entryd + & LOGIN_DATE,LOGIN_TIME,READ_DATE,READ_TIME,FLAGSu + + CALL CLOSE_FILE (4) + RETURNt + +1000 FORMAT(A12,A11,A8,A11,A8,2A4) + END + + + + + + SUBROUTINE CONFIRM_PRIV(USERNAME,PASSWORD,ALLOW)I +CM +C SUBROUTINE CONFIRM_PRIV +CR +C FUNCTION: Confirms that given username has SETPRV, and that the +C the given password is correct. +C +C INPUTS: +C USERNAME - UsernameG +C PASSWORD - Username's password +C OUTPUTS:( +C ALLOW - Returns 1 if correct password and SETPRV set, +C returns 0 if not.& +CO + + IMPLICIT INTEGER (A-Z)T + + CHARACTER*(*) USERNAME,PASSWORD + + PARAMETER UAF$Q_DEF_PRIV = '1A4'X, UAF$Q_PWD = '154'X + PARAMETER UAF$W_SALT = '166'X, UAF$B_ENCRYPT = '168'X + + PARAMETER PRV$V_SETPRV = 'E'X + + LOGICAL*1 UAF(0:583)E + CHARACTER*(*) SYSUAF) + PARAMETER (SYSUAF = 'SYS$SYSTEM:SYSUAF.DAT')E + EQUIVALENCE (UAF(UAF$B_ENCRYPT), UAF_ENCRYPT) + EQUIVALENCE (UAF(UAF$W_SALT), UAF_SALT) + EQUIVALENCE (UAF(UAF$Q_PWD), UAF_PWD) + EQUIVALENCE (UAF(UAF$Q_DEF_PRIV),UAF_DEF_PRIV)M + CHARACTER UAF_PWD*8,HASH*8_ + + CALL STR$UPCASE(PASSWORD,PASSWORD) ! Password must be upper casee + ALLOW = 0 ! Set return falses + CALL LIB$GET_LUN(LUN) ! Get LUNd + OPEN (UNIT=LUN,FILE=SYSUAF,SHARED,READONLY,ACCESS='KEYED',u + & FORM='UNFORMATTED',TYPE='OLD',ERR=999) ! Open UAFm + READ (LUN,KEY=USERNAME,IOSTAT=STATUS) UAF ! Read Record + IF (STATUS.EQ.0) THEN ! If username foundA + IF (BTEST(UAF_DEF_PRIV,PRV$V_SETPRV)) THEN ! System privileges?T + CALL LGI$HPWD(HASH,PASSWORD,%VAL(UAF_ENCRYPT), + & %VAL(UAF_SALT),USERNAME) ! HASH the password_ + IF (HASH.EQ.UAF_PWD) ALLOW = 1 ! Set return true + END IF ! If correct password + END IF + CLOSE (UNIT=LUN) ! Close the LUN +999 CALL LIB$FREE_LUN(LUN) ! Free the LUN + RETURN ! ReturnD + END ! End + + + + INTEGER FUNCTION SYS_TRNLNM(INPUT,OUTPUT,ACCESS)- + + IMPLICIT INTEGER (A-Z)- + + CHARACTER*(*) INPUT,OUTPUTf + + INTEGER ITMLST(4) + + PARAMETER LNM$_STRING = '2'X + + ITMLST(1) = ISHFT(LNM$_STRING,16).OR.LEN(OUTPUT) + ITMLST(2) = %LOC(OUTPUT)t + ITMLST(3) = 0 + + SYS_TRNLNM = SYS$TRNLNM(,'LNM$PROCESS',INPUT,ACCESS,ITMLST) + + RETURN + END + diff --git a/batch/seed/1985c-file4.mai b/batch/seed/1985c-file4.mai new file mode 100644 index 0000000000000000000000000000000000000000..72ef0401b5306daef34b6ab483fd3854bdfe51f4 --- /dev/null +++ b/batch/seed/1985c-file4.mai @@ -0,0 +1,209 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 11:01 +Subj: [TCP/IP Mail From: MRL%PFCVAX@ZERMATT] BULLET.COM + + +Return-Path: <@MIT-ZERMATT.ARPA:MRL%MIT-PFC-VAX@MIT-MC.ARPA> +Received: from MIT-ZERMATT.ARPA by ari-hq1.ARPA ; 30 Oct 85 11:01:48 EST +Received: from MIT-PFC-VAX by ZERMATT via CHAOS with CHAOS-MAIL id 15465; Wed 30-Oct-85 10:56:15-EST +Date: 30 Oct 85 10:57:21 EST +From: MRL%PFCVAX@ZERMATT +Sender: MRL@MIT-PFC-VAX +To: BINGHAM@ARI-HQ1@ZERMATT +Subject: BULLET.COM + +$open/read input bullet.mai +$open/write output AAAREADME.TXT +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 73 then goto again +$ close output +$open/write output BBOARD.COM +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 5 then goto again +$ close output +$open/write output BULLCOM.CLD +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 36 then goto again +$ close output +$open/write output BULLCOMS.HLP +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 135 then goto again +$ close output +$open/write output BULLDIR.INC +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 8 then goto again +$ close output +$open/write output BULLETIN.COM +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 2 then goto again +$ close output +$open/write output BULLETIN.HLP +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 17 then goto again +$ close output +$open/write output BULLETIN.LNK +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 2 then goto again +$ close output +$open/write output BULLETIN.TXT +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 49 then goto again +$ close output +$open/write output BULLFILES.INC +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 27 then goto again +$ close output +$open/write output BULLFLAG.INC +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 23 then goto again +$ close output +$open/write output BULLMAIN.CLD +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 4 then goto again +$ close output +$open/write output BULLSTART.COM +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 3 then goto again +$ close output +$open/write output BULLUSER.INC +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 8 then goto again +$ close output +$open/write output CLIDEF.MAR +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 3 then goto again +$ close output +$open/write output CREATE.COM +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 10 then goto again +$ close output +$open/write output HPWD.MAR +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 223 then goto again +$ close output +$open/write output INSTALL.COM +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 8 then goto again +$ close output +$open/write output INSTRUCT.TXT +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 6 then goto again +$ close output +$open/write output LOGIN.COM +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 2 then goto again +$ close output +$open/write output SETUIC.MAR +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 54 then goto again +$ close output +$open/write output SETUSER.MAR +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 83 then goto again +$ close output +$open/write output STARTUP.COM +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 10 then goto again +$ close output +$open/write output USEROPEN.MAR +$n = 0 +$again: +$read input input +$write output input +$ n = n + 1 +$ if n .lt. 154 then goto again +$ close output +$ close input + diff --git a/batch/seed/1985c-file5.mai b/batch/seed/1985c-file5.mai new file mode 100644 index 0000000000000000000000000000000000000000..0d5e657124728c1f0f8fc4b811be8d00f2304d43 --- /dev/null +++ b/batch/seed/1985c-file5.mai @@ -0,0 +1,960 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 11:03 +Subj: [TCP/IP Mail From: MRL%PFCVAX@ZERMATT] BULLET.MAI + + +Return-Path: <@MIT-ZERMATT.ARPA:MRL%MIT-PFC-VAX@MIT-MC.ARPA> +Received: from MIT-ZERMATT.ARPA by ari-hq1.ARPA ; 30 Oct 85 11:02:45 EST +Received: from MIT-PFC-VAX by ZERMATT via CHAOS with CHAOS-MAIL id 15466; Wed 30-Oct-85 10:56:40-EST +Date: 30 Oct 85 10:57:49 EST +From: MRL%PFCVAX@ZERMATT +Sender: MRL@MIT-PFC-VAX +To: BINGHAM@ARI-HQ1@ZERMATT +Subject: BULLET.MAI + +The following are instructions for creating the BULLETIN executable and +installation of the utility. A brief explanation of how the internals +of the BULLETIN utility works can be found in BULLETIN.TXT . None of +the command procedures included here are sophisticated, so it is likely +that several modifications will have to be made by the installer. +The installer should enable all privileges before installation. + +1) CREATE.COM + This will compile and link the BULLETIN sources. Also, there are several + INCLUDE files for the fortran sources (.INC files). BULLFILES.INC must first + be modified before this procedure is run. It contains the names of data files + which BULLETIN creates. It also has the username for the BBOARD account. + BBOARD is an option by which mail sent to the specified username will be + converted into bulletins. This allows a user on a different system, which is + connected via a network, to be able to submit a bulletin. This feature can + be disabled if it is not desired by specifying the username NONE. In any + case, you should edit BULLFILES.INC and specify the appropriate device and + directories in which you desire that the files be located. (NOTE: Although + the BBOARD feature can be used over DECNET, a more sophisticated method + is available to easily allow one to add bulletins to other DECNET nodes + with all the features of BULLETIN. See below). + +2) STARTUP.COM + The data files that BULLETIN creates should be owned by a system UIC, + and MUST be protected from users being able to have access them. + STARTUP.COM sets the process UIC to [1,4] (you should change this if + you want something else), sets the WORLD and GROUP protection to NONE, + adds the bulletin found in the file INSTRUCT.TXT (it is added with + /PERMANENT, so it never expires), and then resets the UIC and PROTECTION + to what they were before running the procedure. + INSTRUCT.BUL contains a bulletin with instructions to the users as to + how to use the BULLETIN utility. You may want to modify it. + +3) INSTALL.COM + The following procedure copies the executable image to SYS$SYSTEM and + installs it with certain privileges. It also installs the necessary + help files in SYS$HELP. + +4) LOGIN.COM + This contains the comands that should be executed at login time + by SYS$MANAGER:SYLOGIN.COM. It defines the BULLETIN commands. + It also executes the command BULLETIN/LOGIN in order to notify + the user of new bulletins. If desired, the /READNEW qualifier + can also be added. If there are any new non-system bulletins, this + qualifier creates a prompt asking the user if the non-system + bulletins are to be displayed or not. Normally, only system bulletins + are displayed in full, and only the subjects of the non-system + bulletins are displayed. ( Some systems might have a lot of users + who are not interested in reading the non-system bulletins, in + which case /READNEW should probably not be added. Instead, you could + let users enable this feature by entering the BULLETIN utility and + typing the command SET READNEW ). (NOTE: Since /LOGIN and /READNEW + are system commands, they are not included in the help file). + +5) BULLSTART.COM + This procedure contains the commands that should be executed after + a system startup. It should be executed by SYS$MANAGER:SYSTARTUP.COM + as a batch job. It simply installs the BULLETIN utility with correct + privileges. + +6) BULLETIN.COM + If one wants the feature of using BULLETIN between DECNET nodes, + this file must be put in each node's DECNET default user's directory + (usually [DECNET]). Once this is done, the /NODE qualifer for the + ADD command can be used. + NOTE: Presently, privileged functions such as /SYSTEM will work + on other nodes only if you have an account on the other node with + the same username, and with appropriate privileges. You will be + prompted for the password for the account on the remote node. However, + due to unknown reasons, the software I have to check the password will + only work for passwords that have been set under V4.x. If the password + was created under V3.x, the program will not work, and you password will + be treated as invalid. +$ SET PROTECT=(W:RWED)/DEFAULT +$ MAIL +READ +EXTRACT/ALL USRD$:[BBOARD]BBOARD.MAI +DELETE/ALL + MODULE BULLETIN_SUBCOMMANDS + + DEFINE VERB ADD + PARAMETER P1, LABEL = FILESPEC, VALUE(TYPE=$FILE) + QUALIFIER BELL + QUALIFIER BROADCAST + QUALIFIER EDIT + QUALIFIER NODES, LABEL=NODES, VALUE(REQUIRED,LIST) + QUALIFIER PASSWORD, LABEL=PASSWORD, VALUE(REQUIRED) + QUALIFIER PERMANENT + QUALIFIER SHUTDOWN + QUALIFIER SYSTEM + QUALIFIER USERNAME, LABEL=USERNAME, VALUE(REQUIRED) + DEFINE VERB BACK + DEFINE VERB DELETE + PARAMETER P1, LABEL = BULLETIN_NUMBER, VALUE(TYPE=$FILE) + DEFINE VERB DIRECTORY + DEFINE VERB EXIT + DEFINE VERB FILE + PARAMETER P1, LABEL = FILESPEC, VALUE(TYPE=$FILE,REQUIRED), + PROMPT="File" + QUALIFIER HEADER, DEFAULT + DEFINE VERB HELP + PARAMETER P1, LABEL = HELP_TOPIC, VALUE(TYPE=$REST_OF_LINE) + DEFINE VERB NEXT + DEFINE VERB READ + PARAMETER P1, LABEL = BULLETIN_NUMBER, VALUE(TYPE=$NUMBER) + DEFINE VERB REPLACE + PARAMETER P1, LABEL = FILESPEC, VALUE(TYPE=$FILE) + QUALIFIER EXPIRATION + QUALIFIER HEADER + QUALIFIER NUMBER, VALUE(TYPE=$NUMBER,REQUIRED) + QUALIFIER TEXT + DEFINE VERB SET + PARAMETER P1, LABEL = SET_PARAM1, VALUE(REQUIRED), + PROMPT="What" +1 ADD +Adds a bulletin to the bulletin file. A file can be specified which +contains the bulletin. Otherwise, BULLETIN will prompt for the text. +BULLETIN will ask for an expiration date and a header to contain the +topic of the bulletin. + +Format + ADD [file-name] + +All the qualifiers except for /EDIT and /NODES are restricted to users +with SETPRV privileges. +2 /BELL +This option is restricted to privileged users. It is used in conjunction +with the /BROADCAST qualifier. If specified, the bell is rung on the +terminals when the bulletin is broadcasted. +2 /BROADCAST +This option is restricted to privileged users. If specified, bulletin +is both saved in the bulletin file and broadcasted to all users logged +in at the time. +2 /EDIT +Determines whether or not the EDT editor is invoked to edit the bulletin +you are sending. +2 /NODES=(nodes[,...]) +Specifies to send the bulletin to other DECNET nodes. The BULLETIN utility +must be installed properly on the other nodes. You will prompted for the +username to use at the other node. If you give a different username than +that of the local node, or if privileged qualifiers are specified, you will +be prompted for the password of your account on the other nodes. At +present, if the password is invalid, the bulletin will be rejected on the +node, but no error message will be displayed on the local node that this +happened. +2 /PERMANENT +This option is restricted to privileged users. If specified, bulletin +will be a permanent bulletin and will never expire. +2 /SHUTDOWN +This option is restricted to privileged users. If specified, bulletin +will be automatically deleted after a computer shutdown has occurred. +2 /SYSTEM +This option is restricted to privileged users. If specified, bulletin +is both saved in the bulletin file and displayed in full as a system +notice when a user logs in. System notices should be as brief as possible +to avoid the possibility that system notices could scroll off the screen. +1 BACK +Displays the bulletin preceding the current bulletin. +1 DELETE +Deletes the specified bulletin. If no bulletin is specified, the currentu +bulletin is deleted. Only the original owner or a privileged user can +delete a bulletin. + +Format + DELETE [bulletin-number] + +The bulletin's relative number is found by the DIRECTORY command.v +1 DIRECTORYP +Lists a summary of the bulletins. The bulletin number, submitter's name,0 +date, and subject of each bulletin is displayed. +1 EXIT +Exits the BULLETIN program. +1 FILE +Copies the current bulletin to the named file. The file-name parametero +is required, and consists of up to 9 alpha-numeric characters in length. + +Format:x + FILE file-name +2 /HEADER + +/[NO]HEADER + +Controls whether a header containing the owner, subject, and date of the s +bulletin is written in the file. The default is to write the header.c +1 Bulletin +The BULLETIN utility permits a user to create a bulletin for reading by +all users. Users are notified upon logging in that new bulletins have +been added, and what the topic of the bulletins are. Actual reading oft +the bulletins is optional. (See the command SET READNEW for info oni +automatic reading.) Bulletins are automatically deleted when theirs +expiration date has passed.I + +1 HELP +To obtain help on any topic, type: + + HELP topic +1 NEXT +Skips to the next bulletin and displays it. This is useful when pagingt +through the bulletins and you encounter a particularly long bulletin +that you would like to skip over.t +1 READ +Displays the specified bulletin. If you do not specify a bulletin, then +the first time you enter the command, the oldest bulletin will beL +displayed. However, if there are new bulletins, the first new bulletino +will be displayed. Each time you enter the command, the next page, or if +there are no more pages, the next bulletin will be displayed. + +Format + READ [bulletin-number] + +The bulletin's relative number is found by the DIRECTORY command.S + +Pressing just <RETURN> performs the same as the READ command.a +1 REPLACEb +Replaces an existing bulletin in the bulletin file. This is for changing +part or all of a bulletin without causing users who have already seen thed +bulletin to be notified of it a second time. If the text of the bulletint +is to be changed, a file can be specified which contains the text. +Otherwise, BULLETIN will prompt for the text. The expiration date and +header can also be changed. If neither /EXPIRATION, /HEADER, nor /TEXTd +are specified, it is assumed the whole bulletin will be replaced.u + +Format + REPLACE [file-name]L +2 /EXPIRATIONY +Specifies that the bulletin expiration date is to be replaced. +2 /HEADERp +Specifies that the bulletin header is to be replaced. +2 /NUMBER=ni +Specifies the bulletin number to be replaced. If this qualifier is +omitted, the bulletin that is presently being read will be replaced. +2 /TEXTo +Specifies that the bulletin text is to be replaced.t +1 SETE +Defines or changes characteristics associated with automatic reading +of bulletins. + +Format:f + + SET option +2 READNEWt +Controls whether you will be prompted upon logging in if you wish to read +new non-system bulletins (if any exist). The default is that you are notn +prompted. (Previously this was done by including the BULLETIN/READNEW +command in one's login command procedure). + + Format:e + + SET [NO]READNEW + COMMON /BULL_DIR/ DESCRIP,FROM,DATE,TIME,BLOCK,LENGTH,EXDATE + & ,NEWEST_EXDATE,NEWEST_DATE,NEWEST_TIME,SYSTEM,NBULL,NBLOCKn + & ,SHUTDOWN,SHUTDOWN_DATE,SHUTDOWN_TIMEn + CHARACTER*53 DESCRIPy + CHARACTER*12 FROM + CHARACTER*11 DATE,EXDATE,NEWEST_EXDATE,NEWEST_DATE,SHUTDOWN_DATEp + CHARACTER*8 TIME,NEWEST_TIME,SHUTDOWN_TIME/ + LOGICAL SYSTEMW +$ DEFINE SYS$INPUT SYS$NET +$ BULLETIN +1 BULLETIN +Invokes the PFC BULLETIN Utility. This utility is used for reading, addingh +and deleting bulletins. Any user can submit a bulletin. Users areu +notified at login time that new bulletins have been added and the topics ofB +those bulletins are displayed. Reading of those bulletins is optional.n +(Use the command SET READNEW while in BULLETIN for setting automatic +reading.) Privileged users can add system bulletins that are displayeda +in full at login time. These bulletins are also saved, and can be readm +by BULLETIN. Bulletins are automatically deleted after a specified +expiration date, or they can manually be deleted by either the submitter +of the bulletin or a privileged user. + +BULLETIN has an interactive help available while using the utility.o + + Format: + + BULLETIN +$ LINK/NOTRACE BULLETIN,HPWD,BULLSUBS,BULLCOM,BULLMAIN,CLIDEF,USEROPEN,SETUSER,SETUIC,-w +SYS$SYSTEM:SYS.STB/SEL +This file describes the general operation of the BULLETIN utility. + +BULLETIN uses 3 files to store its data: BULLETIN.DAT, BULLDIR.DAT, & +BULLUSER.DAT. These files are opened with the shared attribute as much as +possible to allow simultaneous operations on the files. However, when a +bulletin is added or deleted, the file cannot be shared, as this might cause +the file to be corrupted. Because of this problem, files are closed as soon asD +possible so that it may be quickly opened for adding and deleting files. R +During read operations, the information is passed to temporary storage, theL +file is closed, and then the information is sent to the terminal. This avoids aB +possible problem where the terminal output is stopped by the user, therefore +delaying the closing of the file. Also, the use of CTRL-Y & CTRL-C is disabledI +while the file is opened to avoid lockout problems." + +BULLETIN.DAT stores the actual bulletins in a fixed 80 character length file.T +Bulletins are store sequentially datewise. New bulletins are appended to theA +end of the file. When a bulletin is deleted, all the following bulletins are +moved up in the file to remove the gap, and the file is then truncated to +remove the unused space. F + +BULLDIR.DAT is a fixed record length file storing directory entries for each +bulletin in BULLETIN.DAT. Each entry contains the header information, length,d +and starting record position in BULLETIN.DAT. The first line of BULLDIR.DAT isb +a header containing the date of the next expiration that will occur, the date +of the latest sumbitted bulletin, the number of bulletins, and the total sizet +of BULLETIN.DAT. The last two numbers make it easier to add bulletins. Thes +directory entries then follow, again stored sequentially datewise. r + +NOTE: There are several advantages to keeping a seperate directory file versus +storing the header information with the actual bulletin. Obviously, it avoids +having to scan through a large bulletin file just to extract header +information. This operation is done when a DIRECTORY listing is requested int +BULLETIN. More importantly when a login occurs, non-system bulletins just +require that the header information be displayed. Having a file with pointers +to where the bulletin is stored also avoids requiring the software to read all +the previous bulletins in order to arrive at the desired bulletin. The main +disadvantage is the extra time spent on locating the second file. This time +appears to be minimal. In all the software, the convention is to open theu +directory file first, and then if needed to open the bulletin file. Whent +adding and delete files, this becomes important, as files are opened unshared. e +A deadlock might occur if one user opens the bulletin file first while another +user opens the directory file, and then each try to open the alternate file. + +BULLUSER.DAT is a relative indexed file, where the keyword is the username ofs +the user. Each entry contains the latest time that the user logged in, plus +the latest time that the BULLETIN utility was used to read bulletins. A headert +entry with a blank username stores the latest bulletin date. The informationn +in this file is used for checking to see if the user should be alerted to newn +bulletins or not.h +Cd +C THE FIRST 3 FILES ARE FILES CREATED AND USED BY BULLETIN. +C SEE BULLETIN.TXT FOR MORE INFORMATION. SPECIFY THE DEVICE/DIRECTORY +C IN WHICH YOU DESIRE THAT THEY BE KEPT. THE FOURTH FILE IS SIMPLY +C THE MAIL FILE FROM WHICH MESSAGES ARE CONVERTED TO NON-SYSTEM +C BULLETINS (AFTER WHICH THE MAIL IS DELETED.) IF YOU DO NOT WISHi +C THE BBOARD OPTION, CHANGE THE DEFINITION FOR BBOARD TO BE: /'NONE'/.r +C IF IT IS NOT SELECTED, YOU DO NOT HAVE TO MODIFY THE REST OF THEf +C BBOARD VARIABLES. IF IT IS SELECTED, YOU MUST SPECIFY THE UIC +C NUMBER OF THE BBOARD ACCOUNT. YOU MUST ALSO SPECIFY BBOARD_FILE, +C WHICH IS A TEMPORARY FILE WHICH IS USED TO CONVERT THE BBOARD MAILe +C TO A SEQUENTIAL FILE. +CE + COMMON /FILES/ BULLDIR_FILE,BULLETIN_FILE,BULLUSER_FILE,BBOARD_USER + COMMON /FILES/ BBOARD_UIC,BBOARD_FILE,BBOARD_COMMANDS + CHARACTER*80 BULLDIR_FILE /'IML$EXE:BULLDIR.DAT'/ + CHARACTER*80 BULLETIN_FILE /'IML$EXE:BULLETIN.DAT'/ + CHARACTER*80 BULLUSER_FILE /'IML$EXE:BULLUSER.DAT'/ + CHARACTER*12 BBOARD_USER /'BBOARD'/,BBOARD_UIC/'[330,5]'/ + CHARACTER*80 BBOARD_FILE/'USRD$:[BBOARD]BBOARD.MAI'/A +CF +C THE BBOARD.COM IS INCLUDED WITH THE SOURCES AND IS USED IF THE BBOARD +C FEATURE IS DESIRED. IT IS NOT CREATED, SO YOU MUST MOVE IT TO THEc +C DESIRED DIRECTORY. YOU MUST ALSO EDIT IT SO THAT THE FILE SPECIFIEDH +C IN THE 'EXTRACT' LINE MATCHES THE FILE SPECIFIED BY BBOARD_FILE.d +Ct + CHARACTER*80 BBOARD_COMMAND/'IML$EXE:BBOARD.COM'/ + PARAMETER ADD_FLAG = '1'X + PARAMETER BACK_FLAG = '2'Xu + PARAMETER DELETE_FLAG = '4'X + PARAMETER DIRECTORY_FLAG = '8'X + PARAMETER EXIT_FLAG = '10'X + PARAMETER FILE_FLAG = '20'X + PARAMETER HELP_FLAG = '40'X + PARAMETER NEXT_FLAG = '80'X + PARAMETER READ_FLAG = '100'Xn + PARAMETER SYSTEM_FLAG = '200'XE + PARAMETER BROADCAST_FLAG = '400'X + PARAMETER BADSWITCH_FLAG = '800'X + PARAMETER REPLACE_FLAG = '1000'Xt + PARAMETER EXPIRE_FLAG = '2000'X + PARAMETER HEADER_FLAG = '4000'X + PARAMETER TEXT_FLAG = '8000'X + PARAMETER NUMBER_FLAG = '10000'X + PARAMETER SHUTDOWN_FLAG = '20000'Xu + PARAMETER PERMANENT_FLAG = '40000'X + + COMMON /BULLPAR/ FLAGS,BULL_PARAMETER,LEN_P,NUMBER_PARAM + CHARACTER*64 BULL_PARAMETER + INTEGER FLAGS + MODULE BULLETIN_MAINCOMMANDS + DEFINE VERB BULLETINe + QUALIFIER READNEWb + QUALIFIER LOGINi +$ RUN SYS$SYSTEM:INSTALL +SYS$SYSTEM:BULLETIN/SHARE/OPEN/HEAD/PRIV=(OPER,SYSPRV,CMKRNL). +/EXITt + + COMMON /BULL_USER/ USERNAME,LOGIN_DATE,LOGIN_TIME,READ_DATE,r + & READ_TIME,FLAGSn + CHARACTER*12 USERNAME + CHARACTER*11 LOGIN_DATE,READ_DATE + CHARACTER*8 LOGIN_TIME,READ_TIMEo + DIMENSION FLAGS(2)c + + .LIBRARY /SYS$LIBRARY:LIB.MLB/p + $CLIDEF GLOBALa + .ENDE +$ FORTRAN BULLETIN +$ FORTRAN BULLSUBS +$ MAC CLIDEF +$ MAC HPWD +$ MAC SETUIC +$ MAC SETUSERg +$ MAC USEROPEN +$ SET COMMAND/OBJ BULLCOMs +$ SET COMMAND/OBJ BULLMAIN +$ @BULLETIN.LNKn +.TITLE HPWD - hash user password +.IDENT 'V02-002' + +; This code was gotten by disassembling the AUTHORIZE program. +; It is quite shameful that DEC has not seen fit to providet +; this as a system service.e + +; If you want lots of good comments, see the fiche. + +; e _lib$code:_lib$code+68 + + +; Inputs: PWDDSC -- Addres of password descriptor +; ENCRYPT -- Encryption algorithm index (byte) +; SALT - random number (word)i +; USRDSC - Address of username descriptorf + +; output: OUTDSC -- Address of encrypted output descriptor + +OUTDSC=4 +PWDDSC=OUTDSC+4 +ENCRYPT=PWDDSC+4 +SALT=ENCRYPT+4 +USRDSC=SALT+4t + +.PSECT _LIB$CODE RD,NOWRT,PIC,SHR,BYTE,EXE + +; AUTODIN-II polynomial table used by CRC algorithm +AUTODIN: + .LONG ^X000000000,^X01DB71064,^X03B6E20C8,^X026D930AC,^X076DC4190 + .LONG ^X06B6B51F4,^X04DB26158,^X05005713C,^X0EDB88320,^X0F00F9344 + .LONG ^X0D6D6A3E8,^X0CB61B38C,^X09B64C2B0,^X086D3D2D4,^X0A00AE278 + .LONG ^X0BDBDF21C + +; Purdy polynomial coefficients. Prime, but don't need to be +Purdy_Poly:m +c: + .LONG -83,-1t + .LONG -179,-1 + .LONG -257,-1 + .LONG -323,-1 + .LONG -363,-1 + +.ENTRY LGI$HPWD,^M<R2,R3,R4> + MOVAQ @outdsc(AP),R4E + MOVAQ @4(R4),R4 + TSTB encrypt(AP) + BGTRU 10$ + MNEGL #1,R0 + MOVAQ @pwddsc(AP),R1E + CRC autodin,R0,(R1),@4(R1)N + CLRL R1& + MOVQ R0,(R4) + BRB 20$ + +10$: CLRQ (R4)5 + MOVAQ @pwddsc(AP),R3 + BSBB COLLAPSE_R2 + ADDW2 salt(AP),3(R4)E + MOVAQ @usrdsc(AP),R3 + BSBB COLLAPSE_R2 + PUSHAQ (R4)N + CALLS #1,PURDYS + +20$: MOVL #1,R0 + RET + + +COLLAPSE_R2: + MOVZWL (R3),R0 + BEQL 20$ + MOVAL @4(R3),R2 + PUSHR #^M<R1,R2> + MOVL R0,R1n +5$: CMPB (R2)+,#32 + BNEQ 7$ + DECL R1 +7$: SOBGTR R0,5$. + MOVL R1,R0 + POPR #^M<R1,R2> +10$: BICL3 #-8,R0,R1 + ADDB2 (R2)+,(R4)[R1] + SOBGTR R0,10$ +20$: RSB + +a=59 +n0=1@24-3d +n1=1@24-63 + + +.ENTRY PURDY,^M<r2,r3,r4,r5> + MOVQ @4(AP),-(SP) + BSBW PQMOD_R0 + MOVAQ (SP),R4 + MOVAQ PURDY_POLY,R5 + MOVQ (R4),-(SP)d + PUSHL #n1 + BSBB PQEXP_R3a + MOVQ (R4),-(SP)n + PUSHL #n0-n1l + BSBB PQEXP_R3d + MOVQ (R5)+,-(SP) + BSBW PQADD_R0n + BSBW PQMUL_R2 + MOVQ (R5)+,-(SP) + MOVQ (R4),-(SP), + BSBW PQMUL_R2l + MOVQ (R5)+,-(SP) + BSBW PQADD_R0t + MOVQ (R4),-(SP)i + BSBB PQMUL_R2L + MOVQ (R5)+,-(SP) + BSBW PQADD_R0i + MOVQ (R4),-(SP)o + BSBB PQMUL_R2 + MOVQ (R5)+,-(SP) + BSBW PQADD_R0B + BSBW PQADD_R0L + MOVQ (SP)+,@4(AP)T + MOVL #1,R0 + RET + +PQEXP_R3:S + POPR #^M<r3> + MOVQ #1,-(SP)p + MOVQ 8+4(SP),-(SP) + TSTL 8+8(SP) + BEQL 30$ +10$: BLBC 8+8(SP),20$ + MOVQ (SP),-(SP) + MOVQ 8+8(SP),-(SP) + BSBB PQMUL_R2i + MOVQ (SP)+,8(SP) + CMPZV #1,#31,8+8(SP),#0 + BEQL 30$ +20$: MOVQ (SP),-(SP)s + BSBB PQMUL_R2 + EXTZV #1,#31,8+8(SP),8+8(SP) + BRB 10$ + +30$: MOVQ 8(SP),8+8+4(SP) + MOVAQ 8+8+4(SP),SP + JMP (R3)s + +u=0m +v=u+4 +y=u+8s +z=y+4o + +PQMOD_R0:b + POPR #^M<R0> + CMPL v(SP),#-1 + BLSSU 10$ + CMPL u(SP),#-a + BLSSU 10$ + ADDL2 #a,u(SP)t + ADWC #0,v(SP)m +10$: JMP (R0)L + +PQMUL_R2:s + POPR #^M<r1> + MOVL SP,R2 + PUSHL z(R2) + PUSHL v(R2) + BSBB EMULQ + BSBB PQMOD_R0i + BSBB PQLSH_R0e + PUSHL y(R2) + PUSHL v(R2) + BSBB EMULQ + BSBB PQMOD_R0t + PUSHL z(R2) + PUSHL u(R2) + BSBB EMULQ + BSBB PQMOD_R0 + BSBB PQADD_R0e + BSBB PQADD_R0T + BSBB PQLSH_R0 + PUSHL y(R2) + PUSHL u(R2) + BSBB EMULQ + BSBB PQMOD_R0r + BSBB PQADD_R0 + MOVQ (SP)+,Y(R2) + MOVAQ Y(R2),SP + JMP (R1)e + +EMULQ: + EMUL 4(SP),8(SP),#0,-(SP)h + CLRL -(SP) + TSTL 4+8+4(SP) + BGEQ 10$ + ADDL2 4+8+8(SP),(SP) +10$: TSTL 4+8+8(SP) + BGEQ 20$ + ADDL2 4+8+4(SP),(SP)I +20$: ADDL2 (SP)+,4(SP) + MOVQ (SP)+,4(SP) + RSB e + +PQLSH_R0:u +.ENABLE LSBL + POPR #^M<r0> + PUSHL v(SP) + PUSHL #aa + BSBB EMULQ + ASHQ #32,Y(SP),Y(SP) + BRB 10$ + +PQADD_R0:e + POPR #^M<R0> +10$: ADDL2 u(SP),y(SP) + ADWC v(SP),z(SP) + BLSSU 20$ + CMPL z(SP),#-1 + BLSSU 30$ + CMPL y(SP),#-a + BLSSU 30$ +20$: ADDL2 #a,y(SP)a + ADWC #0,z(SP) +30$: MOVAQ Y(SP),SPa + JMP (R0)m +.END +$ COPY BULLETIN.EXE SYS$SYSTEM:i +$ SET FILE SYS$SYSTEM:BULLETIN.EXE/OWN=[1,4] +$ RUN SYS$SYSTEM:INSTALL +SYS$SYSTEM:BULLETIN/SHARE/OPEN/HEAD/PRIV=(OPER,SYSPRV,CMKRNL)y +/EXITe +$ LIB/CREATE/HELP SYS$HELP:BULLi +$ LIB/HELP SYS$HELP:BULL BULLCOMSu +$ LIB/HELP SYS$HELP:HELPLIB BULLETIN +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. System messages, such as thisn +one, are displayed in full. Only topics will be displayed for non-systemt +messages. Messages are submitted using the BULLETIN command. Any user maye +submit a non-system message. Only privileged users can submit a systemi +message. For more information, see the on-line help (via HELP BULLETIN). x +$ BULL*ETIN :== $SYS$SYSTEM:BULLETIN +$ BULLETIN/LOGIN +;e +; Name: SETUIC.MAR +; +; Type: Integer*4 Function (MACRO)e +;h +; Author: M. R. London +; +; Date: May 31, 1983t +;b +; Purpose: To set the UIC of the current process (which turns out +; to be the process running this program.) +;m +; Usage:i +; status = SETUIC(group number, user number) +;o +; status - $CMKRNL status return. 0 if arguments wrong. +; group number - longword containing UIC group numberi +; user number - longword containing UIC user numberh +;s +; NOTES:n +; Must link with SS:SYS.STBt +; + + .Title SETUIC Set uic + .IDENT /830531/ +;t +; Libraries:l +; + .LIBRARY /SYS$LIBRARY:LIB.MLB/a +;t +; Global variables: +;n + $PCBDEF +;e +; Executable: +;t + .PSECT SETUIC_CODE,EXE,NOWRT ; Executable codee + + .ENTRY SETUIC,^M<R2,R3> + CLRL R0 ; 0 is error coden + MOVZBL (AP),R2 ; Get number of arguments + CMPL R2,#2 ; Are there 2 arguments + BNEQ 5$ ; If not, return + MOVL @4(AP),R3 ; Group number into R3 + ROTL #16,R3,R3 ; Move to upper half of R3 + ADDL2 @8(AP),R3 ; User number to top half of R3 + $CMKRNL_S ROUTIN=10$ ; Must run in kernel modeF +5$: RETA +10$: .WORD ^M<> ; Entry maskS + MOVL SCH$GL_CURPCB,R2 ; Address of current process + MOVL R3,PCB$L_UIC(R2) ; Set UIC to specified + MOVZWL #SS$_NORMAL,R0 ; Normal ending + RET + .ENDT +; +; Name: SETUSER.MAR +; +; Type: Integer*4 Function (MACRO)A +;T +; Author: M. R. London[ +;A +; Date: Jan 26, 1983 +;E +; Purpose: To set the Username of the current process (which turns outA +; to be the process running this program.) +;T +; Usage: +; status = SETUSER(username) +;M +; status - $CMKRNL status return. 0 if arguments wrong. +; username - Character string containing usernameI +;d +; NOTES:A +; Must link with SS:SYS.STBX +;B + + .Title SETUSER Set uicF + .IDENT /830531/ +;R +; Libraries:' +; + .LIBRARY /SYS$LIBRARY:LIB.MLB/P +;M +; Global variables: +;X + $PCBDEF + $JIBDEF +;= +; local variables:L +;L + + .PSECT SETUSER_DATA,NOEXEG + +NEWUSE: .BLKB 12 ; Contains new usernameT +OLDUSE: .BLKB 12 ; Contains old usernameG +;' +; Executable: +;B + .PSECT SETUSER_CODE,EXE,NOWRT ; Executable code + + .ENTRY SETUSER,^M<R2,R3,R4,R5,R6,R7,R8> + CLRL R0 ; 0 is error code + MOVZBL (AP),R8 ; Get number of arguments + CMPL R8,#1 ; Correct number of arguments + BLSS 5$ ; If not, return + MOVZBL @4(AP),R6 ; Get size of string + MOVL 4(AP),R7 ; Get address of descriptor + MOVL 4(R7),R7 ; Get address of string + MOVC5 R6,(R7),#32,#12,NEWUSE ; Get new username string + CMPL R8,#2 ; Old username given? + BLSS 2$ ; No + MOVZBL @8(AP),R6 ; Get size of string + MOVL 8(AP),R7 ; Get address of descriptor + MOVL 4(R7),R7 ; Get address of string + MOVC5 R6,(R7),#32,#12,OLDUSE ; Get old username string + $CMKRNL_S ROUTIN=20$ ; Must run in kernel mode + TSTL R0 ; If old username is checks with + BEQL 2$ ; present process name, changeS + MOVL #2,R0 ; to new username, else flagE + RET ; error and returnA +2$: $CMKRNL_S ROUTIN=10$ ; Must run in kernel mode +5$: RETE +10$: .WORD ^M<> ; Entry mask/ + MOVL SCH$GL_CURPCB,R7 ; Address of current process + MOVL PCB$L_JIB(R7),R7 ; Address of Job Info Block0 + ; NOTE: MOVC destroys r0-r5a + MOVC3 #12,NEWUSE,JIB$T_USERNAME(R7) ; change username JIB + MOVC3 #12,NEWUSE,CTL$T_USERNAME ; change username in P1 + MOVZWL #SS$_NORMAL,R0 ; Normal ending + RET +20$: .WORD ^M<> ; Entry mask+ + MOVL SCH$GL_CURPCB,R7 ; Address of current process + MOVL PCB$L_JIB(R7),R7 ; Address of Job Info Block) + ; NOTE: MOVC destroys r0-r5 + CMPC R6,OLDUSE,JIB$T_USERNAME(R7) ; change username JIBO + RET + .ENDr +$ UIC := 'F$GETJPI("","UIC") +$ SET UIC [1,4] +$ SET PROTECT=(SYSTEM:RWE,OWNER:RWE,WORLD,GROUP)/DEFAULT +$ RUN BULLETIN +ADD/PERMANENT/SYSTEM INSTRUCT.TXTE +INFORMATION ON HOW TO USE THE BULLETIN UTILITY.a +EXIT +$ SET UIC 'UIC'O +$ DEFAULT := 'F$FILE("SYS$LOGIN:LOGIN.COM","PRO")^ +$ SET PROTECT=('DEFAULT')/DEFAULTD +;------------------------------------------------------------------------------4 +;0 +; Name: USER_OPEN +;8 +; Type: Multilple Function (MACRO)o +;l +; Author: T.W.Frediann +; MIT Plasma Fusion Center +; +; Date: January 26, 1983, +; +; Version:. +;G +; Purpose: Used to permit qio access to files with fortran. +; Returns channel and file size information and +; provides file truncation capability. Files opened +; with these useopens cannot be accessed using fortranV +; reads and writes and the dispose= keyword on theQ +; close of the file will have no effect. To make theP +; logical unit reuseable for normal RMS access you must +; deassign the channel using SYS$DASSGN(%VAL(channel))T +; and then use the close (unit= ) statement.$ +;M +; Types of useropens provided: +;n +; USER_OPEN$OLD - open old file +; USER_OPEN$NEW - open new file +; USER_OPEN$TRUNCATE - open old file and truncate it +; to the size specified by theQ +; INITIALSIZE keyword of the open +;1 +; To receive the channel, open RMS status and size of the fileR +; include a common USER_OPEN as follows:P +;L +; Common /USER_OPEN/ CHANNEL,STATUS,SIZE +; Integer*4 CHANNEL - I/O channel assigned to the file, +; Integer*4 STATUS - RMS status return of open +; Integer*4 SIZE - Size of the file opened in blocks +;B +;------------------------------------------------------------------------------T +; +; Call seqence: NONE - USEROPEN keyword of fortran OPEN statement- +; for example: +;0 +; External USER_OPEN$NEW +; . +; .) +; .L +; OPEN (UNIT=lun,FILE=filename,....,USEROPEN=USER_OPEN$NEW)0 +;M +;------------------------------------------------------------------------------ +;$ +; Description:8 +;) +; Entry mask for USER_OPEN$OLD +; Get the FAB address= +; Set the user file open bit +; Open old file +; Save the channel +; Save the sizeU +; Save the statusS +; Return + +; Entry mask for USER_OPEN$NEW +; Get the FAB addressJ +; Set the user file open bit +; Open new fileM +; Save the channel +; Save the size +; Save the statusU +; Return + +; Entry mask for USER_OPEN$TRUNCATEL +; Get the FAB address) +; Get the RAB address +; Save the sizeS +; Open old fileL +; Connect file to record stream +; Load the size of the file in the RAB +; Set the access mode to relative file address +; Find the last record in the file +; Place the end of file marker at this location +; Mark the file to be truncated on close +; Close the file +; Return + +; EndC +; +;+----------------------------------------------------------------------------- + + .TITLE USER_OPEN2 + .IDENT /V_830128/ + +;P +;------------------------------------------------------------------------------A +; +; Global variables:> +;P + .PSECT USER_OPEN LONG,PIC,OVR,GBL,SHR,NOEXE + +CHANNEL: .BLKL 1 ; Channel numberD +STATUS: .BLKL 1 ; Status return of open +SIZE: .BLKL 1 ; Size of fileS + +;2 +;------------------------------------------------------------------------------2 +;# +; Executable: +;# + .PSECT $CODE LONG,PIC,USR,CON,REL,LCL,SHR,EXE,RD,NOWRT,NOVECB + + .ENTRY USER_OPEN$OLD,^M<R2> ; Entry mask for USER_OPEN$OLD + MOVL 4(AP),R2 ; Get the FAB addressL + INSV #1,#FAB$V_UFO,#1,FAB$L_FOP(R2) ; Set the user file open bitA + $OPEN FAB=(R2) ; Open old fileS + MOVL FAB$L_STV(R2),CHANNEL ; Save the channel + MOVL FAB$L_ALQ(R2),SIZE ; Save the sizee + MOVL R0,STATUS ; Save the statusC + RET ; Returns + + .ENTRY USER_OPEN$NEW,^M<R2> ; Entry mask for USER_OPEN$NEW + MOVL 4(AP),R2 ; Get the FAB address + INSV #1,#FAB$V_UFO,#1,FAB$L_FOP(R2) ; Set the user file open bit + INSV #0,#FAB$V_CBT,#1,FAB$L_FOP(R2) ; Disable contiguous best try + $CREATE FAB=(R2) ; Open new files + MOVL FAB$L_STV(R2),CHANNEL ; Save the channel + MOVL FAB$L_ALQ(R2),SIZE ; Save the sizeS + MOVL R0,STATUS ; Save the status + RET ; Return. + + .ENTRY USER_OPEN$TRUNCATE,^M<R2,R3,R4,R5> ; Entry mask for USER_OPEN$TRUNCATE + MOVL 4(AP),R2 ; Get the FAB addresst + MOVL 8(AP),R3 ; Get the RAB address + MOVL FAB$L_ALQ(R2),R4 ; Save the sizep + INCL R4 ; Increment the size + INSV #0,#FAB$V_SQO,#1,FAB$L_FOP(R2) ; Clear the sequential only bit + $OPEN FAB=(R2) ; Open old fileu + BLBC R0,CLOSE ; If unsuccessful branch to close + $CONNECT RAB=@8(AP) ; Connect file to record stream + BLBC R0,CLOSE ; If unsuccessful branch to closeU + MOVL R4,RAB$L_RFA0(R3) ; Load the size of the file in the RABS + MOVW #0,RAB$W_RFA4(R3) + MOVB #RAB$C_RFA,RAB$B_RAC(R3) ; Set the access mode to relative file address, + $FIND RAB=(R3) ; Find the last record in the file + BLBC R0,CLOSE ; If unsuccessful branch to close + $TRUNCATE RAB=(R3) ; Place the end of file marker at this locationB + INSV #1,#FAB$V_TEF,#1,FAB$L_FOP(R2) ; Mark the file to be truncated on close, +CLOSE: PUSHL R0 ; Save error status + $CLOSE FAB=(R2) ; Close the filea + POPL R0 ; Restore error status + MOVL R0,STATUS ; Return the status + RET ; Returny + + .END ; EndL + diff --git a/batch/seed/1985c-instruct.txt b/batch/seed/1985c-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..f1c1ae7c0c6dfce94f751aa4b0558d06eba2556c --- /dev/null +++ b/batch/seed/1985c-instruct.txt @@ -0,0 +1,10 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1985 11:03 +Subj: BULLETIN summary + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. System messages, such as this +one, are displayed in full. Only topics will be displayed for non-system +messages. Messages are submitted using the BULLETIN command. Any user may +submit a non-system message. Only privileged users can submit a system +message. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1986c-aaareadme.txt b/batch/seed/1986c-aaareadme.txt new file mode 100644 index 0000000000000000000000000000000000000000..6dcecc9d73bb1c8fca8da68da1d237f0601f63bb --- /dev/null +++ b/batch/seed/1986c-aaareadme.txt @@ -0,0 +1,16 @@ +From: MRL "Mark R. London" +Date: 30-OCT-1986 11:03 +Subj: BULLETIN summary + +This is BULLETIN, a VAX based bulletin board facility which allows you +to create numerous topic folders and browse them, reply to selected +entries, handle private folders or messages, etc. Any user can send +bulletins or read them (if permitted), and public, private, and +semi-private folders are permitted. Mail can be sent to folders +and the system understands working across networks. Bulletins can +be sent to files, print queues, or mail to other users. + This system seems to do a lot that VAXNotes does, and a lot +that Tools Mail does, and some more besides. Read the BULLETIN.TXT +file for how to get started. + From Mark London, MIT. + diff --git a/batch/seed/1986c-bulletin.txt b/batch/seed/1986c-bulletin.txt new file mode 100644 index 0000000000000000000000000000000000000000..a972086ba74a65cbcb9ce2454888f375f7f3eeda --- /dev/null +++ b/batch/seed/1986c-bulletin.txt @@ -0,0 +1,41 @@ +From: MRL "Mark R. London" +Date: 03-NOV-1986 22:43 +Subj: BULLETIN + +You are about to receive a copy of the PFC BULLETIN. This software is +public domain. I will gladly accept reasonable suggestions for modifications, +and will attempt to fix bugs as quickly as possible. + +You will be receiving 7 files for the 10/1/86 version of BULLETIN facility. +They are: + 1) BULLETIN.FOR + 2) BULLSUB0.FOR + 3) BULLSUB1.FOR + 4) BULLSUB2.FOR + 5) BULLSUB3.FOR + 6) ALLMACS.MAR + 7) BULLET.COM + (They will be indentified in the SUBJECT header.) +BULLET.COM is a command procedure which when run, will create several small +files. This takes about a minutes. After you run it, you can delete it. +Read AAAREADME.TXT for installation instructions. + +NOTE: Remember to strip off any header that is created on these files that is +added when converting them from mail messages to files, including blank lines. + +SECOND NOTE: The feature which allows setting up folders to be publicly +readable but with limited access for writing requires at least VMS VERSION 4.4, +as the code uses a new system service $CHECK_ACCESS. The code is in +BULLSUB2.FOR, and instructions are there for how to comment it out if you are +running an earlier version. This will simply cause the feature to be disabled. +Creating fully private folders will still be possible (i.e. limited access for +both reading and writing). + +I've had various problems sending files to certain sites. I've had to reduce +file sizes in order to transfer the files, and more reduction may be necessary. +BITNET sites are being sent files without any TABs, as TABs were getting +converted to 4 spaces. Please let me know of any sites which have similar +problems (or any other type, for that matter). Thank you. + Mark London + MRL%PFCVAX@XX.LCS.MIT.EDU + diff --git a/batch/seed/1987a-bulletinann.txt b/batch/seed/1987a-bulletinann.txt new file mode 100644 index 0000000000000000000000000000000000000000..da4e9fdbbb992ceacb6f8ac417e0ecd24198fd90 --- /dev/null +++ b/batch/seed/1987a-bulletinann.txt @@ -0,0 +1,190 @@ +From: MRL "Mark R. London" +Date: 19-JUN-1987 16:19 +Subj: BULLETIN + +You are about to receive version 1.31 of the PFC BULLETIN. This software is +public domain. (I will gladly accept recommendations for new features, not +for changes that are due to "personal" preference.) + +(The latest feature and bug fixes for this new version are listed later.) + +You will be receiving 11 files: + 1) BULLETIN.FOR + 2) BULLETIN0.FOR + 3) BULLETIN1.FOR + 4) BULLETIN2.FOR + 5) BULLETIN3.FOR + 6) BULLETIN4.FOR + 7) BULLETIN5.FOR + 8) BULLETIN6.FOR + 9) ALLMACS.MAR + 10) BULLCOMS.HLP + 11) BULLET.COM + (They will be indentified in the SUBJECT header.) +BULLET.COM is a command procedure which when run, will create several small +files. After you run it, you can delete it. +Read AAAREADME.TXT for installation instructions. + +NOTE: When creating these files (using the EXTRACT command) from the VMS MAIL +utility, you will have to strip off any mail headers that are present, including +blank lines. A command procedure is included at this end of this message which +can be run which uses EDT to do this for you. + +SECOND NOTE: The feature which allows setting up folders to be publicly +readable but with limited access for writing requires at least VMS VERSION 4.4, +as the code uses a new system service $CHECK_ACCESS. The code is in +BULLETIN4.FOR, and instructions are there for how to comment it out if you are +running an earlier version. This will simply cause the feature to be disabled. +Creating fully private folders will still be possible (i.e. limited access for +both reading and writing). + +I've had various problems sending files to certain sites. I've had to reduce +file sizes in order to transfer the files, and more reduction may be necessary. +BITNET sites are being sent files without any TABs, as TABs were getting +converted to 4 spaces. Please let me know of any sites which have similar +problems (or any other type, for that matter). Thank you. + Mark London + MRL%PFCVAX@XX.LCS.MIT.EDU +------------------------------------------------------------------------------ +The following is a description of recent new features and bug fixes. + +V1.0 + +One is now able to increase the limit of the number folders to whatever you +want rather than the previous limit of 64. However, changing the limit +requires rebuilding the executable. + +/VMSMAIL added to use with SET BBOARD/SPECIAL to check if there is VMS MAIL +before running special command procedure. This saves time and avoids +needless subprocess creation. + +EXTRACT command added as synonym command to FILE (for compatibility). Also +/NEW qualifier added to create new file rather than appending to existing file. + +CREATE/BRIEF did not work properly. Although SHOW BRIEF would show that BRIEF +was set, in reality it was not. Note that help for these two commands were +also omitted. + +V1.1 + +Removed restriction that prevented GENERAL folder from being set to PRIVATE +or SEMIPRIVATE. + +Fixed bugs with regards to PRIVATE folders. If it had /BRIEF or /READNEW +defaults, a user without the ability to access that folder would get access +violation when logging in. Also, if /NOTIFY was a default, the user would get +notified. These have been fixed. Also, a bug which caused a crash when +attempting to MOVE a message to a PRIVATE folder has been fixed. + +Access to private folders besides being allowed via SET ACCESS commands, +is now allowed based on process privileges. Previously, access was allowed +based on the UAF authorized privileges rather than process privileges. + +Made MODIFY/OWNER a privileged command. Also, modifying ownership of a private +bulletin has been corrected. Previously, it did not change access correctly. +It now removes access from the old user and adds access to the new user. + +Allow the CREATE command to become privileged command via change in BULLCOM.CLD. + +Add /FOLDER qualifier to ADD command. + +Modified algorithm which deleted non-existant users from user data file when +new user logged in. For large databases, this was taking a long time, and +in fact was not very useful. + +Add /EDIT qualifier to BULLETIN command, similar to MAIL/EDIT, to cause /EDIT +to be the default for ADD & REPLACE commands. + +EX command is equal to EXIT, and is not flagged as being ambiguous (due to +conflict with EXTRACT command added in V1.0). + +Fixed bug which caused incorrect notification of new messages in folders. +Situation occurred if new message expired after user logged in. BULLETIN +would notify user that new message existed, and would place user at a +message that the user had already read. + +In login display, add line of minus signs to separate SYSTEM messages. +(This can be disabled if desired by modifying BULLMAIN.CLD). + +Fixed (?) bugs which prevented proper file conversion from older versions of +BULLETIN (circa 1985). + +V1.2 + +Added SHOW NEW command to show folders with unread new messages. This is +useful if you enter BULLETIN and are notified that there are new messages +in certain folder, and later in the session which to show which folders +still have unread messages. + +CREATE/BRIEF should have been a privileged command, but was not. It is +now privileged. + +The /ALL qualifier has been added to the SET BRIEF/NOTIFY/READNEW command. +It will modify the option for the selected option for all users. This is +in contrast to /DEFAULT, which would only modify the default for new users. +This is a privileged command. + +When reading messages, the name of the folder is displayed on the top line +at the upper right hand corner (similar to MAIL). + +V1.3 + +Fixed bug introduced in V1.1 that would put wrong subject in MOVED message. + +/EDIT feature now correctly recognizes MAIL$EDIT definitions of CALLABLE_EDT +and CALLABLE_TPU. + +Messages sent via BBOARD that have lines containing greater than 80 characters +are now broken into separate lines rather than truncated. + +V1.31 + +SEARCH did not work as advertised. It would start the search at the currently +read message rather than at the beginning of the folder. This has been fixed. +Additionally, a /START qualifier has been added to the command. +------------------------------------------------------------------------------- +$ set nover +$ edit/edt/nocommand allmacs.mar +'; Name: SETACC.MAR' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin0.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin1.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin2.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin3.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin4.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin5.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin6.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bullcoms.hlp +'1 ADD' +d 1:.-1 +exit +$ edit/edt/nocommand bullet.com +'$set nover' +d 1:.-1 +exit diff --git a/batch/seed/1987d-bulletin.txt b/batch/seed/1987d-bulletin.txt new file mode 100644 index 0000000000000000000000000000000000000000..0ee14956f6d881fe8e77320678057dd5b8f2bef6 --- /dev/null +++ b/batch/seed/1987d-bulletin.txt @@ -0,0 +1,206 @@ +From: MRL "Mark R. London" +Date: 15-JUL-1987 05:22 +Subj: BULLETIN 1.32 + +You are about to receive version 1.32 of the PFC BULLETIN. This software is +public domain. (I will gladly accept recommendations for new features, not +for changes that are due to "personal" preference.) + +(The latest feature and bug fixes for this new version are listed later.) + +You will be receiving 11 files: + 1) BULLETIN.FOR + 2) BULLETIN0.FOR + 3) BULLETIN1.FOR + 4) BULLETIN2.FOR + 5) BULLETIN3.FOR + 6) BULLETIN4.FOR + 7) BULLETIN5.FOR + 8) BULLETIN6.FOR + 9) ALLMACS.MAR + 10) BULLCOMS.HLP + 11) BULLET.COM + (They will be indentified in the SUBJECT header.) +BULLET.COM is a command procedure which when run, will create several small +files. After you run it, you can delete it. +Read AAAREADME.TXT for installation instructions. + +NOTE: When creating these files (using the EXTRACT command) from the VMS MAIL +utility, you will have to strip off any mail headers that are present, including +blank lines. A command procedure is included at this end of this message which +can be run which uses EDT to do this for you. + +SECOND NOTE: The feature which allows setting up folders to be publicly +readable but with limited access for writing requires at least VMS VERSION 4.4, +as the code uses a new system service $CHECK_ACCESS. The code is in +BULLETIN4.FOR, and instructions are there for how to comment it out if you are +running an earlier version. This will simply cause the feature to be disabled. +Creating fully private folders will still be possible (i.e. limited access for +both reading and writing). + +I've had various problems sending files to certain sites. I've had to reduce +file sizes in order to transfer the files, and more reduction may be necessary. +BITNET sites are being sent files without any TABs, as TABs were getting +converted to 4 spaces. Please let me know of any sites which have similar +problems (or any other type, for that matter). Thank you. + Mark London + MRL%PFCVAX@XX.LCS.MIT.EDU +------------------------------------------------------------------------------ +The following is a description of recent new features and bug fixes. + +V1.0 + +One is now able to increase the limit of the number folders to whatever you +want rather than the previous limit of 64. However, changing the limit +requires rebuilding the executable. + +/VMSMAIL added to use with SET BBOARD/SPECIAL to check if there is VMS MAIL +before running special command procedure. This saves time and avoids +needless subprocess creation. + +EXTRACT command added as synonym command to FILE (for compatibility). Also +/NEW qualifier added to create new file rather than appending to existing file. + +CREATE/BRIEF did not work properly. Although SHOW BRIEF would show that BRIEF +was set, in reality it was not. Note that help for these two commands were +also omitted. + +V1.1 + +Removed restriction that prevented GENERAL folder from being set to PRIVATE +or SEMIPRIVATE. + +Fixed bugs with regards to PRIVATE folders. If it had /BRIEF or /READNEW +defaults, a user without the ability to access that folder would get access +violation when logging in. Also, if /NOTIFY was a default, the user would get +notified. These have been fixed. Also, a bug which caused a crash when +attempting to MOVE a message to a PRIVATE folder has been fixed. + +Access to private folders besides being allowed via SET ACCESS commands, +is now allowed based on process privileges. Previously, access was allowed +based on the UAF authorized privileges rather than process privileges. + +Made MODIFY/OWNER a privileged command. Also, modifying ownership of a private +bulletin has been corrected. Previously, it did not change access correctly. +It now removes access from the old user and adds access to the new user. + +Allow the CREATE command to become privileged command via change in BULLCOM.CLD. + +Add /FOLDER qualifier to ADD command. + +Modified algorithm which deleted non-existant users from user data file when +new user logged in. For large databases, this was taking a long time, and +in fact was not very useful. + +Add /EDIT qualifier to BULLETIN command, similar to MAIL/EDIT, to cause /EDIT +to be the default for ADD & REPLACE commands. + +EX command is equal to EXIT, and is not flagged as being ambiguous (due to +conflict with EXTRACT command added in V1.0). + +Fixed bug which caused incorrect notification of new messages in folders. +Situation occurred if new message expired after user logged in. BULLETIN +would notify user that new message existed, and would place user at a +message that the user had already read. + +In login display, add line of minus signs to separate SYSTEM messages. +(This can be disabled if desired by modifying BULLMAIN.CLD). + +Fixed (?) bugs which prevented proper file conversion from older versions of +BULLETIN (circa 1985). + +V1.2 + +Added SHOW NEW command to show folders with unread new messages. This is +useful if you enter BULLETIN and are notified that there are new messages +in certain folder, and later in the session which to show which folders +still have unread messages. + +CREATE/BRIEF should have been a privileged command, but was not. It is +now privileged. + +The /ALL qualifier has been added to the SET BRIEF/NOTIFY/READNEW command. +It will modify the option for the selected option for all users. This is +in contrast to /DEFAULT, which would only modify the default for new users. +This is a privileged command. + +When reading messages, the name of the folder is displayed on the top line +at the upper right hand corner (similar to MAIL). + +V1.3 + +Fixed bug introduced in V1.1 that would put wrong subject in MOVED message. + +/EDIT feature now correctly recognizes MAIL$EDIT definitions of CALLABLE_EDT +and CALLABLE_TPU. + +Messages sent via BBOARD that have lines containing greater than 80 characters +are now broken into separate lines rather than truncated. + +V1.31 + +SEARCH did not work as advertised. It would start the search at the currently +read message rather than at the beginning of the folder. This has been fixed. +Additionally, a /START qualifier has been added to the command. + +V1.32 + +The change in V1.3 to wrap lines rather than truncate them in BBOARD had a bug +which could occasionally add messages with lines > 80 characters, which cannot +be read by BULLETIN. This has been fixed. + +The change in V1.3 which allowed /EDIT to use the CALLABLE feature to call +editors directly broke the ability to use command procedures to call editors. +This has been fixed. + +When there were new messages in the general folder, SHOW NEW would always show +new messages in that folder. This has been fixed. + +A "SEARCH" can now be stopped by typing a CTRL-C. Previously it could not be +stopped until it found a match or read the last message in the folder. +------------------------------------------------------------------------------- +$ set nover +$ edit/edt/nocommand allmacs.mar +'; Name: SETACC.MAR' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin0.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin1.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin2.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin3.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin4.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin5.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin6.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bullcoms.hlp +'1 ADD' +d 1:.-1 +exit +$ edit/edt/nocommand bullet.com +'$set nover' +d 1:.-1 +exit diff --git a/batch/seed/1987d-bulletinann.txt b/batch/seed/1987d-bulletinann.txt new file mode 100644 index 0000000000000000000000000000000000000000..51b57158cdfe1042c0552a84496182642ca163e4 --- /dev/null +++ b/batch/seed/1987d-bulletinann.txt @@ -0,0 +1,24 @@ +From: MRL "Mark R. London" +Date: 13-DEC-1987 08:36 +Subj: BULLETIN + +There is one major and several minor bugs in V1.44 that I have corrected. +Unless I hear from otherwise, I will be sending out the sources to V1.45 +Friday afternoon. + Mark +------------------------------------------------------------------------- +V1.45 + +Cleanup algorithm was not cleaning up empty blocks in bulletin files. +Bulletin files will grow indefinetly. + +Attempts to add a new message while BULLCP was adding BBOARD message would +result in "unable to open BULLFOLDER.DAT after 30 seconds" error. This +has been fixed. + +SET NOLOGIN feature was not working properly, and has been fixed. + +Folder name abbreviation algorithm changed so that if given letters don't +match any folder name, an error message is returned, rather than selecting +nearest name (the problem with the way it was before is that the nearest +folder name could be very far away, and the user problem doesn't want it). diff --git a/batch/seed/1988a2-handout.txt b/batch/seed/1988a2-handout.txt new file mode 100644 index 0000000000000000000000000000000000000000..750d907bc782f9cbe322145b28a1cfa9295de2d6 --- /dev/null +++ b/batch/seed/1988a2-handout.txt @@ -0,0 +1,272 @@ +From: MRL "Mark R. London" +Date: 01-FEB-1988 12:00 +Subj: Introduction to BULLETIN on the Vax + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. Currently, there are several folders defined: + +GENERAL -- system messages + +PUBLIC_ANNOUNCEMENTS -- Can be used by anyone to post messages +of interest to the public + +On Beta: +AIDE STATION -- Private folder for Computer Center Employees + +In addition on Alpha there are folders that receive electronic +magazines, such as: +NETMONTH -- The monthly magazine of BITNET information. +RISKS -- Identifying the risks involved in using computers. +INFOIBMPC -- Information about the IBM personal computers. +INFOVAX -- Information on the Digital VAX. +PROGRAMMING_JOURNALS-Includes MINIX, UNIX and C, Modula-2 and +Prolog journals +watch for new ones being added. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULD +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS. + +Now the user may enter the subject of the message. + +BULLETIN> + +The above session adds the text in the file 'mess.txt' as the +next message in the PUBLIC_ANNOUNCEMENTS Folder. The message +will be deleted automatically on the 20th of July as requested +by the user adding the message. + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when new +messages are in a folder, he should use the 'READNEW' option. +This command does not force the reader to reading new messages, +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set to +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTS +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEW + +Alternately, you may type SET SHOWNEW. This will just display a +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in the +BULLETIN. While reading the message that he/she desires to send, +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too. + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1988a2-instruct.txt b/batch/seed/1988a2-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..40045828f5cbead042d0628a185f473b9cebd1e7 --- /dev/null +++ b/batch/seed/1988a2-instruct.txt @@ -0,0 +1,12 @@ +From: MRL "Mark R. London" +Date: 01-FEB-1988 12:00 +Subj: Information + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. Messages can be submitted by +using the BULLETIN command. System messages, such as this one, are displayed +in full, but can only be entered by privileged users. Non-system messages can +be entered by anyone, but only their topics will be displayed at login time, +and will be prompted to optionally read them. (This prompting feature can be +disabled). All bulletins can be reread at any time unless they are deleted or +expire. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1988a2-nonsystem.txt b/batch/seed/1988a2-nonsystem.txt new file mode 100644 index 0000000000000000000000000000000000000000..d786e76d175a4eaa40e2003fb2deccfd2e0e48e9 --- /dev/null +++ b/batch/seed/1988a2-nonsystem.txt @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 01-FEB-1988 12:00 +Subj: Information + +Non-system bulletins (such as this) can be submitted by any user. Users are +alerted at login time that new non-system bulletins have been added, but only +their topics are listed. Optionally, users can be prompted at login time to +see if they wish to read the bulletins. When reading the bulletins in this +manner, the bulletins can optionally be written to a file. If you have the +subdirectory [.BULL] created, BULLETIN will use that directory as the default +directory to write the file into. + +A user can disable this prompting featuring by using BULLETIN as follows: + +$ BULLETIN +BULLETIN> SET NOREADNEW +BULLETIN> EXIT + +Afterwords, the user will only be alerted of the bulletins, and will have to +use the BULLETIN utility in order to read the messages. diff --git a/batch/seed/1988a3-bulletin7bugbug.txt b/batch/seed/1988a3-bulletin7bugbug.txt new file mode 100644 index 0000000000000000000000000000000000000000..a94262fb9d2fe5d313a1a1d0f9b937588b923f3d --- /dev/null +++ b/batch/seed/1988a3-bulletin7bugbug.txt @@ -0,0 +1,18 @@ +From: MRL "Mark R. London" +Date: 25-MAY-1988 15:43 +Subj: BULLETIN + +Received: from PFC-VAX.MIT.EDU by XX.LCS.MIT.EDU via Chaosnet; 25 May 88 14:59-EDT +Date: 25 May 88 14:59:09 EDT +From: MRL%PFC-VAX.MIT.EDU@XX.LCS.MIT.EDU +To: TENCATI@VLSI.JPL.NASA.GOV@XX, MHG@MITRE-BEDFORD.ARPA@XX, + EVERHART%ARISIA.DECNET@CRD.GE.COM@XX, GAYMAN@ARI-HQ1.ARPA@XX, + BACH@RADC-SOFTVAX@XX +Subject: BULLETIN + +Apparently, there is another small bug in BULLETIN7.FOR which has been there +for a while which didn't cause any problems until I modified the cleanup +algorithm. There are 2 lines in the subroutine NEW_MESSAGE_NOTIFICATION which +contain the string "0,FOLDER_MAX" which should be changed to "0,FOLDER_MAX-1". +This bug apparently will cause the SET NOTIFY flag to disappear for the +GENERAL folder. MRL diff --git a/batch/seed/1988a3-bulletinann.txt b/batch/seed/1988a3-bulletinann.txt new file mode 100644 index 0000000000000000000000000000000000000000..8b372346582f20bcda9029d76111d4bd747b09ff --- /dev/null +++ b/batch/seed/1988a3-bulletinann.txt @@ -0,0 +1,245 @@ +From: KANE "Joseph Kane" +Date: 05-APR-1988 18:20 +Subj: forwarded mail + +From uunet!rutgers.edu!Postmaster Mon Apr 4 21:45:34 1988 +Received: by kbsvax.steinmetz (1.2/1.1x Steinmetz) + id AA25990; Mon, 4 Apr 88 21:45:24 edt +Received: from RUTGERS.EDU by uunet.UU.NET (5.54/1.14) + id AA27965; Mon, 4 Apr 88 20:41:32 EDT +Received: by rutgers.edu (5.54/1.15) + id AD29798; Mon, 4 Apr 88 20:42:52 EDT +Date: Mon, 4 Apr 88 20:42:52 EDT +From: uunet!rutgers.edu!Postmaster (Mail Delivery Subsystem) +Subject: Returned mail: Host unknown +Message-Id: <8804050042.AD29798@rutgers.edu> +To: <MAILER-DAEMON> +Status: RO + + ----- Transcript of session follows ----- +550 <pfc-vax.mit.edu!mrl@rutgers.edu>... Host unknown + + ----- Unsent message follows ----- +Received: by rutgers.edu (5.54/1.15) + id AA28843; Mon, 4 Apr 88 18:27:10 EDT +Received: from steinmetz.UUCP by uunet.UU.NET (5.54/1.14) with UUCP + id AA17005; Mon, 4 Apr 88 18:23:25 EDT +Received: by kbsvax.steinmetz (1.2/1.1x Steinmetz) + id AA21534; Mon, 4 Apr 88 17:59:48 edt +Date: 2 Apr 88 20:15:30 EST +From: steinmetz!MAILER-DAEMON@uunet.uu.net (Mail Delivery Subsystem) +Subject: Returned mail: User unknown +Message-Id: <8804042159.AA21534@kbsvax.steinmetz> +To: MRL@pfc-vax.mit.edu + + ----- Transcript of session follows ----- +mail11: %MAIL-E-SYNTAX, error parsing 'CRD' +550 crd.ge.com!EVERHART%ARISIA.DECNET... User unknown + + ----- Unsent message follows ----- +Received: by kbsvax.steinmetz (1.2/1.1x Steinmetz) + id AA21526; Mon, 4 Apr 88 17:59:48 edt +Received: by ge-dab.GE.COM (smail2.5) + id AA19407; 4 Apr 88 07:30:44 EDT (Mon) +Received: by ge-rtp.GE.COM (smail2.5) + id AA10949; 3 Apr 88 21:20:10 EST (Sun) +Received: by mcnc.mcnc.org (5.54/MCNC/10-20-87) + id AA15418; Sat, 2 Apr 88 23:08:27 EST +From: <mcnc!rutgers.edu!pfc-vax.mit.edu!MRL> +Received: by rutgers.edu (5.54/1.15) + id AA03601; Sat, 2 Apr 88 21:50:33 EST +Message-Id: <8804030250.AA03601@rutgers.edu> +Received: from PFC-VAX.MIT.EDU by XX.LCS.MIT.EDU via Chaosnet; 2 Apr 88 20:17-EST +Date: 2 Apr 88 20:15:30 EST +To: xx!TENCATI@vlsi.jpl.nasa.gov, xx!MHG@mitre-bedford.arpa, + crd.ge.com!xx!EVERHART@ARISIA.DECNET, xx!GAYMAN@ari-hq1.arpa, + radc-softvax!xx!BACH +Subject: BULLETIN + +You are about to receive version 1.51 of the PFC BULLETIN. + +BULLETIN is public domain software. (I will gladly accept +recommendations for new features, not for changes that are due to +"personal" preference.) + +The previous announcement of a feature that could allow one to eliminate +BBOARD accounts unfortunately does not work with mail received via PMDF, +and probably other packages. See HELP SET BBOARD MORE_INFORMATION. If +your site uses a mailing method that will allow the feature to be used, +you should be aware that there has been a minor change in BOARD_DIGEST.COM +which is related to that feature, so that file should be updated. + +NOTE: If you are upgrading from a version older than 1.4, you should be +aware that the logical names BULLETIN$ and BULL$HELP are no longer being +used in the sources. Also, BULLFOLDER.DAT is converted to a new format +when it is run. This will cause problems in a cluster where each node +must have the executable reinstalled. It is best to deinstall the old +executable on all nodes before installing the new executable. + +(The latest feature and bug fixes for this new version are listed later.) + +You will be receiving 13 files (NOT NECESSARILY IN THIS ORDER!): + 1) BULLETIN.FOR + 2) BULLETIN0.FOR + 3) BULLETIN1.FOR + 4) BULLETIN2.FOR + 5) BULLETIN3.FOR + 6) BULLETIN4.FOR + 7) BULLETIN5.FOR + 8) BULLETIN6.FOR + 9) BULLETIN7.FOR + 10) BULLETIN8.FOR + 11) ALLMACS.MAR + 12) BULLCOMS1.HLP + 13) BULLCOMS2.HLP + 14) BULLET1.COM + 15) BULLET2.COM + +(They will be identified in the SUBJECT header.) BULLET1.COM and +BULLET2.COM are command procedures which when run, will create several +small files. After you run it, you can delete it. Read AAAREADME.TXT +for installation instructions. + +NOTE: When creating these files (using the EXTRACT command) from the VMS +MAIL utility, you will have to strip off any mail headers that are +present, including blank lines. A command procedure is included at this +end of this message which can be run which uses EDT to do this for you. + + MRL%PFCVAX@XX.LCS.MIT.EDU +------------------------------------------------------------------------------ +The following is a description of recent new features and bug fixes. +V1.46 was a minor upgrade which was not distributed to all. V1.5 is a +major upgrade with many new features. + +V1.46 + +The times of the last message read for each folder is now stored in a +global file BULLINF.DAT rather than individually in +SYS$LOGIN:BULLETIN.INF. This was due to conflicts with accounts that +shared the same directory. + +Made several modifications to optimize program running time. Changed +all formatted disk reads to unformatted reads. Changed search algorithm +for latest message in a folder from sequential to binary. Made changes +to speed up BULLCP. + +V1.5 + +Sharing of folders over DECNET is now possible via the BULLCP process +created by BULLETIN/STARTUP. It is now possible to SELECT, READ, +DELETE, etc. a folder on another node. It is also possible to create a +folder that "points" to a folder on another node (i.e. by selecting FOO, +it automatically selects VAX1::FOO). + +Any folder can be made a SYSTEM folder, i.e. a folder than can have +SYSTEM/SHUTDOWN/BROADCAST messages added to it. This allows the +possibility of having a local SYSTEM folder and a shared GLOBAL SYSTEM +folder. One can also use this to easily display SYSTEM messages meant +for only certain UIC groups. This could be done by creating a SYSTEM +PRIVATE folder, with access limited to one UIC group. + +CTRL-C will now abort BULLETIN if BULLETIN is not waiting for input from +the terminal. This is to allow breaking out of a slow or hung +operations (particularly possible with remote folders). CTRL-Y will +continue to work as normal, i.e. to break out but be able to continue if +desired. + +The /SYSTEM qualifier on the BULLETIN command can now be used with +/LOGIN to cause system messages to be continually displayed for a +certain time period rather than just once. + +New qualifiers in commands: + READ/EDIT & CURRENT/EDIT - Uses editor to read message. + RESPOND/EDIT/TEXT - Uses editor to create reply message, and + allows text of message to be read in. + +The DELETE command can now delete a range of messages, i.e. DELETE n-m. + +The /FOLDER qualifier on the ADD command will now accept more than one +folder name. Folders on other nodes can be specified as long as BULLCP +is running on that other node, i.e. /FOLDER=PFCVAX::GENERAL. Prompting +for password for privileged is not necessary, unlike /NODE, since proxy +logins are used. It is also much faster than /NODE. + +Entering BULLETIN should be faster due to optimization (removed code which +unnecessarily was opening folder files). + +Non-ascii characters are removed in messages. This avoids funny escape +sequences which a user might have in a text file. + +V1.51 + +INDEX command added (from Brian@uoft02.bitnet). Gives directory listing +of all folders in sequence. Messages can be read during the listing, and +then the listing can be continued. /NEW will cause the listing of each +folder to start with the first unread message. + +Includes MAKEFILE for MAKE command for assembling executable. + +Modify SEARCH command to search description of message also (MAIL does this.) + +Includes many bug fixes and optimization changes. + +------------------------------------------------------------------------------- +$ set nover +$ edit/edt/nocommand allmacs.mar +'; Name: SETACC.MAR' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin0.for +'C BULLETIN'8 +d 1:.-2o +exit +$ edit/edt/nocommand bulletin1.for +'C BULLETIN'n +d 1:.-2s +exit +$ edit/edt/nocommand bulletin2.for +'C BULLETIN'b +d 1:.-2n +exit +$ edit/edt/nocommand bulletin3.for +'C BULLETIN'1 +d 1:.-2t +exit +$ edit/edt/nocommand bulletin4.for +'C BULLETIN' +d 1:.-27 +exit +$ edit/edt/nocommand bulletin5.for +'C BULLETIN'u +d 1:.-21 +exit +$ edit/edt/nocommand bulletin6.for +'C BULLETIN', +d 1:.-2 +exit +$ edit/edt/nocommand bulletin7.for +'C BULLETIN'l +d 1:.-2s +exit +$ edit/edt/nocommand bulletin8.for +'C BULLETIN' +d 1:.-24 +exit +$ edit/edt/nocommand bullcoms1.hlp +'1 ADD's +d 1:.-1 +exit +$ edit/edt/nocommand bullcoms2.hlp +'1 ADD'p +d 1:.-1t +exit +$ edit/edt/nocommand bullet1.com +'$set nover' +d 1:.-1s +exit +$ edit/edt/nocommand bullet2.com +'$set nover' +d 1:.-1 +exit + M diff --git a/batch/seed/1988b1-handout.txt b/batch/seed/1988b1-handout.txt new file mode 100644 index 0000000000000000000000000000000000000000..750d907bc782f9cbe322145b28a1cfa9295de2d6 --- /dev/null +++ b/batch/seed/1988b1-handout.txt @@ -0,0 +1,272 @@ +From: MRL "Mark R. London" +Date: 01-FEB-1988 12:00 +Subj: Introduction to BULLETIN on the Vax + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. Currently, there are several folders defined: + +GENERAL -- system messages + +PUBLIC_ANNOUNCEMENTS -- Can be used by anyone to post messages +of interest to the public + +On Beta: +AIDE STATION -- Private folder for Computer Center Employees + +In addition on Alpha there are folders that receive electronic +magazines, such as: +NETMONTH -- The monthly magazine of BITNET information. +RISKS -- Identifying the risks involved in using computers. +INFOIBMPC -- Information about the IBM personal computers. +INFOVAX -- Information on the Digital VAX. +PROGRAMMING_JOURNALS-Includes MINIX, UNIX and C, Modula-2 and +Prolog journals +watch for new ones being added. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULD +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS. + +Now the user may enter the subject of the message. + +BULLETIN> + +The above session adds the text in the file 'mess.txt' as the +next message in the PUBLIC_ANNOUNCEMENTS Folder. The message +will be deleted automatically on the 20th of July as requested +by the user adding the message. + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when new +messages are in a folder, he should use the 'READNEW' option. +This command does not force the reader to reading new messages, +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set to +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTS +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEW + +Alternately, you may type SET SHOWNEW. This will just display a +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in the +BULLETIN. While reading the message that he/she desires to send, +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too. + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1988b1-instruct.txt b/batch/seed/1988b1-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..5aa9d9b99569c5ca2e08382937c68850cff579c2 --- /dev/null +++ b/batch/seed/1988b1-instruct.txt @@ -0,0 +1,12 @@ +From: MRL "Mark R. London" +Date: 01-FEB-1988 12:00 +Subj: Instructions + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. Messages can be submitted by +using the BULLETIN command. System messages, such as this one, are displayed +in full, but can only be entered by privileged users. Non-system messages can +be entered by anyone, but only their topics will be displayed at login time, +and will be prompted to optionally read them. (This prompting feature can be +disabled). All bulletins can be reread at any time unless they are deleted or +expire. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1988b1-nonsystem.txt b/batch/seed/1988b1-nonsystem.txt new file mode 100644 index 0000000000000000000000000000000000000000..441055c0a9555a5407f947c7c955791c3f8a4170 --- /dev/null +++ b/batch/seed/1988b1-nonsystem.txt @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 01-FEB-1988 12:00 +Subj: READNEW flag + +Non-system bulletins (such as this) can be submitted by any user. Users are +alerted at login time that new non-system bulletins have been added, but only +their topics are listed. Optionally, users can be prompted at login time to +see if they wish to read the bulletins. When reading the bulletins in this +manner, the bulletins can optionally be written to a file. If you have the +subdirectory [.BULL] created, BULLETIN will use that directory as the default +directory to write the file into. + +A user can disable this prompting featuring by using BULLETIN as follows: + +$ BULLETIN +BULLETIN> SET NOREADNEW +BULLETIN> EXIT + +Afterwords, the user will only be alerted of the bulletins, and will have to +use the BULLETIN utility in order to read the messages. diff --git a/batch/seed/1988b5-bulletin_ann.txt b/batch/seed/1988b5-bulletin_ann.txt new file mode 100644 index 0000000000000000000000000000000000000000..991603f35c32e357e2172895f281317cbf91c680 --- /dev/null +++ b/batch/seed/1988b5-bulletin_ann.txt @@ -0,0 +1,208 @@ +From: MRL "Mark R. London" +Date: 15-JUL-1988 10:42 +Subj: BULLETIN utility. + +Received: from PFC-VAX.MIT.EDU by XX.LCS.MIT.EDU via Chaosnet; 15 Jul 88 09:57-EDT +Date: 15 Jul 88 09:59:23 EDT +From: MRL%PFC-VAX.MIT.EDU@XX.LCS.MIT.EDU +To: EVERHART%ARISIA.DECNET@GE-CRD.ARPA@XX +Subject: BULLETIN utility. + +You are about to receive version 1.52 of the PFC BULLETIN. + +BULLETIN is public domain software. (I will gladly accept +recommendations for new features, not for changes that are due to +"personal" preference.) + +If you are running an older version of BULLETIN, this version will +modify the format of some of the data files. This can cause problems if +the old version of BULLETIN is run after the data files have been +modified. Such a situation is possible on a cluster where each node has +installed the executable separately. To help installation, a new +command procedure INSTALL_REMOTE.COM has been included. This can be +used to install BULLETIN on several nodes from a single node. Read the +comments in the file for information on how to use it. + +(The format of the .BULLDIR will change. After successful installation, +the older versions of these files can be removed. This format change +can take a significant amount of time if the folder is large. If your +site has large folders, it is suggested that the new version be +installed during off peak hours.) + +(The latest feature and bug fixes for this new version are listed later.) + +You will be receiving 14 files (NOT NECESSARILY IN THIS ORDER!): + 1) BULLETIN.FOR + 2) BULLETIN0.FOR + 3) BULLETIN1.FOR + 4) BULLETIN2.FOR + 5) BULLETIN3.FOR + 6) BULLETIN4.FOR + 7) BULLETIN5.FOR + 8) BULLETIN6.FOR + 9) BULLETIN7.FOR + 10) BULLETIN8.FOR + 11) BULLETIN9.FOR + 12) ALLMACS.MAR + 13) BULLCOMS1.HLP + 14) BULLCOMS2.HLP + 15) BULLET1.COM + 16) BULLET2.COM + +(They will be identified in the SUBJECT header.) BULLET1.COM and +BULLET2.COM are command procedures which when run, will create several +small files. After you run it, you can delete it. Read AAAREADME.TXT +for installation instructions. + +NOTE: When creating these files (using the EXTRACT command) from the VMS +MAIL utility, you will have to strip off any mail headers that are +present, including blank lines. A command procedure is included at this +end of this message which can be run which uses EDT to do this for you. + + MRL%PFCVAX@XX.LCS.MIT.EDU +------------------------------------------------------------------------------ +V1.52 + +Made modifications so it would work with VMS V5.0. + +Modified structure of directory files for folders. The files are now +keyed files, the keys being message number and message date. This speeds +up the process of searching for a message using a date. Thus, BULLETIN is +now more efficient when it has to find the latest message in a folder. + +Modified cleanup algorithm. Old code could cause file corruption. + +Add /SUBJECT in SEARCH command to search only the description of messages. + +Add /DESCRIPTION and /OWNER in CREATE command. + +Corrected problem that would cause invalid notification of new messages +in a remote SYSTEM folder. If a new SYSTEM message was added, and a person +entered BULLETIN, it would notify the user that there was a new message in +the folder even though the SYSTEM message had been displayed during logging +in. To correct this, the BULLFOLDER.DAT format had to be changed to store +the date of the last non-SYSTEM message in each folder. + +Added logical name BULL_DISABLE to disable use of BULLETIN. Useful during +installation (or debugging) of BULLETIN. Also added command procedure +INSTALL_REMOTE.COM. These two should make it easier to install a new version +of BULLETIN in a cluster, where INSTALL must be run on each node to install +the new executable. This is especially important when the new executable +changes the format of the data file, so that the old version must not be run +after the data format has been changed. + +Fixed bug which caused NOTIFY flag for GENERAL folder to be cleared. + +Fixed bug which would cause /SUBJECT not to work in MAIL command if placed +after the username. Also added /HEADER qualifier to MAIL to include the +message header with the message. + +Fixed bug which prevented messages with expiration years > 1999 from being +deleted (without /IMMEDITATE). + +Fixed bug which was causing expired messages from not being deleted. + +Fixed bug which allows non-privileged user to copy a permanent message such +that the copy messaged kept the permanent designation. + +Fixed BBOARD algorithm which required the username in the "To:" mail message +field to be uppercase. Some non-DEC mail systems use lowercase. + +When creating a remote folder, i.e. CREATE/NODE, and the actual folder on +the remote node is PRIVATE, this information will now be displayed via the +SHOW FOLDER command. + +Fixed bug in BULLCP which resulted in subprocess BULL_CLEANUP to be spawned. +This should only occur if BULLCP is not running. BULLCP itself does the +cleanup of empty space in folders, so this was redundant and time consuming. + +Added /TEXT qualifier to REPLY command (and, as a consequence, also to the +ADD command). This is present in the RESPOND command, and includes the text +of the previously read message into the new message. Also, the text of the +old message is indented using ">"s, which can be suppressed with /NOINDENT. + +If files are shared between nodes in a cluster, SHUTDOWN messages were not +deleted at the appropriate times, as there was no way of knowing from +which node the messages were submitted from. This has been fixed so that +SHUTDOWN messages will be deleted when the node they were submitted from +is rebooted. + +KEYPAD mode has been added. Keypad can be enabled so that keys are assigned +to BULLETIN commands. This canenabled either by the SET KEYPAD command, or by +adding /KEYPAD to the command line. SHOW KEYPAD shows the definitions. + +Fixed bug which caused BULLCP not to be able to update a private folder after +BULLCP was used by a remote user. (During a remote access, BULLCP sets it's +privileges to that of the user's proxy login who is doing the access. It was +not getting set back to BULLCP's actual privileges.) + +Did you know that access to a folder can be resticted to a particular DECNET +node? This is because interactive processes are assigned the SYS$NODE_nodename +id, and that id can be specified via a SET ACCESS command. + +------------------------------------------------------------------------------- +$ set nover +$ edit/edt/nocommand allmacs.mar +'; Name: SETACC.MAR' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin0.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin1.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin2.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin3.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin4.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin5.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin6.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin7.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin8.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bulletin9.for +'C BULLETIN' +d 1:.-2 +exit +$ edit/edt/nocommand bullcoms1.hlp +'1 ADD' +d 1:.-1 +exit +$ edit/edt/nocommand bullcoms2.hlp +'1 ADD' +d 1:.-1 +exit +$ edit/edt/nocommand bullet1.com +'$set nover' +d 1:.-1 +exit +$ edit/edt/nocommand bullet2.com +'$set nover' +d 1:.-1 +exit diff --git a/batch/seed/1988b5-bulletin_warning_vms_v5.txt b/batch/seed/1988b5-bulletin_warning_vms_v5.txt new file mode 100644 index 0000000000000000000000000000000000000000..1a0e8ad1fbef9ed36b2e0f88a30e63631f1809e2 --- /dev/null +++ b/batch/seed/1988b5-bulletin_warning_vms_v5.txt @@ -0,0 +1,22 @@ +From: MRL "Mark R. London" +Date: 10-AUG-1988 06:57 +Subj: BULLETIN + +Received: from PFC-VAX.MIT.EDU by XX.LCS.MIT.EDU via Chaosnet; 10 Aug 88 06:38-EDT +Date: 10 Aug 88 06:39:13 EDT +From: MRL%PFC-VAX.MIT.EDU@XX.LCS.MIT.EDU +To: TENCATI@VLSI.JPL.NASA.GOV@XX, MHG@MITRE-BEDFORD.ARPA@XX, + EVERHART%ARISIA.DECNET@GE-CRD.ARPA@XX, GAYMAN@ARI-HQ1.ARPA@XX +Subject: BULLETIN + +WARNING: After upgrading to V5, you MUST reassemble ALLMACS.MAR before +relinking BULLETIN. If you don't do this, running BULLCP will cause your +machine to crash. (Luckily, you are forced to relink BULLETIN, since it uses +shared libraries, and these have changed so you will be unable to INSTALL it. +This will probably jog your memory to assemble ALLMACS, and thus avoid +rebooting under V5 and then have your machine crash repeatedly since BULLCP is +created by the system startup procedure, which is what happened to me!) + +Also, I discovered more changes that were needed to allow the remote folder +feature to work under V5. It requires a new BULLETIN8.FOR, which I will be +distributing shortly. diff --git a/batch/seed/1989a2-handout.txt b/batch/seed/1989a2-handout.txt new file mode 100644 index 0000000000000000000000000000000000000000..2c3e34130133f7202fc66c2ab376b0d157d98fb3 --- /dev/null +++ b/batch/seed/1989a2-handout.txt @@ -0,0 +1,272 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: Introduction to BULLETIN on the Vax + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. Currently, there are several folders defined: + +GENERAL -- system messages + +PUBLIC_ANNOUNCEMENTS -- Can be used by anyone to post messages +of interest to the public + +On Beta: +AIDE STATION -- Private folder for Computer Center Employees + +In addition on Alpha there are folders that receive electronic +magazines, such as: +NETMONTH -- The monthly magazine of BITNET information. +RISKS -- Identifying the risks involved in using computers. +INFOIBMPC -- Information about the IBM personal computers. +INFOVAX -- Information on the Digital VAX. +PROGRAMMING_JOURNALS-Includes MINIX, UNIX and C, Modula-2 and +Prolog journals +watch for new ones being added. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULD +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS. + +Now the user may enter the subject of the message. + +BULLETIN> + +The above session adds the text in the file 'mess.txt' as the +next message in the PUBLIC_ANNOUNCEMENTS Folder. The message +will be deleted automatically on the 20th of July as requested +by the user adding the message. + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when new +messages are in a folder, he should use the 'READNEW' option. +This command does not force the reader to reading new messages, +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set to +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTS +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEW + +Alternately, you may type SET SHOWNEW. This will just display a +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in the +BULLETIN. While reading the message that he/she desires to send, +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too. + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1989a2-instruct.txt b/batch/seed/1989a2-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..8421e48d50679389efdbaacac941cb273d5f9c59 --- /dev/null +++ b/batch/seed/1989a2-instruct.txt @@ -0,0 +1,12 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: Instructions + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. Messages can be submitted by +using the BULLETIN command. System messages, such as this one, are displayed +in full, but can only be entered by privileged users. Non-system messages can +be entered by anyone, but only their topics will be displayed at login time, +and will be prompted to optionally read them. (This prompting feature can be +disabled). All bulletins can be reread at any time unless they are deleted or +expire. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1989a2-nonsystem.txt b/batch/seed/1989a2-nonsystem.txt new file mode 100644 index 0000000000000000000000000000000000000000..6c9ed9c2ce0bf344f0137eee30a2212ef648c44f --- /dev/null +++ b/batch/seed/1989a2-nonsystem.txt @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: /READNEW flag info + +Non-system bulletins (such as this) can be submitted by any user. Users are +alerted at login time that new non-system bulletins have been added, but only +their topics are listed. Optionally, users can be prompted at login time to +see if they wish to read the bulletins. When reading the bulletins in this +manner, the bulletins can optionally be written to a file. If you have the +subdirectory [.BULL] created, BULLETIN will use that directory as the default +directory to write the file into. + +A user can disable this prompting featuring by using BULLETIN as follows: + +$ BULLETIN +BULLETIN> SET NOREADNEW +BULLETIN> EXIT + +Afterwords, the user will only be alerted of the bulletins, and will have to +use the BULLETIN utility in order to read the messages. diff --git a/batch/seed/1989a2-writemsg.txt b/batch/seed/1989a2-writemsg.txt new file mode 100644 index 0000000000000000000000000000000000000000..7fadeb9169a631ffa8a89fe9938c7bd4d5368e0c --- /dev/null +++ b/batch/seed/1989a2-writemsg.txt @@ -0,0 +1,40 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: Writing message subroutine + +BULLETIN contains subroutines for writing a message directly to a folder. This +would be useful for someone who is using the BBOARD feature, but wants to avoid +the extra overhead of having the message sent to an account as MAIL, and then +have BULLCP read the mail. It is better if the network mail could be written +directly to the folder bypassing VMS MAIL, as it reduces a lot of cpu overhead. + +Call INIT_MESSAGE_ADD to initiate a message addition. +Call WRITE_MESSAGE_LINE to write individual message lines. +Call FINISH_MESSAGE_ADD to complete a message addition. + +Calling formats: + + CALL INIT_MESSAGE_ADD(IN_FOLDER,IN_FROM,IN_DESCRIP,IER) +C +C INPUTS: +C IN_FOLDER - Character string containing folder name +C IN_FROM - Character string containing name of owner of message. +C If empty, the default is the owner of the process. +C IN_DESCRIP - Character string containing subject of message. +C If empty, the message is searched for a line +C which starts with "Subj:" or "Subject:". +C OUTPUTS: +C IER - Error status. True if properly connected to folder. +C False if folder not found. +C + + CALL WRITE_MESSAGE_LINE(BUFFER) +C +C INPUTS: +C BUFFER - Character string containing line to be put into message. +C + + CALL FINISH_MESSAGE_ADD +C +C NOTE: Only should be run if INIT_MESSAGE_ADD was successful. +C diff --git a/batch/seed/1989b1-aaareadme.txt b/batch/seed/1989b1-aaareadme.txt new file mode 100644 index 0000000000000000000000000000000000000000..04a2ec22fa5cc971ac0c02d5a09117732c7e7de9 --- /dev/null +++ b/batch/seed/1989b1-aaareadme.txt @@ -0,0 +1,28 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: BULLETIN announcement + + BULLETIN + +Note: Source code is in BULLETIN.ZOO. Use ZOO to extract files if needed. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + diff --git a/batch/seed/1989b1-handout.txt b/batch/seed/1989b1-handout.txt new file mode 100644 index 0000000000000000000000000000000000000000..2c3e34130133f7202fc66c2ab376b0d157d98fb3 --- /dev/null +++ b/batch/seed/1989b1-handout.txt @@ -0,0 +1,272 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: Introduction to BULLETIN on the Vax + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. Currently, there are several folders defined: + +GENERAL -- system messages + +PUBLIC_ANNOUNCEMENTS -- Can be used by anyone to post messages +of interest to the public + +On Beta: +AIDE STATION -- Private folder for Computer Center Employees + +In addition on Alpha there are folders that receive electronic +magazines, such as: +NETMONTH -- The monthly magazine of BITNET information. +RISKS -- Identifying the risks involved in using computers. +INFOIBMPC -- Information about the IBM personal computers. +INFOVAX -- Information on the Digital VAX. +PROGRAMMING_JOURNALS-Includes MINIX, UNIX and C, Modula-2 and +Prolog journals +watch for new ones being added. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULD +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS. + +Now the user may enter the subject of the message. + +BULLETIN> + +The above session adds the text in the file 'mess.txt' as the +next message in the PUBLIC_ANNOUNCEMENTS Folder. The message +will be deleted automatically on the 20th of July as requested +by the user adding the message. + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when new +messages are in a folder, he should use the 'READNEW' option. +This command does not force the reader to reading new messages, +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set to +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTS +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEW + +Alternately, you may type SET SHOWNEW. This will just display a +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in the +BULLETIN. While reading the message that he/she desires to send, +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too. + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1989b1-instruct.txt b/batch/seed/1989b1-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..8421e48d50679389efdbaacac941cb273d5f9c59 --- /dev/null +++ b/batch/seed/1989b1-instruct.txt @@ -0,0 +1,12 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: Instructions + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. Messages can be submitted by +using the BULLETIN command. System messages, such as this one, are displayed +in full, but can only be entered by privileged users. Non-system messages can +be entered by anyone, but only their topics will be displayed at login time, +and will be prompted to optionally read them. (This prompting feature can be +disabled). All bulletins can be reread at any time unless they are deleted or +expire. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1989b1-nonsystem.txt b/batch/seed/1989b1-nonsystem.txt new file mode 100644 index 0000000000000000000000000000000000000000..b84873dff1747a280100e885435537c75d3071ac --- /dev/null +++ b/batch/seed/1989b1-nonsystem.txt @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: READNEW flag example + +Non-system bulletins (such as this) can be submitted by any user. Users are +alerted at login time that new non-system bulletins have been added, but only +their topics are listed. Optionally, users can be prompted at login time to +see if they wish to read the bulletins. When reading the bulletins in this +manner, the bulletins can optionally be written to a file. If you have the +subdirectory [.BULL] created, BULLETIN will use that directory as the default +directory to write the file into. + +A user can disable this prompting featuring by using BULLETIN as follows: + +$ BULLETIN +BULLETIN> SET NOREADNEW +BULLETIN> EXIT + +Afterwords, the user will only be alerted of the bulletins, and will have to +use the BULLETIN utility in order to read the messages. diff --git a/batch/seed/1989b1-writemsg.txt b/batch/seed/1989b1-writemsg.txt new file mode 100644 index 0000000000000000000000000000000000000000..4976f17fe0581d1e0e2e6180f820fd3c800b3f44 --- /dev/null +++ b/batch/seed/1989b1-writemsg.txt @@ -0,0 +1,40 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1989 12:00 +Subj: BULLETIN subroutines for writing a message + +BULLETIN contains subroutines for writing a message directly to a folder. This +would be useful for someone who is using the BBOARD feature, but wants to avoid +the extra overhead of having the message sent to an account as MAIL, and then +have BULLCP read the mail. It is better if the network mail could be written +directly to the folder bypassing VMS MAIL, as it reduces a lot of cpu overhead. + +Call INIT_MESSAGE_ADD to initiate a message addition. +Call WRITE_MESSAGE_LINE to write individual message lines. +Call FINISH_MESSAGE_ADD to complete a message addition. + +Calling formats: + + CALL INIT_MESSAGE_ADD(IN_FOLDER,IN_FROM,IN_DESCRIP,IER) +C +C INPUTS: +C IN_FOLDER - Character string containing folder name +C IN_FROM - Character string containing name of owner of message. +C If empty, the default is the owner of the process. +C IN_DESCRIP - Character string containing subject of message. +C If empty, the message is searched for a line +C which starts with "Subj:" or "Subject:". +C OUTPUTS: +C IER - Error status. True if properly connected to folder. +C False if folder not found. +C + + CALL WRITE_MESSAGE_LINE(BUFFER) +C +C INPUTS: +C BUFFER - Character string containing line to be put into message. +C + + CALL FINISH_MESSAGE_ADD +C +C NOTE: Only should be run if INIT_MESSAGE_ADD was successful. +C diff --git a/batch/seed/1990a-aaareadme.txt b/batch/seed/1990a-aaareadme.txt new file mode 100644 index 0000000000000000000000000000000000000000..908aceaf9b4564aeb52608ea77608f2dec69099c --- /dev/null +++ b/batch/seed/1990a-aaareadme.txt @@ -0,0 +1,60 @@ +From: MRL "Mark R. London" +Date: 01-JAN-1990 12:00 +Subj: BULLETIN + + BULLETIN +The BULLETIN utility is a utility to display messages to users when +logging in. Users are notified of messages only once. They're not +forced into reading them every time they log in. Submitting and +reading messages is easy to do via a utility similar to the VMS MAIL +utility. Privileged users can create messages which are displayed in +full. (known as SYSTEM messages). Non-privileged users may be able to +create non-SYSTEM messages (unless your system manager has disabled the +feature), but only topics are displayed at login. + +Folders can be created so that messages pertaining to a single topic +can be placed together. Folders can be made private so that reading +and writing is limited to only users or groups who are granted access. +Alternatively, folders can be made semi-private in that everyone is +allowed to read them but write access is limited. + +When new non-system messages are displayed, an optional feature which a +user may enable will cause BULLETIN to ask whether the user wishes to +read the new bulletins. The user can then read the messages (with the +ability to write any of the messages to a file). A user can enable the +notification and prompting of new messages feature on a folder per +folder basis. However, the exception is messages submitted to the +default GENERAL folder. Users are always notified at login of new +bulletins in this folder, but can disable the prompting. This is to +give non-privileged users some ability to force a notification of an +important message. + +Messages have expiration dates and times, and are deleted automatically. +Expiration dates and times can be specified in absolute or delta +notation. Privileged users can specify "SHUTDOWN" messages, i.e. +messages that get deleted after a system shutdown has occurred. +"PERMANENT" messages can also be created which never expire. + +Privileged users can broadcast their message (to either all users or +all terminals). + +A user can select, on a folder per folder basis, to have a message +broadcast to their terminal immediately notifying them when a new +message has been added. + +An optional "Bulletin Board" feature allows messages to be created by +users of other systems connected via networks. A username can be +assigned to a folder, and any mail sent to that user is converted to +messages and stored in that folder. This feature originally was +designed to duplicate the message board feature that exists on some +Arpanet sites. However, with the addition of folders, another possible +use is to assign an Arpanet mailing list to a folder. For example, one +could have an INFOVAX folder associated with an INFOVAX username, and +have INFO-VAX mail sent to INFOVAX. Users could then read the mailing +list in that folder, rather than having INFO-VAX sent to each user. +Optionally, the input for the bulletin board can be directed to be taken +from any source other than VMS MAIL. This might be useful if incoming +mail is stored in a different place other than VMS MAIL. + +Messages can be either sent to a file, to a print queue, or mailed to +another user. diff --git a/batch/seed/1990a-bulletin_wheretoget.txt b/batch/seed/1990a-bulletin_wheretoget.txt new file mode 100644 index 0000000000000000000000000000000000000000..4be124dec079405e3a557ccf3124b30e3d404aed --- /dev/null +++ b/batch/seed/1990a-bulletin_wheretoget.txt @@ -0,0 +1,25 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: BULLETIN + +Received: by crdgw1.ge.com (5.57/GE 1.70) + id AA02928; Wed, 6 Jun 90 15:59:18 EDT +Received: From NERUS.PFC.MIT.EDU by CRVAX.SRI.COM with TCP; Wed, 6 JUN 90 04:48:03 PDT +Message-Id: <83766B684CBFC02D63@NERUS.PFC.MIT.EDU> +Date: Wed, 6 Jun 90 07:46 EST +From: MRL@NERUS.PFC.MIT.EDU +Subject: Re: BULLETIN +To: MSD@ENH.NIST.GOV, INFO-VAX@KL.SRI.COM +X-Envelope-To: INFO-VAX@KL.SRI.COM +X-Vms-To: IN%"MSD@ENH.NIST.GOV",IN%"INFO-VAX@KL.SRI.COM" + +The new address for getting BULLETIN is BULLETIN@NERUS.PFC.MIT.EDU. + +Valid commands are: + SEND ALL Sends all bulletin files. + SEND filename Sends the specified file. + BUGS Sends a list of the latest bug fixes. + HELP or INFO Sends a brief description of BULLETIN. + + Mark + diff --git a/batch/seed/1990a-handout.txt b/batch/seed/1990a-handout.txt new file mode 100644 index 0000000000000000000000000000000000000000..b465fd0d62af8b49293b00418174b699ef7147a7 --- /dev/null +++ b/batch/seed/1990a-handout.txt @@ -0,0 +1,272 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: Introduction to BULLETIN on the Vax + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. Currently, there are several folders defined: + +GENERAL -- system messages + +PUBLIC_ANNOUNCEMENTS -- Can be used by anyone to post messages +of interest to the public + +On Beta: +AIDE STATION -- Private folder for Computer Center Employees + +In addition on Alpha there are folders that receive electronic +magazines, such as: +NETMONTH -- The monthly magazine of BITNET information. +RISKS -- Identifying the risks involved in using computers. +INFOIBMPC -- Information about the IBM personal computers. +INFOVAX -- Information on the Digital VAX. +PROGRAMMING_JOURNALS-Includes MINIX, UNIX and C, Modula-2 and +Prolog journals +watch for new ones being added. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULD +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS. + +Now the user may enter the subject of the message. + +BULLETIN> + +The above session adds the text in the file 'mess.txt' as the +next message in the PUBLIC_ANNOUNCEMENTS Folder. The message +will be deleted automatically on the 20th of July as requested +by the user adding the message. + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when new +messages are in a folder, he should use the 'READNEW' option. +This command does not force the reader to reading new messages, +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set to +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTS +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEW + +Alternately, you may type SET SHOWNEW. This will just display a +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in the +BULLETIN. While reading the message that he/she desires to send, +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too. + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1990a-instruct.txt b/batch/seed/1990a-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..216d1ccbd59c707117a10674b59581bb4663d58b --- /dev/null +++ b/batch/seed/1990a-instruct.txt @@ -0,0 +1,12 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: Instruction + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. Messages can be submitted by +using the BULLETIN command. System messages, such as this one, are displayed +in full, but can only be entered by privileged users. Non-system messages can +be entered by anyone, but only their topics will be displayed at login time, +and will be prompted to optionally read them. (This prompting feature can be +disabled). All bulletins can be reread at any time unless they are deleted or +expire. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1990a-nonsystem.txt b/batch/seed/1990a-nonsystem.txt new file mode 100644 index 0000000000000000000000000000000000000000..bb95a304cfc7d12c0f3503e9366906d36ec66b18 --- /dev/null +++ b/batch/seed/1990a-nonsystem.txt @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: READNEW flag + +Non-system bulletins (such as this) can be submitted by any user. Users are +alerted at login time that new non-system bulletins have been added, but only +their topics are listed. Optionally, users can be prompted at login time to +see if they wish to read the bulletins. When reading the bulletins in this +manner, the bulletins can optionally be written to a file. If you have the +subdirectory [.BULL] created, BULLETIN will use that directory as the default +directory to write the file into. + +A user can disable this prompting featuring by using BULLETIN as follows: + +$ BULLETIN +BULLETIN> SET NOREADNEW +BULLETIN> EXIT + +Afterwords, the user will only be alerted of the bulletins, and will have to +use the BULLETIN utility in order to read the messages. diff --git a/batch/seed/1990a-writemsg.txt b/batch/seed/1990a-writemsg.txt new file mode 100644 index 0000000000000000000000000000000000000000..97b21384115d2fecfba5d442a18a28fb69c5f4f8 --- /dev/null +++ b/batch/seed/1990a-writemsg.txt @@ -0,0 +1,40 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: subroutines for writing a message + +BULLETIN contains subroutines for writing a message directly to a folder. This +would be useful for someone who is using the BBOARD feature, but wants to avoid +the extra overhead of having the message sent to an account as MAIL, and then +have BULLCP read the mail. It is better if the network mail could be written +directly to the folder bypassing VMS MAIL, as it reduces a lot of cpu overhead. + +Call INIT_MESSAGE_ADD to initiate a message addition. +Call WRITE_MESSAGE_LINE to write individual message lines. +Call FINISH_MESSAGE_ADD to complete a message addition. + +Calling formats: + + CALL INIT_MESSAGE_ADD(IN_FOLDER,IN_FROM,IN_DESCRIP,IER) +C +C INPUTS: +C IN_FOLDER - Character string containing folder name +C IN_FROM - Character string containing name of owner of message. +C If empty, the default is the owner of the process. +C IN_DESCRIP - Character string containing subject of message. +C If empty, the message is searched for a line +C which starts with "Subj:" or "Subject:". +C OUTPUTS: +C IER - Error status. True if properly connected to folder. +C False if folder not found. +C + + CALL WRITE_MESSAGE_LINE(BUFFER) +C +C INPUTS: +C BUFFER - Character string containing line to be put into message. +C + + CALL FINISH_MESSAGE_ADD +C +C NOTE: Only should be run if INIT_MESSAGE_ADD was successful. +C diff --git a/batch/seed/1990b1-aaareadme.txt b/batch/seed/1990b1-aaareadme.txt new file mode 100644 index 0000000000000000000000000000000000000000..97fb21bcf6d43f2befe30e78ce065e419bbb6165 --- /dev/null +++ b/batch/seed/1990b1-aaareadme.txt @@ -0,0 +1,256 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: Introduction to BULLETIN on the Vax + +(Editor's Note: Sources are in the ZOO file BULL_SOURCE.ZOO) + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULDo +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS.L + +Now the user may enter the subject of the message. + +BULLETIN>e + +The above session adds the text in the file 'mess.txt' as theo +next message in the PUBLIC_ANNOUNCEMENTS Folder. The messageo +will be deleted automatically on the 20th of July as requested +by the user adding the message.D + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when newr +messages are in a folder, he should use the 'READNEW' option.b +This command does not force the reader to reading new messages,n +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set tos +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTSp +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEWt + +Alternately, you may type SET SHOWNEW. This will just display ag +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in theT +BULLETIN. While reading the message that he/she desires to send,p +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too.r + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1990b1-announce.txt b/batch/seed/1990b1-announce.txt new file mode 100644 index 0000000000000000000000000000000000000000..a42d97584a00311b003433e6b727d95f697f5c92 --- /dev/null +++ b/batch/seed/1990b1-announce.txt @@ -0,0 +1,223 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: BULLETIN announcement + +You are about to receive version 1.93 of the PFC BULLETIN. + +BULLETIN is public domain software. (I will gladly accept +recommendations for new features, not for changes that are due to +"personal" preference.) + +NOTE: The following commands can be sent to BULLETIN@NERUS.PFC.MIT.EDU: + SEND ALL Sends all bulletin files. + SEND filename Sends the specified file. + BUGS Sends a list of the latest bug fixes. + HELP or INFO Sends a brief description of BULLETIN. + +There is also a documentation file written by Chris Tanner from Chalk +River Nuclear Labs which can be used as handout. To obtain this, +request the file BULLETIN.DOC. + +NOTE: An old bug might have changed the protection on the BULLETIN data +files. The protection on all data files (i.e. B*.DAT, *.BULLFIL, and +*.BULLDIR) should be (RWED,RWED,,). + +This version includes all necessary modifications to work under VMS +V5.0. However, it will still be necessary to reassemble the ALLMACS.MAR +source under V5 and relink. The V4 version will not be installable +under V5 due to a change in a shared library which BULLETIN uses. +However, relinking by itself will not be enough. You MUST also +reassemble ALLMACS.MAR. If you only relink, BULLETIN can cause your +system to crash (the BULLCP process will do this because it uses the +routines in ALLMACS.MAR). + +If you are running a version of BULLETIN older than 1.52, this version +will modify the format of some of the data files. (This will be done +automatically when the new version is run). After successful +installation, the older versions of these files can be removed. This +format change can take a significant amount of time if the folder is +large. If your site has large folders, it is suggested that the new +version be installed during off peak hours. NOTE: Problems can occur +if the old version of BULLETIN is run after the data files have been +modified. Such a situation is possible on a cluster where each node has +installed the executable separately. To help installation, a new +command procedure INSTALL_REMOTE.COM has been included. This can be +used to install BULLETIN on several nodes from a single node. Read the +comments in the file for information on how to use it. + +NOTE: The BULLCP process should be stopped using the BULLETIN/STOP +command before the new version of BULLETIN is installed. It can then be +restarted using the BULLETIN/STARTUP command. (The INSTALL_REMOTE.COM +command procedure does this automatically for remote nodes.) + +You will be receiving 17 files (NOT NECESSARILY IN THIS ORDER!): + 1) BULLETIN.FOR + 2) BULLETIN0.FOR + 3) BULLETIN1.FOR + 4) BULLETIN2.FOR + 5) BULLETIN3.FOR + 6) BULLETIN4.FOR + 7) BULLETIN5.FOR + 8) BULLETIN6.FOR + 9) BULLETIN7.FOR + 10) BULLETIN8.FOR + 11) BULLETIN9.FOR + 12) ALLMACS.MAR + 13) BULLCOMS1.HLP + 14) BULLCOMS2.HLP + 15) BULLET1.COM + 16) BULLET2.COM + 17) PMDF.COM + +(They will be identified in the SUBJECT header.) BULLET1.COM and +BULLET2.COM are command procedures which when run, will create several +small files. After you run them, you can delete them. If you have PMDF +at your site, you should also run PMDF.COM. Otherwise, you can delete +it. Read AAAREADME.TXT for installation instructions. + +NOTE: When creating these files (using the EXTRACT command) from the VMS +MAIL utility, you will have to strip off any mail headers that are +present, including blank lines. + MRL@NERUS.PFC.MIT.EDU +------------------------------------------------------------------------ +V 1.93 + +Fixed bug which wouldn't allow a permanent message to be added by a +non-privileged user in a remote folder (the folder had been setup to allow +permanent messages from non-privileged users, of course). + +Fixed bug which causes the DELETE command not to delete a SHUTDOWN message +without the use of /IMMEDIATE. + +Fixed the algorithm which prevented duplicate notification of messages in +remote folders on different nodes, as duplication was still possible. + +V 1.92 + +Fix bug which causes BULLCP to loop when trying to cleanup a folder which +has more than 127 identifiers granted access to a folder. Also correct +SHOW FOLDER/FULL, which had a similar problem when trying to display the +identifiers. + +Fix PMDF interface to recognize to recognize PMDF_PROTOCOL. + +V 1.91 + +Disallow SPAWN command for CAPTIVE account. + +Fix MAIL command to correctly allow passing addresses with quotes, i.e. +IN%"""MRL@NERUS.PFC.MIT.EDU""". + +V 1.90 + +SET NOTIFY now works for remote folders. + +Bug in DIR/SINCE for remote folders fixed. If no new messages were present, +it would incorrectly show messages. + +Added /FF to EXTRACT command to seperate messages in the file with form feeds. + +Allow specifying CURRENT and LAST when specifying a range of messages for +commands that accept a range, i.e. EXTRACT 1-CURRENT, CURRENT-LAST, etc. + +Open folder files with READONLY when not writing to them in order to avoid +changing modification date, which results in unnecessary backups. + +Modify HELP so that it won't prompt for Subtopic is there is none. + +Prevent screen from being erased after exiting HELP. + +Fix bug which causes CREATE/NOTIFY to crash. + +SET NOTIFY/CLUSTER has been removed. As of VMS V5.2, it is possible to obtain +the list of users logged in to all nodes of a cluster, so this qualifier is no +long necessary. NOTE: You can delete all the BULL_DIR:*.NOTIFY files, as they +are no longer used. + +BULLETIN now will use the editor specified by the SET EDITOR command within +MAIL for editing messages. + +Typing BACK after typing a DIRECTORY command will now show the previous +DIRECTORY display entries rather than reading the previous message. + +Several bugs related to the MARK command were fixed. Also the software has been +optimized so that scanning for MARKed messages should take less time. + +/EXPIRATION added to DIRECTORY command to show expiration rather than creation +date of messages. + +Any BULLETIN interactive command can be executed at DCL level by typing +BULLETIN "command" or BULLETIN "command1;command2;etc.". + +The CHANGE command has been modified so a range of message can be specified, +i.e. /NUMBER=1-10. Also, the code incorrectly misinterpreted /TEXT as meaning +to extract the old text message, whereas it should have meant that only the +text was to be changed. This prevented a user from specifying that only the +text should be changed if that user didn't have editing enabled. This has been +fixed. To eliminate confusing, the /TEXT qualifier on the ADD command has been +removed (previously it was a synonym for /EXTRACT). + +SHOW FOLDER/FULL display of access IDs was fixed to correctly display UICs. + +Removed security hole which occurs if you are using the old method of accessing +a remote node via /NODES (it would have required looking a the sources to find, +which one installer did and was worried about). Because of this, if you use +this old method (i.e. via BULLETIN.COM), the object BULLETIN must be installed +in the NCP database pointing to the file BULLETIN.COM, i.e. the command +"MCR NCP SET BULLETIN FILE directory:BULLETIN.COM NUMBER 0" must be executed +during the system startup. + +Fixed bug in /LOGIN display when erasing page if terminal is hardcopy. No +page would be erased (of course), and the next line outputted would start where +the previous line left off, rather than starting on a new line. + +Added BULLETIN/WIDTH=page_width for users who have BULLETIN/LOGIN in their +login procedure before the terminal is known, and whose default page width is +larger (i.e. 132) than what the terminals are (i.e. 80). + +Added BULLETIN/PGFLQUOTA and /WSEXTENT in order to set those quotas for the +BULLCP process. + +Added ATTACH command. + +Modify SET STRIP so that it saves the date that the message was sent and +leaves it at the to of the message. + +BULLETIN will search BBOARD message headers for a line that starts with +"Expires:" or "X-Expires:", followed by a date (DD MMM YYYY or similar). It if +finds that line, it will use that date as the expiration date of the message. + +Added /REPLY to SEARCH command. Modified so that it's possible to abort out of +a /SUBJECT or /REPLY search using CTRL-C (previous possible only if searching +the text for a string. Also, if you hit CTRL-C at the wrong time, BULLETIN +would abort totally rather than just aborting the search). + +Added /SEARCH= /SUBJ= and /REPLY to the DIRECTORY command. Basically this is +combining the DIRECTORY and SEARCH commands. + +Fixed design flaw which allowed the following to occur: If a folder is a +remote system folder, when BULLETIN/LOGIN was executed, the same messages might +be displayed on both the local and remote nodes. BULLETIN now will know that +the user has seen the message on one node and will not display it if that user +logs in on the other node. + +Optimized code which caused slow display of new messages when executing +BULLETIN/LOGIN without /REVERSE for a remote folder. + +Added /PERMANENT to SET NOTIFY, SHOWNEW, BRIEF, and READNEW. The affect is +that users will not be allowed to change the setting. The main intent here +was to allow the removal ofthe permanent setting of SHOWNEW from the GENERAL +folder. + +Fixed bug which would cause a SYSTEM message not to be shown if SET BRIEF was +selected for that folder, and a non-SYSTEM message was also present. + +Added SET CONTINUOUS_BRIEF. This causes the SET BRIEF setting to show that +there are unread new messages every time BULLETIN/LOGIN is executed, rather +than just the one time. The BRIEF notification code has also been optimized +so that it'll take less time to notify you of new messages. + +A major bug was fixed which was introduced in previous mods to speed up +BULLETIN/LOGIN. The effect is that no notifications will appear for certain +folders via BULLETIN/LOGIN. This would only happen if a folder was removed at +some time. diff --git a/batch/seed/1990b1-handout.txt b/batch/seed/1990b1-handout.txt new file mode 100644 index 0000000000000000000000000000000000000000..b465fd0d62af8b49293b00418174b699ef7147a7 --- /dev/null +++ b/batch/seed/1990b1-handout.txt @@ -0,0 +1,272 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: Introduction to BULLETIN on the Vax + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. Currently, there are several folders defined: + +GENERAL -- system messages + +PUBLIC_ANNOUNCEMENTS -- Can be used by anyone to post messages +of interest to the public + +On Beta: +AIDE STATION -- Private folder for Computer Center Employees + +In addition on Alpha there are folders that receive electronic +magazines, such as: +NETMONTH -- The monthly magazine of BITNET information. +RISKS -- Identifying the risks involved in using computers. +INFOIBMPC -- Information about the IBM personal computers. +INFOVAX -- Information on the Digital VAX. +PROGRAMMING_JOURNALS-Includes MINIX, UNIX and C, Modula-2 and +Prolog journals +watch for new ones being added. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULD +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS. + +Now the user may enter the subject of the message. + +BULLETIN> + +The above session adds the text in the file 'mess.txt' as the +next message in the PUBLIC_ANNOUNCEMENTS Folder. The message +will be deleted automatically on the 20th of July as requested +by the user adding the message. + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when new +messages are in a folder, he should use the 'READNEW' option. +This command does not force the reader to reading new messages, +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set to +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTS +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEW + +Alternately, you may type SET SHOWNEW. This will just display a +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in the +BULLETIN. While reading the message that he/she desires to send, +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too. + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1990b1-instruct.txt b/batch/seed/1990b1-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..216d1ccbd59c707117a10674b59581bb4663d58b --- /dev/null +++ b/batch/seed/1990b1-instruct.txt @@ -0,0 +1,12 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: Instruction + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. Messages can be submitted by +using the BULLETIN command. System messages, such as this one, are displayed +in full, but can only be entered by privileged users. Non-system messages can +be entered by anyone, but only their topics will be displayed at login time, +and will be prompted to optionally read them. (This prompting feature can be +disabled). All bulletins can be reread at any time unless they are deleted or +expire. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1990b1-nonsystem.txt b/batch/seed/1990b1-nonsystem.txt new file mode 100644 index 0000000000000000000000000000000000000000..0174f95b5249c2601ee9cbbd5f65a900b3391099 --- /dev/null +++ b/batch/seed/1990b1-nonsystem.txt @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: SET NOREADNEW example + +Non-system bulletins (such as this) can be submitted by any user. Users are +alerted at login time that new non-system bulletins have been added, but only +their topics are listed. Optionally, users can be prompted at login time to +see if they wish to read the bulletins. When reading the bulletins in this +manner, the bulletins can optionally be written to a file. If you have the +subdirectory [.BULL] created, BULLETIN will use that directory as the default +directory to write the file into. + +A user can disable this prompting featuring by using BULLETIN as follows: + +$ BULLETIN +BULLETIN> SET NOREADNEW +BULLETIN> EXIT + +Afterwords, the user will only be alerted of the bulletins, and will have to +use the BULLETIN utility in order to read the messages. diff --git a/batch/seed/1990b1-writemsg.txt b/batch/seed/1990b1-writemsg.txt new file mode 100644 index 0000000000000000000000000000000000000000..97b21384115d2fecfba5d442a18a28fb69c5f4f8 --- /dev/null +++ b/batch/seed/1990b1-writemsg.txt @@ -0,0 +1,40 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1990 16:36 +Subj: subroutines for writing a message + +BULLETIN contains subroutines for writing a message directly to a folder. This +would be useful for someone who is using the BBOARD feature, but wants to avoid +the extra overhead of having the message sent to an account as MAIL, and then +have BULLCP read the mail. It is better if the network mail could be written +directly to the folder bypassing VMS MAIL, as it reduces a lot of cpu overhead. + +Call INIT_MESSAGE_ADD to initiate a message addition. +Call WRITE_MESSAGE_LINE to write individual message lines. +Call FINISH_MESSAGE_ADD to complete a message addition. + +Calling formats: + + CALL INIT_MESSAGE_ADD(IN_FOLDER,IN_FROM,IN_DESCRIP,IER) +C +C INPUTS: +C IN_FOLDER - Character string containing folder name +C IN_FROM - Character string containing name of owner of message. +C If empty, the default is the owner of the process. +C IN_DESCRIP - Character string containing subject of message. +C If empty, the message is searched for a line +C which starts with "Subj:" or "Subject:". +C OUTPUTS: +C IER - Error status. True if properly connected to folder. +C False if folder not found. +C + + CALL WRITE_MESSAGE_LINE(BUFFER) +C +C INPUTS: +C BUFFER - Character string containing line to be put into message. +C + + CALL FINISH_MESSAGE_ADD +C +C NOTE: Only should be run if INIT_MESSAGE_ADD was successful. +C diff --git a/batch/seed/1991a-aaareadme.txt b/batch/seed/1991a-aaareadme.txt new file mode 100644 index 0000000000000000000000000000000000000000..5194a6d8729b9cd8c3b4af7ae4913af52f1b1c23 --- /dev/null +++ b/batch/seed/1991a-aaareadme.txt @@ -0,0 +1,173 @@ +From: MRL "Mark R. London" +Date: 06-JUN-1991 16:36 +Subj: BULLETIN readme... + +The following are instructions for creating and installing the BULLETIN +utility. None of the command procedures included here are sophisticated, so it +is likely that several modifications will have to be made by the installer. +The installer should enable all privileges before installation. + +Once installation is complete, it is suggested that the installer enter +BULLETIN and read HELP FOLDERS to see the options available when creating +or modifying folders. + +One of the main uses of BULLETIN, besides storage of messages that are manually +entered by users, is storage of messages from network mailing lists. This is +done by using the BBOARD feature, which is enabled using the SET BBOARD command +inside BULLETIN. The alternative method is for mail messages to be written +directly by a mailing program by calling internal BULLETIN routines. Such a +a program has been written for the popular mail utility PMDF. If you wish to +do so for another utility, read the text file WRITEMSG.TXT. I would be glad to +include any such programs with my distribution if you think such a program +would be of use to other users. + +Responding to mail which is either added via the BBOARD feature is done using +VMS MAIL. If for some reason this is inappropriate, you can define BULL_MAILER +to point to a command procedure, and which will be run instead of VMS MAIL. +The parameters passed to this procedure are P1 = username and P2 = subject. + +1) CREATE.COM + This will compile and link the BULLETIN sources. Also, there are several + INCLUDE files for the fortran sources (.INC files). BULLETIN will create it's + data files in the directory pointed to by the logical name BULL_DIR. If you + elect not to use this definition, BULLFILES.INC should be modified. + Note that after this procedure compiles the sources, it puts the objects + into an object library, and then deletes all the OBJ files in the directory. + + NOTE 1: If you plan on using the USENET NEWS reader capability of BULLETIN, + read NEWS.TXT for installation instructions before compiling. + + NOTE 2: The maximum number of folders for this distribution is 96 folders. + If you wish to increase this, modify BULLUSER.INC and recompile the sources. + When the new executable is run, it will create a new BULLUSER.DAT data file + and rename the old one to BULLUSER.OLD. You cannot reduce the number of + folders. + +2) INSTALL.COM + The following procedure copies the executable image to SYS$SYSTEM and + installs it with certain privileges. It also installs the necessary + help files in SYS$HELP. (BULLETIN help file is installed into the + system help library HELPLIB.HLB. If you don't wish this done, delete + or modify the appropriate line in the procedure. Also, the help + library for the BULLETIN program, BULL.HLB, can be moved to a different + directory other than SYS$HELP. If this is done, the system logical name + BULL_HELP should be defined to be the directory where the library is + to be found.) + +3) LOGIN.COM + This contains the commands that should be executed at login time + by SYS$MANAGER:SYLOGIN.COM. It defines the BULLETIN commands. + It also executes the command BULLETIN/LOGIN in order to notify + the user of new messages. NOTE: If you wish the utility to be a + different name than BULLETIN, you should modify this procedure. + The prompt which the utility uses is named after image executable. + If you want messages displayed upon logging in starting from + oldest to newest (rather than newest to oldest), add /REVERSE to + the BULLETIN/LOGIN command. Note that users with the DISMAIL + flag setting in the authorization file will not be notified of + new messages. See help on the SET LOGIN command within the BULLETIN + utility for more information on this. Also, please note that when + a brand new user to the system logins, to avoid overwhelming the new + user with lots of messages, only PERMANENT SYSTEM messages are displayed. + + If you want SYSTEM messages, i.e. messages which are displayed in full + when logging in, to be continually displayed for a period of time rather + than just once, you should add the /SYSTEM= qualifier. This is documented + in BULLETIN.HLP, although there it is referred to only with respect to + a user wanting to review system messages. It can be added with /LOGIN. + +4) BULLSTART.COM + This procedure contains the commands that should be executed after + a system startup. It should be executed by SYS$MANAGER:SYSTARTUP.COM. + It installs the BULLETIN utility with correct privileges. It also + includes the command BULLETIN/STARTUP. This starts up a detached process + with the name BULLCP. It periodically check for expire messages, cleanup + empty space in files, and converts BBOARD mail to messages. It also allows + other DECNET nodes to share it's folders. If you don't want this feature + and don't plan on having multiple folders or make use of BBOARD, you could + eliminate this command if you like. However, it is highly recommended that + you create this process to avoid extra overhead when users login. NOTE: + BULLCP normally is created so it is owned by the DECNET account. If that + account does not exist, BULLCP will be owned by the account that issues + the BULLETIN/START command. In that case, access via other DECNET nodes + will not be available. + + If you are installing BULLETIN on a cluster and plan to have the bulletin + files be shared between all of the cluster nodes, you only need to have + this process running on one node. On all other nodes, the system logical + name BULL_BULLCP should be defined (to anything you want) so as to notify + BULLETIN that BULLCP is running. (On the local node where BULLCP is running, + this logical name is automatically defined.) + + The use of the MARK command to mark messages require that a file be + created for each user which saves the marked info. That file file is + stored in the directory pointed to by the logical name BULL_MARK. You can + either let users who want to use this command define it themselves, or + you can define it for them, i.e. DEFINE/SYSTEM BULL_MARK SYS$LOGIN. + +5) INSTRUCT.COM + This procedure adds 2 permanent messages which give a very brief + description about the BULLETIN utility, and how to turn off optional + prompting of non-system messages (via SET NOREADNEW). + +6) BOARD_SPECIAL.COM + This command procedure describes and illustrates how to use the + SET BBOARD/SPECIAL feature. This feature allows the use of BBOARD + where the input does not come from VMS MAIL. For example, this could + be used in the case where mail from a non-DEC network is not stored + in the VMS MAIL. Another example is BOARD_DIGEST.COM. This file + takes mail messages from "digest" type mailing lists and splits them + into separate BULLETIN messages for easier reading. + + To use this feature, place the special command procedure into the + bulletin file directory using the name BOARD_SPECIAL.COM. If you want + to have several different special procedure, you should name the command + procedure after the username specified by the SET BBOARD command. + +7) INSTALL_REMOTE.COM + This procedure, in conjunction with REMOTE.COM and DCLREMOTE.COM allows + a user to install new versions of BULLETIN on several DECNET nodes from + a single node, rather than having to login to each node. This is + especially useful when a new version modifies the format of one of the + data file. Older versions of BULLETIN will not run with newer formats + and will either issue error statements when run, or may cause major + problems by attempting to change the files back to the old format. + (NOTE: Don't attempt to use this if different nodes are running + different versions of VMS, i.e. V4 and V5, as they require different + linked executables.) + +8) MASTER.COM + If you are using PMDF, and want to use the BBOARD option, a set of + routines are included which will allow PMDF to write message directly + into folders, which is a much more effecient way of doing it than + the normal BBOARD method of using VMS MAIL. Read PMDF.TXT for how + to do this. + +9) OPTIMIZE_RMS.COM + This routine optimizes index files. To run, type @OPTIMIZE_RMS.COM + followed by the filename. If you omit the filename, it will prompt + you to allow you to turn off or on several different types of RMS + compression. The default is to turn on all types of compression. + The optimization will cause the file to be compressed. + + If you use the NEWS feature, it is suggest that you run this procedure + on BULLNEWS.DAT after it is created. Compression that file greatly speeds + up the NEWS update process. If you are tight on space, and have been + running BULLETIN for a long time, it might also be useful to compress + BULLINF.DAT if that file is very large. However, compressing that (or + the other BULLETIN data files) don't appear to save any execution time, + unlike BULLNEWS.DAT. + +10) BULLETIN.COM + If one wants BULLETIN to be able to send messages to other DECNET + node's GENERAL folder, but wants to avoid running the process created + by BULLETIN/STARTUP on this node, another method exists. This is the + "older" (and slower) method. BULLETIN.COM must be put in each node's + DECNET default user's directory (usually [DECNET]). Once this is done, + the /NODE qualifier for the ADD & DELETE commands can be used. + The object BULLETIN pointing to BULLETIN.COM must be added to the NCP + database, i.e. the command + MCR NCP SET OBJ BULLETIN FILE directory:BULLETIN.COM number 0 + must be executed at startup time on the remote node. + NOTE: Privileged functions such as /SYSTEM will work on other nodes + if you have an account on the other node with appropriate privileges. diff --git a/batch/seed/1991a-bulletin_ann.txt b/batch/seed/1991a-bulletin_ann.txt new file mode 100644 index 0000000000000000000000000000000000000000..64c05e193d568b6bc7bdb8ca362599da09c2e0f2 --- /dev/null +++ b/batch/seed/1991a-bulletin_ann.txt @@ -0,0 +1,341 @@ +From: MRL "Mark R. London" +Date: 30-APR-1991 16:21 +Subj: BULLETIN utility. + +Received: by ADVAX.DECnet (utk-mail11 v1.5) ; Tue, 30 Apr 91 16:19:21 EDT +Received: from mcnc by ge-dab.GE.COM (5.61/GE-DAB 1.15) with UUCP + id AA09520 for ; Tue, 30 Apr 91 16:05:01 -0400 +From: BULLETIN@ORYANA.PFC.MIT.EDU +Received: from ORYANA.PFC.MIT.EDU by mcnc.mcnc.org (5.59/MCNC/3-21-91) + id AA08259; Tue, 30 Apr 91 11:29:23 -0400 + for ARISIA.dnet.ge.com!EVERHART +Message-Id: <819B16569FEDC00303@ORYANA.PFC.MIT.EDU> +Date: Tue, 30 Apr 91 11:14 EST +Subject: BULLETIN utility. +To: ARISIA::EVERHART +X-Envelope-To: EVERHART@ARISIA.dnet.ge.com +X-Vms-To: IN%"EVERHART@ARISIA.dnet.ge.com" + +You are about to receive version 2.04 of the PFC BULLETIN. + +BULLETIN is public domain software. (I will gladly accept +recommendations for new features, not for changes that are due to +"personal" preference.) + +As of V2.0, BULLETIN is able to read USENET NEWS via TCP/IP using either +CMU, MULTINET, UCX, or via DECNET. It can also serve as a NEWS gateway +for DECNET nodes without direct access to the NEWS server, i.e. a DECNET +node without Internet access will be able to read NEWS. + +NOTE: The following commands can be sent to BULLETIN@ORYANA.PFC.MIT.EDU: + SEND ALL [SINCE time] Sends all bulletin files. + If SINCE time specified, only files created + since that time will be sent. + SEND filename Sends the specified file. + BUGS Sends a list of the latest bug fixes. + HELP or INFO Sends a brief description of BULLETIN. + +There is also a documentation file written by Chris Tanner from Chalk +River Nuclear Labs which can be used as handout. To obtain this, +request the file BULLETIN.DOC. (This does not describe the NEWS reader +feature, however.) + +NOTE: An old bug might have changed the protection on the BULLETIN data +files. The protection on all data files (i.e. B*.DAT, *.BULLFIL, and +*.BULLDIR) should be (RWED,RWED,,). + +This version includes all necessary modifications to work under VMS +V5.0. However, it will still be necessary to reassemble the ALLMACS.MAR +source under V5 and relink. The V4 version will not be installable +under V5 due to a change in a shared library which BULLETIN uses. +However, relinking by itself will not be enough. You MUST also +reassemble ALLMACS.MAR. If you only relink, BULLETIN can cause your +system to crash (the BULLCP process will do this because it uses the +routines in ALLMACS.MAR). + +If you are running a version of BULLETIN older than 1.52, this version +will modify the format of some of the data files. (This will be done +automatically when the new version is run). After successful +installation, the older versions of these files can be removed. This +format change can take a significant amount of time if the folder is +large. If your site has large folders, it is suggested that the new +version be installed during off peak hours. NOTE: Problems can occur +if the old version of BULLETIN is run after the data files have been +modified. Such a situation is possible on a cluster where each node has +installed the executable separately. To help installation, a new +command procedure INSTALL_REMOTE.COM has been included. This can be +used to install BULLETIN on several nodes from a single node. Read the +comments in the file for information on how to use it. + +NOTE: The BULLCP process should be stopped using the BULLETIN/STOP +command before the new version of BULLETIN is installed. It can then be +restarted using the BULLETIN/STARTUP command. (The INSTALL_REMOTE.COM +command procedure does this automatically for remote nodes.) + +You will be receiving 19 files (NOT NECESSARILY IN THIS ORDER!): + 1) BULLETIN.FOR + 2) BULLETIN0.FOR + 3) BULLETIN1.FOR + 4) BULLETIN2.FOR + 5) BULLETIN3.FOR + 6) BULLETIN4.FOR + 7) BULLETIN5.FOR + 8) BULLETIN6.FOR + 9) BULLETIN7.FOR + 10) BULLETIN8.FOR + 11) BULLETIN9.FOR + 12) BULLETIN10.FOR + 13) ALLMACS.MAR + 14) BULLCOMS1.HLP + 15) BULLCOMS2.HLP + 16) BULLET1.COM + 17) BULLET2.COM + 18) PMDF.COM + 19) MX.COM + +(They will be identified in the SUBJECT header.) BULLET1.COM and +BULLET2.COM are command procedures which when run, will create several +small files. After you run them, you can delete them. If you have PMDF +at your site, you should also run PMDF.COM. Otherwise, you can delete +it. The same applies to MX. Then, read AAAREADME.TXT for BULLETN +installation instructions. + +NOTE: When creating these files (using the EXTRACT command) from the VMS +MAIL utility, you will have to strip off any mail headers that are +present, including blank lines. + MRL@NERUS.PFC.MIT.EDU +------------------------------------------------------------------------ +V2.04 + +Added ALWAYS attribute for folders. Any SYSTEM messages in a folder in which +ALWAYS has been set will be displayed every time a user logs in, rather than +just once. Also, non-SYSTEM messages will be displayed continuously (via +whatever mode is set, i.e. READNEW, SHOWNEW, or BRIEF) until it is actually +read. 4/29/91 + +Added capability of controlling the time between updates for BBOARD and NEWS in +BULLCP by defining the logical names BULL_BBOARD_UPDATE or BULL_NEWS_UPDATE to +the number of minutes of desired time in minutes. 4/27/91 + +Added /GROUPS= qualifier to all commands which post to NEWS groups. 4/26/91 + +Fixed bug which prevented SET SHOWNEW or READNEW from working with subscribed +news group folders. 4/25/91 + +V2.03 + +Added /FOLDER to SHOW USER in order to show the latest message that a user +has read in the specified folder. Also added /SINCE and /START (the former +for real folders, the latter for news groups). 4/11/91 + +Fixed logic so that defining BULL_NEWS_ORGANIZATION will override the +definition defined in BULLNEWS.INC. 4/10/91 + +Fixed SEARCH command, as it broke in V2.02 when /EDIT was added to read +message commands. There is a missing QUALIFIER EDIT in BULLCOM.CLD for the +SEARCH verb. /EDIT now works with SEARCH. 4/9/91 + +Fixed bug in BULLCP which prevented the DECNET/INTERNET NEWS gateway software +from working with UCX. 4/9/91 + +Fixed bug caused by V2.00 which caused incorrect listing of message during +BULL/LOGIN for remote folders. 4/3/91 + +Fixed bugs which caused erroneous new message notifications for subscribed +NEWS groups that were empty. 3/27/91 + V 2.02 + +Include BBOARD support for MX (courtesy of goathunter@wkuvx1.bitnet). + +Changed BBOARD algorithm so that it is now possible to have only one real +BBOARD account, and have all the others be VMS MAIL forwarding entries. +See HELP SET BBOARD MORE_INFO for more info (it's been updated). + +Added hook to allow postings from BULLETIN to a LISTSERV mailing list to use +the BBOARD account from it was subscribed to. See HELP SET BBOARD LISTSERV. + +Fixed many bugs in POST, REPLY, and RESPOND. + +Fixed /ALL for COPY, PRINT, and EXTRACT when using NEWS groups. + +Included RMS optimizer procedure for indexed files to optimize BULLNEWS.DAT +to speed up NEWS updates. Can be used on other files (in particular +BULLINF.DAT) in order to save space. + +Add /EDIT to BACK, NEXT, LAST, and when entering message number. + +Modify ADD/REPLY command to local (non-NEWS) folders so if there are new +messages present, it doesn't reset the newest message count. Previously, +adding a message would reset the user's last read message date to that message +in order to avoid notifying the user of new messages due to the user's own +message. + +Fixed code so that when reading new messages, and if READ/EDIT or DELETE/IMMED- +IATE IS entered, a carriage return will read the next new message. Previously +the wrong message would be displayed. + +V 2.01 + +Fixed many bugs associated with USENET NEWS reading feature. + +Added UCX interface for NEWS. + +Added signature file for POST and RESPOND messages." + 3 +Added capability to specify file name for POST, REPLY, and RESPOND.i + y +Added the line "In a previous message, <message-owner> wrote:" to the9 +beginning of a message when /EXTRACT is specified6 + E +Added hook for network mail to run command procedure rather then using +VMS MAIL. BULL_MAILER can be defined to point to the procedure, and itm +is called with the username and subject as the parameters. + 1 +V 2.00 + 0 +Added USENET NEWS reading feature. + s +V 1.93 + 9 +Fixed bug which wouldn't allow a permanent message to be added by a +non-privileged user in a remote folder (the folder had been setup to allow +permanent messages from non-privileged users, of course). + +Fixed bug which causes the DELETE command not to delete a SHUTDOWN message +without the use of /IMMEDIATE. + t +Fixed the algorithm which prevented duplicate notification of messages in +remote folders on different nodes, as duplication was still possible.2 + +V 1.92 + +Fixed bug which causes BULLCP to loop when trying to cleanup a folder whichD +has more than 127 identifiers granted access to a folder. Also correctr +SHOW FOLDER/FULL, which had a similar problem when trying to display the +identifiers. + r +Fix PMDF interface to recognize to recognize PMDF_PROTOCOL.U + T +V 1.91 + F +Disallow SPAWN command for CAPTIVE account.b + e +Fix MAIL command to correctly allow passing addresses with quotes, i.e.h +IN%"""MRL@NERUS.PFC.MIT.EDU""".e + e +V 1.90 + s +SET NOTIFY now works for remote folders. + l +Avoid generating notification message due to SET NOTIFY flag if the messageh +was broadcasted when added using ADD/BROADCAST.r + T +Bug in DIR/SINCE for remote folders fixed. If no new messages were present, +it would incorrectly show messages.T + D +Added /FF to EXTRACT command to seperate messages in the file with form feeds. + +Allow specifying CURRENT and LAST when specifying a range of messages fort +commands that accept a range, i.e. EXTRACT 1-CURRENT, CURRENT-LAST, etc. + e +Open folder files with READONLY when not writing to them in order to avoid +changing modification date, which results in unnecessary backups.e + e +Modify HELP so that it won't prompt for Subtopic is there is none. + w +Prevent screen from being erased after exiting HELP. + s +Fix bug which causes CREATE/NOTIFY to crash. + +SET NOTIFY/CLUSTER has been removed. As of VMS V5.2, it is possible to obtain +the list of users logged in to all nodes of a cluster, so this qualifier is no +long necessary. NOTE: You can delete all the BULL_DIR:*.NOTIFY files, as they +are no longer used.g + v +BULLETIN now will use the editor specified by the SET EDITOR command within +MAIL for editing messages. + i +Typing BACK after typing a DIRECTORY command will now show the previous +DIRECTORY display entries rather than reading the previous message.n + +Several bugs related to the MARK command were fixed. Also the software has been +optimized so that scanning for MARKed messages should take less time.t + e +/EXPIRATION added to DIRECTORY command to show expiration rather than creation +date of messages.o + o +Any BULLETIN interactive command can be executed at DCL level by typingt +BULLETIN "command" or BULLETIN "command1;command2;etc.". + t +The CHANGE command has been modified so a range of message can be specified, +i.e. /NUMBER=1-10. Also, the code incorrectly misinterpreted /TEXT as meaning +to extract the old text message, whereas it should have meant that only thei +text was to be changed. This prevented a user from specifying that only the +text should be changed if that user didn't have editing enabled. This has beenl +fixed. To eliminate confusing, the /TEXT qualifier on the ADD command has beenL +removed (previously it was a synonym for /EXTRACT). + o +SHOW FOLDER/FULL display of access IDs was fixed to correctly display UICs. + E +Removed security hole which occurs if you are using the old method of accessing +a remote node via /NODES (it would have required looking a the sources to find, +which one installer did and was worried about). Because of this, if you use +this old method (i.e. via BULLETIN.COM), the object BULLETIN must be installed +in the NCP database pointing to the file BULLETIN.COM, i.e. the commandf +"MCR NCP SET BULLETIN FILE directory:BULLETIN.COM NUMBER 0" must be executed +during the system startup. + +Fixed bug in /LOGIN display when erasing page if terminal is hardcopy. No +page would be erased (of course), and the next line outputted would start wheree +the previous line left off, rather than starting on a new line. + +Added BULLETIN/WIDTH=page_width for users who have BULLETIN/LOGIN in their +login procedure before the terminal is known, and whose default page width isf +larger (i.e. 132) than what the terminals are (i.e. 80). + i +Added BULLETIN/PGFLQUOTA and /WSEXTENT in order to set those quotas for the- +BULLCP process.- + - +Added ATTACH command.- + - +Modify SET STRIP so that it saves the date that the message was sent and +leaves it at the to of the message. + L +BULLETIN will search BBOARD message headers for a line that starts withn +"Expires:" or "X-Expires:", followed by a date (DD MMM YYYY or similar). It ift +finds that line, it will use that date as the expiration date of the message. + 2 +Added /REPLY to SEARCH command. Modified so that it's possible to abort out ofn +a /SUBJECT or /REPLY search using CTRL-C (previous possible only if searchingS +the text for a string. Also, if you hit CTRL-C at the wrong time, BULLETINd +would abort totally rather than just aborting the search). u + +Added /SEARCH= /SUBJ= and /REPLY to the DIRECTORY command. Basically this ish +combining the DIRECTORY and SEARCH commands. + 2 +Fixed design flaw which allowed the following to occur: If a folder is aa +remote system folder, when BULLETIN/LOGIN was executed, the same messages mightr +be displayed on both the local and remote nodes. BULLETIN now will know that +the user has seen the message on one node and will not display it if that user +logs in on the other node. + i +Optimized code which caused slow display of new messages when executinge +BULLETIN/LOGIN without /REVERSE for a remote folder. + L +Added /PERMANENT to SET NOTIFY, SHOWNEW, BRIEF, and READNEW. The affect ise +that users will not be allowed to change the setting. The main intent herer +was to allow the removal ofthe permanent setting of SHOWNEW from the GENERAL +folder.i + o +Fixed bug which would cause a SYSTEM message not to be shown if SET BRIEF wasc +selected for that folder, and a non-SYSTEM message was also present. + t +Added SET CONTINUOUS_BRIEF. This causes the SET BRIEF setting to show thats +there are unread new messages every time BULLETIN/LOGIN is executed, rathern +than just the one time. The BRIEF notification code has also been optimized +so that it'll take less time to notify you of new messages. + +A major bug was fixed which was introduced in previous mods to speed upL +BULLETIN/LOGIN. The effect is that no notifications will appear for certain +folders via BULLETIN/LOGIN. This would only happen if a folder was removed at +some time. diff --git a/batch/seed/1991a-handout.txt b/batch/seed/1991a-handout.txt new file mode 100644 index 0000000000000000000000000000000000000000..9f18b240026cfd576982076f096d3b897ec11f15 --- /dev/null +++ b/batch/seed/1991a-handout.txt @@ -0,0 +1,272 @@ +From: MRL "Mark R. London" +Date: 30-APR-1991 16:21 +Subj: Introduction to BULLETIN on the Vax + + Introduction to BULLETIN on the Vax + 2/88 AW + +PUBLISHED BY THE DREW UNIVERSITY ACADEMIC COMPUTER CENTER. MAY BE +COPIED WITH WRITING CREDIT GIVEN TO DREW UNIVERSITY. + +BULLETIN was written for the Public Domain by Mark London at MIT. + + The BULLETIN utility permits a user to create messages for +reading by other users. Users may be notified upon logging on +that new messages have been added, and what the topic of the +messages are. Actual reading of the messages is optional. (See +the command SET READNEW for info on automatic reading.) Messages +are automatically deleted when their expiration data has passed. + The program runs like VAX mail. The different interest +groups or BULLETIN boards are implemented in the form of +'Folders', just like a filing cabinet. A Folder contain various +messages on the same general topic. A message is a piece of text +written by a user or staff person and added to a particular +folder. All users are not permitted to submit messages to all +folders. + + A message consists of an expiration date, a subject line +and the text of the message. BULLETIN will prompt the user for +these things when a message is being added. + + Several different folders are currently defined to +BULLETIN. The General Folders will be used by Computer Center +Staff to post messages of general interest concerning the VAX to +the user community. If something is of an important nature, it +will be posted in the General folder as a 'System' message. +This is a special message type. It will be displayed to each +user as they log in the first time after that message was +posted. This will be done automatically by BULLETIN on login. +Once a particular system message has been displayed, it will not +be displayed for that user on subsequent logins. + +Folders + + Different folders have been created to contain messages on +different topics. Folders may be public, semi-private, or +private. The majority of the folders will be public. However a +few will be semi-private, which will mean that all users may +read messages in the folder but not all will be able to post to +it. Currently, there are several folders defined: + +GENERAL -- system messages + +PUBLIC_ANNOUNCEMENTS -- Can be used by anyone to post messages +of interest to the public + +On Beta: +AIDE STATION -- Private folder for Computer Center Employees + +In addition on Alpha there are folders that receive electronic +magazines, such as: +NETMONTH -- The monthly magazine of BITNET information. +RISKS -- Identifying the risks involved in using computers. +INFOIBMPC -- Information about the IBM personal computers. +INFOVAX -- Information on the Digital VAX. +PROGRAMMING_JOURNALS-Includes MINIX, UNIX and C, Modula-2 and +Prolog journals +watch for new ones being added. + +Using BULLETIN + + BULLETIN is invoked by type the command 'BULLETIN' (or BULL, +for short) at the '$' prompt. BULLETIN will display its prompt +'BULLETIN>'. Help is available from DCL command level ($) or from +within the BULLETIN program itself by typing the word 'HELP'. To +leave the BULLETIN program, type 'EXIT'. + +To see what is there + + In order to see message and folders, on can use the +'Directory' command. Upon entering BULLETIN, the user is place +in the General folder. If the user wishes to see which folders +exist, the directory/folders command is used. for example: +typing: + + BULLETIN> directory/folders + +will make a display like: + + Folder Owner + *GENERAL SYSTEM + *PUBLIC_ANNOUNCEMENTS BBEYER + NETMONTH BITNET + *VAX_SIG BBEYER + +An asterisk (*) next to the folder name indicates you have unread +messages in that folder. + +The command 'DIRECTORY/FOLDERS/DESCRIBE' would list all available +folders, along with a brief description of each. + + To switch from one folder to another folder, the user may +execute the 'SELECT' command. For example, the following +command would show what a user would do to switch to the folder +called PUBLIC_ANNOUNCEMENTS: + +BULLETIN> SELECT PUBLIC_ANNOUNCEMENTS + +and BULLETIN would respond: + Folder has been set to PUBLIC_ANNOUNCEMENTS + + Now the user may get a list of the messages in this folder +by issuing the directory command with no qualifiers. +This command, for example: +BULLETIN> DIRECTORY +would have bulletin respond: + + # Description From Date + 1 CHRISTMAS PARTY oleksiak 26-JUN-88 + 2 Learning about BULLETIN oleksiak 26-JUN-87 + 3 VAX MAIL LLLOYD 01-Jan-87 + + The command 'DIR/NEW' will list just unread messages. + + +Reading messages + + In order to read messages in a folder, the user may type +the read command or he/she may simply type the number of the +message he wishes to read. The message numbers can be acquired +by doing the 'DIRECTORY' command. If the user hits a carriage +return with no input whatsoever, BULLETIN will type the first +message in the folder, or if there are new messages present, it +will type the first new message in the folder. + + If a folder contains the above messages (as seen by the +'Directory' command) then these messages can be read by: + +BULLETIN> READ +and BULLETIN would respond: + +Message number: 1 PUBLIC_ANNOUNCEMENTS +Description: CHRISTMAS PARTY +Date: 26-JUN-1988 8:08:40 Expires: 1-JAN-1989 08:08:40 + +...Body of message..... + + Should the user only wish to see message number 3, he can +enter the 'READ' command with the message number as a parameter. +for example: + +BULLETIN> READ 3 + + There are three other useful commands that can be used at +the 'BULLETIN>' prompt when reading messages. These are: + +BACK - Read the message preceding the message currently being +read. + +CURRENT - Start reading the current message at the top. This is +useful for someone who is reading a message and wishes to reread +it from the beginning. + +NEXT - Start reading from the beginning of the next message. +This is handy if the user is reading a very long message and +wants to skip to the next one. + +Saving the interesting stuff. + + If the user sees something which he/she wants a copy of, +the extract command can be use to write an ASCII copy of the +message into a file. This command works on the current message +being read. It requires the name of the file into which to save +the message. If the file name is not given, the user will be +prompted for it. For example: + +BULLETIN> Read 2 + +********** Message on Screen ******** + +A person could then type +BULLETIN> extract +file: FV.TXT +BULLETIN> + +BULLETIN has now saved the contents of message number 2 into the +file name 'FV.txt'. + If the file to which the user is writing already exists, +BULLETIN will append the message to the file. The user can +force BULLETIN to write a new file containing only the message +being saved by using the '/new' qualifier in the 'extract' +command. These messages can then be sent to other users, or +downloaded for use in Wordperfect. (See "Mail on the Vax", or +"Transferring a file between a PC and the VAX"). + +This command may be useful if you wish to transfer the message to +your PC, perhaps using a BITNET journal message as a reference in +a paper. Once the file is saved, you can transfer it to a PC by +following the instructions in the handout 'Transferring files +from the PC to the VAX of from the VAX to a PC". + +Adding messages + A user may add a message to a folder by selecting the +folder and then using the 'ADD' command. This is provided that +the user is adding the message to a public folder. The user has +the option of giving the 'ADD' command and typing a message using +the VAX editor or uploading a message from your PC (see +documentation), or add a message you have extracted from VAX +mail. BULLETIN will prompt for the expiration date and subject +line. It will then add the text of the file as the body of the +message. To add a message that is stored in a file (from MAIL or +from your PC, for example) type: + + ADD filename + +If the user does not specify a file name, he/she will be +prompted to enter the body of the message. The user may also +use the EDT text editor by issuing the command with the +'/EDIT'option. + +For example: +BULLETIN> sel PUBLIC_ANNOUNCEMENTS + folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> ADD MESS.TXT + +IT IS 10-JUL-1988 12:41:06.15. SPECIFY WHEN THE MESSAGE SHOULD +EXPIRE: ENTER ABsolute TIME: <DD-MMM-YYYY]HH:MM:SS OR DELTA +TIME: DDD HH:MM:SS + +A user then type the date of expiration and press the 'return' +button. The time input may be ignored. For example, typing: +20-JUL-1988 or type "10" - for ten days in the future. + +BULLETIN responds: +ENTER DESCRIPTION HEADER. LIMIT HEADER TO 53 CHARACTERS. + +Now the user may enter the subject of the message. + +BULLETIN> + +The above session adds the text in the file 'mess.txt' as the +next message in the PUBLIC_ANNOUNCEMENTS Folder. The message +will be deleted automatically on the 20th of July as requested +by the user adding the message. + +Asking BULLETIN to notify you of new messages upon logging in. + + If the user wishes to get notification on login when new +messages are in a folder, he should use the 'READNEW' option. +This command does not force the reader to reading new messages, +only gives notification. To do this, 'SELECT' each folder you +are interested in and do a 'SET READNEW' command while set to +that folder. + +Example: + +BULLETIN> Select PUBLIC_ANNOUNCEMENTS +folder has been set to PUBLIC_ANNOUNCEMENTS +BULLETIN> SET READNEW + +Alternately, you may type SET SHOWNEW. This will just display a +message notifying you that there are new messages. + +Mailing a BULLETIN message + + A user may directly mail another user a message found in the +BULLETIN. While reading the message that he/she desires to send, +at the 'BULLETIN>' type 'MAIL'. The Vax will then ask to whom +you wish to send the information too. + +Check the BULLETIN DISCUSSION folder on ALPHA for new additions. +If you have comments or questions about BULLETIN, leave them +there. diff --git a/batch/seed/1991a-instruct.txt b/batch/seed/1991a-instruct.txt new file mode 100644 index 0000000000000000000000000000000000000000..fa01194507f4d27491310970c1e997eb4e7fd6e9 --- /dev/null +++ b/batch/seed/1991a-instruct.txt @@ -0,0 +1,12 @@ +From: MRL "Mark R. London" +Date: 30-APR-1991 16:21 +Subj: Instructions + +This message is being displayed by the BULLETIN facility. This is a non-DEC +facility, so it is not described in the manuals. Messages can be submitted by +using the BULLETIN command. System messages, such as this one, are displayed +in full, but can only be entered by privileged users. Non-system messages can +be entered by anyone, but only their topics will be displayed at login time, +and will be prompted to optionally read them. (This prompting feature can be +disabled). All bulletins can be reread at any time unless they are deleted or +expire. For more information, see the on-line help (via HELP BULLETIN). diff --git a/batch/seed/1991a-news.txt b/batch/seed/1991a-news.txt new file mode 100644 index 0000000000000000000000000000000000000000..f9aed2f2424a45662ce8d33c73fab1628c68ed9d --- /dev/null +++ b/batch/seed/1991a-news.txt @@ -0,0 +1,106 @@ +From: MRL "Mark R. London" +Date: 30-APR-1991 16:21 +Subj: BULLETIN USENET NEWS features + +BULLETIN now has the capability to read and post messages to USENET NEWS in a +client mode. I realize that there are many NEWS readers, some with much more +elegant interfaces. However, I elected to modify BULLETIN for the following +reason: We have many decnet nodes, but only several are internet nodes. Our +only access to a news server was via internet. In order for those +non-internet nodes to read USENET, the only method that seemed available was to +run a NEWS server program on one of our own internet nodes so that it could +be accessible via decnet. I did not want to do that, as that requires storing +the news groups on disk, and I do not have the room for that. I thus added the +ability in BULLETIN (actually BULLCP) so that it acts as as a gateway between +decnet and tcp for NEWS. This method does not require spawning any processes, +since the detached process BULLCP is always present, so the access is very +fast. Also, since BULLETIN uses a shared database to store info on the NEWS +groups and periodically updates it, there is no need for that to be done when a +user accesses the NEWS groups. Several other NEWS readers do this when you run +them, which is why they take a long time to start up. It is also possible to +feed NEWS groups into a "real" BULLETIN folder, so that the messages are saved +on disk. + +Presently, BULLETIN can be used with either UCX, MULTINET, or CMU TCP/IP +packages (and of course DECNET) for reading NEWS. Support for other packages +can be added if I can find sites willing to beta test the interface for me. +The source for the TCP interface is in C rather than FORTRAN because the +MULTINET include files are in C. However, if you do not have C, I will be glad +to send the object for it (or to even possibly rewrite the code in FORTRAN). + +The instructions for installation are as follows. Define BULL_NEWS_SERVER +to be a system logical name pointing to either your internet or decnet NEWS +node. If it is decnet, simply specify the decnet node name, i.e. + + $ DEFINE/SYSTEM BULL_NEWS_SERVER NERUS + +BULLETIN decides to use DECNET rather than TCP access based on the node name. +If it does not have any periods in it, then it assumes it is a DECNET node. + +In our cluster, we usually have one node which is an internet node, and the +rest non-internet nodes. If you have a similar situation, you'll have to +create a startup procedure that defines BULL_NEWS_SERVER to be the internet +news server address only on the node (or nodes) on the cluster that have +actually internet access. The other nodes will have BULL_NEWS_SERVER defined +as the decnet node name that BULLCP is running on in the cluster. (Of course, +BULLCP will have to be running on a node with internet access.) + +NOTE: If you want to disable the gateway feature, then before starting BULLCP, +define the logical name: + + $ DEFINE/SYSTEM BULL_NO_NEWS_GATEWAY "FALSE" + +Defining this will only shut off the gateway. BULLETIN will still be allowed +to read NEWS from the local node as long as BULL_NEWS_SERVER is defined. + +In order to post messages, BULLETIN needs to know the internet nodename of +the local host. This is done automatically for nodes running MULTINET. For +other nodes, BULLETIN attempts to translate the logical name ARPANET_HOST_NAME, +INTERNET_HOST_NAME, and MX_NODE_NAME. + +The local time zone is detected by looking at the following logical names: +LISP$TIME_ZONE, MULTINET_TIMEZONE, or PMDF_TIMEZONE. (LISP$TIME_ZONE is +defined if you have LISP installed.) + +The name of the organization is included in the header of the NEWS message. +This can be anything, but usually is the company or university name. This +can be hardcoded into the source by putting in BULLNEWS.INC, or by defining +the system logical name BULL_NEWS_ORGANIZATION. + +The name of the mail protocol to use for responding by mail to NEWS messages +can also be either hardcoded by putting in BULLNEWS.INC, or by defining the +system logical name BULL_NEWS_MAILER. + +After installing the new BULLETIN, execute the command NEWS, which asks for a +list of all the news groups. Because this is the first time it is executed, it +will cause a load of all the remote news groups into a local data base +(BULL_DIR:BULLNEWS.DAT). This will take several minutes to do. It is the only +time that this load will be done interactively. Afterwards, BULLCP will +periodically update the data base. For this reason, it is highly recommeded +that BULLCP be installed. BULLCP will update NEWS every hour. If you want to +change this frequency, define the logical name BULL_NEWS_UPDATE to the number +of minutes in between updates, i.e. DEFINE/SYSTEM BULL_NEWS_UPDATE "30" for 30 +minutes. (NOTE: BULLCP will create a subprocess BULLCP NEWS which does the +update. You can watch how long it takes for this to run in order to determine +if you want to change the update period). After BULLNEWS.DAT is created, it is +suggested that you run OPTIMIZE_RMS.COM on it, as it will cause the file to be +compressed and will allow updates to run much faster (factor of 5 or more). + +If you have any problems or questions, please let me know. + MRL +P.s. + If you do not know what USENET NEWS, it's basically news messages which +are passed between nodes. Originally it was limited to USENET, but that is no +longer the case. Unlike internet mailing lists which use MAIL to send the +messages to individuals, NEWS messages are not sent via MAIL. They are passed +between nodes using a special protocol, NNTP. Users must use a NEWS reader +package to read them. However, it is possible to read NEWS remotely over a +network, and therefore avoiding having to actually store the messages. +BULLETIN is setup to be used mainly in this client mode, i.e. it can read +messages on another node via TCP or DECNET. This is useful, since the number +of NEWS groups total over 1000, the disk space required for storage is very +high. If you are interested in finding a server node that would allow you to +read NEWS, and do not know of one (i.e. a USENET node), I know of no official +way of doing so. However, one suggestion was to try connecting to BBN.COM via +ANONYMOUS FTP and look through the directory uumap/comp.mail.maps to find a +USENET node near you to contact. diff --git a/batch/seed/1991a-nonsystem.txt b/batch/seed/1991a-nonsystem.txt new file mode 100644 index 0000000000000000000000000000000000000000..b61eb38e14eabebdb181174fe3bf5fba2190d340 --- /dev/null +++ b/batch/seed/1991a-nonsystem.txt @@ -0,0 +1,20 @@ +From: MRL "Mark R. London" +Date: 30-APR-1991 16:21 +Subj: READNEW example + +Non-system bulletins (such as this) can be submitted by any user. Users are +alerted at login time that new non-system bulletins have been added, but only +their topics are listed. Optionally, users can be prompted at login time to +see if they wish to read the bulletins. When reading the bulletins in this +manner, the bulletins can optionally be written to a file. If you have the +subdirectory [.BULL] created, BULLETIN will use that directory as the default +directory to write the file into. + +A user can disable this prompting featuring by using BULLETIN as follows: + +$ BULLETIN +BULLETIN> SET NOREADNEW +BULLETIN> EXIT + +Afterwords, the user will only be alerted of the bulletins, and will have to +use the BULLETIN utility in order to read the messages. diff --git a/batch/seed/1991a-writemsg.txt b/batch/seed/1991a-writemsg.txt new file mode 100644 index 0000000000000000000000000000000000000000..b901c4ca17efe2f80136b8a297a8fc03ddecd99b --- /dev/null +++ b/batch/seed/1991a-writemsg.txt @@ -0,0 +1,40 @@ +From: MRL "Mark R. London" +Date: 30-APR-1991 16:21 +Subj: subroutines for writing a message + +BULLETIN contains subroutines for writing a message directly to a folder. This +would be useful for someone who is using the BBOARD feature, but wants to avoid +the extra overhead of having the message sent to an account as MAIL, and then +have BULLCP read the mail. It is better if the network mail could be written +directly to the folder bypassing VMS MAIL, as it reduces a lot of cpu overhead. + +Call INIT_MESSAGE_ADD to initiate a message addition. +Call WRITE_MESSAGE_LINE to write individual message lines. +Call FINISH_MESSAGE_ADD to complete a message addition. + +Calling formats: + + CALL INIT_MESSAGE_ADD(IN_FOLDER,IN_FROM,IN_DESCRIP,IER) +C +C INPUTS: +C IN_FOLDER - Character string containing folder name +C IN_FROM - Character string containing name of owner of message. +C If empty, the default is the owner of the process. +C IN_DESCRIP - Character string containing subject of message. +C If empty, the message is searched for a line +C which starts with "Subj:" or "Subject:". +C OUTPUTS: +C IER - Error status. True if properly connected to folder. +C False if folder not found. +C + + CALL WRITE_MESSAGE_LINE(BUFFER) +C +C INPUTS: +C BUFFER - Character string containing line to be put into message. +C + + CALL FINISH_MESSAGE_ADD +C +C NOTE: Only should be run if INIT_MESSAGE_ADD was successful. +C diff --git a/batch/announcement-2.06.txt b/batch/seed/1991b-bulletin.ann similarity index 81% rename from batch/announcement-2.06.txt rename to batch/seed/1991b-bulletin.ann index b41d0330bba89de4d7b4e9d6125e49c922ce7858..862aa14d1142a69f770fba3df1fd1c158ab0590d 100644 --- a/batch/announcement-2.06.txt +++ b/batch/seed/1991b-bulletin.ann @@ -1,4 +1,19 @@ -You are about to receive version 2.06 of the PFC BULLETIN. +From: MRL "Mark R. London" +Date: 10-JAN-1992 17:24 +Subj: BULLETIN utility (last FORTRAN version). + +Received: by AITGW.DECnet (utk-mail11 v1.5) ; Fri, 10 Jan 92 17:23:59 EST +Received: from ORYANA.PFC.MIT.EDU by aitgw.ge.com (5.65/GE Gateway 1.4) + id AA16962; Fri, 10 Jan 92 17:23:43 -0500 +Message-Id: <B90954FBA613401A55@ORYANA.PFC.MIT.EDU> +Date: Fri, 10 Jan 92 17:01 EST +From: BULLETIN@ORYANA.PFC.MIT.EDU +Subject: BULLETIN utility. +To: ARISIA::EVERHART +X-Envelope-To: EVERHART@ARISIA.dnet.ge.com +X-Vms-To: IN%"EVERHART@ARISIA.dnet.ge.com" + +You are about to receive version 2.07 of the PFC BULLETIN. BULLETIN is public domain software. (I will gladly accept recommendations for new features, not for changes that are due to @@ -13,7 +28,7 @@ NOTE: The following commands can be sent to BULLETIN@ORYANA.PFC.MIT.EDU: SEND ALL [SINCE time] Sends all bulletin files. If SINCE time specified, only files created since that time will be sent. - SEND filename Sends the specified file. + SEND filename Sends the specified file. BUGS Sends a list of the latest bug fixes. HELP or INFO Sends a brief description of BULLETIN. SUBSCRIBE Subscribes to mailing list for upgrade @@ -57,7 +72,7 @@ command before the new version of BULLETIN is installed. It can then be restarted using the BULLETIN/STARTUP command. (The INSTALL_REMOTE.COM command procedure does this automatically for remote nodes.) -You will be receiving 20 files (NOT NECESSARILY IN THIS ORDER!): +You will be receiving 21 files (NOT NECESSARILY IN THIS ORDER!): 1) BULLETIN.FOR 2) BULLETIN0.FOR 3) BULLETIN1.FOR @@ -78,19 +93,46 @@ You will be receiving 20 files (NOT NECESSARILY IN THIS ORDER!): 18) BULLET2.COM 19) PMDF.COM 20) MX.COM + 21) NEWS.COM (They will be identified in the SUBJECT header.) BULLET1.COM and BULLET2.COM are command procedures which when run, will create several small files. After you run them, you can delete them. If you have PMDF at your site, you should also run PMDF.COM. Otherwise, you can delete it. The same applies to MX. Then, read AAAREADME.TXT for BULLETN -installation instructions. +installation instructions. If you are using the news feature, NEWS.COM +contains files which pertain to news. NOTE: When creating these files (using the EXTRACT command) from the VMS MAIL utility, you will have to strip off any mail headers that are present, including blank lines. MRL@NERUS.PFC.MIT.EDU -------------------------------------------------------------------------- +Allow list of numbers when specifying message numbers for PRINT and FILE +commands. 11/27/91 + +Fixed bugs in BBOARD code: Messages with lines > 255 characters would not be +included. Subject line not correctly extracted if next line was simply a +To:. (relink PMDF driver if using PMDF for patch to take affect). 11/27/91 + +V 2.07 + +NEWS listing now shows the status of the news group, i.e. active, inactive, +moderated, or renamed. 10/23/91 + +Fixed PRINT command so that if a print qualifier (i.e. /QUEUE) is specified, +it will cause any pending print jobs to be printed if the qualifier for the +pending jobs is different. 10/23/91 + +Added /NOSIGNATURE qualifier for POST & RESPOND commands. 10/21/91 + +Fixed error in POST & RESPOND command. If a file was specified on the command +line, and /EDIT was specified, the file would be sent even if the user quit out +of the edit, rather than exitting (i.e. outputting a file). 10/21/91 + +Fixed REPLY option in READNEW, as it was possible for users with only read +access to a folder to be able to add REPLY messages. 10/10/91 + Add REPLY option to READNEW feature when reading messages. Also, really fix the REPLY command, as mentioned in V2.06. 8/11/91 @@ -133,264 +175,264 @@ one folder at a time. 6/13/91 NEWS/SUBSCRIBED listing was fixed. If the list could not fit on a single page, a folder was skipped when the next page was shown. 6/3/91 -INDEX was fixed. If it was used with the qualifiers /NEW or /MARK, and the +INDEX was fixed. If it was used with the qualifiers /NEW or /MARK, and the1 directory listing of a folder was displayed, and then RETURN is entered to skip to the next folder, the directory display of the next folder would be -incorrect. 6/3/91 - -Fixed broadcast bug. If a message was added with /BROADCAST to a remote folder +incorrect. 6/3/91 N + F +Fixed broadcast bug. If a message was added with /BROADCAST to a remote folder2 from a node in a cluster which was not the node that BULLCP was running on. -The broadcast would appear twice on the cluster. 5/24/91 +The broadcast would appear twice on the cluster. 5/24/91j + : +Added code to alert user if message too large to be fully broadcasted. 5/24/91c -Added code to alert user if message too large to be fully broadcasted. 5/24/91 - -Added code to avoid erroneous notifications of new messages for an empty NEWS +Added code to avoid erroneous notifications of new messages for an empty NEWSe group. Unlike a similar fix in V2.03 which was due to a bug, this fix may not affect all sites, as it depends on the behavior of the server. 5/22/91 Fixed NEWS to FOLDER feed. A recent change broke it. 5/22/91 - + 2 Added /EDIT qualifier for MAIL. 5/20/91 - + T Added /HEADER qualifier for LAST, BACK, and CURRENT commands. 5/19/91 - + r Added TWG (Wollongong) interface for NEWS. 5/18/91 - + e Fixed bug which truncated subject headers of messages created when using REPLY -and RESPOND to messages which have long subject lines. 5/12/91 - -V2.04 - +and RESPOND to messages which have long subject lines. 5/12/91U + T +V2.04N + F Added ALWAYS attribute for folders. Any SYSTEM messages in a folder in which ALWAYS has been set will be displayed every time a user logs in, rather than -just once. Also, non-SYSTEM messages will be displayed continuously (via +just once. Also, non-SYSTEM messages will be displayed continuously (viax whatever mode is set, i.e. READNEW, SHOWNEW, or BRIEF) until it is actually -read. 4/29/91 - +read. 4/29/91 e + o Added capability of controlling the time between updates for BBOARD and NEWS in BULLCP by defining the logical names BULL_BBOARD_UPDATE or BULL_NEWS_UPDATE to -the number of minutes of desired time in minutes. 4/27/91 - -Added /GROUPS= qualifier to all commands which post to NEWS groups. 4/26/91 +the number of minutes of desired time in minutes. 4/27/91i +Added /GROUPS= qualifier to all commands which post to NEWS groups. 4/26/91h + f Fixed bug which prevented SET SHOWNEW or READNEW from working with subscribed -news group folders. 4/25/91 - -V2.03 - +news group folders. 4/25/91a + c +V2.03t + p Added /FOLDER to SHOW USER in order to show the latest message that a user has read in the specified folder. Also added /SINCE and /START (the former -for real folders, the latter for news groups). 4/11/91 - -Fixed logic so that defining BULL_NEWS_ORGANIZATION will override the +for real folders, the latter for news groups). 4/11/91u + r +Fixed logic so that defining BULL_NEWS_ORGANIZATION will override theA definition defined in BULLNEWS.INC. 4/10/91 - -Fixed SEARCH command, as it broke in V2.02 when /EDIT was added to read -message commands. There is a missing QUALIFIER EDIT in BULLCOM.CLD for the + v +Fixed SEARCH command, as it broke in V2.02 when /EDIT was added to readl +message commands. There is a missing QUALIFIER EDIT in BULLCOM.CLD for thee SEARCH verb. /EDIT now works with SEARCH. 4/9/91 -Fixed bug in BULLCP which prevented the DECNET/INTERNET NEWS gateway software -from working with UCX. 4/9/91 - +Fixed bug in BULLCP which prevented the DECNET/INTERNET NEWS gateway softwarer +from working with UCX. 4/9/91 s + e Fixed bug caused by V2.00 which caused incorrect listing of message during BULL/LOGIN for remote folders. 4/3/91 - + y Fixed bugs which caused erroneous new message notifications for subscribed NEWS groups that were empty. 3/27/91 - + f V 2.02 - -Include BBOARD support for MX (courtesy of goathunter@wkuvx1.bitnet). - -Changed BBOARD algorithm so that it is now possible to have only one real -BBOARD account, and have all the others be VMS MAIL forwarding entries. + s +Include BBOARD support for MX (courtesy of goathunter@wkuvx1.bitnet).. + h +Changed BBOARD algorithm so that it is now possible to have only one reals +BBOARD account, and have all the others be VMS MAIL forwarding entries.w See HELP SET BBOARD MORE_INFO for more info (it's been updated). - + o Added hook to allow postings from BULLETIN to a LISTSERV mailing list to use the BBOARD account from it was subscribed to. See HELP SET BBOARD LISTSERV. - + l Fixed many bugs in POST, REPLY, and RESPOND. - -Fixed /ALL for COPY, PRINT, and EXTRACT when using NEWS groups. - -Included RMS optimizer procedure for indexed files to optimize BULLNEWS.DAT + t +Fixed /ALL for COPY, PRINT, and EXTRACT when using NEWS groups.i + u +Included RMS optimizer procedure for indexed files to optimize BULLNEWS.DATe to speed up NEWS updates. Can be used on other files (in particular BULLINF.DAT) in order to save space. Add /EDIT to BACK, NEXT, LAST, and when entering message number. - + n Modify ADD/REPLY command to local (non-NEWS) folders so if there are new -messages present, it doesn't reset the newest message count. Previously, +messages present, it doesn't reset the newest message count. Previously,o adding a message would reset the user's last read message date to that message in order to avoid notifying the user of new messages due to the user's own -message. - -Fixed code so that when reading new messages, and if READ/EDIT or DELETE/IMMED- +message. T + . +Fixed code so that when reading new messages, and if READ/EDIT or DELETE/IMMED-O IATE IS entered, a carriage return will read the next new message. Previously -the wrong message would be displayed. - +the wrong message would be displayed.S + R V 2.01 - + C Fixed many bugs associated with USENET NEWS reading feature. Added UCX interface for NEWS. -Added signature file for POST and RESPOND messages. - -Added capability to specify file name for POST, REPLY, and RESPOND. - -Added the line "In a previous message, <message-owner> wrote:" to the -beginning of a message when /EXTRACT is specified - +Added signature file for POST and RESPOND messages.e + U +Added capability to specify file name for POST, REPLY, and RESPOND.r + w +Added the line "In a previous message, <message-owner> wrote:" to theo +beginning of a message when /EXTRACT is specifiede + o Added hook for network mail to run command procedure rather then using -VMS MAIL. BULL_MAILER can be defined to point to the procedure, and it +VMS MAIL. BULL_MAILER can be defined to point to the procedure, and its is called with the username and subject as the parameters. - + i V 2.00 - + i Added USENET NEWS reading feature. - + e V 1.93 -Fixed bug which wouldn't allow a permanent message to be added by a +Fixed bug which wouldn't allow a permanent message to be added by al non-privileged user in a remote folder (the folder had been setup to allow permanent messages from non-privileged users, of course). - + U Fixed bug which causes the DELETE command not to delete a SHUTDOWN message without the use of /IMMEDIATE. - + r Fixed the algorithm which prevented duplicate notification of messages in -remote folders on different nodes, as duplication was still possible. - +remote folders on different nodes, as duplication was still possible.u + n V 1.92 - -Fixed bug which causes BULLCP to loop when trying to cleanup a folder which + l +Fixed bug which causes BULLCP to loop when trying to cleanup a folder which( has more than 127 identifiers granted access to a folder. Also correct SHOW FOLDER/FULL, which had a similar problem when trying to display the identifiers. -Fix PMDF interface to recognize to recognize PMDF_PROTOCOL. +Fix PMDF interface to recognize to recognize PMDF_PROTOCOL.t V 1.91 - + q Disallow SPAWN command for CAPTIVE account. - + s Fix MAIL command to correctly allow passing addresses with quotes, i.e. IN%"""MRL@NERUS.PFC.MIT.EDU""". - + e V 1.90 - + U SET NOTIFY now works for remote folders. - -Avoid generating notification message due to SET NOTIFY flag if the message -was broadcasted when added using ADD/BROADCAST. + / +Avoid generating notification message due to SET NOTIFY flag if the messagen +was broadcasted when added using ADD/BROADCAST.f Bug in DIR/SINCE for remote folders fixed. If no new messages were present, it would incorrectly show messages. - + i Added /FF to EXTRACT command to seperate messages in the file with form feeds. -Allow specifying CURRENT and LAST when specifying a range of messages for +Allow specifying CURRENT and LAST when specifying a range of messages fort commands that accept a range, i.e. EXTRACT 1-CURRENT, CURRENT-LAST, etc. - + , Open folder files with READONLY when not writing to them in order to avoid -changing modification date, which results in unnecessary backups. - +changing modification date, which results in unnecessary backups.& + S Modify HELP so that it won't prompt for Subtopic is there is none. - + X Prevent screen from being erased after exiting HELP. - + t Fix bug which causes CREATE/NOTIFY to crash. - + / SET NOTIFY/CLUSTER has been removed. As of VMS V5.2, it is possible to obtain the list of users logged in to all nodes of a cluster, so this qualifier is no long necessary. NOTE: You can delete all the BULL_DIR:*.NOTIFY files, as they -are no longer used. +are no longer used.r BULLETIN now will use the editor specified by the SET EDITOR command within MAIL for editing messages. Typing BACK after typing a DIRECTORY command will now show the previous -DIRECTORY display entries rather than reading the previous message. - +DIRECTORY display entries rather than reading the previous message.c + y Several bugs related to the MARK command were fixed. Also the software has been -optimized so that scanning for MARKed messages should take less time. - +optimized so that scanning for MARKed messages should take less time.. + / /EXPIRATION added to DIRECTORY command to show expiration rather than creation -date of messages. - -Any BULLETIN interactive command can be executed at DCL level by typing +date of messages.Y + m +Any BULLETIN interactive command can be executed at DCL level by typingg BULLETIN "command" or BULLETIN "command1;command2;etc.". - + 3 The CHANGE command has been modified so a range of message can be specified, i.e. /NUMBER=1-10. Also, the code incorrectly misinterpreted /TEXT as meaning -to extract the old text message, whereas it should have meant that only the +to extract the old text message, whereas it should have meant that only thes text was to be changed. This prevented a user from specifying that only the -text should be changed if that user didn't have editing enabled. This has been +text should be changed if that user didn't have editing enabled. This has beena fixed. To eliminate confusing, the /TEXT qualifier on the ADD command has been removed (previously it was a synonym for /EXTRACT). - -SHOW FOLDER/FULL display of access IDs was fixed to correctly display UICs. - -Removed security hole which occurs if you are using the old method of accessing -a remote node via /NODES (it would have required looking a the sources to find, + f +SHOW FOLDER/FULL display of access IDs was fixed to correctly display UICs.f + f +Removed security hole which occurs if you are using the old method of accessinge +a remote node via /NODES (it would have required looking a the sources to find,r which one installer did and was worried about). Because of this, if you use this old method (i.e. via BULLETIN.COM), the object BULLETIN must be installed -in the NCP database pointing to the file BULLETIN.COM, i.e. the command +in the NCP database pointing to the file BULLETIN.COM, i.e. the commandl "MCR NCP SET BULLETIN FILE directory:BULLETIN.COM NUMBER 0" must be executed during the system startup. - + i Fixed bug in /LOGIN display when erasing page if terminal is hardcopy. No -page would be erased (of course), and the next line outputted would start where -the previous line left off, rather than starting on a new line. +page would be erased (of course), and the next line outputted would start wheree +the previous line left off, rather than starting on a new line.. Added BULLETIN/WIDTH=page_width for users who have BULLETIN/LOGIN in their login procedure before the terminal is known, and whose default page width is larger (i.e. 132) than what the terminals are (i.e. 80). -Added BULLETIN/PGFLQUOTA and /WSEXTENT in order to set those quotas for the -BULLCP process. - -Added ATTACH command. +Added BULLETIN/PGFLQUOTA and /WSEXTENT in order to set those quotas for theY +BULLCP process.m + a +Added ATTACH command.j Modify SET STRIP so that it saves the date that the message was sent and leaves it at the to of the message. - -BULLETIN will search BBOARD message headers for a line that starts with -"Expires:" or "X-Expires:", followed by a date (DD MMM YYYY or similar). It if + L +BULLETIN will search BBOARD message headers for a line that starts withn +"Expires:" or "X-Expires:", followed by a date (DD MMM YYYY or similar). It ift finds that line, it will use that date as the expiration date of the message. + 2 +Added /REPLY to SEARCH command. Modified so that it's possible to abort out ofn +a /SUBJECT or /REPLY search using CTRL-C (previous possible only if searchingS +the text for a string. Also, if you hit CTRL-C at the wrong time, BULLETINd +would abort totally rather than just aborting the search). u -Added /REPLY to SEARCH command. Modified so that it's possible to abort out of -a /SUBJECT or /REPLY search using CTRL-C (previous possible only if searching -the text for a string. Also, if you hit CTRL-C at the wrong time, BULLETIN -would abort totally rather than just aborting the search). - -Added /SEARCH= /SUBJ= and /REPLY to the DIRECTORY command. Basically this is +Added /SEARCH= /SUBJ= and /REPLY to the DIRECTORY command. Basically this ish combining the DIRECTORY and SEARCH commands. - -Fixed design flaw which allowed the following to occur: If a folder is a -remote system folder, when BULLETIN/LOGIN was executed, the same messages might + 2 +Fixed design flaw which allowed the following to occur: If a folder is aa +remote system folder, when BULLETIN/LOGIN was executed, the same messages mightr be displayed on both the local and remote nodes. BULLETIN now will know that the user has seen the message on one node and will not display it if that user logs in on the other node. - -Optimized code which caused slow display of new messages when executing + i +Optimized code which caused slow display of new messages when executinge BULLETIN/LOGIN without /REVERSE for a remote folder. - -Added /PERMANENT to SET NOTIFY, SHOWNEW, BRIEF, and READNEW. The affect is -that users will not be allowed to change the setting. The main intent here + L +Added /PERMANENT to SET NOTIFY, SHOWNEW, BRIEF, and READNEW. The affect ise +that users will not be allowed to change the setting. The main intent herer was to allow the removal ofthe permanent setting of SHOWNEW from the GENERAL -folder. - -Fixed bug which would cause a SYSTEM message not to be shown if SET BRIEF was +folder.s + g +Fixed bug which would cause a SYSTEM message not to be shown if SET BRIEF wash selected for that folder, and a non-SYSTEM message was also present. - -Added SET CONTINUOUS_BRIEF. This causes the SET BRIEF setting to show that -there are unread new messages every time BULLETIN/LOGIN is executed, rather + h +Added SET CONTINUOUS_BRIEF. This causes the SET BRIEF setting to show thats +there are unread new messages every time BULLETIN/LOGIN is executed, rathern than just the one time. The BRIEF notification code has also been optimized so that it'll take less time to notify you of new messages. -A major bug was fixed which was introduced in previous mods to speed up +A major bug was fixed which was introduced in previous mods to speed upL BULLETIN/LOGIN. The effect is that no notifications will appear for certain folders via BULLETIN/LOGIN. This would only happen if a folder was removed at some time. diff --git a/batch/seed/2025-announce.txt b/batch/seed/2025-announce.txt new file mode 100644 index 0000000000000000000000000000000000000000..935e50fd4d6fc7be23387f7da96fbeb01e717945 --- /dev/null +++ b/batch/seed/2025-announce.txt @@ -0,0 +1,50 @@ +From: V510UEFS "Kevin Lyda" +Date: 16-MAY-2025 16:13 +Subj: Go version of BULLETIN + +This is the Go port of BULLETIN based on the original FORTRAN BULLETIN +at version 2.07. + +The Go port lacks news, mailing list and mail functionality. In addition +remote folders are not supported. Commands and flags related to those +haven't been implemented. In addition, it just uses a basic text editor, +not an editor like EDT. Though I'm open to implementing one. + +However the rest of BULLETIN works. There are message boards, you can +add and read messages in them. Not all the commands work yet, but they +are being added. + +A mail system like VMS mail will be added. Additional enhancements +being considered are: + + * Tab completion. + * Code highlighting. + * Adding ssh keys via gitlab/github/codeberg. + +All of this should work as an unprivileged user and only need a single +binary that is started via ssh connections. + +Future enhancements that might need a daemon to run (as the unprivileged +user): + + * Remote folder support - possibly using something like activitypub? + * An account signup system accessible via telnet. + +To install this just run the following (assumes the go bin directory is +in your path): + + bulletin$ go install git.lyda.ie:kevin/bulletin@latest + bulletin$ bulletin -u SYSTEM -b install + +It will ask you for an initial account and seed the GENERAL board with +historical messages and this one. + +It will create a crontab for the user it is run as and the following files: + + * ~/.bulletin-installed - a touch file to make sure install only + runs once. + * ~/.local/share/BULLETIN/bulletin.db - contains all the messages + and users. + * ~/.ssh/authorized_keys - keys are added and removed from here to + let users connect. + diff --git a/pager/pager.go b/pager/pager.go index c2a0c4fdfdbed2b0eda1858dc630ddb2958b24f8..ce7d0d4c83d54cd14057a1ad89d83637c8153e29 100644 --- a/pager/pager.go +++ b/pager/pager.go @@ -3,3 +3,90 @@ Package pager implements the pager. This is used for any large block of text that bulletin needs to show. */ package pager + +import ( + "fmt" + "os" + "strings" + + "golang.org/x/sys/unix" + "golang.org/x/term" +) + +func getTerminalHeight() (int, error) { + ws, err := unix.IoctlGetWinsize(0, unix.TIOCGWINSZ) + if err != nil { + return 0, err + } + return int(ws.Row), nil +} + +// readKey reads a single key without needing Enter +func readKey() (byte, error) { + var buf [1]byte + _, err := os.Stdin.Read(buf[:]) + if err != nil { + return 0, err + } + return buf[0], nil +} + +// Pager pages through a string. +func Pager(content string) bool { + lines := strings.Split(content, "\n") + totalLines := len(lines) + + height, err := getTerminalHeight() + if err != nil { + fmt.Printf("%s\n", content) + return true + } + pageSize := height - 1 // Reserve last line for prompt. + + // Set terminal raw mode. + oldState, err := term.MakeRaw(int(os.Stdin.Fd())) + if err != nil { + fmt.Printf("%s\n", content) + return true + } + defer term.Restore(int(os.Stdin.Fd()), oldState) + + start := 0 + for { + // State for where we are. + if start < 0 { + start = 0 + } + end := start + pageSize + if end > totalLines { + end = totalLines + } + + // Clear prompt and display the chunk. + fmt.Print("\r \r") + fmt.Print(strings.Join(lines[start:end], "\r\n")) + + if end == totalLines { + fmt.Println("\r") // move to next line after paging ends + return true + } + + percent := (end * 100) / totalLines + fmt.Printf("\r\nMore %d%%", percent) + + key, err := readKey() + if err != nil { + return false + } + + switch key { + case ' ': // page down + start += pageSize + case 'b': // page up + start -= pageSize + case 'q', 'Q': // quit + fmt.Println("\r") // move cursor to next line + return false + } + } +} diff --git a/pager/tview.go b/pager/tview.go deleted file mode 100644 index fd2634624acd32961d448f9b2d492bfc60355629..0000000000000000000000000000000000000000 --- a/pager/tview.go +++ /dev/null @@ -1,59 +0,0 @@ -package pager - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// Pager is the pager for text data. -func Pager(text string) error { - theme := tview.Theme{ - PrimitiveBackgroundColor: tcell.ColorDefault, - ContrastBackgroundColor: tcell.ColorDefault, - MoreContrastBackgroundColor: tcell.ColorDefault, - BorderColor: tcell.ColorDefault, - TitleColor: tcell.ColorDefault, - GraphicsColor: tcell.ColorDefault, - PrimaryTextColor: tcell.ColorDefault, - SecondaryTextColor: tcell.ColorDefault, - TertiaryTextColor: tcell.ColorDefault, - InverseTextColor: tcell.ColorDefault, - ContrastSecondaryTextColor: tcell.ColorDefault, - } - tview.Styles = theme - app := tview.NewApplication() - - page := tview.NewTextView(). - SetWrap(true). - SetScrollable(true). - SetChangedFunc(func() { - app.Draw() - }). - SetText(text) - // TODO: this doesn't seem to be working. - page.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { - switch event.Key() { - case tcell.KeyRune: - switch event.Rune() { - case 'B', 'b': - _, y := page.GetScrollOffset() - _, _, _, height := page.GetInnerRect() - page.ScrollTo(0, max(y+height, 0)) - return nil - case ' ': - _, y := page.GetScrollOffset() - _, _, _, height := page.GetInnerRect() - page.ScrollTo(0, y+height) - return nil - case 'Q', 'q': - app.Stop() - return nil - } - case tcell.KeyEsc, tcell.KeyCtrlC: - app.Stop() - return nil - } - return event - }) - return app.SetRoot(page, true).Run() -} diff --git a/repl/help.go b/repl/help.go index b1fd35b8cf5a36a0dae4495a8c13fa8304dbf5b5..0b39ea9003c0b058c2ec3e928a10fa446908f3fb 100644 --- a/repl/help.go +++ b/repl/help.go @@ -7,6 +7,7 @@ import ( "strings" "git.lyda.ie/kevin/bulletin/dclish" + "git.lyda.ie/kevin/bulletin/pager" ) var helpmap = map[string]string{ @@ -181,6 +182,6 @@ func ActionHelp(cmd *dclish.Command) error { } } - fmt.Printf("\n%s\n\n", helptext) + pager.Pager(helptext) return nil } diff --git a/repl/messages.go b/repl/messages.go index 3368838f1ddd7c88e076d3a0fb542c84143d80e1..13b976325bbb4f50d4ea8e2b47a0cdbc026828c4 100644 --- a/repl/messages.go +++ b/repl/messages.go @@ -39,10 +39,12 @@ func ActionDirectory(cmd *dclish.Command) error { fmt.Println("There are no messages present.") return nil } - fmt.Printf("%4s %-43s %-12s %-10s\n", "#", "Subject", "From", "Date") + buf := strings.Builder{} + buf.WriteString(fmt.Sprintf("%4s %-43s %-12s %-10s\n", "#", "Subject", "From", "Date")) for _, msg := range msgs { - fmt.Printf("%s\n", msg.OneLine(showExpiration)) + buf.WriteString(fmt.Sprint(msg.OneLine(showExpiration))) } + pager.Pager(buf.String()) return nil } diff --git a/storage/display.go b/storage/display.go index d01d7f28ed8a7ca698aa87fcdb133faf76e739f5..cf230417b788eb2dc2caf340da33df43db40fbf3 100644 --- a/storage/display.go +++ b/storage/display.go @@ -30,8 +30,8 @@ func (m *Message) OneLine(expire bool) string { } else { t = m.CreateAt } - ts := t.Format("2006-05-04 15:02:01") - return fmt.Sprintf("%4d %-43s %-12s %-10s\n", m.ID, m.Subject, m.Author, ts) + ts := t.Format("2006-01-02 15:04:05") + return fmt.Sprintf("%4d %-43.43s %-12.12s %-10s\n", m.ID, m.Subject, m.Author, ts) } // String displays a user (mainly used for debugging). diff --git a/storage/queries/seed.sql b/storage/queries/seed.sql index d0d3c4638baecd0026632442ec400aa95bccc572..27e3f001b57b0604e444c73cce4049e573549a68 100644 --- a/storage/queries/seed.sql +++ b/storage/queries/seed.sql @@ -12,7 +12,7 @@ -- name: SeedCreateMessage :exec INSERT INTO messages ( id, - folder, author, subject, message, permanent, expiration + folder, author, subject, message, permanent, create_at, update_at, expiration ) VALUES ( - (SELECT COALESCE(MAX(id), 0) + 1 FROM messages AS m WHERE m.folder = ?), - ?, 'SYSTEM', ?, ?, 1, ?); + (SELECT COALESCE(MAX(id), 0) + 1 FROM messages AS m WHERE m.folder = ?1), + ?1, ?2, ?3, ?4, 1, ?5, ?5, ?6); diff --git a/storage/queries/standard.sql b/storage/queries/standard.sql index a341d18ee791881d75c87e42594b880625ecef6c..8edc1bb19ee80b6272f4838f16f00c480fc28023 100644 --- a/storage/queries/standard.sql +++ b/storage/queries/standard.sql @@ -35,7 +35,7 @@ DELETE FROM owners WHERE folder = ? AND login = ?; INSERT INTO messages (id, folder) VALUES (?, ?); -- name: ListMessages :many -SELECT * FROM messages WHERE folder = ?; +SELECT * FROM messages WHERE folder = ? ORDER BY id; -- name: GetMessage :one SELECT * FROM messages WHERE id = ? AND folder = ?; diff --git a/storage/seed.sql.go b/storage/seed.sql.go index 11e3cb9f233b189136e2085395ec6d9cf89df058..c8fcbfd8c7579f354bc914efa6dfa76b6b791551 100644 --- a/storage/seed.sql.go +++ b/storage/seed.sql.go @@ -13,26 +13,28 @@ import ( const seedCreateMessage = `-- name: SeedCreateMessage :exec INSERT INTO messages ( id, - folder, author, subject, message, permanent, expiration + folder, author, subject, message, permanent, create_at, update_at, expiration ) VALUES ( - (SELECT COALESCE(MAX(id), 0) + 1 FROM messages AS m WHERE m.folder = ?), - ?, 'SYSTEM', ?, ?, 1, ?) + (SELECT COALESCE(MAX(id), 0) + 1 FROM messages AS m WHERE m.folder = ?1), + ?1, ?2, ?3, ?4, 1, ?5, ?5, ?6) ` type SeedCreateMessageParams struct { Folder string - Folder_2 string + Author string Subject string Message string + CreateAt time.Time Expiration time.Time } func (q *Queries) SeedCreateMessage(ctx context.Context, arg SeedCreateMessageParams) error { _, err := q.db.ExecContext(ctx, seedCreateMessage, arg.Folder, - arg.Folder_2, + arg.Author, arg.Subject, arg.Message, + arg.CreateAt, arg.Expiration, ) return err diff --git a/storage/standard.sql.go b/storage/standard.sql.go index b192647d0836e26f743e4a245bbddcbbf3902d3a..0c05956a06a2790d370fe0db195d9ac612319add 100644 --- a/storage/standard.sql.go +++ b/storage/standard.sql.go @@ -535,7 +535,7 @@ func (q *Queries) ListMark(ctx context.Context) ([]Mark, error) { } const listMessages = `-- name: ListMessages :many -SELECT id, folder, author, subject, message, permanent, shutdown, expiration, create_at, update_at FROM messages WHERE folder = ? +SELECT id, folder, author, subject, message, permanent, shutdown, expiration, create_at, update_at FROM messages WHERE folder = ? ORDER BY id ` func (q *Queries) ListMessages(ctx context.Context, folder string) ([]Message, error) {