News for hackers. Stuff that matters.
Re:Down go all the major browsers at Pwn2Own by aroman on Sunday March 16, 2014 @05:27PM (#7411383)
No, it's because writing software in C++ is like riding your bike in the middle lane of a highway with no helmet on.

If you're really really careful, it can work fine, and your trip will be efficient and productive. But it's really hard to do it properly -- you could hit a car (buffer overflow), you could get hit by someone (heap overflow), or your brakes might give out (input sanitization fail).

It's not that it's impossible or that it's a "bad idea", it's just that it'd be a lot safer to spend the extra resources on a motorcycle (Python) or an SUV (Rust).

Re:Down go all the major browsers at Pwn2Own by TillE on Sunday March 16, 2014 @06:02PM (#7411579)
C is irreducibly dangerous, but you can do quite a lot with C++ by avoiding legacy C stuff. Build almost everything on top of the STL and Boost, which are safe.

And of course there are security bugs (eg, goto fail) that would affect any language.

Re:Down go all the major browsers at Pwn2Own by pjmlp on Sunday March 16, 2014 @06:34PM (#7411708)
Fully agree, mankind would be better without C and C++.

But given they are the current mainstream options for the time of applications they are used to, better use modern C++ like you are advocating and stay as far as possible from any pure C constructs.

Additionally use static analyser, enable all warnings as errors and turn on pedantic mode.

Re:Down go all the major browsers at Pwn2Own by munin on Sunday March 16, 2014 @10:52PM (#7412613)
> Build almost everything on top of the STL and Boost, which are safe.

this is not really true, you can have temporal memory safety issues using STL and boost.

Re:Down go all the major browsers at Pwn2Own by jkrems on Sunday March 16, 2014 @06:13PM (#7411621)
The examples should be the other way around. Very safe and simple to drive but slower and not that powerful: bike an a proper bike lane (Python). Reasonably safe & fast: SUV (Rust). Really fast and you can do crazy things (drive on one wheel at 200km/h) but also enormously dangerous: Motorcycle (C/C++).
Re:Down go all the major browsers at Pwn2Own by dictum on Sunday March 16, 2014 @06:21PM (#7411663)
Re:Down go all the major browsers at Pwn2Own by jk4930 on Sunday March 16, 2014 @07:03PM (#7411799)
Or a tank (Ada). Seriously, Ada is alive and in version 2012 pretty okay. It depends on your application domain, of course, but if you care about safety and reliability, Ada is battle-proven.