|
|
|
|
|
by HorstG
2355 days ago
|
|
I agree that 5 to 10 lines might be a sensible upper limit where a shell can safely be used. Basic does have Goto, but modern dialects do have all the usual control structures. Perl has weird syntax, but far less dangerous footguns: e.g. there are proper arrays, as opposed to many shells. One can distinguish between an empty and an undefined string. One can declare variables and there is the notion of data types. There are even things like taint mode. In shell, you can't even properly iterate over a directory without nasty surprises. Same in C. Yes, there are memory safety problems, but those are outnumbered by far by shellscripts exploitable via some expansion or variable injection. Its just that thankfully nobody uses shellskripts as network services, so you don't see as many reports about that. And yes, brainfuck was there as hyperbole. But I truly believe that there are very few things worse than shell for programming. |
|