News for hackers. Stuff that matters.
Re:Closing web browser windows doesn't close connections by ilaksh on Tuesday March 23, 2021 @09:52PM (#26562649)
If this type of BS bothers you, check out the Gemini protocol. Basically a very simple browser concept that cuts out all of the BS. No JavaScript, cookies, secret connections, ads, etc. It's mainly just a simplified markdown over TLS.

Because it's so simple, it is possible for any programmer to make their own client. Unike with web browsers which require you to basically implement an entire operating system. That means if you don't like something a client is doing, it's not a problem finding another good one.

Re:Closing web browser windows doesn't close connections by woodruffw on Tuesday March 23, 2021 @10:21PM (#26562836)
I'll admit that I haven't looked closely at Gemini, but I don't understand how it solves this qua protocol: keepalives and socket reuse are an extension of HTTP that every major client agreed upon as a performance win, and Gemini has response headers[1] that clients could easily use to advertise similar functionality.

Same goes for any number of terrible parts of the modern web: the fact that Gemini doesn't have them now is a function of its niche status and community, not some fundamental restriction. That's how HTTP 1.0 started as well.

[1]: https://gemini.circumlunar.space/docs/specification.html

Re:Closing web browser windows doesn't close connections by Arnavion on Tuesday March 23, 2021 @11:32PM (#26563275)
There's no content-length header in the response. The server has to close the connection to signal the end of the response body.
Re:Closing web browser windows doesn't close connections by woodruffw on Tuesday March 23, 2021 @11:51PM (#26563406)
> There's no content-length header in the response.

I'm not sure I understand -- what's stopping me from adding one? One of Gemini's design goals seems to be client diversity and allowing clients to interpret responses on their own terms.

Edit: To be even more explicit about it: the Gemini specification doesn't include any language that says that clients and servers MUST not use the "meta" field or their response bodies to negotiate additional functionality. The observation that nobody in the Gemini ecosystem currently does is tantamount to the observation that nobody has bothered to yet, just like with HTTP 1.0.

Re:Closing web browser windows doesn't close connections by Arnavion on Wednesday March 24, 2021 @12:58AM (#26563754)
>One of Gemini's design goals seems to be client diversity and allowing clients to interpret responses on their own terms.

No, the design goal is the exact opposite of that. The protocol is intentionally designed to be non-extensible so that other features that go against its spirit are not added.

You can of course add a content-length header to your server and write your own client that parses it, but you wouldn't be writing a Gemini server and client any more.

https://gemini.circumlunar.space/docs/faq.gmi goes in great length about this in section 2, and even specifically about (the lack of) content-length in section 2.12

Re:Closing web browser windows doesn't close connections by speexmex on Tuesday March 23, 2021 @10:45PM (#26562987)
It's not clear what problem Gemini solves.

Some webmaster willing to host a Gemini server could also setup an nginx serving static markdown files with no cookies/js/... and the privacy conscious client could use lynx to browse it.

Re:Closing web browser windows doesn't close connections by aidenn0 on Tuesday March 23, 2021 @11:14PM (#26563158)
Tell me without clicking if an http(s) uri requires javascript and/or a graphical browser to render properly. Then tell me the same thing for a gemini uri.
Re:Closing web browser windows doesn't close connections by Dylan16807 on Wednesday March 24, 2021 @12:00AM (#26563465)
I can go host a gemini server with javascript out of spite if you want.
Re:Closing web browser windows doesn't close connections by aidenn0 on Wednesday March 24, 2021 @01:03PM (#26569975)
There is no expectation of a gemini server that it can run arbitrary code on the client. There is for an http server. This changes what works and what doesn't work.
Re:Closing web browser windows doesn't close connections by Dylan16807 on Wednesday March 24, 2021 @01:58PM (#26570761)
Yeah but there's also no expectation that images will work, so "this document won't work right unless you have certain client features" wouldn't even be unique.

So I disagree with your earlier statement even if we exclude javascript. No, I can't tell you without clicking if a gemini URL requires a graphical browser to render properly. Without even being cheeky or pedantic.

Re:Closing web browser windows doesn't close connections by agumonkey on Tuesday March 23, 2021 @10:23PM (#26562850)
I tried it, it's somehow nice but:

- not fast enough yet (I expect leaner protocol and data => instant)

- navigation is still crude, directories and text are.. not ideal so far

I'm open minded, it's not a blind critic of gemini (I wish projects like that to succeed, and for instance, I use dillo regularly) but using it threw me off a little bit.

Re:Closing web browser windows doesn't close connections by Arnavion on Wednesday March 24, 2021 @04:58PM (#26572810)
A comparative HTTP page ("comparative" == "same text content, no non-text content, no XHR or JS to delay-load content") is almost always going to be faster. Every gemini page request has to set up a brand new connection, ie brand new TCP handshake and TLS handshake.
Re:Closing web browser windows doesn't close connections by duncan-donuts on Tuesday March 23, 2021 @09:57PM (#26562689)
I haven’t looked at the protocol but how does it prevent ads?
Re:Closing web browser windows doesn't close connections by ilaksh on Tuesday March 23, 2021 @10:01PM (#26562714)
Well, maybe look at the protocol. It doesn't strictly prevent ads, but it makes it a lot harder. And for example since there is no JavaScript, there is no way to pop open another window, or freeze up the page loading an ad. In fact, most clients don't even display images inline, since images aren't part of the spec. There are no cookies for tracking because there are no cookies.