Re:Some near-term arm64 hardening patches
by monocasa on Monday November 18, 2019 @05:19PM
(#21568746)
So now we're going to see the next step be making gadgets out of code fragments that happen to begin with BTI.
The real end game here is memory safety.
Re:Some near-term arm64 hardening patches
by wahern on Monday November 18, 2019 @06:58PM
(#21569433)
There are ways to compile that elide ROP gadgets. It's easier on architectures like ARM than x86. OpenBSD has taken this approach:
Number of ROP gadgets in 6.3-release arm64 kernel
69935
Number of ROP gadgets in 6.4-beta arm64 kernel
46
https://www.openbsd.org/papers/eurobsdcon2018-rop.pdfNote: As described later in the presentation, those 46 remaining gadgets are in the boot code, which is erased after booting.
Re:Some near-term arm64 hardening patches
by saagarjha on Monday November 18, 2019 @07:42PM
(#21569739)
I’m not convinced their search for ROP gadgets in libc is useful; often there’s a “magic” address that will do all the work to directly execve /bin/sh if you jump there (in glibc, this is inside of do_system).
Re:Some near-term arm64 hardening patches
by monocasa on Monday November 18, 2019 @07:03PM
(#21569468)
I'm not convinced that a conditional branch to the ret followed by breakpoints between it and the ret is enough to remove the usefulness of the gadget as much as they say.
Re:Some near-term arm64 hardening patches
by saagarjha on Monday November 18, 2019 @07:43PM
(#21569742)
Why?
Re:Some near-term arm64 hardening patches
by monocasa on Monday November 18, 2019 @10:39PM
(#21570468)
It's exactly the kind of roadblock that people who do offensive security are great at finding loopholes around.
Re:Some near-term arm64 hardening patches
by saagarjha on Tuesday November 19, 2019 @12:59AM
(#21570948)
I mean, that's really been their job every time a new mitigation is developed…the introduction of NX led to the use of ROP, which has been joined by JOP techniques as efforts to remove return gadgets gain momentum.
Re:Some near-term arm64 hardening patches
by monocasa on Tuesday November 19, 2019 @12:47PM
(#21575812)
This is more like fitting shellcode into something that can be strcpyed. Not really that much of a complication from an attack perspective.
Re:Some near-term arm64 hardening patches
by saagarjha on Monday November 18, 2019 @05:26PM
(#21568809)
That's where pointer authentication can help.
Re:Some near-term arm64 hardening patches
by qubex on Tuesday November 19, 2019 @05:51AM
(#21571945)
> memory safety
Harvard Architecture?
Re:Some near-term arm64 hardening patches
by monocasa on Tuesday November 19, 2019 @01:00PM
(#21575987)
Or a language that doesn't let you overflow buffers.
It's very much a cat and mouse game.