|
Zephyr API Documentation 4.5.99
A Scalable Open Source RTOS
|
Macros | |
| #define | NPF_IP_SRC_ADDR_ALLOWLIST(_name, _ip_addr_array, _ip_addr_num, _af) |
| Statically define a "ip address allowlist" packet filter condition. | |
| #define | NPF_IP_SRC_ADDR_BLOCKLIST(_name, _ip_addr_array, _ip_addr_num, _af) |
| Statically define a "ip address blocklist" packet filter condition. | |
| #define NPF_IP_SRC_ADDR_ALLOWLIST | ( | _name, | |
| _ip_addr_array, | |||
| _ip_addr_num, | |||
| _af ) |
#include <zephyr/net/net_pkt_filter.h>
Statically define a "ip address allowlist" packet filter condition.
This tests if the packet source ip address matches any of the ip addresses contained in the provided set.
The set holds addresses of one address family. A packet of another address family matches none of them, so the condition is false for it.
| _name | Name of the condition |
| _ip_addr_array | Array of struct net_in_addr or struct net_in6_addr items to test against |
| _ip_addr_num | number of IP addresses in the array |
| _af | Addresses family type (NET_AF_INET / NET_AF_INET6) in the array |
| #define NPF_IP_SRC_ADDR_BLOCKLIST | ( | _name, | |
| _ip_addr_array, | |||
| _ip_addr_num, | |||
| _af ) |
#include <zephyr/net/net_pkt_filter.h>
Statically define a "ip address blocklist" packet filter condition.
This tests if the packet source ip address matches none of the ip addresses contained in the provided set.
The set holds addresses of one address family. A packet of another address family matches none of them, so the condition is true for it.
| _name | Name of the condition |
| _ip_addr_array | Array of struct net_in_addr or struct net_in6_addr items to test against |
| _ip_addr_num | number of IP addresses in the array |
| _af | Addresses family type (NET_AF_INET / NET_AF_INET6) in the array |