summaryrefslogtreecommitdiff
path: root/src/usr.bin
diff options
context:
space:
mode:
authorderaadt <>2002-11-14 00:50:40 +0000
committerderaadt <>2002-11-14 00:50:40 +0000
commit1aab6b876c209fe72e840d7b23a86e1239e81593 (patch)
treee4367539e40df8a6b7d6e9e60d420bb77473ffee /src/usr.bin
parenteeff5c2280da20072c42dc5447aa41beb7f22d6e (diff)
downloadopenbsd-1aab6b876c209fe72e840d7b23a86e1239e81593.tar.gz
openbsd-1aab6b876c209fe72e840d7b23a86e1239e81593.tar.bz2
openbsd-1aab6b876c209fe72e840d7b23a86e1239e81593.zip
$ in front of commands
Diffstat (limited to 'src/usr.bin')
-rw-r--r--src/usr.bin/nc/nc.126
1 files changed, 13 insertions, 13 deletions
diff --git a/src/usr.bin/nc/nc.1 b/src/usr.bin/nc/nc.1
index 759be26a31..b696b3d693 100644
--- a/src/usr.bin/nc/nc.1
+++ b/src/usr.bin/nc/nc.1
@@ -1,4 +1,4 @@
1.\" $OpenBSD: nc.1,v 1.22 2002/02/28 18:05:36 markus Exp $ 1.\" $OpenBSD: nc.1,v 1.23 2002/11/14 00:50:40 deraadt Exp $
2.\" 2.\"
3.\" Copyright (c) 1996 David Sacerdote 3.\" Copyright (c) 1996 David Sacerdote
4.\" All rights reserved. 4.\" All rights reserved.
@@ -151,40 +151,40 @@ If version is not specified, SOCKS version 5 is used.
151.El 151.El
152.Sh EXAMPLES 152.Sh EXAMPLES
153.Bl -tag -width x 153.Bl -tag -width x
154.It Li "nc hostname 42" 154.It Li "$ nc hostname 42"
155Open a TCP connection to port 42 of hostname. 155Open a TCP connection to port 42 of hostname.
156.It Li "nc -p 31337 hostname 42" 156.It Li "$ nc -p 31337 hostname 42"
157Open a TCP connection to port 42 of hostname, and use port 31337 as 157Open a TCP connection to port 42 of hostname, and use port 31337 as
158the source port. 158the source port.
159.It Li "nc -w 5 hostname 42" 159.It Li "$ nc -w 5 hostname 42"
160Open a TCP connection to port 42 of hostname, and timeout after 160Open a TCP connection to port 42 of hostname, and timeout after
161five seconds while attempting to connect. 161five seconds while attempting to connect.
162.It Li "nc -u hostname 53" 162.It Li "$ nc -u hostname 53"
163Open a UDP connection to port 53 of hostname. 163Open a UDP connection to port 53 of hostname.
164.It Li "nc -s 10.1.2.3 example.host 42" 164.It Li "$ nc -s 10.1.2.3 example.host 42"
165Open a TCP connection to port 42 of example.host using 10.1.2.3 as the 165Open a TCP connection to port 42 of example.host using 10.1.2.3 as the
166IP for the local end of the connection. 166IP for the local end of the connection.
167.It Li "nc -v hostname 42" 167.It Li "$ nc -v hostname 42"
168Open a TCP connection to port 42 of hostname, displaying some 168Open a TCP connection to port 42 of hostname, displaying some
169diagnostic messages on stderr. 169diagnostic messages on stderr.
170.It Li "nc -v -z hostname 20-30" 170.It Li "$ nc -v -z hostname 20-30"
171Attempt to open TCP connections to ports 20 through 30 of 171Attempt to open TCP connections to ports 20 through 30 of
172hostname, and report which ones 172hostname, and report which ones
173.Nm 173.Nm
174was able to connect to. 174was able to connect to.
175.It Li "nc -v -u -z -w 3 hostname 20-30" 175.It Li "$ nc -v -u -z -w 3 hostname 20-30"
176Send UDP packets to ports 20-30 of example.host, and report which ones 176Send UDP packets to ports 20-30 of example.host, and report which ones
177did not respond with an ICMP packet after three seconds. 177did not respond with an ICMP packet after three seconds.
178.It Li "nc -l 3000" 178.It Li "$ nc -l 3000"
179Listen on TCP port 3000, and once there is a connection, send stdin to 179Listen on TCP port 3000, and once there is a connection, send stdin to
180the remote host, and send data from the remote host to stdout. 180the remote host, and send data from the remote host to stdout.
181.It Li "echo foobar | nc hostname 1000" 181.It Li "$ echo foobar | nc hostname 1000"
182Connect to port 1000 of hostname, send the string "foobar" 182Connect to port 1000 of hostname, send the string "foobar"
183followed by a newline, and move data from port 1000 of hostname to 183followed by a newline, and move data from port 1000 of hostname to
184stdout until hostname closes the connection. 184stdout until hostname closes the connection.
185.It Li "nc -U /var/tmp/dsocket" 185.It Li "$ nc -U /var/tmp/dsocket"
186Connect to a Unix Domain Socket. 186Connect to a Unix Domain Socket.
187.It Li "nc -lU /var/tmp/dsocket" 187.It Li "$ nc -lU /var/tmp/dsocket"
188Create and listen on a Unix Domain Socket. 188Create and listen on a Unix Domain Socket.
189.El 189.El
190.Sh SEE ALSO 190.Sh SEE ALSO