From f07614424980336b1fdbe852dd2ecee2d337a93c Mon Sep 17 00:00:00 2001 From: Izaya Date: Fri, 9 Mar 2018 19:41:00 +1100 Subject: [PATCH] Documentation updates. --- MMail/MMail-protocol.md | 24 ++++++++++++++++++++++++ MMail/OpenOS/usr/man/mmail-send | 18 ++++++++++++++++++ OpenOS/usr/man/{minitel => }/minitel | 0 programs.cfg | 3 ++- 4 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 MMail/MMail-protocol.md create mode 100644 MMail/OpenOS/usr/man/mmail-send rename OpenOS/usr/man/{minitel => }/minitel (100%) diff --git a/MMail/MMail-protocol.md b/MMail/MMail-protocol.md new file mode 100644 index 0000000..1b231f1 --- /dev/null +++ b/MMail/MMail-protocol.md @@ -0,0 +1,24 @@ +# MMail - simple mail protocol + +MMail, or Minitel Mail, is a simple electronic mail protocol for Minitel networks, using port 25. + +## Messages + +A message must contain: + + - A line with `From: ` and an address, specifying where this mail came from, in the form of `user@host` + - A line with `To: ` and an address, specifying to whom this mail is addressed to, in the form of `user@host` + - A line with `Subject: ` and a subject line, specifying the subject of the message. + +The entire exchange will be written to the file, but those lines are required. + +## Sending + +Sending a MMail message is simple: + +1. The client opens a connection to the server on the MMail port. +2. The client sends the header, with To, From and Subject lines. +3. The client sends the message contents. +4. The client closes the connection. + +The server can then decide what to do with the message. diff --git a/MMail/OpenOS/usr/man/mmail-send b/MMail/OpenOS/usr/man/mmail-send new file mode 100644 index 0000000..12348e7 --- /dev/null +++ b/MMail/OpenOS/usr/man/mmail-send @@ -0,0 +1,18 @@ +NAME + mmail-send - send mmail-compatible messages from the command line + +SYNOPSIS + mmail-send [TO] [FROM] [SUBJECT] [PATH] + +DESCRIPTION + `mmail-send` sends mail over the Minitel network to MMail-compatible mail servers. + +EXAMPLES + mmail-send alice@host bob "Example message" /usr/man/mmail-send + Sends the user alice a message addressed from bob, with subject 'Example message', containing the contents of this manual page. + + mmail-send alice@host + Sends the user alice a message, and prompts for all the other information. + + mmail-send + Prompts for all required information (to, from, subject, message) diff --git a/OpenOS/usr/man/minitel/minitel b/OpenOS/usr/man/minitel similarity index 100% rename from OpenOS/usr/man/minitel/minitel rename to OpenOS/usr/man/minitel diff --git a/programs.cfg b/programs.cfg index 615817a..b1ee70b 100644 --- a/programs.cfg +++ b/programs.cfg @@ -3,7 +3,7 @@ files = { ["master/OpenOS/etc/rc.d/minitel.lua"] = "//etc/rc.d", ["master/OpenOS/usr/lib/net.lua"] = "/lib", - ["master/OpenOS/usr/man/minitel/minitel"] = "/usr/man", + ["master/OpenOS/usr/man/minitel"] = "/usr/man", }, name = "Minitel", description = "Simple and powerful networking stack", @@ -49,6 +49,7 @@ ["mmail-send"] = { files = { ["master/MMail/OpenOS/usr/bin/mmail-send.lua"] = "/bin" + ["master/MMail/OpenOS/usr/man/mmail-send"] = "/man" }, dependencies = { ["minitel"] = ""