This is a static archive of our old Q&A Site. Please post any new questions and answers at ask.wireshark.org.

Can’t find configuration file of wireshark in Linux

0

Hi, I installed wireshark in a remote server.But I am not able to see the wireshark folder inside /home/username/.config/ or in /etc/wireshark.conf .

I have access to remote server only through ssh.

Actually I need to add some columns in preference file of wireshark.But I can't see preference file in any of these locations.

Right now I am doing the following method.But in the following code I need to add ip identification field(ip.id) also. Is there any method I can do it without adding a column in preference file.?

tshark -r capture.pcap -Y "udp or tcp and ip.dst == 192.22.167.00/24" -o "gui.column.format:\"Time\",\"%Yt\",\"Source address\",\"%s\",\"Protocol\",\"%p\",\"Destination address\",\"%d\",\"SrcPort\",\"%S\",\"DstPort\",\"%D\"" > text

Server is using Ubuntu Zesty Zapus(17.04) and wireshark version is 2.2.4.

Thanks in advance

Subin

asked 25 Jan '17, 10:05

subinjp's gravatar image

subinjp
417713
accept rate: 0%


One Answer:

1

Typically it's located in $HOME/.wireshark/, but if you want to add the ip.id field, you can do so with a custom column, such as \"IP ID\",\"%Cus:ip.id:0:R\" ... where the 0 indicates all occurrences of the field as opposed to only the 1st, 2nd, nth, or last occurrence, and the R indicates "Resolved", as opposed to "Unresolved", which typically makes more sense for things like addresses and ports.

answered 25 Jan '17, 10:17

cmaynard's gravatar image

cmaynard ♦♦
9.4k1038142
accept rate: 20%

edited 25 Jan '17, 10:55

Thank you very much for your response.It worked. Could you give a reference or a general pattern of adding custom columns in tshark.??

(25 Jan '17, 10:37) subinjp

Unfortunately, I don't think custom column formats are documented very well, at least not that I can find. Basically, the format is as I described though:

"Arbitrary Name","%Cus:fieldname" ... with optional occurrence and resolved/unresolved flag. Use an occurrence value of -1 for the last occurrence, 0 for all occurrences and any other positive integer n for the nth occurrence. I'm not entirely sure, but resolved (R)/unresolved(U) may depend upon whether name resolution is enabled or not for those fields where it's applicable.

(25 Jan '17, 11:00) cmaynard ♦♦

Thank you.:)

(25 Jan '17, 12:59) subinjp