Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(do not merge yet) Add support for no-capture and no-inject device flags. #1246

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Nov 24, 2024

  1. Add support for no-capture and no-inject device flags.

    Add PCAP_IF_NO_INJECT and PCAP_IF_NO_CAPTURE to the list of known device
    flags.  In show_devices_and_exit() do not print a shorthand number for
    and in find_interface_by_number() do not count no-capture devices.
    Update description on the "-D" flag in the man page.
    
    Before:
    1.enp8s0 [Up, Running, Connected]
    2.enp4s0 [Up, Running, Connected]
    3.ens5 [Up, Running, Connected]
    4.any (Pseudo-device that captures on all interfaces) [Up, Running]
    5.lo [Up, Running, Loopback]
    6.dag0 (alias for dag0:0) [none]
    7.dag0:0 (Rx stream 0) [none]
    8.dag0:1 (Tx stream 1) [none]
    9.dag16 (alias for dag16:0) [none]
    10.dag16:0 (Rx stream 0) [none]
    11.dag16:1 (Tx stream 1) [none]
    12.dag17 (alias for dag17:0) [none]
    13.dag17:0 (Rx stream 0) [none]
    14.dag17:1 (Tx stream 1) [none]
    15.bluetooth-monitor (Bluetooth Linux Monitor) [Wireless]
    16.nflog (Linux netfilter log (NFLOG) interface) [none]
    17.nfqueue (Linux netfilter queue (NFQUEUE) interface) [none]
    
    After:
    1.enp8s0 [Up, Running, Connected]
    2.enp4s0 [Up, Running, Connected]
    3.ens5 [Up, Running, Connected]
    4.any (Pseudo-device that captures on all interfaces) [Up, Running,
      NoInject]
    5.lo [Up, Running, Loopback]
    6.dag0 (alias for dag0:0) [NoInject]
    7.dag0:0 (Rx stream 0) [NoInject]
      dag0:1 (Tx stream 1) [NoCapture]
    8.dag16 (alias for dag16:0) [NoInject]
    9.dag16:0 (Rx stream 0) [NoInject]
      dag16:1 (Tx stream 1) [NoCapture]
    10.dag17 (alias for dag17:0) [NoInject]
    11.dag17:0 (Rx stream 0) [NoInject]
       dag17:1 (Tx stream 1) [NoCapture]
    12.bluetooth-monitor (Bluetooth Linux Monitor) [Wireless, NoInject]
    13.nflog (Linux netfilter log (NFLOG) interface) [NoInject]
    14.nfqueue (Linux netfilter queue (NFQUEUE) interface) [NoInject]
    infrastation committed Nov 24, 2024
    Configuration menu
    Copy the full SHA
    4065319 View commit details
    Browse the repository at this point in the history