You know you've been working with ASCII for a long time when you can automatically unescape the title... and then pause, considering whether to unescape again.
I think reading the comments on that bug is also rather enlightening; points of note include a 62-level-deep stack trace, comments to the effect of "we don't know what the bug is/how this is supposed to work", and discussions about whether escaping multiple times is the solution (absolutely not!) https://tools.ietf.org/html/rfc3986#section-2.4 Implementations must not percent-encode or decode the same string more than once, as decoding an already decoded string might lead to misinterpreting a percent data octet as the beginning of a percent-encoding, or vice versa in the case of percent-encoding an already percent-encoded string. Seriously, I'm quite surprised that basic URL handling is still a problem. Making a game to bring this to the attention of a wider audience is certainly a good idea.
> Recursing is definitely not the answer, yet it gets brought up a lot.
Speaking as someone with an apostrophe in his name, I'm not sure whether this makes me want to chuckle and reach for the popcorn, or bang my head against the desk. The answer to multiple (un-)escaping bugs is never recursion.
It's surprising that this issue was brought up multiple times as a bug, but wasn't taken seriously until it got special attention. This bug is definitely notorious, I wonder setting a similar URL as the homepage of Chrome will cause Chrome to continuously crash and make it useless.
The crash was definitely not there in the beginning, since I happened to have Chromium 22 (from 2012 - when I first tried it), and although it doesn't crash with %%30%30, it also refuses to visit such a URL. Someone with suitable tools should be able to do some bisection to narrow down exactly when it was introduced.
> Seriously, I'm quite surprised that basic URL handling is still a problem. Making a game to bring this to the attention of a wider audience is certainly a good idea.
I think the problem is that a spec exists, but existing browser incorrectly implemented it (hello Netscape), and given their prevalence browsers are stuck with weird hacks so that existing websites continue to work. In particular around percent escapes there's lots of trouble. Nothing really specs the encoding to be used for those percent escapes (the RFC only has some odd notes on encodings), and there's a whole bunch of odd behaviours, e.g. how characters are handled when pasting a URL into an address bar vs having it as an href on a web page.
Slack's desktop apps are HTML5 webapps wrapped inside native desktop wrappers. Specifically, Slack uses Github's Electron (formerly, Atom Shell) which is basically Chromium. The desktop app is a webpage inside Chromium.
Yeah, I strenuously object to the fad of calling wrapped web pages 'native apps'. They get zero benefits that would normally accrue to real native apps. They just launch 'as if' they were native.
Well, the benefits of Electron or NW.js compared to a Web App are things like filesystem access - as well as the entire Node JS ecosystem, which has many modules, some capable of performing native operations in a variety of different platforms.
Thank you. People calling web-render wrappers "native applications" must not realize how great it is when applications are mere coördinators on top of an integrated platform full of services designed to improve user productivity.
I guess if that demographic did, there would be less "unix philosophy" cultism, as the efficacy of the unix shell is merely on par with that provided by other relatively coherent software toolsets. The shell is really pretty barebones compared to the rich semantics provided by many toolkits and object systems on which user interfaces have been built: GObject and NeXT are two modern examples. [That said, where shell shines is by providing so few abstractions that virtually any garbage has the same semantic depth as things which were designed to be used in the shell. Bytes are universal on the common computing substrate.] The web, on the other hand, is a platform "designed" by the erosive flow of eyeballs during the 1st-nth browser wars, without much of a direction beyond tacking on additional pretty features without breaking backwards compatibility too much. Attributes like a11y, embeddability, composability, and effective resource sharing tend to simply fall out of well-designed platforms. The web has an effective answer for none of these desirable concerns. Look at how screen readers break on js-heavy and dynamic web pages, the ongoing security disasters of XSS and iframes (and the complexity of login services like Facebook's/oauth/openid), the disappearance of Google reader, and the half-assed way CDNs offer partial, ad-hoc offloading of some resources via surrender to centralization.
I think this should be the future of native apps. You do get all of the benefits of native apps -- there are plenty of modules to handle key bindings, notifications, file system IO, etc. By using web page rendering you also get the incredible ecosystem of front-end tooling and plugins (React, Bootstrap, the infinite jQuery plugin world). All of this beats Qt in my opinion, having designed both.
I wonder how many other apps will also have this bug due to being a webapp inside Chromium, and thus require updating when it's fixed. It's not Heartbleed-like criticality, but still seems rather unpleasant, not to mention the waste of keeping multiple copies of Chromium around (I'd guess the typical webapp is much smaller than the browser itself.)
Comments (89) 28 threads
I think reading the comments on that bug is also rather enlightening; points of note include a 62-level-deep stack trace, comments to the effect of "we don't know what the bug is/how this is supposed to work", and discussions about whether escaping multiple times is the solution (absolutely not!)
https://tools.ietf.org/html/rfc3986#section-2.4
Implementations must not percent-encode or decode the same string more than once, as decoding an already decoded string might lead to misinterpreting a percent data octet as the beginning of a percent-encoding, or vice versa in the case of percent-encoding an already percent-encoded string.
Seriously, I'm quite surprised that basic URL handling is still a problem. Making a game to bring this to the attention of a wider audience is certainly a good idea.
Also, %00 shouldn't cause the browser to crash, and the fixes suggested so far are just work-arounds :/
Speaking as someone with an apostrophe in his name, I'm not sure whether this makes me want to chuckle and reach for the popcorn, or bang my head against the desk. The answer to multiple (un-)escaping bugs is never recursion.
I think the problem is that a spec exists, but existing browser incorrectly implemented it (hello Netscape), and given their prevalence browsers are stuck with weird hacks so that existing websites continue to work.
In particular around percent escapes there's lots of trouble. Nothing really specs the encoding to be used for those percent escapes (the RFC only has some odd notes on encodings), and there's a whole bunch of odd behaviours, e.g. how characters are handled when pasting a URL into an address bar vs having it as an href on a web page.
more details here on the bug in chromium here: https://code.google.com/p/chromium/issues/detail?id=533361
Slack's desktop apps are HTML5 webapps wrapped inside native desktop wrappers. Specifically, Slack uses Github's Electron (formerly, Atom Shell) which is basically Chromium. The desktop app is a webpage inside Chromium.
Continue this thread — 4 replies
Try hitting Cmd + , to change change some of your HN settings, or alt-tabbing to your HN tab (the one in your browser).
I guess if that demographic did, there would be less "unix philosophy" cultism, as the efficacy of the unix shell is merely on par with that provided by other relatively coherent software toolsets. The shell is really pretty barebones compared to the rich semantics provided by many toolkits and object systems on which user interfaces have been built: GObject and NeXT are two modern examples.
[That said, where shell shines is by providing so few abstractions that virtually any garbage has the same semantic depth as things which were designed to be used in the shell. Bytes are universal on the common computing substrate.]
The web, on the other hand, is a platform "designed" by the erosive flow of eyeballs during the 1st-nth browser wars, without much of a direction beyond tacking on additional pretty features without breaking backwards compatibility too much.
Attributes like a11y, embeddability, composability, and effective resource sharing tend to simply fall out of well-designed platforms. The web has an effective answer for none of these desirable concerns. Look at how screen readers break on js-heavy and dynamic web pages, the ongoing security disasters of XSS and iframes (and the complexity of login services like Facebook's/oauth/openid), the disappearance of Google reader, and the half-assed way CDNs offer partial, ad-hoc offloading of some resources via surrender to centralization.
Continue this thread — 8 replies
Continue this thread — 1 reply
"harmless"
oops.
http://www.stfj.net/art/2009/loselose/
All comments shown.
Couldn't load more comments. Check your connection and try again.