Live data from Hacker News

Re: Integrating "safe" languages into OpenBSD? (2017)

marc.info

191–200 of 400 posts

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#191
Every time I see a Theo de Raadt thing on the front page it's some nonsensical language rant that has the utility of a PR review comment on some random leaf JS project.

The guy does a lot of work maintaining OpenBSD but it looks like people only upvote his pointless flaming. This is practically TMZ for Nerds stuff.

I think I'll block Theo de Raadt for myself on HN.

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#192

Earlier quoted context omitted.

Yeah. Not sure about BSD, but I was wading into building the GNU coreutils and other GNU packages just yesterday. Fresh hell, they all seem to be build dependencies of each other. ‘sed’ is its own build dependency. The whole C ecosystem is a joke with respect to builds—all dependencies are implicit; you’re just expected to have the exact dependencies installed on your system at the exact versions and in the exact loc…

Agreed on a hundred thousand. I used to feel sheepish defending npm and the whole node package ecosystem against its critics, but once I started trying to run deep learning applications or WebRTC media servers I quickly realized that some of the critics are probably coming from a much worse package management system that they’ve merely grown familiar with. Want to have two pieces of software on one computer that rely…

There are a lot of package ecosystems, but more packages, and one of these packages will always depend on something implicit.

Building a new system is not going to help. Xkcd 927 about standards applies

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#193
post #33

I have been using bat and exa along with alacritty for a while. All of them are pretty good https://github.com/alacritty/alacritty https://github.com/sharkdp/bat https://github.com/ogham/exa

Throw in those, + fd[0] and rg[1] 0: https://github.com/sharkdp/fd 1: https://github.com/BurntSushi/ripgrep

Oh cool. Thanks

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#194
post #119

Earlier quoted context omitted.

can you elaborate please?

... I am not really sure how to elaborate, to be honest. Rust prevents memory unsafety, but memory leaks are not memory un-safe. There are many kinds of bugs that Rust does not prevent. Leaks are one of them.

How can leaked memory, pragmatically, be considered safe? The language spec definition seems useless.

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#195

It also doesn't help that Rust keeps on pushing on the idea that "static linking is the only way to go". This is another cargo-cult which I wish didn't end up being engrained so deep in the toolchain because while it has some merits, it also has significant drawbacks of a typical unix distribution. Static linking might be good for folks distributing a single server binary over a fleet of machines (pretty much like Go…

How much do your programs really share? After libc, libm, and pthreads, the most common thing they link to is probably pcre, and I'm sure you can guess how many of your programs are using that. A good linker will shave off the parts of a library you're not using, and the parts which are left over are usually not very big. The problem isn't with static linking, it's that some "developers" think that bundling an entire…

> bundling an entire Chromium build with their app is a good idea.

Does Chromium offer any other type of linking? I mean, is the problem in the developer including it when another option is possible or the fact that no other option is possible?

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#196

Earlier quoted context omitted.

How much do your programs really share? After libc, libm, and pthreads, the most common thing they link to is probably pcre, and I'm sure you can guess how many of your programs are using that. A good linker will shave off the parts of a library you're not using, and the parts which are left over are usually not very big. The problem isn't with static linking, it's that some "developers" think that bundling an entire…

Dynamic linking is pretty common in GUI applications (xlib, GTK/QT). Server-side there's also libssl, xml libraries, zlib, curl.

Wouldn't GUI bindings link to the underlying system library anyway, even in Rust? I think those Rust bindings are thin enough where having them as an additional dynamic library would not be helpful. Similar for the server side - in practice, Rust-based solutions are quite rare and ones that don't expose a stable C ABI for ease of using from C/C++ are even rarer.

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#197
post #95

> Yes, now I am implying something: you won't bother to rewrite the utilities. > So we cannot replace any base utility, unless the toolchain to build it is in the base. Adding such a toolchain would take make build time from 40 minutes to hours. I don't see how that would happen. So, to summarize: "We're not going to include the capability to write core utils in Rust, and also, no one is bothering to do it." Its rath…

Censorship of opinionated entities speaking in a manner you disagree with is so popular right now how can you be wrong? The 'community' meaning my cloud/bubble/echo chamber as usual I guess? Theos take was refreshing honesty in my bubble.

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#198

Earlier quoted context omitted.

... I am not really sure how to elaborate, to be honest. Rust prevents memory unsafety, but memory leaks are not memory un-safe. There are many kinds of bugs that Rust does not prevent. Leaks are one of them.

How can leaked memory, pragmatically, be considered safe? The language spec definition seems useless.

The only issue memory leaks can cause is being a DDoS vector. Memory unsafety can cause a host of other issues, and much more serious ones.

It is also very difficult to come up with a definition of "memory leak" that doesn't include programmer intention, and so it's not clear that you can come up with static analysis to preclude it.

Re: Re: Integrating "safe" languages into OpenBSD? (2017)

#199
post #9

Earlier quoted context omitted.

I think Theo's reply was a bit excessive in some regards but I can also understand him being frustrated when you've been working on a very complex project for decades and somebody comes around and say "uh, why don't you rewrite it in ?". It's seldom a very interesting or constructive discussion. If you think Rust has something to bring to some project then you should at least take the time to write a decent proof of…

I don’t think Linux or bsd will ever be rewritten in rust nor should they. I do think eventually there will be an os written in rust that surpasses them in popularity, but probably on the time frame of decades.

There are not many CVEs for coreutils anyways: https://www.cvedetails.com/product/5075/GNU-Coreutils.html?v...

To improve security, Rust should probably aim to replace libjpeg and other stuff which deals with malicious data a lot.

Post reply on HN