*.cgi: use 3-argument open to guarantee no shell used