Pretty relevant for this community <https://www.gw...
# thinking-together
s
Pretty relevant for this community https://www.gwern.net/Turing-complete
d
What drives me crazy about this kind of blog post is the term "Turing complete" has a perfectly precise meaning in computability theory, which has nothing to do with security. Now we are seeing bloggers misuse the term to mean whatever they want it to mean, and every author means something slightly different.
The authors of the Dhall configuration language claim that their language is not Turing complete. They aren't confused about the meaning, they are using the same definition as computability theory. Then they claim that not being Turing complete makes their language more secure, which is highly debateable, if not false.
👍 1
This author has latched onto the idea, but is very loose about the meaning of "Turing complete". At one point he claims it means that the language has side effects that can be used to interfere with or take over the host (that's not what it means). At another point he claims that Turing completeness allows Row Hammer attacks (and implies that "total functional programming" somehow prevents writing such attacks). The reality is different. Security vulnerabilities can be present in any kind of interpreter. Rowhammer requires the ability to trick the interpreter into repeatly hammering on the same contiguous array of memory, which doesn't require Turing completeness. A Turing complete language need not be vulnerable to this, if the run time data structures and interpreter are carefully designed.
In a Turing complete language, you can write a program that loops forever, and attempts to allocate an infinite amount of memory. The "total functional programming" model of Dhall prevents you from doing these things, and that's supposed to be a big win. But Dhall does not prevent you from allocating all of the memory in the machine, and it doesn't prevent you from writing a loop that iterates for billions of years. So there's no benefit at all, in terms of protecting you from malicious code.
p
The problem here is that very few programmers me included are competent/bothered enough to get an outline or grasp on these matters and dig down to understand what it means. So we are all but relegated to sit on the gallery watch a few illuminated people who have differing level of understanding on these issues debate the very important issues with a semblance of enjoyment derived from the rhetoric devices they employ to pick apart these conceptions.