▲ | crawshaw 5 days ago | |||||||
Memory safety is a big deal because many of the CVEs against C programs are memory safety bugs. Thread safety is not a major source of CVEs against Go programs. It’s a nice theoretical argument but doesn’t hold up in practice. | ||||||||
▲ | nine_k 5 days ago | parent | next [-] | |||||||
A typical memory safety issue in a C program is likely to generate an RCE. A thread-safety issue that leads to a segfault can likely only lead to a DoS attack, unpleasant but much less dangerous. A race condition can theoretically lead to more powerful attacks, but triggering it should be much harder. | ||||||||
| ||||||||
▲ | okanat 5 days ago | parent | prev | next [-] | |||||||
It depends on what threads can do. Threads share memory with other threads and you can corrupt the data structure to force the other thread to do an unsafe / invalid operation. It can be as simple as changing the size of a vector from one thread while the other one accesses it. When executed sequentiality, the operations are safe. With concurrency all bets are off. Even with Go. Hence the argument in TFA. | ||||||||
| ||||||||
▲ | stouset 5 days ago | parent | prev | next [-] | |||||||
A CVE is worse, but a threading bug resulting in corrupted data or a crash is still a bug that needs someone to triage, understand, and fix. | ||||||||
| ||||||||
▲ | kllrnohj 4 days ago | parent | prev [-] | |||||||
This isn't arguing about exploit risks of the language but simply whether or not it meets the definition of memory safe. Go doesn't satisfy the definition, so it's not memory safe. It's quite black & white here. Nice strawman though |