You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If an existing network interface is taken down, pcap's next_packet method will indefinitely throw a generic error PcapError("The interface disappeared"), causing our associated loops to start spinning.
This issue manifests in two cases:
the currently monitored network interface is taken down during an ongoing packet capture
Even if the interface is later brought back up, the existing capture will still return the error, and a new capture must be re-instantiated to be able to correctly read packets from the interface again.
Right now, I'm not re-instantiating the capture so this means that new packets won't be seen by Sniffnet.
Note: this is based on my observation on macOS, but behaviour could be platform-dependent.
If an existing network interface is taken down,
pcap'snext_packetmethod will indefinitely throw a generic errorPcapError("The interface disappeared"), causing our associated loops to start spinning.This issue manifests in two cases:
Even if the interface is later brought back up, the existing capture will still return the error, and a new capture must be re-instantiated to be able to correctly read packets from the interface again.
Right now, I'm not re-instantiating the capture so this means that new packets won't be seen by Sniffnet.
Note: this is based on my observation on macOS, but behaviour could be platform-dependent.
Related issue: rust-pcap/pcap#393