Public bug reported:

dumpcap -g is supposed to have the output file created with group read
permission. It works only when specifying an output file with "-w".

Works (with -w):

$ sudo -u root -g $(id -ng) /usr/bin/dumpcap -g -i enp0s25 -p -w /tmp/foo.pcapng
[sudo] password for sdeziel: 
Capturing on 'enp0s25'
File: /tmp/foo.pcapng
Packets captured: 4
Packets received/dropped on interface 'enp0s25': 4/0 
(pcap:0/dumpcap:0/flushed:0/ps_ifdrop:0) (100.0%)

$ ll /tmp/foo.pcapng 
-rw-r----- 1 root sdeziel 1416 Jul 11 12:08 /tmp/foo.pcapng

Does not work (without -w):

$ sudo -u root -g $(id -ng) /usr/bin/dumpcap -g -i enp0s25 -p
Capturing on 'enp0s25'
File: /tmp/wireshark_enp0s25_20180711120842_0KgkEu.pcapng
Packets captured: 37
Packets received/dropped on interface 'enp0s25': 37/0 
(pcap:0/dumpcap:0/flushed:0/ps_ifdrop:0) (100.0%)

$ ll /tmp/wireshark_enp0s25_20180711120842_0KgkEu.pcapng
-rw------- 1 root sdeziel 5568 Jul 11 12:08 

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: wireshark-common 2.4.5-1
ProcVersionSignature: Ubuntu 4.15.0-24.26-generic 4.15.18
Uname: Linux 4.15.0-24-generic x86_64
NonfreeKernelModules: zfs zunicode zavl icp zcommon znvpair
ApportVersion: 2.20.9-0ubuntu7.2
Architecture: amd64
CurrentDesktop: ubuntu:GNOME
Date: Wed Jul 11 11:42:03 2018
InstallationDate: Installed on 2018-06-24 (16 days ago)
InstallationMedia: Ubuntu 18.04 LTS "Bionic Beaver" - Release amd64 (20180622)
 PATH=(custom, no user)
SourcePackage: wireshark
UpgradeStatus: No upgrade log present (probably fresh install)

** Affects: wireshark (Ubuntu)
     Importance: Undecided
         Status: New

** Tags: amd64 apport-bug bionic third-party-packages

You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

  dumpcap group read (-g) doesn't work without specifying an output file

To manage notifications about this bug go to:

ubuntu-bugs mailing list

Reply via email to