I had a dream last night that I was doing a FreeBSD reimplementation of a Linux ...

@david_chisnall@infosec.exchange

I had a dream last night that I was doing a FreeBSD reimplementation of a Linux security thing. The idea was that userspace would provide the kernel with a random bit pattern that it would use to initialise uninitialised memory and write into freed objects and the kernel would kill the process if this bit pattern showed up in any copyin.

I presume my brain completely made up this existing in Linux, but has anyone built a thing like this? In the dream, it was a 64-bit value and I'm wondering what the false positive rate would be for that. The changes to snmalloc to support something like this would be quite small and the changes in the kernel could be localised in the copyin routine.