ipfixcol2-filter-inter(7)
π NAME π
okay so bestie, you've found ipfixcol2-filter-inter β that's the filter plugin, and it's an intermediate plugin for IPFIXcol2. It lives in the ipfixcol2-filter-inter(7) manual section 7, and it's lowkey the bouncer at the club door of your flow pipeline. π«Ά
β¨ DESCRIPTION β¨
This plugin does filtering of flow records, and it decides everything based on a filter expression. Flow records that do not match the filtering criteria you gave it? Discarded. Gone. Not invited to the party. π
π SUPPORTED OPERATIONS π
Here's everything your expression is allowed to do, no cap:
- Comparison operators β
==,<,>,<=,>=,!=. And if you just forget to type a comparison operator? The default comparison is==. It's giving "I assumed" but fr fr that's the behaviour. - The
containsoperator for substring comparison, e.g.DNSName contains "example". - Arithmetic operations β
+,-,*,/,%. - Bitwise operations β
not~,or|,and&,xor^. - The
inoperator for list comparison, e.g.port in [80, 443]. Obsessed with this one honestly. - The logical
and,or,notoperators.
π¦ VALUE TYPES π¦
- Numbers β can be integer or floating point. Integers can also be written in hexadecimal or binary form using the
0xor0bprefix. Floating point numbers also support exponential notation such as1.2345e+2. A number can be explicitly unsigned using theusuffix. Numbers also support size suffixesB,k,M,G,T, and time suffixesns,us,ms,s,m,d. So many suffixes, we ate. π - Strings β values enclosed in a pair of double quotes
". Supported escape sequences aren,r,tand". The escape sequences to write characters using their octal or hexadecimal value are also supported, e.g.ux22or042. - IP addresses β written in their usual format, e.g.
127.0.0.1or1234:5678:9abc:def1:2345:6789:abcd:ef12. The shortened IPv6 version is also supported, e.g.::ff. IP addresses can also contain a suffix specifying their prefix length, e.g.10.0.0.0/16. πΈ - MAC addresses β written in their usual format, e.g.
12:34:56:78:9a:bc. - Timestamps β use the ISO timestamp format, e.g.
2020-04-05T24:00Z.
π IPFIX FIELD IDENTIFICATORS π
So here's the tea: IPFIX fields can be identified using their name specified in the IPFIX information elements table, or their alias defined in the aliases.xml file. If the IPFIX name is used and the default iana table is being referred to, the iana: prefix can be omitted. π
Heads up bestie: one alias can point to multiple IPFIX information elements. It's not a 1:1 situation, it's a situationship.
The default location of the aliases file is /etc/libfds/system/aliases.xml.
π VALUE MAPPINGS π
Commonly used values can be mapped to a name using the mappings.xml file β for example, the name http when used in an expression like port http can refer to the value 80. So cute, so convenient. β¨
These names can have different meanings depending on the IPFIX field they're being compared with. The default location of the mappings file is /etc/libfds/system/mappings.xml.
π₯ EXAMPLE CONFIGURATION π₯
Here's what it looks like in the wild:
<intermediate>
<name>Filter</name>
<plugin>filter</plugin>
<params>
<expr>ip 10.0.0.0/16 and port in [80, 8080]</expr>
</params>
</intermediate>
The most common use case would be filtering based on a list of allowed IP address ranges. In that case, it's recommended to use the following construct for optimal performance β this is the main character config, fr:
<intermediate>
<name>Filter</name>
<plugin>filter</plugin>
<params>
<expr>srcip in [1.0.0.0/8, 2.2.0.0/16, 3.3.3.0/24] or dstip in [4.4.4.0/24]</expr>
</params>
</intermediate>
β PARAMETERS β
exprβ The filter expression. That's it, that's the whole parameter. Simple queen. π
π AUTHOR π
Michal SedlΓ‘k (xsedla0v@stud.fit.vutbr.cz)
πΈ COPYRIGHT πΈ
Copyright Β© 2020 CESNET, z.s.p.o.
omg okay that's the whole vibe check complete π«Ά this page is version 1.0, dated 2020-08-24, and it came to you straight from IPFIXcol collector (you know, the ipfixcol2-filter-inter(7) one). now go filter some flows bestie, you got this πβ¨
π¦ where this page comes from
- ubuntu stonking: ipfixcol2 2.8.0+20260701-1 Β· BSD-3-Clause OR GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms