Score:0

TCPDUMP install problems

in flag

I'm getting an error when running the following command:

sudo setcap cap_net_raw,cap_net_admin=eip /usr/sbin/tcpdump

Which provides the following error:

Failed to set capabilities on file /usr/sbin/tcpdump (No such file or directory) The value of the capability argument is not permitted for a file. Or the file is not a regular (non-symlink) file

As of yet I haven't been able to find any solutions - and would be extremely grateful to anyone who could offer or help me find one.

Score:0
in flag

Running tcpdump as non root user

This is a short guide to setup tcpdump as a non root user but only so that specific users which are added to a group can actually run tcpdump. This is different from running tcpdump from sudo which will still actually be running tcpdump as a root user. Also you can check the file /usr/bin/tcpdump , if it does not resides at /usr/sbin/tcpdump

You can enable this for non root users in a secure method by using the following commands

groupadd tcpdump
addgroup <username> tcpdump
chown root.tcpdump /usr/sbin/tcpdump
chmod 0750 /usr/sbin/tcpdump
setcap "CAP_NET_RAW+eip" /usr/sbin/tcpdump

As a brief explanation of the above.

We create a group called tcpdump We then add the user or users that we want to be able to use tcpdump to the group. We then change the user/group of tcpdump to match root and the new group. We then make sure the permissions are set on tcpdump so that members of the group can execute it but other normal users cannot. We then use setcap to give the CAP_NET_RAW priviledge to the executable when it runs. This is so that tcpdump can open its raw socket which is not normally permitted unless you are root.

found on : https://www.stev.org/post/howtoruntcpdumpasroot

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.