(b) The well-tempered server ought to send "text" (unless a file
must be transferred as raw binary). Should this text include
tabs, formfeeds, frufru? Probably not, but rude servers will
probably send them anyway. Publishers of documents should be
given simple tools (filters) that will alert them if there are any
funny characters in the documents they wish to publish, and give
them the opportunity to strip the questionable characters out; the
publisher may well refuse.
(c) The well-tempered client should do something reasonable with
funny characters received in text; filter them out, leave them in,
whatever.
RFC 1436 Gopher March 1993
Appendix
Paul's NQBNF (Not Quite BNF) for the Gopher Protocol.
Note: This is modified BNF (as used by the Pascal people) with a few
English modifiers thrown in. Stuff enclosed in '{}' can be
repeated zero or more times. Stuff in '[]' denotes a set of
items. The '-' operator denotes set subtraction.
Directory Entity
CR-LF ::= ASCII Carriage Return Character followed by Line Feed
character.
Tab ::= ASCII Tab character.
NUL ::= ASCII NUL character.
UNASCII ::= ASCII - [Tab CR-LF NUL].
Lastline ::= '.'CR-LF.
TextBlock ::= Block of ASCII text not containing Lastline pattern.
Type ::= UNASCII.
RedType ::= '+'.
User_Name ::= {UNASCII}.
Selector ::= {UNASCII}.
Host ::= {{UNASCII - ['.']} '.'} {UNASCII - ['.']}.
Note: This is a Fully Qualified Domain Name as defined in RFC 1034.
(e.g., gopher.micro.umn.edu) Hosts that have a CR-LF
TAB or NUL in their name get what they deserve.
Digit ::= '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' .
DigitSeq ::= digit {digit}.
Port ::= DigitSeq.
Note: Port corresponds the the TCP Port Number, its value should
be in the range [0..65535]; port 70 is officially assigned
to gopher.
RFC 1436 Gopher March 1993
DirEntity ::= Type User_Name Tab Selector Tab Host Tab Port CR-LF
{RedType User_Name Tab Selector Tab Host Tab Port CR-LF}
Notes:
It is *highly* recommended that the User_Name field contain only
printable characters, since many different clients will be using
it. However if eight bit characters are used, the characters
should conform with the ISO Latin1 Character Set. The length of
the User displayable line should be less than 70 Characters; longer
lines may not fit across some screens.
The Selector string should be no longer than 255 characters.
Menu Entity
Menu ::= {DirEntity} Lastline.
=7= |