]> The Tcpdump Group git mirrors - libpcap/commit
Make the error message for PCAP_ERROR_PERM_DENIED a little more open-ended.
authorGuy Harris <[email protected]>
Sat, 19 Mar 2022 02:16:52 +0000 (19:16 -0700)
committerGuy Harris <[email protected]>
Sat, 19 Mar 2022 06:26:35 +0000 (23:26 -0700)
commit88108a5774fc3ac7554ed910573fb4777c9914e9
tree5522f9f36ab799a190d6201ea282fca4a51d5e88
parent1bc6b04c2fba4a87ee670e5291b85bf4e8d08cdf
Make the error message for PCAP_ERROR_PERM_DENIED a little more open-ended.

PCAP_ERROR_PERM_DENIED can be returned for reasons other than "you don't
have any permission to capture on that device", e.g. it might be "you
have permission to capture on it, but not to capture on it with hardware
time stamps (as on Linux) or to capture in monitor mode or to...".

This leaves it more open-ended, in case we add support for
device-dependent or platform-dependent configuration parameters and some
of them require more privileges than just capturing with the default
setting does, without having to keep adding more PERM_DENIED error
codes.

This, along with some other changes, may help debug problems such as the
one in issue #1098.

(cherry picked from commit dcb90c46c20cb3483c4e53484adb3264dc7902f0)
pcap.c