News for hackers. Stuff that matters.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by temac on Monday November 15, 2021 @12:01PM (#29229585)
The problem is right now DDR4 devices that work correctly in that regard, do not exist. Likely the best mitigation for any sensitive application, even so lightly, is DDR4 with ECC (even if it may not be enough, it is vastly better than nothing, and not just because of rowhammer)

And I have no idea if the internal "ECC" of standard DDR5 helps or not. It is not intended for regular ECC level of reliability anyway. (And I have seen discussion about likely bitflips detected in crash dumps of M1 Pro devices)

So, as much as I would like to return defective devices, I would probably be left with no computer, no smartphone, etc.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by buran77 on Monday November 15, 2021 @12:33PM (#29229988)
According to older paper [0] ECC can also be bypassed after reverse-engineering the mitigation in DDR3 DIMMs. Also:

> “DDR4 systems with ECC will likely be more exploitable, after reverse-engineering the ECC functions,” researchers Razavi and Jattke said

> What if I have ECC-capable DIMMs? Previous work [1] showed that due to the large number of bit flips in current DDR4 devices, ECC cannot provide complete protection against Rowhammer but makes exploitation harder.

[0] https://cs.vu.nl/~lcr220/ecc/ecc-rh-paper-eccploit-press-pre...

[1] https://ieeexplore.ieee.org/stamp/stamp.jsp?arnumber=8835222

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by FpUser on Monday November 15, 2021 @03:49PM (#29232531)
While it can not protect from bit flips it can most likely warn about attack in progress due to a large number of bit flips.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by indymike on Monday November 15, 2021 @01:20PM (#29230621)
> The problem is right now DDR4 devices that work correctly in that regard, do not exist.

Yes, and this is actually the problem. Without safe hardware, it is almost impossible to write safe software.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by userbinator on Monday November 15, 2021 @03:58PM (#29232649)
Meanwhile you can still buy DDR3 --- used --- from various shops in China, and it'll be 100% perfect and Rowhammer-free because it was made before the insane process shrinkages that caused it.

(Have done this a few times. Was hesitant initially because of the low price and used nature, but when the first stick passed MemTest86+ including RH perfectly, I was convinced. Half a dozen more sticks later and still good. But maybe they've started to run out of the good old stuff now...)

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by inetknght on Monday November 15, 2021 @06:55PM (#29234645)
> you can still buy DDR3 --- used --- from various shops in China, and it'll be 100% perfect and Rowhammer-free because it was made before the insane process shrinkages that caused it

That's demonstrably false. I remember rowhammer being thought of and demonstrated on DDR3 modules.

[0] https://hammertux.github.io/rowhammer-ffs-ddr3

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by userbinator on Monday November 15, 2021 @07:55PM (#29235174)
Rowhammer started appearing in newer DDR3; see the original paper (figure 3): https://news.ycombinator.com/item?id=8713411

The tl;dr is that everything 2009 and older is good, 2010-2011 is possibly bad, 2012 and newer is almost certainly bad.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by throwaway81523 on Monday November 15, 2021 @07:47PM (#29235097)
> Yes, and this is actually the problem. Without safe hardware, it is almost impossible to write safe software.

Software that attempts a hostile rowhammer attack aims to be unsafe by definition. It's not a matter of trying and failing to be safe. Rather, we're seeing that it's very difficult to build hardware and software that prevents hostile code from running amuck: if the attacker can run hostile code on your computer at all, you have already lost. That's bad news for cloud hosts and confirms what we already knew about web scripting, but doesn't seem all THAT bad for the rest of us.

Of course it's possible to build computers with no DRAM at all (i.e. only SRAM, which costs more). That is not economically sane for big servers, but might be the right thing to do for security sensitive components.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by fpoling on Tuesday November 16, 2021 @03:59AM (#29238414)
The sizes of current CPU caches is enough to run a lot of code…
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by jandrese on Monday November 15, 2021 @12:23PM (#29229850)
Maybe a paranoid app could try to allocate the memory adjacent to any sensitive bits as a buffer? That would be pretty difficult to do but might be possible if you are tremendously paranoid and have a good way to examine the hardware.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by mnw21cam on Monday November 15, 2021 @12:53PM (#29230219)
You'd have to have the operating system's cooperation, because it may be mapping individual 4k pages all over the place, and it's the only thing that has a chance of knowing how the memory is laid out on the actual chips.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by AshamedCaptain on Monday November 15, 2021 @02:05PM (#29231231)
And the CPU and the chipset's cooperation. In many cases it is even a trade secret how data is striped across the different slots/banks.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by StillBored on Monday November 15, 2021 @03:37PM (#29232372)
<i> it is even a trade secret how data is striped across the different slots/banks </i>

If that is true, vs just the usual "you don't need to know" trash common these days, its crazy. A pretty good picture can be built up with just software timing analysis, but its hardly rocket science to hook a logic analyzer/scope up and determine bit swizzling and page/bank interleave. Plus, many of the more open BIOS vendors have tended to provide page/row/controller/socket interleave options for quite a while, partially because it can mean a 5-10% uplift for some applications to have it set one way or the other. Its been one of those how do you tune your memory system options for a couple decades now.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by xxpor on Monday November 15, 2021 @02:16PM (#29231364)
Doesn't the same thing to exploiting rowhammer though? If you're after specific data, how would you know what physical address to use, even if you knew the physical address of the target data?
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by jandrese on Monday November 15, 2021 @02:35PM (#29231623)
Yes, but there is a difference between an attack being run by a low level hardware hacker vs. the software being run by average users. This is why I said it would be hard, you would need to encode a lot of low level hardware knowledge into your application.

This might only be useful in very specialized circumstances, like with kernel support on only a handful of carefully chosen hardware platforms. However, someone like Apple could do this on their systems, as they control both the kernel and the hardware. Sensitive memory locations could be cordoned off in special zones with buffering to prevent Rowhammer type attacks.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by pas on Monday November 15, 2021 @12:38PM (#29230039)
Or use different banks of DRAM for different security contexts, managed via NUMA?
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by to11mtm on Monday November 15, 2021 @12:44PM (#29230107)
I wonder how easy that would be to reason about though. I really don't know much about modern DRAM circuitry I feel like it might be abstracted away to some level, also there are bios-tweaky settings that might make a difference (i.e. things like channel configuration and/or bank interleaving, if that's still a thing.)

IDK though. Maybe there's a way. I've worked on code that uses padding around a data structure to ensure it has it's own cache line. Maybe if you allocate a large enough contiguous block you'll be OK?

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by staticassertion on Monday November 15, 2021 @03:49PM (#29232535)
If your app is particularly paranoid you could just double your memory usage, and verify errors against the clone.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by myself248 on Monday November 15, 2021 @01:09PM (#29230447)
Yep, though I agree with the parent, if a RAM returns data from a location that is different from what is stored in that location, assuming all recommended timings have been followed, then that RAM is defective. If that means they should be recommending a refresh after every single operation, then that's what it means.

In other words, the whole industry sits on a bed of lies at this point and it's only because government is technically incompetent that we haven't seen the world's biggest class-action.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by ygjb on Monday November 15, 2021 @01:48PM (#29230993)
> In other words, the whole industry sits on a bed of lies at this point and it's only because government is technically incompetent that we haven't seen the world's biggest class-action.

That's a pretty bold claim - if it's accurate, can you point at the government regulation that precludes a class action lawsuit? I would assume it's something in the T&C or EULA for the hardware rather than a regulation?

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by userbinator on Monday November 15, 2021 @03:51PM (#29232555)
Bold but sadly correct. The industry runs on misdirection and deception.

If users knew better, we'd have the equivalent of another Pentium FDIV bug.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by rzerda on Tuesday November 16, 2021 @01:53AM (#29237674)
The whole industry built this bed of lies by their own hands, I don’t see how it’s government’s fault.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by oopsyDoodl on Monday November 15, 2021 @02:37PM (#29231661)
I think this illustrates the cloud is unacceptable for anything more than storage and retrieval.

All computed results from data science must include steps and code to verify locally.

It calls into question privacy on federated networks and crypto networks; any node can be manipulated locally to change payload outputs on delivery, reveal secrets, disrupt workloads.

This makes sense to a lot of folks in computer engineering and physics, versus abstract software. No physical theory I know of offers any guarantee our arbitrary computing machines will ever be securable. We put fart pipes on Hondas.

Science proves it’s titillating smoke and mirrors once again. Still waiting for nuclear rocket cars.

I think this proves further as well why general computing chips need to be replaced with workload specific designs, where the anticipated inputs are well known and no vague logic paths to intentionally allow software monkey patching ever ship.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by cheschire on Monday November 15, 2021 @02:58PM (#29231897)
Security doesn’t scale at a price point that private sector companies could typically afford.

Perhaps we fail at pricing security into the value of a company, or maybe that’s what risk appetite is about.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by Sebb767 on Monday November 15, 2021 @07:27PM (#29234933)
The problem is that you can get away with minimal security for a long time. Sure, if you get hit, shit hits the fan. But by then, it's quite likely that all competitors that spend money and time on security and good infrastructure are long gone.

This is worsened by the fact that it's very hard for laypeople to assess the security of a specific application and that, by now, "cyberattack" has become common enough that it's easily accepted as an excuse.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by dredmorbius on Monday November 15, 2021 @09:31PM (#29236005)
Which is why certifications, audits, and minimum mandated standards are critically important.

The market just yawns at this stuff, until it gets fragged. Then it forgets and the cycle repeats.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by tatersolid on Tuesday November 16, 2021 @11:21PM (#29249259)
> Which is why certifications, audits, and minimum mandated standards are critically important.

Not sure about that. All the security standards want me to run software written in an unsafe language as root on every device, intentionally parsing malicious inputs continuously.

That’s not making anything safer.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by dredmorbius on Wednesday November 17, 2021 @12:52AM (#29249647)
Pretty clearly, the standards have to be effective and well-designed. And yes, there are problems with that.

But the point remains that markets do very poorly at rare and/or cumulative risks. And that's the comparison I'm making. The market of and by itself will give you a race to the bottom in standards.

A longer-term view, whether through government regulation and oversight, social suasion, religious morality and ethics, or (possibly) insurance-oriented risk management (yes, a market mechanism, though something of an exception to the rule), will typically operate by the mechanisms I've described above. That there may be poor implementations doesn't obviate the fact that there can also be good ones, and that that's the goal we're aiming for.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by passerby1 on Monday November 15, 2021 @06:33PM (#29234421)
Probably, at least some part of a modern financial sector including startups has many things in common to pyramid schemes.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by Ysraes on Monday November 15, 2021 @10:20PM (#29236368)
> I think this illustrates the cloud is unacceptable for anything more than storage and retrieval.

You can run in dedicated tenancy where you have the whole machine or a metal configuration where you also have the whole machine.

Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by frankzinger on Tuesday November 16, 2021 @01:11AM (#29237452)
That would ruin providers' user:hardware ratios, one of the foundational principals of cloud computing.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by Terretta on Wednesday November 17, 2021 @11:03PM (#29261851)
On the contrary, certain CSPs did this already (quietly) and further, had already developed hardware mitigations for things like meltdown, spectre and rowhammer.
Re:Blacksmith – Rowhammer bit flips on all DRAM devices toda... by frankzinger on Friday November 19, 2021 @12:17AM (#29274067)
But did they manage to keep their prices low?

(And those who employed hardware mitigations wouldn't have a problem with user:hardware ratios, would they?)