Bash does thing I never suspected.
Try this and be amazed:
$ cat < /dev/tcp/gsmtp163.google.com/25 220 mx.google.com ESMTP 12si345086nzn
Be honest: did you know bash could do that? I didn't until finding it in the man page
Now try this and be amazed it doesn't work (yes, it's in the docs):
$ cat /dev/tcp/gsmtp163.google.com/25 cat: /dev/tcp/gsmtp163.google.com/25: No such file or directory
And remember, on unix everything is a file, but maybe that file is only there in some very specific circunstances.
UPDATE: There is a chance this will not work in your distro, specifically Debian.
This doesn't work for me - I get "no such file or directory". Have I missed something?
Doesn't work for me. "man bash" reports
"NOTE: Bash, as packaged for Debian, does not support using the /dev/tcp and /dev/udp files."
Well, that explains it. It works here :-)
Will update it to show the output and mention this.