Complete.Org: Mailing Lists: Archives: gopher: October 2002:
[gopher] Gopher+ Uploading
Home

[gopher] Gopher+ Uploading

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: gopher@xxxxxxxxxxxx
Subject: [gopher] Gopher+ Uploading
From: Timm Murray <hardburn@xxxxxxxxxx>
Date: Mon, 21 Oct 2002 18:56:25 -0500
Reply-to: gopher@xxxxxxxxxxxx

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Here's the start of a standard on uploading using Gopher+.  Unlike the 
authentication proposal, this one actually uses +ASK in a compatible way.


Gopher+ Uploading

By Timm Murray

This document describes a means of uploading files to a Gopher server using 
Gopher+ 
attributes.

In breaking with Gopher tradition, this document uses '\t' to denote a 
tab, '\r' to denote a cariage return, and '\n' to denote a newline.  
'C:' is a line of text sent by the client, and 'S: is a line sent by the 
server.  


MENU SELECTOR

'u' is defined as being the item type indicating an upload selector.  It is 
recommended 
that any upload fields use Gopher+ Authentication before allowing an upload.

Example:

uUpload a file\t/incoming\thost\tport\t*\r\n

Clients should expect to go through the +ASK exchange for the upload even if 
a '?' is not present in the Gopher+ section.


PREFORMING THE UPLOAD

After the optional authentication exchange, the client sends meta information 
about 
the file being uploaded.  The following exchange takes place:

C: [selector string] \r\n
S: +ASK \r\n
S: Ask: Size of file (bytes)? \r\n
S: Ask: Selector string to put under? \r\n
S: AskF: File to send \r\n
S: AskL: Additional information \r\n
C: <size of file, in bytes> \r\n
C: <description> \r\n
C: <selector string> \r\n
C: <filename> \r\n
C: <additional info> \r\n
C: <the file itself>

In keeping with Gopher+, a size of -1 means "read data until a period on a 
line 
by itself".  A size of -2 means "read data until I close the connection" (this 
meathod is strongly discouraged).  Any size of >= 0 means "read this many 
bytes, 
then close the connection".

The "description" sent MAY be used by servers for the 'user' field in menu 
entries.  
Clients SHOULD keep this under 70 characters, in keeping with Gopher tradition 
for 
'user' fields.  It MUST NOT contain any tab characters.

The "selector string" sent for the file MAY be ignored by servers.  It is used 
only as a 
guide for servers that choose to use it.

The filename sent MUST be ignored by servers.  The "AskF" statement mearly 
provides the 
client with a chance to open a file dialog box so the user can choose the file 
to send 
(or however else the client wishes to handle it).  Clients MAY send an empty 
string 
for the filename.

["Additional info" section]


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.4 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iEYEARECAAYFAj20lCsACgkQqpueKcacfLTdagCguRtsvcY2WK1oN9qPuZP1peWe
8K4AoImav/1PR8igsulTeTPiy/g/cV7A
=LgIu
-----END PGP SIGNATURE-----



[Prev in Thread] Current Thread [Next in Thread]
  • [gopher] Gopher+ Uploading, Timm Murray <=