Документ взят из кэша поисковой машины. Адрес оригинального документа : http://lvk.cs.msu.su/~sveta/4-5utils.pdf
Дата изменения: Wed Mar 9 18:49:27 2016
Дата индексирования: Sat Apr 9 22:36:23 2016
Кодировка:
IP ?
Dynamic Host Configuration Protocol · · - :
­ DHCP (UDP:67) ­ ( , IP , , DNS-) ­ DHCP (UDP:68) ­ DHCP netstat -pan | grep "\:68 "


DHCP?
· Discovery (Client -> Server)
· Src: CLI_ETH | 0.0.0.0 · Dst: FF:FF:FF:FF:FF | 255.255.255.0

· Offer (Server -> Client)
· Src: SRV_ETH | SRV_IP · Dst: CLI_ETH | CLI_IP

· Request (Client -> Server)
· Src: CLI_ETH | 0.0.0.0 · Dst: FF:FF:FF:FF:FF | 255.255.255.0

· Acknowledge (Server -> Client)
· Src: SRV_ETH | SRV_IP · Dst: CLI_ETH | CLI_IP


ping
· ping
­ (Echo Request) ­ (Echo Reply) ICMP

· . · :
­ ­ ­ ­ pi pi pi pi ng ng ng ng 12 ( ip ) lt gateway> ( ) e ip> ( ) ping

·
­ ­ ­ ­ ­

echo- Echo- -


ping
echo ping- ... Linux -c -w -s -M do Windows -n -w -l -f

:
· ping , 3000 . · ...


traceroute / tracert
· TTL IP ICMP


traceroute / tracert
· TTL=1, · ICMP


traceroute / tracert
ICMP echo TCP SYN UDP TTL TTL Linux -I, --icmp -T, --tcp -U, --udp -f -m -q -N -w Windows =icmp --=1 -h ---w (ms)

: · stanford.edu · ? · ?


traceroute ?
Domain Name System (DNS) · · DNS- · (, IP (A, AAAA)) · DNS UDP:53


DNS
ip :
nslookup [] dig [@]

ip arpa:
ya.ru (93.158.134.3) dig 3.134.158.93.in-addr.arpa dig 8.8.8.8.in-addr.arpa


iperf
iperf e2e


iperf
udp tcp () () , -u -s -p -c -n -t



-i

: · ·


netcat (nc)
TCP UDP

Slide #12


netcat (nc)
IP UDP TCP * /bin/sh * -l port -s source_ip -p source_port -z -v -u -e filename -c cmd

* ­e ­ nc-traditional nc nc-openbsd


nc
:
user@client$ nc server 1234

:
user@server$ nc -l 1234



:
user@client$ nc server 3333 < backup.iso

:
user@server$ nc -l 3333 > backup.iso

Slide #14



· ():
· nc-traditional:
user@server$ nc ­l ­p 1234 ­e /bin/sh

· nc-openbsd
user@server$ rm -f /tmp/f; mkfifo /tmp/f user@server$ cat /tmp/f | /bin/sh -i 2>&1 | nc -l 127.0.0.1 1234 > /tmp/f

· ():
user@client$ nc server 1234
Slide #15