| Edited for tone. > STDIN/STDOUT is an unrestricted protocol. So are WebSockets. > Normally when you write a webapp you have a well-tested parser to validate the HTTP request for you The only HTTP in WebSockets is the handshake, which is what this daemon handles for you. > and you have safe APIs to access parameters, There are no "parameters"; WebSockets transport a stream of opaque packets. > and your templating language auto-escapes dangerous characters for you, There are no "unsafe characters" in a binary protocol. At best you could claim NUL and LF, the former because it has special meaning to C, and the latter because it's used as a message delimiter by this daemon. The worst either of those will cause is reading less of a message instead of more. > and the response goes through middleware to prevent XSRF attacks You have to do this in any language you use. This has nothing to do with communicating via Unix pipes. > With this, you have to handle all of that in your application binary. Most HTML parsing engines are available as libraries. |
It's oftentimes really dangerous to expose the raw stdin/stdout to the web. The point is that this by default has none of the usual safeties associated with making a program web-accessible. It's dangerous.
This doesn't make it a bad tool. It just means you need to be aware of the downsides.