Where Online Learning is simpler!
The C and C++ Include Header Files
/usr/include/openvpn/openvpn-msg.h
$ cat -n /usr/include/openvpn/openvpn-msg.h 1 /* 2 * OpenVPN -- An application to securely tunnel IP networks 3 * over a single TCP/UDP port, with support for SSL/TLS-based 4 * session authentication and key exchange, 5 * packet encryption, packet authentication, and 6 * packet compression. 7 * 8 * Copyright (C) 2013-2024 Heiko Hund
9 * 10 * This program is free software; you can redistribute it and/or modify 11 * it under the terms of the GNU General Public License version 2 12 * as published by the Free Software Foundation. 13 * 14 * This program is distributed in the hope that it will be useful, 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 * GNU General Public License for more details. 18 * 19 * You should have received a copy of the GNU General Public License along 20 * with this program; if not, write to the Free Software Foundation, Inc., 21 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 22 */ 23 24 #ifndef OPENVPN_MSG_H_ 25 #define OPENVPN_MSG_H_ 26 27 typedef enum { 28 msg_acknowledgement, 29 msg_add_address, 30 msg_del_address, 31 msg_add_route, 32 msg_del_route, 33 msg_add_dns_cfg, 34 msg_del_dns_cfg, 35 msg_add_nbt_cfg, 36 msg_del_nbt_cfg, 37 msg_flush_neighbors, 38 msg_add_block_dns, 39 msg_del_block_dns, 40 msg_register_dns, 41 msg_enable_dhcp, 42 msg_register_ring_buffers, 43 msg_set_mtu, 44 msg_add_wins_cfg, 45 msg_del_wins_cfg 46 } message_type_t; 47 48 typedef struct { 49 message_type_t type; 50 size_t size; 51 int message_id; 52 } message_header_t; 53 54 typedef union { 55 struct in_addr ipv4; 56 struct in6_addr ipv6; 57 } inet_address_t; 58 59 typedef struct { 60 int index; 61 char name[256]; 62 } interface_t; 63 64 typedef struct { 65 message_header_t header; 66 short family; 67 inet_address_t address; 68 int prefix_len; 69 interface_t iface; 70 } address_message_t; 71 72 typedef struct { 73 message_header_t header; 74 short family; 75 inet_address_t prefix; 76 int prefix_len; 77 inet_address_t gateway; 78 interface_t iface; 79 int metric; 80 } route_message_t; 81 82 typedef struct { 83 message_header_t header; 84 interface_t iface; 85 char domains[512]; 86 short family; 87 int addr_len; 88 inet_address_t addr[4]; /* support up to 4 dns addresses */ 89 } dns_cfg_message_t; 90 91 typedef struct { 92 message_header_t header; 93 interface_t iface; 94 int addr_len; 95 inet_address_t addr[4]; /* support up to 4 dns addresses */ 96 } wins_cfg_message_t; 97 98 typedef struct { 99 message_header_t header; 100 interface_t iface; 101 int disable_nbt; 102 int nbt_type; 103 char scope_id[256]; 104 struct in_addr primary_nbns; 105 struct in_addr secondary_nbns; 106 } nbt_cfg_message_t; 107 108 /* TODO: NTP */ 109 110 typedef struct { 111 message_header_t header; 112 short family; 113 interface_t iface; 114 } flush_neighbors_message_t; 115 116 typedef struct { 117 message_header_t header; 118 int error_number; 119 } ack_message_t; 120 121 typedef struct { 122 message_header_t header; 123 interface_t iface; 124 } block_dns_message_t; 125 126 typedef struct { 127 message_header_t header; 128 interface_t iface; 129 } enable_dhcp_message_t; 130 131 typedef struct { 132 message_header_t header; 133 HANDLE device; 134 HANDLE send_ring_handle; 135 HANDLE receive_ring_handle; 136 HANDLE send_tail_moved; 137 HANDLE receive_tail_moved; 138 } register_ring_buffers_message_t; 139 140 typedef struct { 141 message_header_t header; 142 interface_t iface; 143 short family; 144 int mtu; 145 } set_mtu_message_t; 146 147 #endif /* ifndef OPENVPN_MSG_H_ */
Contact us
|
About us
|
Term of use
|
Copyright © 2000-2025 MyWebUniversity.com ™