]> git.ipfire.org Git - thirdparty/systemd.git/blob - src/systemd/sd-ndisc-redirect.h
Merge pull request #31648 from neighbourhoodie/review-content
[thirdparty/systemd.git] / src / systemd / sd-ndisc-redirect.h
1 /* SPDX-License-Identifier: LGPL-2.1-or-later */
2 #ifndef foosdndiscredirectfoo
3 #define foosdndiscredirectfoo
4
5 /***
6 systemd is free software; you can redistribute it and/or modify it
7 under the terms of the GNU Lesser General Public License as published by
8 the Free Software Foundation; either version 2.1 of the License, or
9 (at your option) any later version.
10
11 systemd is distributed in the hope that it will be useful, but
12 WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Lesser General Public License for more details.
15
16 You should have received a copy of the GNU Lesser General Public License
17 along with systemd; If not, see <https://www.gnu.org/licenses/>.
18 ***/
19
20 #include <inttypes.h>
21 #include <net/ethernet.h>
22 #include <netinet/in.h>
23 #include <netinet/ip6.h>
24 #include <sys/types.h>
25 #include <time.h>
26
27 #include "_sd-common.h"
28
29 _SD_BEGIN_DECLARATIONS;
30
31 typedef struct sd_ndisc_redirect sd_ndisc_redirect;
32
33 sd_ndisc_redirect* sd_ndisc_redirect_ref(sd_ndisc_redirect *na);
34 sd_ndisc_redirect* sd_ndisc_redirect_unref(sd_ndisc_redirect *na);
35 _SD_DEFINE_POINTER_CLEANUP_FUNC(sd_ndisc_redirect, sd_ndisc_redirect_unref);
36
37 int sd_ndisc_redirect_set_sender_address(sd_ndisc_redirect *rd, const struct in6_addr *addr);
38 int sd_ndisc_redirect_get_sender_address(sd_ndisc_redirect *na, struct in6_addr *ret);
39 int sd_ndisc_redirect_get_target_address(sd_ndisc_redirect *na, struct in6_addr *ret);
40 int sd_ndisc_redirect_get_destination_address(sd_ndisc_redirect *na, struct in6_addr *ret);
41 int sd_ndisc_redirect_get_target_mac(sd_ndisc_redirect *na, struct ether_addr *ret);
42 int sd_ndisc_redirect_get_redirected_header(sd_ndisc_redirect *na, struct ip6_hdr *ret);
43
44 _SD_END_DECLARATIONS;
45
46 #endif