|
ru.unix.bsd- RU.UNIX.BSD ------------------------------------------------------------------ From : Vladimir Podgorny 2:5020/400 23 Apr 2002 16:41:33 To : Andrew Khlebutin Subject : Re: Help with tcpdump -------------------------------------------------------------------------------- Andrew Khlebutin <andrey@hm.perm.ru> wrote: > Привет Всем! > > Поправьте мне пожалуйста руки - как заставить tcpdump грабить только > tcp? Пускаю так - говорит syntax error: [root@t-rex - 15:40:10 Tue Apr 23 ~] # grep -i tcp /etc/protocols tcp 6 TCP # transmission control protocol [root@t-rex - 15:39:17 Tue Apr 23 ~] # tcpdump -i eth0 \( proto 6 and port 80 \) tcpdump: listening on eth0 15:39:23.678459 www.ritlabs.com.http > andrey.1932: . 1626324657:1626326117(1460) ack 21882460 win 17520 (DF) 15:39:23.810552 andrey.1932 > www.ritlabs.com.http: . ack 1460 win 8760 (DF) 15:39:24.042632 oleg.1163 > forum.ixbt.com.http: P 5370826:5371269(443) ack 2194706816 win 8760 (DF) 15:39:24.195682 www.ritlabs.com.http > andrey.1932: . 1460:2920(1460) ack 1 win 17520 (DF) 15:39:24.309685 andrey.1932 > www.ritlabs.com.http: . ack 2920 win 8760 (DF) ^C > #tcpdump -vvvxX -s 0 dst host x.x.x.x ip proto tcp > /home/andrew/dump > tcpdump: syntax error > > Пытался так, всё равно: > #tcpdump -vvvxX -s 0 dst host x.x.x.x ip proto \tcp\ > /home/andrew/dump > > т.к. в мане написано: > ... > ip proto protocol > True if the packet is an IP packet (see > ip(4P)) of protocol type protocol. Protocol > can be a number or one of the names icmp, > icmp6, igmp, igrp, pim, ah, esp, udp, or > tcp. Note that the identifiers tcp, udp, > and icmp are also keywords and must be > escaped via backslash (\), which is \\ in > the C-shell. Note that this primitive does > not chase protocol header chain. > > -- > Заранее благодарен, > Андрей Хлебутин > -- VP992-RIPE --- ifmail v.2.15dev5 * Origin: Adamant ISP news server (2:5020/400) Вернуться к списку тем, сортированных по: возрастание даты уменьшение даты тема автор
Архивное /ru.unix.bsd/12034c19cde65.html, оценка из 5, голосов 10
|