Skip to content
Better HN
Top
New
Best
Ask
Show
Jobs
Search
⌘K
undefined | Better HN
0 points
fafner
13y ago
0 comments
Share
exec 5<>"/dev/tcp/localhost/80" echo -ne "GET / HTTP/1.1\r\nHost: localhost\r\n\r\n" > &5 cat < &5
FTFY
0 comments
default
newest
oldest
jlgreco
13y ago
Clever, though nc really is better than telnet. It is much easier to pipe into just for starters.
planckscnst
13y ago
/dev/tcp is a bashism. It's not a real (kernel-provided) device.
j
/
k
navigate · click thread line to collapse