Wilders Security Forums  

Go Back   Wilders Security Forums > Software, Hardware and General Services > all things UNIX
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread
  #1  
Old May 4th, 2012, 09:35 PM
iceni60 iceni60 is offline
( ^o^)
 
Join Date: Jun 2004
Posts: 5,116
Default setting up Wireshark and tshark

this is so you can run both Wireshark and tshark as a user rather than root which is dangerous.

Code:
sudo apt-get install libcap2-bin wireshark sudo chgrp admin /usr/bin/dumpcap sudo chmod 750 /usr/bin/dumpcap sudo setcap cap_net_raw,cap_net_admin+eip /usr/bin/dumpcap
hopefully someone will find it useful

i was following this and getting this error -
Code:
tshark: Lua: Error during loading: [string "/usr/share/wireshark/init.lua"]:45: dofile has been disabled

the above commands, in the first code box, fixed the problem for me

1. Run the following command (as root or sudo root) to list the network interfaces:

tshark -D

2. Let us say you want to trace eth0, run the follwoing command:

tshark -F libpcap -w /tmp/eth0_tshark_trace.pcap -i eth0

-F libpcap specifies the file format of the trace. SAP support usually requests for libpcap.
-w /tmp/eth0_tshark_trace.pcap specifies the file name where the trace is written.
-i eth0 specifies that the trace is being written for the network interface eth0.

If you want to see the trace on the scree, use the following command:

tshark -i eth0

3. Once you have recreated the problem close tshark with ctrl+c
__________________
musical savant
-http://www.youtube.com/watch?v=liprsDr8GrE-
-http://www.youtube.com/watch?v=qpIigV7-kJk-

Last edited by iceni60 : May 4th, 2012 at 09:50 PM.
  #2  
Old May 5th, 2012, 07:58 AM
tlu's Avatar
tlu tlu is offline
Very Frequent Poster
 
Join Date: Sep 2004
Posts: 2,076
Default Re: setting up Wireshark and tshark

Quote:
Originally Posted by iceni60
this is so you can run both Wireshark and tshark as a user rather than root which is dangerous.

Code:
sudo apt-get install libcap2-bin wireshark sudo chgrp admin /usr/bin/dumpcap sudo chmod 750 /usr/bin/dumpcap sudo setcap cap_net_raw,cap_net_admin+eip /usr/bin/dumpcap

Exactly. One small additional comment: In Ubuntu 12.04 the "admin" group has been renamed to "adm".

So the 2nd command should look like this:

sudo chgrp adm /usr/bin/dumpcap

Normally I have no use for Wireshark. But recently I installed it to check if DNSCrypt is working on my system following the advice here. It does I had installed it using the method described here which changed compared to Ubuntu 11.10 due to 12.04 using dnsmasq as a local DNS cache.
 

Wilders Security Forums > Software, Hardware and General Services > all things UNIX « Previous Thread | Next Thread »

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Settings
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 09:29 PM.


Powered by vBulletin® Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Copyright ©2002 - 2013, Wilders Security Forums