Exactly my thought. I wont be using this for exposed/public access. Which websockets are.
First vector that comes to mind the stdin escape sequences, then there is the inevitable leaking of sensitive information (besides bugs in the process, what about its unhandled exceptions, segfaults, or other system errors), and then there is the denial-of-service unless it can throttle before invoking a process, and lets not forget about command injection.
But still i must say the idea is nice in simplicity..
Inetd on wikipedia: https://en.wikipedia.org/wiki/Inetd
Inetd on NVD: https://nvd.nist.gov/vuln/search/statistics?form_type=Basic&... I expected worse ;-)