Re: element for reading UDP packets

Eddie Kohler <[email protected]>
Newsgroups gmane.network.routing.click
Message-ID <CAF0C5SL3v9tB4tAudhRvVXhZTYtmB4ch1KqacNFyi9LpJQoYfw@mail.gmail.com>
The following IPClassifier selects all UDP packets and emits them on
output 0. All other packets go to output 1

f :: IPClassifier(udp, -)


IPFilter's code is complex because it is basically a compiler. If youw
ant to see how to access a UDP packet's fields look at IPPrint, or
CheckUDPHeader.  Use p->udp_header() for example

Eddie


On Tue, Nov 8, 2011 at 12:13 PM, Surendran P <[email protected]> wrote:
> Hi,
>  I am new to click. i'm trying to filter the packets on a particular UDP
> port and extract the packet information elements from it.
> I don't see element already defined for it. if i'm wrong, please guide to
> the correct element to do that.
> otherwise, please help me how could i write a new elements for UDP port ?.
> Actually, i can write a basic element. but by seeing the IPFilter, i dont
> understand how the code flow/logic goes in it and couldn't get the proper
> documentation for it as well. I'm almost confused for UDP. so, someone
> please help me to do this.
>
> i'm using click-2.0.1
>
> Thanks,
> Surendran
> _______________________________________________
> click mailing list
> [email protected]
> https://amsterdam.lcs.mit.edu/mailman/listinfo/click
>

_______________________________________________
click mailing list
[email protected]
https://amsterdam.lcs.mit.edu/mailman/listinfo/click
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.