News for hackers. Stuff that matters.
Re:Simple Linux kernel memory corruption bug can lead to com... by vlovich123 on Wednesday October 20, 2021 @01:48PM (#28933642)
I recommend reading the article I linked. They thought they found a solution with volatile and it turns out didn’t actually work. Malloc/free are 100% special and a sufficiently smart compiler can remove this stuff (sometimes automatically, sometimes if you turn on LTO).

memset_s is the only function that would be defined to work precisely because this was needed for crypto so it is solvable but just take it on faith that if it’s not explicitly called out as forcing the compiler to not do dead store elimination, it will happen.

Re:Simple Linux kernel memory corruption bug can lead to com... by guerrilla on Wednesday October 20, 2021 @03:17PM (#28934911)
Thanks for the recommendation, I had skipped it. It's worse than I thought. Wow, I need to reprogram my brain actually. Maybe it's time for me to actually read the standard and rethink these things.