Go to the documentation of this file.
1 /**
2  * @file dhcpv6_debug.h
3  * @brief Data logging functions for debugging purpose (DHCPv6)
4  *
5  * @section License
6  *
7  * SPDX-License-Identifier: GPL-2.0-or-later
8  *
9  * Copyright (C) 2010-2024 Oryx Embedded SARL. All rights reserved.
10  *
11  * This file is part of CycloneTCP Open.
12  *
13  * This program is free software; you can redistribute it and/or
14  * modify it under the terms of the GNU General Public License
15  * as published by the Free Software Foundation; either version 2
16  * of the License, or (at your option) any later version.
17  *
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21  * GNU General Public License for more details.
22  *
23  * You should have received a copy of the GNU General Public License
24  * along with this program; if not, write to the Free Software Foundation,
25  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
26  *
27  * @author Oryx Embedded SARL (www.oryx-embedded.com)
28  * @version 2.4.2
29  **/
31 #ifndef _DHCPV6_DEBUG_H
32 #define _DHCPV6_DEBUG_H
34 //Dependencies
35 #include "core/net.h"
36 #include "dhcpv6/dhcpv6_common.h"
37 #include "debug.h"
39 //C++ guard
40 #ifdef __cplusplus
41 extern "C" {
42 #endif
44 //Check current trace level
46  error_t dhcpv6DumpMessage(const void *message, size_t length);
47  error_t dhcpv6DumpOptions(const uint8_t *options, size_t length, uint_t level);
48  error_t dhcpv6DumpGenericOption(const Dhcpv6Option *option, uint_t level);
51  error_t dhcpv6DumpIaNaOption(const Dhcpv6Option *option, uint_t level);
52  error_t dhcpv6DumpIaTaOption(const Dhcpv6Option *option, uint_t level);
53  error_t dhcpv6DumpIaAddrOption(const Dhcpv6Option *option, uint_t level);
54  error_t dhcpv6DumpOroOption(const Dhcpv6Option *option, uint_t level);
58  error_t dhcpv6DumpAuthOption(const Dhcpv6Option *option, uint_t level);
70 #else
71  #define dhcpv6DumpMessage(message, length)
72 #endif
74 //C++ guard
75 #ifdef __cplusplus
76 }
77 #endif
79 #endif
error_t dhcpv6DumpIaNaOption(const Dhcpv6Option *option, uint_t level)
Dump IA_NA option.
Definition: dhcpv6_debug.c:405
error_t dhcpv6DumpReconfAcceptOption(const Dhcpv6Option *option, uint_t level)
Dump Reconfigure Accept option.
Definition: dhcpv6_debug.c:878
error_t dhcpv6DumpElapsedTimeOption(const Dhcpv6Option *option, uint_t level)
Dump Elapsed Time option.
Definition: dhcpv6_debug.c:569
error_t dhcpv6DumpAuthOption(const Dhcpv6Option *option, uint_t level)
Dump Authentication option.
Definition: dhcpv6_debug.c:661
uint8_t message[]
Definition: chap.h:154
error_t dhcpv6DumpPreferenceOption(const Dhcpv6Option *option, uint_t level)
Dump Preference option.
Definition: dhcpv6_debug.c:542
error_t dhcpv6DumpStatusCodeOption(const Dhcpv6Option *option, uint_t level)
Dump Status Code option.
Definition: dhcpv6_debug.c:724
Definitions common to DHCPv6 client, server and relay agent.
error_t dhcpv6DumpIaTaOption(const Dhcpv6Option *option, uint_t level)
Dump IA_TA option.
Definition: dhcpv6_debug.c:437
error_t dhcpv6DumpVendorClassOption(const Dhcpv6Option *option, uint_t level)
Dump Vendor Class option.
Definition: dhcpv6_debug.c:797
error_t dhcpv6DumpGenericOption(const Dhcpv6Option *option, uint_t level)
Dump generic DHCPv6 option.
Definition: dhcpv6_debug.c:351
error_t dhcpv6DumpReconfMessageOption(const Dhcpv6Option *option, uint_t level)
Dump Reconfigure Message option.
Definition: dhcpv6_debug.c:851
error_t dhcpv6DumpIaAddrOption(const Dhcpv6Option *option, uint_t level)
Dump IA Address option.
Definition: dhcpv6_debug.c:467
Error codes.
Definition: error.h:43
error_t dhcpv6DumpRelayMessageOption(const Dhcpv6Option *option, uint_t level)
Dump Relay Message option.
Definition: dhcpv6_debug.c:599
error_t dhcpv6DumpServerIdOption(const Dhcpv6Option *option, uint_t level)
Dump Server Identifier option.
Definition: dhcpv6_debug.c:387
error_t dhcpv6DumpDnsServersOption(const Dhcpv6Option *option, uint_t level)
Dump DNS Recursive Name Server option.
Definition: dhcpv6_debug.c:899
uint8_t length
Definition: tcp.h:368
error_t dhcpv6DumpClientIdOption(const Dhcpv6Option *option, uint_t level)
Dump Client Identifier option.
Definition: dhcpv6_debug.c:369
error_t dhcpv6DumpMessage(const void *message, size_t length)
Dump DHCPv6 message for debugging purpose.
Definition: dhcpv6_debug.c:123
error_t dhcpv6DumpOptions(const uint8_t *options, size_t length, uint_t level)
Dump DHCPv6 options for debugging purpose.
Definition: dhcpv6_debug.c:208
error_t dhcpv6DumpRapidCommitOption(const Dhcpv6Option *option, uint_t level)
Dump Rapid Commit option.
Definition: dhcpv6_debug.c:758
error_t dhcpv6DumpUserClassOption(const Dhcpv6Option *option, uint_t level)
Dump User Class option.
Definition: dhcpv6_debug.c:779
error_t dhcpv6DumpDomainListOption(const Dhcpv6Option *option, uint_t level)
Dump Domain Search List option.
Definition: dhcpv6_debug.c:936
uint8_t options[]
Definition: tcp.h:357
unsigned int uint_t
Definition: compiler_port.h:50
TCP/IP stack core.
error_t dhcpv6DumpOroOption(const Dhcpv6Option *option, uint_t level)
Dump Option Request option.
Definition: dhcpv6_debug.c:499
error_t dhcpv6DumpVendorSpecificInfoOption(const Dhcpv6Option *option, uint_t level)
Dump Vendor Specific Information option.
Definition: dhcpv6_debug.c:815
error_t dhcpv6DumpInterfaceIdOption(const Dhcpv6Option *option, uint_t level)
Dump Interface ID option.
Definition: dhcpv6_debug.c:833
Debugging facilities.
error_t dhcpv6DumpServerUnicastOption(const Dhcpv6Option *option, uint_t level)
Dump Server Unicast option.
Definition: dhcpv6_debug.c:697