Bug 809638

Summary: EPERM with -w x.dump
Product: [Fedora] Fedora Reporter: Pete Zaitcev <zaitcev>
Component: tcpdumpAssignee: Michal Sekletar <msekleta>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: jsynacek, msekleta
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-05-16 18:12:00 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
Fix permission denied error none

Description Pete Zaitcev 2012-04-03 21:27:29 UTC
Description of problem:

[zaitcev@lembas ~]$ ssh kvm-rei
Last login: Mon Apr  2 13:41:07 2012 from simbelmyne-gw.zaitcev.lan
[zaitcev@kvm-rei ~]$ su
Password: 
[root@kvm-rei zaitcev]# tcpdump -n -w xxxx
tcpdump: xxxx: Permission denied
[root@kvm-rei zaitcev]# 

Version-Release number of selected component (if applicable):

libpcap-1.2.1-2.fc17.x86_64
kernel-3.4.0-0.rc0.git1.2.fc18.x86_64
tcpdump-4.2.1-2.fc17.x86_64

How reproducible:

Synchronous

Steps to Reproduce:
1. login as a user
2. su
3. tcpdump -w x.dump
  
Actual results:

EPERM

Expected results:

Working

Additional info:

This worked fine in RHEL 6, regression.

SELinux is off:
[root@kvm-rei zaitcev]# cat /proc/cmdline
ro root=/dev/vda2 rd_NO_LVM rd_NO_LUKS rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYTABLE=us enforcing=0
[root@kvm-rei zaitcev]# getenforce 
Permissive

I suspect someone was tinkering with capabilities again.

Comment 1 Michal Sekletar 2012-05-16 14:54:14 UTC
Created attachment 584994 [details]
Fix permission denied error

Fixed in rawhide. http://koji.fedoraproject.org/koji/taskinfo?taskID=4081569
Feel free to give it a try. It should work now. Once patch gets reviewed I will push update to f17 as well (most likely tomorrow). Feedback is very welcome.

Comment 2 Pete Zaitcev 2012-05-16 18:12:00 UTC
Fix verified using the package tcpdump-4.2.1-3.fc18.x86_64 from Koji.

I see there may be other use cases, but this one works now.

Comment 3 Fedora Update System 2012-05-17 10:25:03 UTC
tcpdump-4.2.1-3.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/tcpdump-4.2.1-3.fc17

Comment 4 Fedora Update System 2012-05-29 10:23:18 UTC
tcpdump-4.2.1-3.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.