2 # - use policykit to gain root
3 # - use %caps when rpm supports it: %attr(750,root,wireshark) %caps(cap_net_raw,cap_net_admin=eip) %{_sbindir}/dumpcap
6 %bcond_without kerberos5 # Kerberos V support
7 %bcond_without snmp # SNMP support
8 %bcond_without gui # without QT GUI
10 Summary: Network traffic and protocol analyzer
11 Summary(es.UTF-8): Analizador de tráfico de red
12 Summary(pl.UTF-8): Analizator ruchu i protokołów sieciowych
13 Summary(pt_BR.UTF-8): Analisador de tráfego de rede
14 Summary(ru.UTF-8): Анализатор сетевого траффика
15 Summary(uk.UTF-8): Аналізатор мережевого трафіку
20 Group: Networking/Utilities
21 Source0: https://www.wireshark.org/download/src/%{name}-%{version}.tar.xz
22 # Source0-md5: 258d62ac7434d126dc497303c8f7961b
23 Patch0: %{name}-desktop.patch
24 URL: https://www.wireshark.org/
25 BuildRequires: GeoIP-devel
26 BuildRequires: asciidoc
29 BuildRequires: c-ares-devel
30 BuildRequires: doxygen
32 BuildRequires: gcc >= 5:3.2
33 BuildRequires: glib2-devel >= 1:2.32
34 BuildRequires: gnutls-devel >= 3.2.0
35 %{?with_kerberos5:BuildRequires: heimdal-devel}
36 BuildRequires: libcap-devel
37 BuildRequires: libgcrypt-devel >= 1.4.2
38 BuildRequires: libmaxminddb-devel
39 BuildRequires: libnl-devel >= 3.2
40 BuildRequires: libpcap-devel >= 2:1.0.0-4
41 BuildRequires: libssh-devel >= 0.6.0
42 BuildRequires: libsmi-devel
43 BuildRequires: libstdc++-devel
44 BuildRequires: libtool >= 2:2.2.2
45 BuildRequires: libxml2-devel >= 2.0
46 BuildRequires: libxslt-progs
47 BuildRequires: lua52-devel
48 BuildRequires: lz4-devel
49 %{?with_snmp:BuildRequires: net-snmp-devel}
50 BuildRequires: nghttp2-devel
51 BuildRequires: perl-tools-pod
52 BuildRequires: pkgconfig >= 1:0.7
53 %{?with_gui:BuildRequires: portaudio-devel}
54 BuildRequires: python3 >= 1:3.4
55 BuildRequires: rpmbuild(macros) >= 1.527
56 %{?with_gui:BuildRequires: sbc-devel >= 1.0}
57 %{?with_qt:BuildRequires: speexdsp-devel}
58 BuildRequires: sed >= 4.0
59 BuildRequires: snappy-devel
60 BuildRequires: spandsp-devel
61 BuildRequires: tar >= 1:1.22
64 BuildRequires: zlib-devel
66 BuildRequires: Qt5Core-devel >= 5.2
67 BuildRequires: Qt5Multimedia-devel >= 5.2
68 BuildRequires: Qt5PrintSupport-devel >= 5.2
69 BuildRequires: Qt5Widgets-devel >= 5.2
70 BuildRequires: libstdc++-devel >= 5
71 BuildRequires: qt5-build >= 5.2
72 BuildRequires: qt5-linguist >= 5.2
74 Requires: %{name}-gui-common = %{version}-%{release}
75 Requires: gdk-pixbuf2 >= 2.26
77 Requires: gtk+2 >= 2:2.12.0
79 Requires: gtk+3 >= 3.0.0
83 Provides: ethereal-gnome
85 Obsoletes: ethereal-gnome
86 Obsoletes: wireshark-gui-common
87 Obsoletes: wireshark-qt
88 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
91 Wireshark is the name for powerful graphical network sniffer, traffic
92 and protocol analyzer based on GTK+ and libpcap libraries. It lets you
93 capture and interactively browse the contents of network frames with
94 vast knowledge of more than 100 network protocols. Wireshark has
95 severeal useful features, including a rich display filter language,
96 the ability to view the ASCII contents of a TCP connection and plug-in
99 %description -l es.UTF-8
100 Analizador de tráfico de red.
102 %description -l pl.UTF-8
103 Wireshark jest potężnym, graficznym snifferem, analizatorem ruchu oraz
104 protokołów sieciowych opartym na bibliotekach GTK+ oraz libpcap.
105 Umożliwia on przechwytywanie oraz interaktywną analizę zawartości
106 ramek oraz ponad stu protokołów sieciowych. Wireshark posiada wiele
107 użytecznych cech, takich jak rozbudowany język filtrów wyświetlania,
108 możliwość oglądania przebiegu sesji TCP oraz możliwość dołączania
111 %description -l pt_BR.UTF-8
112 O Wireshark é um analisador de protocolo de rede baseado no GTK+.
114 %description -l ru.UTF-8
115 Wireshark - это анализатор сетевого траффика для Unix-подобных ОС. Он
116 базируется на GTK+ и libpcap.
118 %description -l uk.UTF-8
119 Wireshark - це аналізатор мережевого трафіку для Unix-подібних ОС. Він
120 базується на GTK+ та libpcap.
123 Summary: Network traffic and protocol analyzer - common files
124 Summary(pl.UTF-8): Analizator ruchu i protokołów sieciowych - wspólne pliki
126 Requires: %{name}-libs = %{version}-%{release}
127 Requires: gnutls >= 3.1.10
128 Requires: libpcap >= 0.4
129 Requires: libssh >= 0.6.0
130 Provides: ethereal-common
131 Provides: group(wireshark)
132 Provides: wireshark-tools
133 Obsoletes: ethereal-common
134 Obsoletes: wireshark-tools
135 Requires(post,postun): /sbin/setcap
138 Wireshark is the name for powerful graphical network sniffer, traffic
139 and protocol analyzer based on GTK+ and libpcap libraries. It lets you
140 capture and interactively browse the contents of network frames with
141 vast knowledge of more than 100 network protocols. Wireshark has
142 severeal useful features, including a rich display filter language,
143 the ability to view the ASCII contents of a TCP connection and plug-in
146 This package provides the shared library, plugins, data and a set of
147 tools for manipulating capture files. It contains:
148 - capinfos - prints informatio about binary capture files,
149 - captype - prints the file types of capture files,
150 - dftest - shows display filter byte-code,
151 - dumpcap - dumps network traffic to a file,
152 - editcap - edit and/or translate the format of capture files,
153 - mergecap - merges two capture files into one,
154 - randpkt - generates libpcap trace file full of random packets,
155 - rawshark - dumps and analyzes raw libpcap data,
156 - text2cap - generate a capture file from an ASCII hexdump of packets.
158 %description common -l es.UTF-8
159 Analizador de tráfico de red.
161 %description common -l pl.UTF-8
162 Wireshark jest potężnym, graficznym snifferem, analizatorem ruchu oraz
163 protokołów sieciowych opartym na bibliotekach GTK+ oraz libpcap.
164 Umożliwia on przechwytywanie oraz interaktywną analizę zawartości
165 ramek oraz ponad stu protokołów sieciowych. Wireshark posiada wiele
166 użytecznych cech, takich jak rozbudowany język filtrów wyświetlania,
167 możliwość oglądania przebiegu sesji TCP oraz możliwość dołączania
170 Ten pakiet ten zawiera bibliotekę współdzieloną, wtyczki, dane oraz
171 zestaw narzędzi do obróbki plików z przechwyconymi pakietami,
173 - capinfos - do wyświetlania informacji o binarnych plikach zrzutu,
174 - captype - do wyświetlania rodzaju plików zrzutu,
175 - dftest - do pokazywania bajtkodu filtrów wyświetlania,
176 - dumpcap - do zrzucania ruchu sieciowego do pliku,
177 - editcap - do edycji plików i tłumaczenia ich na inne formaty,
178 - mergecap - do łączenia dwóch plików w jeden,
179 - randpkt - do generowania plikow cap z losowymi danymi,
180 - rawshark - do obróbki plików cap,
181 - text2cap - do generowania pliku cap z szesnastkowego zrzutu ASCII
184 %description common -l pt_BR.UTF-8
185 O Wireshark é um analisador de protocolo de rede baseado no GTK+.
187 %description common -l ru.UTF-8
188 Wireshark - это анализатор сетевого траффика для Unix-подобных ОС. Он
189 базируется на GTK+ и libpcap.
191 %description common -l uk.UTF-8
192 Wireshark - це аналізатор мережевого трафіку для Unix-подібних ОС. Він
193 базується на GTK+ та libpcap.
195 %package -n twireshark
196 Summary: Text-mode network traffic and protocol analyzer
197 Summary(pl.UTF-8): Tekstowy analizator ruchu i protokołów sieciowych
198 Summary(pt_BR.UTF-8): Analisador modo texto de tráfego de rede (sniffer)
200 Requires: %{name}-common = %{version}-%{release}
201 Requires: libpcap >= 0.4
205 %description -n twireshark
206 Twireshark is a network protocol analyzer. It lets you capture packet
207 data from a live network, or read packets from a previously saved
208 capture file, either printing a decoded form of those packets to the
209 standard output or writing the packets to a file. Twireshark's native
210 capture file format is libpcap format, which is also the format used
211 by tcpdump and various other tools.
213 %description -n twireshark -l pl.UTF-8
214 Twireshark jest analizatorem protokołów sieciowych. Pozwala na
215 przechwytywanie pakietów z sieci lub wczytywanie danych z pliku.
216 Zdekodowany wynik (a twireshark zna ponad 100 rozmaitych protokołów
217 sieciowych!) jest wyświetlony na ekranie. Natywnym formatem plików
218 tetherala jest format libpcap, tak więc jest on kompatybilny z
219 tcpdumpem i innymi podobnymi narzędziami.
221 %description -n twireshark -l pt_BR.UTF-8
222 Esta é uma versão para modo texto do analisador de tráfego de rede
226 Summary: Wireshark packet capture and dissection libraries
227 Summary(pl.UTF-8): Biblioteki Wiresharka do przechwytywania i sekcji pakietów
229 Requires: glib2 >= 1:2.32
230 Requires: libgcrypt >= 1.4.2
231 Requires: libnl >= 3.2
232 Obsoletes: libwiretap < 2.4.0
235 Wireshark packet capture and dissection libraries.
237 %description libs -l pl.UTF-8
238 Biblioteki Wiresharka do przechwytywania i sekcji pakietów.
241 Summary: Header files for Wireshark libraries
242 Summary(pl.UTF-8): Pliki nagłówkowe bibliotek Wiresharka
243 Group: Development/Libraries
244 Requires: %{name}-libs = %{version}-%{release}
245 Requires: glib2-devel >= 1:2.32
246 Requires: libgcrypt-devel >= 1.4.2
247 Requires: libnl-devel >= 3.2
248 Obsoletes: libwiretap-devel < 2.4.0
251 Header files for Wireshark libraries.
253 %description devel -l pl.UTF-8
254 Pliki nagłówkowe bibliotek Wiresharka.
261 %cmake -G "Unix Makefiles" \
262 -DDISABLE_WERROR=ON \
263 -DBUILD_wireshark=ON \
266 -DBUILD_mmdbresolve=ON \
267 -DBUILD_randpktdump=OFF \
268 -DBUILD_androiddump=OFF \
270 -DENABLE_PORTAUDIO=ON \
271 -DENABLE_PLUGINS=ON \
272 -DENABLE_NETLINK=ON \
273 -DBUILD_dcerpcidl2wrs=OFF
278 rm -rf $RPM_BUILD_ROOT
279 install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},%{_includedir}/wireshark}
282 DESTDIR=$RPM_BUILD_ROOT
284 cp -p image/wsicon48.png $RPM_BUILD_ROOT%{_pixmapsdir}/%{name}.png
286 %{?with_gui:cp -p wireshark.desktop $RPM_BUILD_ROOT%{_desktopdir}/wireshark.desktop}
288 # headers (from Fedora, inspired by debian/wireshark-dev.header-files)
289 install -d $RPM_BUILD_ROOT%{_includedir}/wireshark/{epan/{crypt,ftypes,dfilter,dissectors,wmem},wiretap,wsutil}
290 install config.h $RPM_BUILD_ROOT%{_includedir}/wireshark
291 install cfile.h file.h $RPM_BUILD_ROOT%{_includedir}/wireshark
292 install ws_diag_control.h $RPM_BUILD_ROOT%{_includedir}/wireshark
293 install ws_symbol_export.h $RPM_BUILD_ROOT%{_includedir}/wireshark
294 install epan/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/epan
295 install epan/crypt/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/epan/crypt
296 install epan/ftypes/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/epan/ftypes
297 install epan/dfilter/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/epan/dfilter
298 install epan/dissectors/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/epan/dissectors
299 install epan/wmem/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/epan/wmem
300 install wiretap/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/wiretap
301 install wsutil/*.h $RPM_BUILD_ROOT%{_includedir}/wireshark/wsutil
303 # plugins *.la are useless - *.so are loaded through gmodule
304 #%{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins/*/*/*.la
307 rm -rf $RPM_BUILD_ROOT
310 %update_mime_database
313 %update_mime_database
316 %groupadd -P %{name}-common -g 104 wireshark
319 /sbin/setcap 'CAP_NET_RAW+eip CAP_NET_ADMIN+eip' %{_bindir}/dumpcap
323 if [ "$1" = "0" ]; then
324 %groupremove wireshark
327 %post libs -p /sbin/ldconfig
328 %postun libs -p /sbin/ldconfig
332 %defattr(644,root,root,755)
333 %attr(755,root,root) %{_bindir}/wireshark
334 %{_desktopdir}/wireshark.desktop
336 %{_datadir}/appdata/wireshark.appdata.xml
337 %{_datadir}/mime/packages/wireshark.xml
338 %{_pixmapsdir}/%{name}.png
339 %{_iconsdir}/hicolor/16x16/apps/%{name}.png
340 %{_iconsdir}/hicolor/16x16/mimetypes/application-%{name}-doc.png
341 %{_iconsdir}/hicolor/24x24/apps/%{name}.png
342 %{_iconsdir}/hicolor/24x24/mimetypes/application-%{name}-doc.png
343 %{_iconsdir}/hicolor/32x32/apps/%{name}.png
344 %{_iconsdir}/hicolor/32x32/mimetypes/application-%{name}-doc.png
345 %{_iconsdir}/hicolor/48x48/apps/%{name}.png
346 %{_iconsdir}/hicolor/48x48/mimetypes/application-%{name}-doc.png
347 %{_iconsdir}/hicolor/64x64/apps/%{name}.png
348 %{_iconsdir}/hicolor/64x64/mimetypes/application-%{name}-doc.png
349 %{_iconsdir}/hicolor/128x128/apps/%{name}.png
350 %{_iconsdir}/hicolor/128x128/mimetypes/application-%{name}-doc.png
351 %{_iconsdir}/hicolor/256x256/apps/%{name}.png
352 %{_iconsdir}/hicolor/256x256/mimetypes/application-%{name}-doc.png
353 %{_iconsdir}/hicolor/scalable/apps/%{name}.svg
354 %{_mandir}/man1/wireshark.1*
358 %defattr(644,root,root,755)
359 %doc AUTHORS* ChangeLog NEWS README.md README.linux doc/README.*
360 %dir %{_libdir}/%{name}
361 %dir %{_libdir}/%{name}/extcap
362 %dir %{_libdir}/%{name}/plugins
363 %dir %{_libdir}/%{name}/plugins/3.0
364 %dir %{_libdir}/%{name}/plugins/3.0/codecs
365 %dir %{_libdir}/%{name}/plugins/3.0/epan
366 %dir %{_libdir}/%{name}/plugins/3.0/wiretap
367 %attr(755,root,root) %{_libdir}/%{name}/extcap/ciscodump
368 #%attr(755,root,root) %{_libdir}/%{name}/extcap/androiddump
369 #%attr(755,root,root) %{_libdir}/%{name}/extcap/randpktdump
370 %attr(755,root,root) %{_libdir}/%{name}/extcap/sshdump
371 %attr(755,root,root) %{_libdir}/%{name}/extcap/udpdump
372 %attr(755,root,root) %{_libdir}/%{name}/plugins/3.0/codecs/*.so
373 %attr(755,root,root) %{_libdir}/%{name}/plugins/3.0/epan/*.so
374 %attr(755,root,root) %{_libdir}/%{name}/plugins/3.0/wiretap/*.so
375 %attr(755,root,root) %{_bindir}/capinfos
376 %attr(755,root,root) %{_bindir}/captype
377 #%attr(755,root,root) %{_bindir}/dftest
378 %attr(750,root,wireshark) %{_bindir}/dumpcap
379 %attr(755,root,root) %{_bindir}/editcap
380 #%attr(755,root,root) %{_bindir}/idl2wrs
381 %attr(755,root,root) %{_bindir}/mergecap
382 %attr(755,root,root) %{_bindir}/mmdbresolve
383 %attr(755,root,root) %{_bindir}/randpkt
384 %attr(755,root,root) %{_bindir}/rawshark
385 %attr(755,root,root) %{_bindir}/reordercap
386 %attr(755,root,root) %{_bindir}/sharkd
387 %attr(755,root,root) %{_bindir}/text2pcap
388 #%attr(755,root,root) %{_bindir}/tfshark
389 %{_mandir}/man1/androiddump.1*
390 %{_mandir}/man1/capinfos.1*
391 %{_mandir}/man1/captype.1*
392 %{_mandir}/man1/ciscodump.1*
393 %{_mandir}/man1/dftest.1*
394 %{_mandir}/man1/dumpcap.1*
395 %{_mandir}/man1/editcap.1*
396 %{_mandir}/man1/mergecap.1*
397 %{_mandir}/man1/mmdbresolve.1*
398 %{_mandir}/man1/rawshark.1*
399 %{_mandir}/man1/randpkt.1*
400 %{_mandir}/man1/randpktdump.1*
401 %{_mandir}/man1/reordercap.1*
402 %{_mandir}/man1/sshdump.1*
403 %{_mandir}/man1/text2pcap.1*
404 %{_mandir}/man1/udpdump.1*
405 %{_mandir}/man4/extcap.4*
406 %{_mandir}/man4/wireshark-filter.4*
409 %defattr(644,root,root,755)
410 %attr(755,root,root) %{_bindir}/tshark
411 %{_mandir}/man1/tshark*.1*
414 %defattr(644,root,root,755)
415 #%doc wiretap/README*
416 %attr(755,root,root) %{_libdir}/libwireshark.so.*.*.*
417 %attr(755,root,root) %ghost %{_libdir}/libwireshark.so.12
418 %attr(755,root,root) %{_libdir}/libwiretap.so.*.*.*
419 %attr(755,root,root) %ghost %{_libdir}/libwiretap.so.9
420 %attr(755,root,root) %{_libdir}/libwscodecs.so.*.*.*
421 %attr(755,root,root) %ghost %{_libdir}/libwscodecs.so.2
422 %attr(755,root,root) %{_libdir}/libwsutil.so.*.*.*
423 %attr(755,root,root) %ghost %{_libdir}/libwsutil.so.10
426 %defattr(644,root,root,755)
427 %attr(755,root,root) %{_libdir}/libwireshark.so
428 %attr(755,root,root) %{_libdir}/libwiretap.so
429 %attr(755,root,root) %{_libdir}/libwscodecs.so
430 %attr(755,root,root) %{_libdir}/libwsutil.so
431 #%{_libdir}/libwireshark.la
432 #%{_libdir}/libwiretap.la
433 #%{_libdir}/libwscodecs.la
434 #%{_libdir}/libwsutil.la
435 %{_includedir}/wireshark
436 %{_pkgconfigdir}/wireshark.pc