This is an old revision of the document!
QWK is a common protocol for offline message readers and BBS software. This is a quick synopsis on how to implement support into your product (reader, processor, or BBS).
Even though the files are zipped, the file extension is renamed to .QWK for the download from the BBS software, and .REP for the zip uploading messages to the BBS.
Each line is CRLF 0x0D 0x0A (#13#10) (\r\n) delimited.
Line 1 | BBS name |
---|---|
Line 2 | BBS city and state |
Line 3 | BBS phone number |
Line 4 | BBS Sysop name |
Line 5 | Mail door registration #, BBSID |
Line 6 | Mail packet creation time |
Line 7 | User name (upper case) |
Line 8 | Name of menu for Qmail, blank if none |
Line 9 | ? Seem to be always zero |
Line 10 | Total number of messages in packet |
Line 11 | Total number of conference minus 1 |
Line 12 | 1st conf. number |
Line 13 | 1st conf. name (13 characters or less) Modern QWK BBSes send Full Conference Names |
Line 14 | next conf. number |
Line 15 | next conf. name (13 characters or less) Modern QWK BBSes send Full Conference Names |
2nd from last | Welcome screen file |
Next from last | BBS news file |
Last Line | Log off screen |
Some BBS systems will have additional lines after those above:
Next Section | ? always a zero |
---|---|
Screen length on the BBS | 25 |
User name in uppercase | OZZ NIXON |
User first name in mixed case | Ozz |
User city information | Crestview, Fl |
User data phone number | 850-123-4567 |
User home phone number | 850-555-1212 |
Security level | 110 |
Expiration date | 00-00-00 |
Last log on date | 11-16-19 |
Last log on time | 13:24:59 |
Log on count | 134 |
Current conference number on the BBS | 8 |
Total KB downloaded | 0 |
Download count | 0 |
Total KB uploaded | 0 |
Upload count | 0 |
Minutes per day | 459 |
Minutes remaining today | 439 |
Minutes used this call | 20 |
Max. download KB per day | 10240000 |
Remaining KB today | 10240000 |
KB downloaded today | 0 |
Current time on BBS | 13:27:03 |
Current date on BBS | 11-17-19 |
BBS network tag-line | FSXNet BBS |
Messages file starts with a 128 byte product information. Like:
That block is followed by messages using PCBoard 12.0 format.
In Pascal:
type MsgHeaderRec=Packed Record TypeID:String[1]; MsgID:String[7]; DateStr:String[8]; TimeStr:String[5]; MsgTo:String[25]; MsgFrom:String[25]; MsgSubj:String[25]; Reserved:String[12]; MsgRefer:String[8]; Chunks:Longint; Attributes:String[6]; End;
Of course to populate that structure you will BlockRead 128 bytes, them move from offset to length to each field.
Offset | Length | Description | ||
---|---|---|---|---|
1 | 1 | Message status flag (unsigned character) | ||
#32 = (space) public, unread | ||||
'-' = public, read | ||||
'+' = private, unread | ||||
'*' = private, read | ||||
'~' = comment to Sysop, unread | ||||
'`' = comment to Sysop, read | ||||
'%' = password protected, unread | ||||
#94 = (carrot) password protected, read | ||||
'!' = group password, unread | ||||
'#' = group password, read | ||||
'$' = group password to all | ||||
2 | 7 | Message number (in ASCII) | ||
9 | 8 | Date (mm-dd-yy, in ASCII) | ||
17 | 5 | Time (24 hour hh:mm, in ASCII) | ||
22 | 25 | To (uppercase, left justified) | ||
47 | 25 | From (uppercase, left justified) | ||
72 | 25 | Subject of message (mixed case) | ||
97 | 12 | Password (space filled) | ||
109 | 8 | Reference message number (in ASCII) | ||
117 | 6 | Number of 128-bytes blocks in message [1] | ||
123 | 1 | Flag [2] | ||
124 | 2 | Conference number (unsigned word) | ||
126 | 2 | Logical message number in the current packet [3] | ||
128 | 1 | Indicates whether the message has a network tag-line or not. [4] |
[1] = (including the header, in ASCII; the lowest value should be 2, header plus one block message; this number may not be left flushed within the field)
[2] = (ASCII 225 means message is active; ASCII 226 means this message is to be killed)
[3] = this number will be 1 for the first message, 2 for the second, and so on. (unsigned word)
[4] = A value of '*' indicates that a network tag-line is present; a value of ' ' (space) indicates there isn't one. Messages sent to readers (non-net-status) generally leave this as a space. Only network software need this information.