Ethereal-users: Re: [Ethereal-users] Cannot chmod interface to allow non-root ethereal on Solari
Trebor Sreyb wrote:
I tried to 'chmod +rw' on my network interface on a
Solaris 9 system, but the chmod won't take - no error,
but the file permissions just don't change.
To quote the Solaris 9 chmod(1) man page:
operator
either +, -, or =, signifying how permissions are to be changed:
+
Add permissions.
If <permissions> is omitted, nothing is added.
If <who> is omitted, add the file mode bits represented by
permissions, except for the those with corresponding bits in the file
mode creation mask.
If <who> is present, add the file mode bits represented by the
permissions.
In the command "chmod +rw", <who> is omitted; if the umask is 022 (which
is, I think, the default on many UN*Xes), "chmod +rw" will have no
effect on the "group" or "other" "w" bit, i.e. a file with permissions
rw-r--r-- will, after the "chmod", still have permissions rw-r--r--.
If you have a umask of 022 or 002, and you want to turn on the group and
other "r" and "w" bits, you need to do "chmod a+rw", not just "chmod +rw".
Note, however, that:
Hence, I cannot run ethereal as non-root user.
at least some drivers in some versions of Solaris will
1) not allow you to turn promiscuous mode on if you're not root
and
2) not capture outgoing packets unless you're in promiscuous mode
so, no matter what the permissions are on the file, you will have to be
root in order to capture outgoing traffic.