diff options
author | Anas Nashif <anas.nashif@intel.com> | 2012-11-23 12:31:07 -0800 |
---|---|---|
committer | Anas Nashif <anas.nashif@intel.com> | 2012-11-23 12:31:07 -0800 |
commit | b55901027e1f7dbbb1c04aa50b0389097b25ab6b (patch) | |
tree | db59d339a3e0920f6a3fe646c4832895589cfd46 /packaging | |
parent | 4f594407831f6476157b25ef33f242dd7e1021e0 (diff) | |
download | tcpdump-b55901027e1f7dbbb1c04aa50b0389097b25ab6b.tar.gz tcpdump-b55901027e1f7dbbb1c04aa50b0389097b25ab6b.tar.bz2 tcpdump-b55901027e1f7dbbb1c04aa50b0389097b25ab6b.zip |
remove extra filesubmit/tizen/20130517.024222submit/tizen/20130509.184519submit/tizen/20130503.233113accepted/tizen/20130520.094352accepted/tizen/20130503.230851
Diffstat (limited to 'packaging')
-rw-r--r-- | packaging/tcpdump-qeth | 80 | ||||
-rw-r--r-- | packaging/tcpdump.spec | 3 |
2 files changed, 1 insertions, 82 deletions
diff --git a/packaging/tcpdump-qeth b/packaging/tcpdump-qeth deleted file mode 100644 index b5e9b89..0000000 --- a/packaging/tcpdump-qeth +++ /dev/null @@ -1,80 +0,0 @@ -#!/usr/bin/perl -# (C)2002 by IBM Corporation, published under terms of the GPL V2 -# Author: Holger Smolinski <smolinsk@de.ibm.com> -# this file is a wrapper around tcpdump, which provides the capability -# for debugging qeth and/or HiperSocket(TM) network interfaces under -# Linux for S/390 and zSeries. tcpdump Syntax is preserved. -# Bugs: When the input pipe ends the process is not stopped. - -use Getopt::Std; - -my $incmd,$outcmd; - -getopts ("adeflnNOpqRStuvxXc:C:F:i:m:r:s:T:w:E:",\%options); - -# Check which options to replace for the reader process -if ( defined($options{'r'}) ) { - $incmd = "cat $options{'r'}"; - $filter_out = 1; -} else { - $incmd = "tcpdump -l -w -"; - $filter_out = 0; - if ( defined($options{'i'}) ) { - $incmd .= " -i ".$options{'i'}; - delete $options{'i'}; # remove -i option from option list - } - foreach $key (@ARGV) { - $incmd .= " $key"; - } -} - -$outcmd = "tcpdump -r -"; -# Rebuild arglist for the writer process -delete $options{'r'}; # remove -r option from option list -foreach $key (keys %options) { - if ((index "adeflnNOpqRStuvxX",$key) >= 0 ) { - $outcmd .= " -$key"; - } else { - $outcmd .= " -$key $options{$key}"; - } - if ( $filter_out == 1 ) { - foreach $key (@ARGV) { - $outcmd .= " $key"; - } - } -} - -open READER,"$incmd|" or die "Cannot spawn reader command $incmd"; -open WRITER,"|$outcmd" or die "Cannot spawn writer command $outcmd"; - -sysread READER,$filehdr,24 or die "Cannot read file header"; -($magic,$version_major,$version_minor,$thiszone,$sigfigs,$snaplen,$linktype) = - unpack("ISSIIII",$filehdr); -$snaplen += 14; -$filehdr = pack ("ISSIIII",($magic,$version_major,$version_minor,$thiszone,$sigfigs,$snaplen,$linktype)); -syswrite WRITER,$filehdr,24; - -$etherheaderip6 = pack ("IIIS",(0,0,0,0x8dd)); -$etherheaderip4 = pack ("IIIS",(0,0,0,0x800)); - -while ( 1 ) { - $hdrd = 0; - do {$hdrd += sysread READER, $pkthdr, 16-$hdrd, $hdrd; } while ($hdrd < 16); - ($seconds,$usecs,$caplen,$len) = unpack ("IIII",$pkthdr); - $hdrd = 0; - do {$hdrd += sysread READER, $packet,$caplen-$hdrd, $hdrd; } while ($hdrd < $caplen); - $paktype = unpack("C",$packet); - if ( $paktype & 0xf0 == 0x60 ) { - $caplen += 14; - $len += 14; - $header = $etehrheaderip6; - } elsif ($paktype >= 0x45 && $paktype <= 0x4f ) { - $caplen += 14; - $len += 14; - $header = $etherheaderip4; - } else { - $header = ""; - } - $pkthdr = pack ("IIII",($seconds,$usecs,$caplen,$len)); - syswrite WRITER,"$pkthdr$header$packet",16+$caplen; -} diff --git a/packaging/tcpdump.spec b/packaging/tcpdump.spec index 1d77929..a6fae96 100644 --- a/packaging/tcpdump.spec +++ b/packaging/tcpdump.spec @@ -6,9 +6,8 @@ Summary: A Packet Sniffer Url: http://www.tcpdump.org/ Group: Productivity/Networking/Diagnostic Source: http://www.tcpdump.org/release/%{name}-%{version}.tar.gz -Source1: tcpdump-qeth BuildRequires: libpcap-devel -BuildRequires: libsmi-devel +#BuildRequires: libsmi-devel BuildRequires: openssl-devel %description |