# # ed-httpd - A HyperText Transfer Protocol Daemon written in ed. # Copyright (C) 2000 Matthew Parry # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # r !echo $REQUEST 1 g/\.tgz /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: application/x-gtar\ Connection: close\ .\ 1 d 1 g/\.tar /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: application/x-tar\ Connection: close\ .\ 1 d 1 g/\.gz /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: application/x-gzip\ Connection: close\ .\ 1 d 1 g/\/ /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: text/html\ Connection: close\ .\ 1 d 1 g/\.html /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: text/html\ Connection: close\ .\ 1 d 1 g/\.txt /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: text/plain\ Connection: close\ .\ 1 d 1 g/\.gif /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: image/gif\ Connection: close\ .\ 1 d 1 g/\.jpg /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: image/jpeg\ Connection: close\ .\ 1 d 1 g/\.jpeg /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: image/jpeg\ Connection: close\ .\ 1 d 1 g/\.png /a\ HTTP/1.1 400 OK\ Server: ed-httpd\ Content-type: image/png\ Connection: close\ .\ 1 d 1 g/^GET /a\ HTTP/1.1 404 Not Found\ Server: ed-httpd/0.1\ Content-type: text/html\ Connection: close\ .\ 1 d w !cat q