Hacker Newsnew | past | comments | ask | show | jobs | submit | more codezero's commentslogin

I may be wrong but I think the realm of human experience has grown quite significantly since this was made, kind of awesome.


He wrote realm of "direct" human experience, which presumably means the unaided human senses over a human lifetime.


Ah thanks. That makes sense.


There is still a limit, and beyond that is Sagan's 'Forbidden Zone'. We can move the line, but only infinitesimal amounts.


I loved this walk through back when it came out and even made a ham handed attempt to write the example code in Go https://github.com/radiofreejohn/gobinson

It is a bummer it ended with a to be continued that never happened, I remember checking up on it from time to time.


Honestly I feel like he covered the hardest and weirdest things (parsing html and CSS is just weird but not hard. Layout and painting is (IMO) pretty hard and there are a lot of places to get lost.)

Scripting is mostly about hooking up a VM to the other stuff and there are a thousand and one articles on writing VMs.

For networking you should just use libcurl. Now that the URL parser is part of the public API you’re better off with it anyway. Plus the networking should be done outside of the engine anyway.


No doubt. The author owes me nothing, it is a great series. I just felt like I was left hanging a bit by the conclusion. :)


I feel the same way. I took a stab at reimplementing it in C https://github.com/wernsey/robinson-c

My Readme.md contains a lot of TODOs, which I thought I'd be able to tackle on my own, but sadly never got around to.


So the blog post ends with a promise of sections about:

* inline layout

* text rendering.

* networking.

* scripting.

LAYOUT

I think here could be useful to take a look at something like Facebook's Yoga [1] although maybe not great to start. There's this little layout demo that could be interesting to investigate [2].

TEXT

Regarding text probably the keyword to learn about is "rasterization". I found a few tutorials back in the day [3], [4]. In general rendering text is a PITA and you don't want to do it no matter what :-) The only lightweight solution I found was stb's truetype [3].

So if you want to render text yourself you'll need:

- a parser for a font format format (e.g. TTF, PITA) to have a way to get the curve definitions for each font.

- a rasterizer (could be a fun project for getting something reasonable and probably slow performant)

- a curve filling algorithm and plugging it to your rasterizer, which will probably be able to do humble things like drawing filled triangles and other simple shapes (PITA! :-p)

- a word and paragraph layout engine (PITA again :-)

Overall I'm happy half understanding the steps involved and not having to deal with all the messy steps in the middle.

NETWORKING

I'm super lazy in this area, and I would rather learn something like ZeroMQ to posix sockets... back in the day I followed Beej's tutorial which was nice. [6] Then you can connect your sockets to some pre-existing HTTP parser which are a dime a dozen these days [7] and you are all set! :-p

SCRIPTING

Not much to say here... hundreds of languages available. Probably Lua is a nice alternative to JavaScript, but there are also plenty of lightweight JavaScript implementations these days (I think there is a nice little one called V7). If you want to learn how to actually implement an interpreter there are plenty of resources too. If I went this route I would start by implementing some version of lisp or scheme for simplicity.

1: https://yogalayout.com/

2: https://github.com/randrew/layout

3: https://github.com/NotCamelCase/RasterizationInOneWeekend

4: http://www.scratchapixel.com/index.php

5: https://github.com/nothings/stb/blob/master/stb_truetype.h

6: https://beej.us/guide/bgnet/

7: https://github.com/search?q=http+parser&ref=opensearch


>So if you want to render text yourself you'll need (...)

Or possibly use SDL or a similar graphics library meant for game development.

You would still probably have to write a lot of code but you would get a rasterizer, font loading, simple primitives and image rendering in a cross-platform compatible API.


If you’re going to use a library just use straight freetype (what SDL wraps.) It’s very easy to use.


Sure, but SDL gives you more on top of just font handling.

I'm just saying, it's not necessary to reinvent all of the wheels.


Amazing follow up. Thanks so much.


This is indeed what people expect but it’s still pretty far from true. There are still a bunch of CSS quirks that are vendor specific. Also if you want to have fun read about the history of the innerText API - it even works different in different versions of IE! And wasn’t adopted by Firefox until about two years ago. These are only a few of the myriad mines you dodge when developing a library for the web at large. Have a look at caniuse.com for a journey down a compatibility rabbit hole. :)


It sure if it’s related but I learned from my brother in law’s girlfriend that her little brother had been hoarding scooters because they had some app that could disable the tracking and let you ride for free.

I guess the fact that these show up on a map contradicts that.


So could it be an alternative client that uses straw-man accounts to cash in every time the hoarder charges a scooter, occasionally using some of the spoils to buy them a "free" ride? That would be fascinatingly twisted: make your accomplices think they are part in an entirely different kind of crime than they are. Even more twisted (but not as creative) if it's an inside job to get a larger slice of the VC pie.


They can use Firefox, just not the rendering engine. I expect that would still be considered an adequate move. Nobody I know (bias) has an iOS device and no laptop or PC, so they can also adopt it on their PC.


How is using reskinned Safari with WebKit rendering engine considered adequate move?

That would be like putting a Firefox skin over IE6 engine a few years back - it would not help the ecosystem in the way this article asks for.


It would still use any bundled Firefox services. Mozilla makes (most?) of their money from search engine referrals so this alone is likely to be a direct support of them.


I’ve been going pretty strong with a host based blocker. I mention this in case you really want to use Next and are willing to try a different blocking approach :)

I know it’s not as comprehensive as extension based blocking, but it seems solid.


We've been leaning towards using Webkit's integrated content blocking rules, but we weren't sure how effective it would be, thanks for the feedback!


Yes it is, when you have the surface area of a company like Quora, or even a much smaller company.

I worked at Quora, and totally unrelated, at my current company, had the opportunity to source and be point on multiple penetration tests. At my current company, I work with some people I consider extremely competent at SQL, and in particular PostgreSQL, but that didn't stop the pentesters from finding SQLi in our code. It sneaks in, and all it takes is one fuck up for a hacker to go to town.

I think that most startups don't understand the value of dropping 20-30k on an engagement with a competent pentest company, and this can propagate even longer into an org to the point that they never bother to get outside testing. Don't fall into that trap. Having a third-party with eyes on your org is worth every cent. If you run a startup or aspire to, I highly recommend you consider getting a pentest when you have ~5M ARR, and continue to do a yearly engagement to make sure your shit is covered until you can afford a full time security staff.


All of these appear filled out now.

Quora is good about responding quickly, which should be appreciated. That the FAQ wasn't fully filled out was just because it was being filled out. I know this can be an awkward experience for someone who immediately sees and responds to the tech news, but a bulk of their users won't be that profile. They got the framework for response laid out immediately, and are working on the responses. This seems pretty solid.


They were already filled out, but with non-answers. For example:

> When did you first learn of the issue? How was it brought to your attention?

> We first learned of the issue on November 30. Upon learning about the issue, we immediately launched a comprehensive investigation and remediation effort.

There is absolutely nothing in there about how this was brought to Quora's attention. Did they see identities for sale on the dark net? Were they approached for a ransom? Did a user inform them? Nothing.

The other questions ditto.


Ah OK – I read this wrong then. My bad. I am confident, or at least optimistic, they will make improvements, if not, then I'll let you know how my foot tastes.


I worked at Quora, but left before this change was made, but I believe it was totally retroactive, mainly because I got emails with information about my previous anonymous answers and a deadline to get the one-time link.

Now... if the emails were logged and in the exploited database, then all bets are off, but there's no indication that happened at all.

There are about a hundred other things about this that give me anxiety, but Quora is run by extremely competent people (engineering and otherwise), so I am pretty confident about their ability to be transparent and to know the extent of any issue.

This entire thing is really shitty for everyone involved, but given Quora's tenure (almost nine years!) that this is the first breach is pretty amazing, and that they've done so much work to make it less of a problem is great.

None of the above is meant to diminish the general dissatisfaction others are expressing here.


>given Quora's tenure (almost nine years!) that this is the first breach is pretty amazing

I am sorry but this is #ShitHackerNewsSays worthy. Let me fix it for you

>given Equifax's tenure (almost 119 years! Since 1899) that this is the first breach is pretty amazing

Better now? Downvote me if you want, but there are no pats in the back for having PII leaks, no matter the years.


There have been at least 5 different breaches (of varying impact) at Equifax in the recent past several years. (https://en.wikipedia.org/wiki/Equifax)

Another set of 5 data breaches at Equifax dating back to 2013 (some but not all of these overlap with the Wikipedia reference) (https://www.forbes.com/sites/thomasbrewster/2017/09/08/equif...)

I would not be surprised if Equifax has been "breached" more than a hundred times over its history. Do your research.


This is an understandable counter point. I don’t really agree but I appreciate it.


I don't know why you need to be so aggressive. You've made multiple comments on this thread, all in this vein.

Flagged.


He is not aggressive at all. Upset? Maybe. Aggressive? No.


As a meta point, the word "aggressive" has undergone significant scope creep in tech lately. It's worrisome that lots of people with influence have started to punish messages that, while polite, express explicit, forceful, and direct disagreement. The only remaining option is an indirect approach laden with false pleasantries and ambiguous language that leaves the reader confused about the actual state of agreement. We need to push back against false claims of aggressiveness.


Really? If I dismissed your comment with #ShitHackerNewsSays, you'd say that was a "forceful, direct disagreement"? Maybe you think this is great because "false" pleasantries are cut off, but for me that's aggressive.


This is the one which came to light.


Which is all that is worth speculating about and discussing in this thread, or are you suggesting otherwise?


Ditto. This works for me. I don't always do it because I forget, but I don't usually get a hangover anyways.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: