Skip to content
This repository has been archived by the owner on Dec 10, 2020. It is now read-only.

tcpdump-style filtering #2

Closed
boristian opened this issue Jan 21, 2015 · 3 comments
Closed

tcpdump-style filtering #2

boristian opened this issue Jan 21, 2015 · 3 comments

Comments

@boristian
Copy link

Hi,

i have another question.
For the project i'm working on, i need tcpdump-style packet filtering. Here is the tcpdump-call what does the job:

$ tcpdump -i en4 ether proto 0x22f0

I something like this possible with the layer2 module?

I saw there is some filter related code in src/js/capture.js. When i naive tried to pass the filter as an option in the capture.Live constructor like this:

var capture = new layer2.capture.Live('en4', {filter: 'ether proto 0x22f0'});

all i got was an error:

> Error: link-layer multicast filters supported only on ethernet/FDDI/token ring/ARCNET/802.11/ATM LANE/Fibre Channel

Greets and thanks in advance,
Christian

@mtth
Copy link
Owner

mtth commented Jan 22, 2015

Filters weren't fully implemented yet (hence the missing documentation :) ). I just released a new version (0.1.6) which should support them. Let me know if you run into any issues.

@boristian
Copy link
Author

Works perfect, thank you.

@mtth
Copy link
Owner

mtth commented Jan 22, 2015

Glad to hear!

@mtth mtth closed this as completed Jan 22, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants