BerryFarm / berrymuch

🍇 Power user Unix distribution for Blackberry 10
50 stars 10 forks source link

bash-5.0: warning: /dev/(tcp|udp)/host/port not supported without networking #32

Open karawitan opened 4 years ago

karawitan commented 4 years ago

Hi Blackberry 10 believers !

While trying to open a tcp socket using bash-5.0 on bb10, I hit the following issue:

bash-5.0$ exec 3<>/dev/tcp/www.eff.org/80
bash: warning: /dev/(tcp|udp)/host/port not supported without networking

Is there any hope to have this feature working on bb10 ? Or maybe we should get "nc" instead ?

vaskas commented 4 years ago

What are you trying to achieve? The above command also doesn't work on mksh: can't create /dev/tcp/www.eff.org/...

karawitan commented 4 years ago

This syntax would be used to open an http request to www.eff.org on port 80. There is such example here: (talking SMTP over port 25 using bash, without a telnet or nc client)

image

(taken from https://stackoverflow.com/questions/49179707/tcp-socket-server-in-bash)