diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:53 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:53 +0000 |
commit | a86c5f7cae7ec9a3398300555a0b644689d946a1 (patch) | |
tree | 39fe4b107c71174fd1e8a8ceb9a4d2aa14116248 /epan/iana-ip.h | |
parent | Releasing progress-linux version 4.2.6-1~progress7.99u1. (diff) | |
download | wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.tar.xz wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.zip |
Merging upstream version 4.4.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'epan/iana-ip.h')
-rw-r--r-- | epan/iana-ip.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/epan/iana-ip.h b/epan/iana-ip.h new file mode 100644 index 00000000..3f3efb92 --- /dev/null +++ b/epan/iana-ip.h @@ -0,0 +1,47 @@ +/* iana-ip.h + * + * Wireshark - Network traffic analyzer + * By Gerald Combs <gerald@wireshark.org> + * Copyright 1998 Gerald Combs + * + * SPDX-License-Identifier: GPL-2.0-or-later + */ +#ifndef __IANA_IP_H__ +#define __IANA_IP_H__ + +#include <wireshark.h> +#include <wsutil/inet_cidr.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +enum iana_ip { + WS_IANA_IPv4 = 4, + WS_IANA_IPv6 = 6, +}; + +struct ws_iana_ip_special_block { + enum iana_ip type; + union { + ipv4_addr_and_mask ipv4; + ipv6_addr_and_prefix ipv6; + } u_ip; + const char *name; + /* true = 1; false = 0; n/a = -1 */ + int source, destination, forwardable, global, reserved; +}; + +WS_DLL_PUBLIC +const struct ws_iana_ip_special_block * +ws_iana_ipv4_special_block_lookup(uint32_t ipnum); + +WS_DLL_PUBLIC +const struct ws_iana_ip_special_block * +ws_iana_ipv6_special_block_lookup(const ws_in6_addr *addr); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif |