Complete.Org: Mailing Lists: Archives: gopher: January 2009:
[gopher] Re: How to handle lines beginning by a dot?
Home

[gopher] Re: How to handle lines beginning by a dot?

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: gopher@xxxxxxxxxxxx
Subject: [gopher] Re: How to handle lines beginning by a dot?
From: Matjaž Mešnjak <matjaz85@xxxxxxxxx>
Date: Wed, 28 Jan 2009 23:18:10 +0100
Reply-to: gopher@xxxxxxxxxxxx

2009/1/28 Mateusz Viste <mateusz@xxxxxxxxxxxxxxxx>
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On Wednesday 28 January 2009 22:29, Matja=BE Me=B9njak wrote:
> > clients will terminate the connection when they find <cr><lf>.<cr><lf> =
(at
> > least WSGopher and my Gopher Client). The line ".Blah!" can be sent wit=
hout
> > modifications.
>
> That what I think, too... But then I do not understant why the RFC tells =
us that "Lines beginning with periods must be prepended with an extra perio=
d"... Have I missed something?

I tested this with WSGopher:

test<cr><lf>
.abcd<cr><lf>
..<cr><lf>
.<space>123321<cr><lf>
.

This is the output:

test
.abcd
..
. 123321

I am currently writing a client and a server and in the process I got
the feeling that RFC is more like a gudeline than actual rule ... Some
servers don't even send newline+dot after the menu - that breaks
WSGopher for example. I guess the best way is to try with a couple of
clients and if it works than its OK.

>
> > If the text file contains "<cr><lf>.<cr><lf>" mail client would transfo=
rm it
> > to "<cr><lf>..<cr><lf>", but that's not the case with gopher. For text =
files
> > you could modify it to "<cr><lf>.<space><cr><lf>"
>
> That's a good idea, indeed. I have added that to my todo list for the nex=
t version of my gopher server :-)
>
> > The problem could
> > be with binary files that contain "<cr><lf>.<cr><lf>" - but the clients=
 that
> > I tried, downloaded the binary file correctly when it was sent as raw d=
ata -
> > without "<cr><lf>.<cr><lf>" on the end.
>
> That's rather normal - binary data has no "<cr><lf>.<cr><lf>" terminator,=
 it just listens until the connection is closed by the server, so I would s=
ay that there's no surprise there...
> By the way, I noticed that some Gopher clients (at least Firefox and Lynx=
) are displaying the "dot terminator" of text files just as it would be par=
t of the document. Too bad for them :)

For Firefox, try this add-on http://gopher.floodgap.com/overbite/
It makes Firefox gopher experience much better.

>
> Best regard,
> Mateusz Viste
> - --
> You'll find my public OpenPGP key at http://www.viste-family.net/mateusz/=
pub_key
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2.0.9 (GNU/Linux)
>
> iQEcBAEBAgAGBQJJgNMNAAoJEC30Ty9xnkvbfqkH/3catSVEhIkfyGDbhnbDOSTs
> x7bZ4tTWENQd4/M60Su3/rHqO39Okdp32qRSosU6W2hzQUa9Lonk0VtHziKUgcE+
> eD93+Ui4Wjr2qXQK4i5ohEeDCp6iaRJ+6H6qBFb8VE9vct5EmHcu3ul01T+RM1SE
> Ax1Yosd0slnjabiC1N9aXIig9TbsjN856dXDHWAvO4Hs4f9xnnwFrZHxpwSvorT5
> gYum4lnmb1Rm2wRoheubPzjCOzHmPqK1ZqQnH3TJn44YoVrq0/T6mKG3Yc0LhT8g
> nVGWsHwSHjKHE1eK6qVuRDlI4+GB4lHH/cmcI05oB5GIcBtYnY8D7PaIMB7OaNA=3D
> =3DSo1I
> -----END PGP SIGNATURE-----
>
>

Matjaz



[Prev in Thread] Current Thread [Next in Thread]