1 1.1 christos /* 2 1.14 christos * Copyright (C) 1998-2026 Internet Systems Consortium, Inc. ("ISC") 3 1.1 christos * 4 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 5 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 6 1.9 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 7 1.1 christos */ 8 1.1 christos 9 1.1 christos /*************** 10 1.1 christos *************** 11 1.1 christos *************** THIS FILE IS AUTOMATICALLY GENERATED BY gen.c. 12 1.1 christos *************** DO NOT EDIT! 13 1.1 christos *************** 14 1.1 christos ***************/ 15 1.1 christos 16 1.1 christos /*! \file */ 17 1.1 christos 18 1.1 christos /* 19 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 20 1.1 christos * 21 1.9 christos * SPDX-License-Identifier: MPL-2.0 22 1.9 christos * 23 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 24 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 25 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 26 1.1 christos * 27 1.1 christos * See the COPYRIGHT file distributed with this work for additional 28 1.1 christos * information regarding copyright ownership. 29 1.1 christos */ 30 1.1 christos 31 1.11 christos #pragma once 32 1.1 christos 33 1.1 christos #include <isc/lang.h> 34 1.1 christos #include <isc/sockaddr.h> 35 1.1 christos 36 1.1 christos #include <dns/name.h> 37 1.1 christos #include <dns/types.h> 38 1.1 christos 39 1.1 christos ISC_LANG_BEGINDECLS 40 1.1 christos 41 1.1 christos typedef struct dns_rdatacommon { 42 1.6 christos dns_rdataclass_t rdclass; 43 1.6 christos dns_rdatatype_t rdtype; 44 1.6 christos ISC_LINK(struct dns_rdatacommon) link; 45 1.1 christos } dns_rdatacommon_t; 46 1.1 christos 47 1.1 christos #define DNS_RDATACOMMON_INIT(_data, _rdtype, _rdclass) \ 48 1.6 christos do { \ 49 1.6 christos (_data)->common.rdtype = (_rdtype); \ 50 1.6 christos (_data)->common.rdclass = (_rdclass); \ 51 1.1 christos ISC_LINK_INIT(&(_data)->common, link); \ 52 1.1 christos } while (0) 53 1.1 christos /* 54 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 55 1.1 christos * 56 1.9 christos * SPDX-License-Identifier: MPL-2.0 57 1.9 christos * 58 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 59 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 60 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 61 1.1 christos * 62 1.1 christos * See the COPYRIGHT file distributed with this work for additional 63 1.1 christos * information regarding copyright ownership. 64 1.1 christos */ 65 1.1 christos 66 1.1 christos /* */ 67 1.11 christos #pragma once 68 1.1 christos 69 1.1 christos typedef struct dns_rdata_in_a { 70 1.6 christos dns_rdatacommon_t common; 71 1.6 christos struct in_addr in_addr; 72 1.1 christos } dns_rdata_in_a_t; 73 1.1 christos /* 74 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 75 1.1 christos * 76 1.9 christos * SPDX-License-Identifier: MPL-2.0 77 1.9 christos * 78 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 79 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 80 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 81 1.1 christos * 82 1.1 christos * See the COPYRIGHT file distributed with this work for additional 83 1.1 christos * information regarding copyright ownership. 84 1.1 christos */ 85 1.1 christos 86 1.1 christos /* by Bjorn.Victor (at) it.uu.se, 2005-05-07 */ 87 1.1 christos /* Based on generic/mx_15.h */ 88 1.1 christos 89 1.11 christos #pragma once 90 1.1 christos 91 1.2 christos typedef uint16_t ch_addr_t; 92 1.1 christos 93 1.1 christos typedef struct dns_rdata_ch_a { 94 1.6 christos dns_rdatacommon_t common; 95 1.6 christos isc_mem_t *mctx; 96 1.6 christos dns_name_t ch_addr_dom; /* ch-addr domain for back mapping 97 1.6 christos * */ 98 1.6 christos ch_addr_t ch_addr; /* chaos address (16 bit) network 99 1.6 christos * order */ 100 1.1 christos } dns_rdata_ch_a_t; 101 1.1 christos /* 102 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 103 1.1 christos * 104 1.9 christos * SPDX-License-Identifier: MPL-2.0 105 1.9 christos * 106 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 107 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 108 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 109 1.1 christos * 110 1.1 christos * See the COPYRIGHT file distributed with this work for additional 111 1.1 christos * information regarding copyright ownership. 112 1.1 christos */ 113 1.1 christos 114 1.1 christos /* */ 115 1.11 christos #pragma once 116 1.1 christos 117 1.1 christos typedef struct dns_rdata_hs_a { 118 1.6 christos dns_rdatacommon_t common; 119 1.6 christos struct in_addr in_addr; 120 1.1 christos } dns_rdata_hs_a_t; 121 1.1 christos /* 122 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 123 1.1 christos * 124 1.9 christos * SPDX-License-Identifier: MPL-2.0 125 1.9 christos * 126 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 127 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 128 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 129 1.1 christos * 130 1.1 christos * See the COPYRIGHT file distributed with this work for additional 131 1.1 christos * information regarding copyright ownership. 132 1.1 christos */ 133 1.1 christos 134 1.1 christos /* */ 135 1.11 christos #pragma once 136 1.1 christos 137 1.1 christos typedef struct dns_rdata_ns { 138 1.6 christos dns_rdatacommon_t common; 139 1.6 christos isc_mem_t *mctx; 140 1.6 christos dns_name_t name; 141 1.1 christos } dns_rdata_ns_t; 142 1.1 christos /* 143 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 144 1.1 christos * 145 1.9 christos * SPDX-License-Identifier: MPL-2.0 146 1.9 christos * 147 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 148 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 149 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 150 1.1 christos * 151 1.1 christos * See the COPYRIGHT file distributed with this work for additional 152 1.1 christos * information regarding copyright ownership. 153 1.1 christos */ 154 1.1 christos 155 1.1 christos /* */ 156 1.11 christos #pragma once 157 1.1 christos 158 1.1 christos typedef struct dns_rdata_md { 159 1.6 christos dns_rdatacommon_t common; 160 1.6 christos isc_mem_t *mctx; 161 1.6 christos dns_name_t md; 162 1.1 christos } dns_rdata_md_t; 163 1.1 christos /* 164 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 165 1.1 christos * 166 1.9 christos * SPDX-License-Identifier: MPL-2.0 167 1.9 christos * 168 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 169 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 170 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 171 1.1 christos * 172 1.1 christos * See the COPYRIGHT file distributed with this work for additional 173 1.1 christos * information regarding copyright ownership. 174 1.1 christos */ 175 1.1 christos 176 1.1 christos /* */ 177 1.11 christos #pragma once 178 1.1 christos 179 1.1 christos typedef struct dns_rdata_mf { 180 1.6 christos dns_rdatacommon_t common; 181 1.6 christos isc_mem_t *mctx; 182 1.6 christos dns_name_t mf; 183 1.1 christos } dns_rdata_mf_t; 184 1.1 christos /* 185 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 186 1.1 christos * 187 1.9 christos * SPDX-License-Identifier: MPL-2.0 188 1.9 christos * 189 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 190 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 191 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 192 1.1 christos * 193 1.1 christos * See the COPYRIGHT file distributed with this work for additional 194 1.1 christos * information regarding copyright ownership. 195 1.1 christos */ 196 1.1 christos 197 1.11 christos #pragma once 198 1.1 christos 199 1.1 christos typedef struct dns_rdata_cname { 200 1.6 christos dns_rdatacommon_t common; 201 1.6 christos isc_mem_t *mctx; 202 1.6 christos dns_name_t cname; 203 1.1 christos } dns_rdata_cname_t; 204 1.1 christos /* 205 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 206 1.1 christos * 207 1.9 christos * SPDX-License-Identifier: MPL-2.0 208 1.9 christos * 209 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 210 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 211 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 212 1.1 christos * 213 1.1 christos * See the COPYRIGHT file distributed with this work for additional 214 1.1 christos * information regarding copyright ownership. 215 1.1 christos */ 216 1.1 christos 217 1.1 christos /* */ 218 1.11 christos #pragma once 219 1.1 christos 220 1.1 christos typedef struct dns_rdata_soa { 221 1.6 christos dns_rdatacommon_t common; 222 1.6 christos isc_mem_t *mctx; 223 1.6 christos dns_name_t origin; 224 1.6 christos dns_name_t contact; 225 1.6 christos uint32_t serial; /*%< host order */ 226 1.6 christos uint32_t refresh; /*%< host order */ 227 1.6 christos uint32_t retry; /*%< host order */ 228 1.6 christos uint32_t expire; /*%< host order */ 229 1.6 christos uint32_t minimum; /*%< host order */ 230 1.1 christos } dns_rdata_soa_t; 231 1.1 christos /* 232 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 233 1.1 christos * 234 1.9 christos * SPDX-License-Identifier: MPL-2.0 235 1.9 christos * 236 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 237 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 238 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 239 1.1 christos * 240 1.1 christos * See the COPYRIGHT file distributed with this work for additional 241 1.1 christos * information regarding copyright ownership. 242 1.1 christos */ 243 1.1 christos 244 1.1 christos /* */ 245 1.11 christos #pragma once 246 1.1 christos 247 1.1 christos typedef struct dns_rdata_mb { 248 1.6 christos dns_rdatacommon_t common; 249 1.6 christos isc_mem_t *mctx; 250 1.6 christos dns_name_t mb; 251 1.1 christos } dns_rdata_mb_t; 252 1.1 christos /* 253 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 254 1.1 christos * 255 1.9 christos * SPDX-License-Identifier: MPL-2.0 256 1.9 christos * 257 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 258 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 259 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 260 1.1 christos * 261 1.1 christos * See the COPYRIGHT file distributed with this work for additional 262 1.1 christos * information regarding copyright ownership. 263 1.1 christos */ 264 1.1 christos 265 1.1 christos /* */ 266 1.11 christos #pragma once 267 1.1 christos 268 1.1 christos typedef struct dns_rdata_mg { 269 1.6 christos dns_rdatacommon_t common; 270 1.6 christos isc_mem_t *mctx; 271 1.6 christos dns_name_t mg; 272 1.1 christos } dns_rdata_mg_t; 273 1.1 christos /* 274 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 275 1.1 christos * 276 1.9 christos * SPDX-License-Identifier: MPL-2.0 277 1.9 christos * 278 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 279 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 280 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 281 1.1 christos * 282 1.1 christos * See the COPYRIGHT file distributed with this work for additional 283 1.1 christos * information regarding copyright ownership. 284 1.1 christos */ 285 1.1 christos 286 1.1 christos /* */ 287 1.11 christos #pragma once 288 1.1 christos 289 1.1 christos typedef struct dns_rdata_mr { 290 1.6 christos dns_rdatacommon_t common; 291 1.6 christos isc_mem_t *mctx; 292 1.6 christos dns_name_t mr; 293 1.1 christos } dns_rdata_mr_t; 294 1.1 christos /* 295 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 296 1.1 christos * 297 1.9 christos * SPDX-License-Identifier: MPL-2.0 298 1.9 christos * 299 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 300 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 301 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 302 1.1 christos * 303 1.1 christos * See the COPYRIGHT file distributed with this work for additional 304 1.1 christos * information regarding copyright ownership. 305 1.1 christos */ 306 1.1 christos 307 1.1 christos /* */ 308 1.11 christos #pragma once 309 1.1 christos 310 1.1 christos typedef struct dns_rdata_null { 311 1.6 christos dns_rdatacommon_t common; 312 1.6 christos isc_mem_t *mctx; 313 1.6 christos uint16_t length; 314 1.6 christos unsigned char *data; 315 1.1 christos } dns_rdata_null_t; 316 1.1 christos /* 317 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 318 1.1 christos * 319 1.9 christos * SPDX-License-Identifier: MPL-2.0 320 1.9 christos * 321 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 322 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 323 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 324 1.1 christos * 325 1.1 christos * See the COPYRIGHT file distributed with this work for additional 326 1.1 christos * information regarding copyright ownership. 327 1.1 christos */ 328 1.1 christos 329 1.11 christos #pragma once 330 1.1 christos 331 1.6 christos typedef struct dns_rdata_in_wks { 332 1.6 christos dns_rdatacommon_t common; 333 1.6 christos isc_mem_t *mctx; 334 1.6 christos struct in_addr in_addr; 335 1.6 christos uint16_t protocol; 336 1.6 christos unsigned char *map; 337 1.6 christos uint16_t map_len; 338 1.1 christos } dns_rdata_in_wks_t; 339 1.1 christos /* 340 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 341 1.1 christos * 342 1.9 christos * SPDX-License-Identifier: MPL-2.0 343 1.9 christos * 344 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 345 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 346 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 347 1.1 christos * 348 1.1 christos * See the COPYRIGHT file distributed with this work for additional 349 1.1 christos * information regarding copyright ownership. 350 1.1 christos */ 351 1.1 christos 352 1.1 christos /* */ 353 1.11 christos #pragma once 354 1.1 christos 355 1.1 christos typedef struct dns_rdata_ptr { 356 1.6 christos dns_rdatacommon_t common; 357 1.6 christos isc_mem_t *mctx; 358 1.6 christos dns_name_t ptr; 359 1.1 christos } dns_rdata_ptr_t; 360 1.1 christos /* 361 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 362 1.1 christos * 363 1.9 christos * SPDX-License-Identifier: MPL-2.0 364 1.9 christos * 365 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 366 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 367 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 368 1.1 christos * 369 1.1 christos * See the COPYRIGHT file distributed with this work for additional 370 1.1 christos * information regarding copyright ownership. 371 1.1 christos */ 372 1.1 christos 373 1.11 christos #pragma once 374 1.1 christos 375 1.1 christos typedef struct dns_rdata_hinfo { 376 1.6 christos dns_rdatacommon_t common; 377 1.6 christos isc_mem_t *mctx; 378 1.6 christos char *cpu; 379 1.6 christos char *os; 380 1.6 christos uint8_t cpu_len; 381 1.6 christos uint8_t os_len; 382 1.1 christos } dns_rdata_hinfo_t; 383 1.1 christos /* 384 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 385 1.1 christos * 386 1.9 christos * SPDX-License-Identifier: MPL-2.0 387 1.9 christos * 388 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 389 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 390 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 391 1.1 christos * 392 1.1 christos * See the COPYRIGHT file distributed with this work for additional 393 1.1 christos * information regarding copyright ownership. 394 1.1 christos */ 395 1.1 christos 396 1.1 christos /* */ 397 1.11 christos #pragma once 398 1.1 christos 399 1.1 christos typedef struct dns_rdata_minfo { 400 1.6 christos dns_rdatacommon_t common; 401 1.6 christos isc_mem_t *mctx; 402 1.6 christos dns_name_t rmailbox; 403 1.6 christos dns_name_t emailbox; 404 1.1 christos } dns_rdata_minfo_t; 405 1.1 christos /* 406 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 407 1.1 christos * 408 1.9 christos * SPDX-License-Identifier: MPL-2.0 409 1.9 christos * 410 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 411 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 412 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 413 1.1 christos * 414 1.1 christos * See the COPYRIGHT file distributed with this work for additional 415 1.1 christos * information regarding copyright ownership. 416 1.1 christos */ 417 1.1 christos 418 1.1 christos /* */ 419 1.11 christos #pragma once 420 1.1 christos 421 1.1 christos typedef struct dns_rdata_mx { 422 1.6 christos dns_rdatacommon_t common; 423 1.6 christos isc_mem_t *mctx; 424 1.6 christos uint16_t pref; 425 1.6 christos dns_name_t mx; 426 1.1 christos } dns_rdata_mx_t; 427 1.1 christos /* 428 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 429 1.1 christos * 430 1.9 christos * SPDX-License-Identifier: MPL-2.0 431 1.9 christos * 432 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 433 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 434 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 435 1.1 christos * 436 1.1 christos * See the COPYRIGHT file distributed with this work for additional 437 1.1 christos * information regarding copyright ownership. 438 1.1 christos */ 439 1.1 christos 440 1.1 christos /* */ 441 1.11 christos #pragma once 442 1.1 christos 443 1.1 christos typedef struct dns_rdata_txt_string { 444 1.6 christos uint8_t length; 445 1.6 christos unsigned char *data; 446 1.1 christos } dns_rdata_txt_string_t; 447 1.1 christos 448 1.1 christos typedef struct dns_rdata_txt { 449 1.6 christos dns_rdatacommon_t common; 450 1.6 christos isc_mem_t *mctx; 451 1.6 christos unsigned char *txt; 452 1.6 christos uint16_t txt_len; 453 1.1 christos /* private */ 454 1.6 christos uint16_t offset; 455 1.1 christos } dns_rdata_txt_t; 456 1.1 christos 457 1.1 christos /* 458 1.1 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 459 1.1 christos * via rdatastructpre.h and rdatastructsuf.h. 460 1.1 christos */ 461 1.1 christos 462 1.1 christos isc_result_t 463 1.1 christos dns_rdata_txt_first(dns_rdata_txt_t *); 464 1.1 christos 465 1.1 christos isc_result_t 466 1.1 christos dns_rdata_txt_next(dns_rdata_txt_t *); 467 1.1 christos 468 1.1 christos isc_result_t 469 1.1 christos dns_rdata_txt_current(dns_rdata_txt_t *, dns_rdata_txt_string_t *); 470 1.1 christos /* 471 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 472 1.1 christos * 473 1.9 christos * SPDX-License-Identifier: MPL-2.0 474 1.9 christos * 475 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 476 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 477 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 478 1.1 christos * 479 1.1 christos * See the COPYRIGHT file distributed with this work for additional 480 1.1 christos * information regarding copyright ownership. 481 1.1 christos */ 482 1.1 christos 483 1.11 christos #pragma once 484 1.1 christos 485 1.1 christos /*! 486 1.1 christos * \brief Per RFC1183 */ 487 1.1 christos 488 1.1 christos typedef struct dns_rdata_rp { 489 1.6 christos dns_rdatacommon_t common; 490 1.6 christos isc_mem_t *mctx; 491 1.6 christos dns_name_t mail; 492 1.6 christos dns_name_t text; 493 1.1 christos } dns_rdata_rp_t; 494 1.1 christos /* 495 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 496 1.1 christos * 497 1.9 christos * SPDX-License-Identifier: MPL-2.0 498 1.9 christos * 499 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 500 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 501 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 502 1.1 christos * 503 1.1 christos * See the COPYRIGHT file distributed with this work for additional 504 1.1 christos * information regarding copyright ownership. 505 1.1 christos */ 506 1.1 christos 507 1.11 christos #pragma once 508 1.1 christos 509 1.1 christos /*! 510 1.1 christos * \brief Per RFC1183 */ 511 1.1 christos 512 1.1 christos typedef struct dns_rdata_afsdb { 513 1.6 christos dns_rdatacommon_t common; 514 1.6 christos isc_mem_t *mctx; 515 1.6 christos uint16_t subtype; 516 1.6 christos dns_name_t server; 517 1.1 christos } dns_rdata_afsdb_t; 518 1.1 christos /* 519 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 520 1.1 christos * 521 1.9 christos * SPDX-License-Identifier: MPL-2.0 522 1.9 christos * 523 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 524 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 525 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 526 1.1 christos * 527 1.1 christos * See the COPYRIGHT file distributed with this work for additional 528 1.1 christos * information regarding copyright ownership. 529 1.1 christos */ 530 1.1 christos 531 1.11 christos #pragma once 532 1.1 christos 533 1.1 christos /*! 534 1.1 christos * \brief Per RFC1183 */ 535 1.1 christos 536 1.1 christos typedef struct dns_rdata_x25 { 537 1.6 christos dns_rdatacommon_t common; 538 1.6 christos isc_mem_t *mctx; 539 1.6 christos unsigned char *x25; 540 1.6 christos uint8_t x25_len; 541 1.1 christos } dns_rdata_x25_t; 542 1.1 christos /* 543 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 544 1.1 christos * 545 1.9 christos * SPDX-License-Identifier: MPL-2.0 546 1.9 christos * 547 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 548 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 549 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 550 1.1 christos * 551 1.1 christos * See the COPYRIGHT file distributed with this work for additional 552 1.1 christos * information regarding copyright ownership. 553 1.1 christos */ 554 1.1 christos 555 1.11 christos #pragma once 556 1.1 christos 557 1.1 christos /*! 558 1.1 christos * \brief Per RFC1183 */ 559 1.1 christos 560 1.1 christos typedef struct dns_rdata_isdn { 561 1.6 christos dns_rdatacommon_t common; 562 1.6 christos isc_mem_t *mctx; 563 1.6 christos char *isdn; 564 1.6 christos char *subaddress; 565 1.6 christos uint8_t isdn_len; 566 1.6 christos uint8_t subaddress_len; 567 1.1 christos } dns_rdata_isdn_t; 568 1.1 christos /* 569 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 570 1.1 christos * 571 1.9 christos * SPDX-License-Identifier: MPL-2.0 572 1.9 christos * 573 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 574 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 575 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 576 1.1 christos * 577 1.1 christos * See the COPYRIGHT file distributed with this work for additional 578 1.1 christos * information regarding copyright ownership. 579 1.1 christos */ 580 1.1 christos 581 1.11 christos #pragma once 582 1.1 christos 583 1.1 christos /*! 584 1.1 christos * \brief Per RFC1183 */ 585 1.1 christos 586 1.1 christos typedef struct dns_rdata_rt { 587 1.6 christos dns_rdatacommon_t common; 588 1.6 christos isc_mem_t *mctx; 589 1.6 christos uint16_t preference; 590 1.6 christos dns_name_t host; 591 1.1 christos } dns_rdata_rt_t; 592 1.1 christos /* 593 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 594 1.1 christos * 595 1.9 christos * SPDX-License-Identifier: MPL-2.0 596 1.9 christos * 597 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 598 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 599 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 600 1.1 christos * 601 1.1 christos * See the COPYRIGHT file distributed with this work for additional 602 1.1 christos * information regarding copyright ownership. 603 1.1 christos */ 604 1.1 christos 605 1.11 christos #pragma once 606 1.1 christos 607 1.1 christos /*! 608 1.1 christos * \brief Per RFC1706 */ 609 1.1 christos 610 1.1 christos typedef struct dns_rdata_in_nsap { 611 1.6 christos dns_rdatacommon_t common; 612 1.6 christos isc_mem_t *mctx; 613 1.6 christos unsigned char *nsap; 614 1.6 christos uint16_t nsap_len; 615 1.1 christos } dns_rdata_in_nsap_t; 616 1.1 christos /* 617 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 618 1.1 christos * 619 1.9 christos * SPDX-License-Identifier: MPL-2.0 620 1.9 christos * 621 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 622 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 623 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 624 1.1 christos * 625 1.1 christos * See the COPYRIGHT file distributed with this work for additional 626 1.1 christos * information regarding copyright ownership. 627 1.1 christos */ 628 1.1 christos 629 1.11 christos #pragma once 630 1.1 christos 631 1.1 christos /*! 632 1.1 christos * \brief Per RFC1348. Obsoleted in RFC 1706 - use PTR instead. */ 633 1.1 christos 634 1.1 christos typedef struct dns_rdata_in_nsap_ptr { 635 1.6 christos dns_rdatacommon_t common; 636 1.6 christos isc_mem_t *mctx; 637 1.6 christos dns_name_t owner; 638 1.1 christos } dns_rdata_in_nsap_ptr_t; 639 1.1 christos /* 640 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 641 1.1 christos * 642 1.9 christos * SPDX-License-Identifier: MPL-2.0 643 1.9 christos * 644 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 645 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 646 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 647 1.1 christos * 648 1.1 christos * See the COPYRIGHT file distributed with this work for additional 649 1.1 christos * information regarding copyright ownership. 650 1.1 christos */ 651 1.1 christos 652 1.11 christos #pragma once 653 1.1 christos 654 1.1 christos /*! 655 1.1 christos * \brief Per RFC2535 */ 656 1.1 christos 657 1.1 christos typedef struct dns_rdata_sig_t { 658 1.6 christos dns_rdatacommon_t common; 659 1.6 christos isc_mem_t *mctx; 660 1.6 christos dns_rdatatype_t covered; 661 1.6 christos dns_secalg_t algorithm; 662 1.6 christos uint8_t labels; 663 1.6 christos uint32_t originalttl; 664 1.6 christos uint32_t timeexpire; 665 1.6 christos uint32_t timesigned; 666 1.6 christos uint16_t keyid; 667 1.6 christos dns_name_t signer; 668 1.6 christos uint16_t siglen; 669 1.6 christos unsigned char *signature; 670 1.1 christos } dns_rdata_sig_t; 671 1.1 christos /* 672 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 673 1.1 christos * 674 1.9 christos * SPDX-License-Identifier: MPL-2.0 675 1.9 christos * 676 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 677 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 678 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 679 1.1 christos * 680 1.1 christos * See the COPYRIGHT file distributed with this work for additional 681 1.1 christos * information regarding copyright ownership. 682 1.1 christos */ 683 1.1 christos 684 1.11 christos #pragma once 685 1.1 christos 686 1.1 christos /*! 687 1.1 christos * \brief Per RFC2535 */ 688 1.1 christos 689 1.1 christos typedef struct dns_rdata_key { 690 1.6 christos dns_rdatacommon_t common; 691 1.6 christos isc_mem_t *mctx; 692 1.6 christos uint16_t flags; 693 1.6 christos dns_secproto_t protocol; 694 1.6 christos dns_secalg_t algorithm; 695 1.6 christos uint16_t datalen; 696 1.6 christos unsigned char *data; 697 1.1 christos } dns_rdata_key_t; 698 1.1 christos /* 699 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 700 1.1 christos * 701 1.9 christos * SPDX-License-Identifier: MPL-2.0 702 1.9 christos * 703 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 704 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 705 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 706 1.1 christos * 707 1.1 christos * See the COPYRIGHT file distributed with this work for additional 708 1.1 christos * information regarding copyright ownership. 709 1.1 christos */ 710 1.1 christos 711 1.11 christos #pragma once 712 1.1 christos 713 1.1 christos /*! 714 1.1 christos * \brief Per RFC2163 */ 715 1.1 christos 716 1.1 christos typedef struct dns_rdata_in_px { 717 1.6 christos dns_rdatacommon_t common; 718 1.6 christos isc_mem_t *mctx; 719 1.6 christos uint16_t preference; 720 1.6 christos dns_name_t map822; 721 1.6 christos dns_name_t mapx400; 722 1.1 christos } dns_rdata_in_px_t; 723 1.1 christos /* 724 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 725 1.1 christos * 726 1.9 christos * SPDX-License-Identifier: MPL-2.0 727 1.9 christos * 728 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 729 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 730 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 731 1.1 christos * 732 1.1 christos * See the COPYRIGHT file distributed with this work for additional 733 1.1 christos * information regarding copyright ownership. 734 1.1 christos */ 735 1.1 christos 736 1.11 christos #pragma once 737 1.1 christos 738 1.1 christos /*! 739 1.1 christos * \brief per RFC1712 */ 740 1.1 christos 741 1.1 christos typedef struct dns_rdata_gpos { 742 1.6 christos dns_rdatacommon_t common; 743 1.6 christos isc_mem_t *mctx; 744 1.6 christos char *longitude; 745 1.6 christos char *latitude; 746 1.6 christos char *altitude; 747 1.6 christos uint8_t long_len; 748 1.6 christos uint8_t lat_len; 749 1.6 christos uint8_t alt_len; 750 1.1 christos } dns_rdata_gpos_t; 751 1.1 christos /* 752 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 753 1.1 christos * 754 1.9 christos * SPDX-License-Identifier: MPL-2.0 755 1.9 christos * 756 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 757 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 758 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 759 1.1 christos * 760 1.1 christos * See the COPYRIGHT file distributed with this work for additional 761 1.1 christos * information regarding copyright ownership. 762 1.1 christos */ 763 1.1 christos 764 1.11 christos #pragma once 765 1.1 christos 766 1.1 christos /*! 767 1.1 christos * \brief Per RFC1886 */ 768 1.1 christos 769 1.1 christos typedef struct dns_rdata_in_aaaa { 770 1.6 christos dns_rdatacommon_t common; 771 1.6 christos struct in6_addr in6_addr; 772 1.1 christos } dns_rdata_in_aaaa_t; 773 1.1 christos /* 774 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 775 1.1 christos * 776 1.9 christos * SPDX-License-Identifier: MPL-2.0 777 1.9 christos * 778 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 779 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 780 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 781 1.1 christos * 782 1.1 christos * See the COPYRIGHT file distributed with this work for additional 783 1.1 christos * information regarding copyright ownership. 784 1.1 christos */ 785 1.1 christos 786 1.11 christos #pragma once 787 1.1 christos 788 1.1 christos /*! 789 1.1 christos * \brief Per RFC1876 */ 790 1.1 christos 791 1.1 christos typedef struct dns_rdata_loc_0 { 792 1.6 christos uint8_t version; /* must be first and zero */ 793 1.6 christos uint8_t size; 794 1.6 christos uint8_t horizontal; 795 1.6 christos uint8_t vertical; 796 1.6 christos uint32_t latitude; 797 1.6 christos uint32_t longitude; 798 1.6 christos uint32_t altitude; 799 1.1 christos } dns_rdata_loc_0_t; 800 1.1 christos 801 1.1 christos typedef struct dns_rdata_loc { 802 1.6 christos dns_rdatacommon_t common; 803 1.1 christos union { 804 1.1 christos dns_rdata_loc_0_t v0; 805 1.1 christos } v; 806 1.1 christos } dns_rdata_loc_t; 807 1.1 christos /* 808 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 809 1.1 christos * 810 1.9 christos * SPDX-License-Identifier: MPL-2.0 811 1.9 christos * 812 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 813 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 814 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 815 1.1 christos * 816 1.1 christos * See the COPYRIGHT file distributed with this work for additional 817 1.1 christos * information regarding copyright ownership. 818 1.1 christos */ 819 1.1 christos 820 1.11 christos #pragma once 821 1.1 christos 822 1.1 christos /*! 823 1.1 christos * \brief RFC2535 */ 824 1.1 christos 825 1.1 christos typedef struct dns_rdata_nxt { 826 1.6 christos dns_rdatacommon_t common; 827 1.6 christos isc_mem_t *mctx; 828 1.6 christos dns_name_t next; 829 1.6 christos unsigned char *typebits; 830 1.6 christos uint16_t len; 831 1.1 christos } dns_rdata_nxt_t; 832 1.1 christos /* 833 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 834 1.1 christos * 835 1.9 christos * SPDX-License-Identifier: MPL-2.0 836 1.9 christos * 837 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 838 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 839 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 840 1.1 christos * 841 1.1 christos * See the COPYRIGHT file distributed with this work for additional 842 1.1 christos * information regarding copyright ownership. 843 1.1 christos */ 844 1.1 christos 845 1.11 christos #pragma once 846 1.2 christos 847 1.2 christos /*! 848 1.2 christos * \brief http://ana-3.lcs.mit.edu/~jnc/nimrod/dns.txt 849 1.2 christos */ 850 1.2 christos 851 1.2 christos typedef struct dns_rdata_in_eid { 852 1.6 christos dns_rdatacommon_t common; 853 1.6 christos isc_mem_t *mctx; 854 1.6 christos unsigned char *eid; 855 1.6 christos uint16_t eid_len; 856 1.2 christos } dns_rdata_in_eid_t; 857 1.2 christos /* 858 1.2 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 859 1.2 christos * 860 1.9 christos * SPDX-License-Identifier: MPL-2.0 861 1.9 christos * 862 1.2 christos * This Source Code Form is subject to the terms of the Mozilla Public 863 1.2 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 864 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 865 1.2 christos * 866 1.2 christos * See the COPYRIGHT file distributed with this work for additional 867 1.2 christos * information regarding copyright ownership. 868 1.2 christos */ 869 1.2 christos 870 1.11 christos #pragma once 871 1.2 christos 872 1.2 christos /*! 873 1.2 christos * \brief http://ana-3.lcs.mit.edu/~jnc/nimrod/dns.txt 874 1.2 christos */ 875 1.2 christos 876 1.2 christos typedef struct dns_rdata_in_nimloc { 877 1.6 christos dns_rdatacommon_t common; 878 1.6 christos isc_mem_t *mctx; 879 1.6 christos unsigned char *nimloc; 880 1.6 christos uint16_t nimloc_len; 881 1.2 christos } dns_rdata_in_nimloc_t; 882 1.2 christos /* 883 1.2 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 884 1.2 christos * 885 1.9 christos * SPDX-License-Identifier: MPL-2.0 886 1.9 christos * 887 1.2 christos * This Source Code Form is subject to the terms of the Mozilla Public 888 1.2 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 889 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 890 1.2 christos * 891 1.2 christos * See the COPYRIGHT file distributed with this work for additional 892 1.2 christos * information regarding copyright ownership. 893 1.2 christos */ 894 1.2 christos 895 1.11 christos #pragma once 896 1.1 christos 897 1.1 christos /*! 898 1.1 christos * \brief Per RFC2782 */ 899 1.1 christos 900 1.1 christos typedef struct dns_rdata_in_srv { 901 1.6 christos dns_rdatacommon_t common; 902 1.6 christos isc_mem_t *mctx; 903 1.6 christos uint16_t priority; 904 1.6 christos uint16_t weight; 905 1.6 christos uint16_t port; 906 1.6 christos dns_name_t target; 907 1.1 christos } dns_rdata_in_srv_t; 908 1.1 christos /* 909 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 910 1.1 christos * 911 1.9 christos * SPDX-License-Identifier: MPL-2.0 912 1.9 christos * 913 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 914 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 915 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 916 1.1 christos * 917 1.1 christos * See the COPYRIGHT file distributed with this work for additional 918 1.1 christos * information regarding copyright ownership. 919 1.1 christos */ 920 1.1 christos 921 1.11 christos #pragma once 922 1.2 christos 923 1.2 christos /*! 924 1.2 christos * \brief Per RFC1706 */ 925 1.2 christos 926 1.2 christos typedef struct dns_rdata_in_atma { 927 1.6 christos dns_rdatacommon_t common; 928 1.6 christos isc_mem_t *mctx; 929 1.6 christos unsigned char format; 930 1.6 christos unsigned char *atma; 931 1.6 christos uint16_t atma_len; 932 1.2 christos } dns_rdata_in_atma_t; 933 1.2 christos /* 934 1.2 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 935 1.2 christos * 936 1.9 christos * SPDX-License-Identifier: MPL-2.0 937 1.9 christos * 938 1.2 christos * This Source Code Form is subject to the terms of the Mozilla Public 939 1.2 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 940 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 941 1.2 christos * 942 1.2 christos * See the COPYRIGHT file distributed with this work for additional 943 1.2 christos * information regarding copyright ownership. 944 1.2 christos */ 945 1.2 christos 946 1.11 christos #pragma once 947 1.1 christos 948 1.1 christos /*! 949 1.1 christos * \brief Per RFC2915 */ 950 1.1 christos 951 1.1 christos typedef struct dns_rdata_naptr { 952 1.6 christos dns_rdatacommon_t common; 953 1.6 christos isc_mem_t *mctx; 954 1.6 christos uint16_t order; 955 1.6 christos uint16_t preference; 956 1.6 christos char *flags; 957 1.6 christos uint8_t flags_len; 958 1.6 christos char *service; 959 1.6 christos uint8_t service_len; 960 1.6 christos char *regexp; 961 1.6 christos uint8_t regexp_len; 962 1.6 christos dns_name_t replacement; 963 1.1 christos } dns_rdata_naptr_t; 964 1.1 christos /* 965 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 966 1.1 christos * 967 1.9 christos * SPDX-License-Identifier: MPL-2.0 968 1.9 christos * 969 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 970 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 971 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 972 1.1 christos * 973 1.1 christos * See the COPYRIGHT file distributed with this work for additional 974 1.1 christos * information regarding copyright ownership. 975 1.1 christos */ 976 1.1 christos 977 1.11 christos #pragma once 978 1.1 christos 979 1.1 christos /*! 980 1.1 christos * \brief Per RFC2230 */ 981 1.1 christos 982 1.1 christos typedef struct dns_rdata_in_kx { 983 1.6 christos dns_rdatacommon_t common; 984 1.6 christos isc_mem_t *mctx; 985 1.6 christos uint16_t preference; 986 1.6 christos dns_name_t exchange; 987 1.1 christos } dns_rdata_in_kx_t; 988 1.1 christos /* 989 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 990 1.1 christos * 991 1.9 christos * SPDX-License-Identifier: MPL-2.0 992 1.9 christos * 993 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 994 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 995 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 996 1.1 christos * 997 1.1 christos * See the COPYRIGHT file distributed with this work for additional 998 1.1 christos * information regarding copyright ownership. 999 1.1 christos */ 1000 1.1 christos 1001 1.11 christos #pragma once 1002 1.1 christos 1003 1.1 christos /*% RFC2538 */ 1004 1.1 christos typedef struct dns_rdata_cert { 1005 1.6 christos dns_rdatacommon_t common; 1006 1.6 christos isc_mem_t *mctx; 1007 1.6 christos uint16_t type; 1008 1.6 christos uint16_t key_tag; 1009 1.6 christos uint8_t algorithm; 1010 1.6 christos uint16_t length; 1011 1.6 christos unsigned char *certificate; 1012 1.1 christos } dns_rdata_cert_t; 1013 1.1 christos /* 1014 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1015 1.1 christos * 1016 1.9 christos * SPDX-License-Identifier: MPL-2.0 1017 1.9 christos * 1018 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1019 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1020 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1021 1.1 christos * 1022 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1023 1.1 christos * information regarding copyright ownership. 1024 1.1 christos */ 1025 1.1 christos 1026 1.11 christos #pragma once 1027 1.1 christos 1028 1.1 christos /*! 1029 1.1 christos * \brief Per RFC2874 */ 1030 1.1 christos 1031 1.1 christos typedef struct dns_rdata_in_a6 { 1032 1.6 christos dns_rdatacommon_t common; 1033 1.6 christos isc_mem_t *mctx; 1034 1.6 christos dns_name_t prefix; 1035 1.6 christos uint8_t prefixlen; 1036 1.6 christos struct in6_addr in6_addr; 1037 1.1 christos } dns_rdata_in_a6_t; 1038 1.1 christos /* 1039 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1040 1.1 christos * 1041 1.9 christos * SPDX-License-Identifier: MPL-2.0 1042 1.9 christos * 1043 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1044 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1045 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1046 1.1 christos * 1047 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1048 1.1 christos * information regarding copyright ownership. 1049 1.1 christos */ 1050 1.1 christos 1051 1.11 christos #pragma once 1052 1.1 christos 1053 1.1 christos /*! 1054 1.1 christos * \brief per RFC2672 */ 1055 1.1 christos 1056 1.1 christos typedef struct dns_rdata_dname { 1057 1.6 christos dns_rdatacommon_t common; 1058 1.6 christos isc_mem_t *mctx; 1059 1.6 christos dns_name_t dname; 1060 1.1 christos } dns_rdata_dname_t; 1061 1.1 christos /* 1062 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1063 1.1 christos * 1064 1.9 christos * SPDX-License-Identifier: MPL-2.0 1065 1.9 christos * 1066 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1067 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1068 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1069 1.1 christos * 1070 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1071 1.1 christos * information regarding copyright ownership. 1072 1.1 christos */ 1073 1.1 christos 1074 1.11 christos #pragma once 1075 1.1 christos 1076 1.1 christos typedef struct dns_rdata_sink_t { 1077 1.6 christos dns_rdatacommon_t common; 1078 1.6 christos isc_mem_t *mctx; 1079 1.6 christos uint8_t meaning; 1080 1.6 christos uint8_t coding; 1081 1.6 christos uint8_t subcoding; 1082 1.6 christos uint16_t datalen; 1083 1.6 christos unsigned char *data; 1084 1.1 christos } dns_rdata_sink_t; 1085 1.1 christos /* 1086 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1087 1.1 christos * 1088 1.9 christos * SPDX-License-Identifier: MPL-2.0 1089 1.9 christos * 1090 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1091 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1092 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1093 1.1 christos * 1094 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1095 1.1 christos * information regarding copyright ownership. 1096 1.1 christos */ 1097 1.1 christos 1098 1.11 christos #pragma once 1099 1.1 christos 1100 1.1 christos /*! 1101 1.1 christos * \brief Per RFC2671 */ 1102 1.1 christos 1103 1.1 christos typedef struct dns_rdata_opt_opcode { 1104 1.6 christos uint16_t opcode; 1105 1.6 christos uint16_t length; 1106 1.6 christos unsigned char *data; 1107 1.1 christos } dns_rdata_opt_opcode_t; 1108 1.1 christos 1109 1.1 christos typedef struct dns_rdata_opt { 1110 1.6 christos dns_rdatacommon_t common; 1111 1.6 christos isc_mem_t *mctx; 1112 1.6 christos unsigned char *options; 1113 1.6 christos uint16_t length; 1114 1.1 christos /* private */ 1115 1.6 christos uint16_t offset; 1116 1.1 christos } dns_rdata_opt_t; 1117 1.1 christos 1118 1.1 christos /* 1119 1.1 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 1120 1.1 christos * via rdatastructpre.h and rdatastructsuf.h. 1121 1.1 christos */ 1122 1.1 christos 1123 1.1 christos isc_result_t 1124 1.1 christos dns_rdata_opt_first(dns_rdata_opt_t *); 1125 1.1 christos 1126 1.1 christos isc_result_t 1127 1.1 christos dns_rdata_opt_next(dns_rdata_opt_t *); 1128 1.1 christos 1129 1.1 christos isc_result_t 1130 1.1 christos dns_rdata_opt_current(dns_rdata_opt_t *, dns_rdata_opt_opcode_t *); 1131 1.1 christos /* 1132 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1133 1.1 christos * 1134 1.9 christos * SPDX-License-Identifier: MPL-2.0 1135 1.9 christos * 1136 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1137 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1138 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1139 1.1 christos * 1140 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1141 1.1 christos * information regarding copyright ownership. 1142 1.1 christos */ 1143 1.1 christos 1144 1.1 christos /* */ 1145 1.11 christos #pragma once 1146 1.1 christos 1147 1.1 christos typedef struct dns_rdata_apl_ent { 1148 1.6 christos bool negative; 1149 1.6 christos uint16_t family; 1150 1.6 christos uint8_t prefix; 1151 1.6 christos uint8_t length; 1152 1.6 christos unsigned char *data; 1153 1.1 christos } dns_rdata_apl_ent_t; 1154 1.1 christos 1155 1.1 christos typedef struct dns_rdata_in_apl { 1156 1.6 christos dns_rdatacommon_t common; 1157 1.6 christos isc_mem_t *mctx; 1158 1.1 christos /* type & class specific elements */ 1159 1.6 christos unsigned char *apl; 1160 1.6 christos uint16_t apl_len; 1161 1.1 christos /* private */ 1162 1.6 christos uint16_t offset; 1163 1.1 christos } dns_rdata_in_apl_t; 1164 1.1 christos 1165 1.1 christos /* 1166 1.1 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 1167 1.1 christos * via rdatastructpre.h and rdatastructsuf.h. 1168 1.1 christos */ 1169 1.1 christos 1170 1.1 christos isc_result_t 1171 1.1 christos dns_rdata_apl_first(dns_rdata_in_apl_t *); 1172 1.1 christos 1173 1.1 christos isc_result_t 1174 1.1 christos dns_rdata_apl_next(dns_rdata_in_apl_t *); 1175 1.1 christos 1176 1.1 christos isc_result_t 1177 1.1 christos dns_rdata_apl_current(dns_rdata_in_apl_t *, dns_rdata_apl_ent_t *); 1178 1.1 christos 1179 1.1 christos unsigned int 1180 1.1 christos dns_rdata_apl_count(const dns_rdata_in_apl_t *apl); 1181 1.1 christos /* 1182 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1183 1.1 christos * 1184 1.9 christos * SPDX-License-Identifier: MPL-2.0 1185 1.9 christos * 1186 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1187 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1188 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1189 1.1 christos * 1190 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1191 1.1 christos * information regarding copyright ownership. 1192 1.1 christos */ 1193 1.1 christos 1194 1.11 christos #pragma once 1195 1.1 christos 1196 1.1 christos /*! 1197 1.1 christos * \brief per draft-ietf-dnsext-delegation-signer-05.txt */ 1198 1.1 christos typedef struct dns_rdata_ds { 1199 1.6 christos dns_rdatacommon_t common; 1200 1.6 christos isc_mem_t *mctx; 1201 1.6 christos uint16_t key_tag; 1202 1.6 christos dns_secalg_t algorithm; 1203 1.6 christos dns_dsdigest_t digest_type; 1204 1.6 christos uint16_t length; 1205 1.6 christos unsigned char *digest; 1206 1.1 christos } dns_rdata_ds_t; 1207 1.1 christos /* 1208 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1209 1.1 christos * 1210 1.9 christos * SPDX-License-Identifier: MPL-2.0 1211 1.9 christos * 1212 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1213 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1214 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1215 1.1 christos * 1216 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1217 1.1 christos * information regarding copyright ownership. 1218 1.1 christos */ 1219 1.1 christos 1220 1.1 christos /*! 1221 1.1 christos * \brief Per RFC 4255 */ 1222 1.1 christos 1223 1.11 christos #pragma once 1224 1.1 christos 1225 1.1 christos typedef struct dns_rdata_sshfp { 1226 1.6 christos dns_rdatacommon_t common; 1227 1.6 christos isc_mem_t *mctx; 1228 1.6 christos uint8_t algorithm; 1229 1.6 christos uint8_t digest_type; 1230 1.6 christos uint16_t length; 1231 1.6 christos unsigned char *digest; 1232 1.1 christos } dns_rdata_sshfp_t; 1233 1.1 christos /* 1234 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1235 1.1 christos * 1236 1.9 christos * SPDX-License-Identifier: MPL-2.0 1237 1.9 christos * 1238 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1239 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1240 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1241 1.1 christos * 1242 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1243 1.1 christos * information regarding copyright ownership. 1244 1.1 christos */ 1245 1.1 christos 1246 1.11 christos #pragma once 1247 1.1 christos 1248 1.1 christos typedef struct dns_rdata_ipseckey { 1249 1.6 christos dns_rdatacommon_t common; 1250 1.6 christos isc_mem_t *mctx; 1251 1.6 christos uint8_t precedence; 1252 1.6 christos uint8_t gateway_type; 1253 1.6 christos uint8_t algorithm; 1254 1.6 christos struct in_addr in_addr; /* gateway type 1 */ 1255 1.6 christos struct in6_addr in6_addr; /* gateway type 2 */ 1256 1.6 christos dns_name_t gateway; /* gateway type 3 */ 1257 1.6 christos unsigned char *key; 1258 1.6 christos uint16_t keylength; 1259 1.1 christos } dns_rdata_ipseckey_t; 1260 1.1 christos /* 1261 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1262 1.1 christos * 1263 1.9 christos * SPDX-License-Identifier: MPL-2.0 1264 1.9 christos * 1265 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1266 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1267 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1268 1.1 christos * 1269 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1270 1.1 christos * information regarding copyright ownership. 1271 1.1 christos */ 1272 1.1 christos 1273 1.11 christos #pragma once 1274 1.1 christos 1275 1.1 christos /*! 1276 1.1 christos * \brief Per RFC2535 */ 1277 1.1 christos typedef struct dns_rdata_rrsig { 1278 1.6 christos dns_rdatacommon_t common; 1279 1.6 christos isc_mem_t *mctx; 1280 1.6 christos dns_rdatatype_t covered; 1281 1.6 christos dns_secalg_t algorithm; 1282 1.6 christos uint8_t labels; 1283 1.6 christos uint32_t originalttl; 1284 1.6 christos uint32_t timeexpire; 1285 1.6 christos uint32_t timesigned; 1286 1.6 christos uint16_t keyid; 1287 1.6 christos dns_name_t signer; 1288 1.6 christos uint16_t siglen; 1289 1.6 christos unsigned char *signature; 1290 1.1 christos } dns_rdata_rrsig_t; 1291 1.1 christos /* 1292 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1293 1.1 christos * 1294 1.9 christos * SPDX-License-Identifier: MPL-2.0 1295 1.9 christos * 1296 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1297 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1298 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1299 1.1 christos * 1300 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1301 1.1 christos * information regarding copyright ownership. 1302 1.1 christos */ 1303 1.1 christos 1304 1.11 christos #pragma once 1305 1.1 christos 1306 1.1 christos /*! 1307 1.1 christos * \brief Per RFC 3845 */ 1308 1.1 christos 1309 1.1 christos typedef struct dns_rdata_nsec { 1310 1.6 christos dns_rdatacommon_t common; 1311 1.6 christos isc_mem_t *mctx; 1312 1.6 christos dns_name_t next; 1313 1.6 christos unsigned char *typebits; 1314 1.6 christos uint16_t len; 1315 1.1 christos } dns_rdata_nsec_t; 1316 1.1 christos /* 1317 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1318 1.1 christos * 1319 1.9 christos * SPDX-License-Identifier: MPL-2.0 1320 1.9 christos * 1321 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1322 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1323 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1324 1.1 christos * 1325 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1326 1.1 christos * information regarding copyright ownership. 1327 1.1 christos */ 1328 1.1 christos 1329 1.11 christos #pragma once 1330 1.1 christos 1331 1.1 christos /*! 1332 1.1 christos * \brief per RFC2535 1333 1.1 christos */ 1334 1.1 christos 1335 1.1 christos typedef struct dns_rdata_key dns_rdata_dnskey_t; 1336 1.1 christos /* 1337 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1338 1.1 christos * 1339 1.9 christos * SPDX-License-Identifier: MPL-2.0 1340 1.9 christos * 1341 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1342 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1343 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1344 1.1 christos * 1345 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1346 1.1 christos * information regarding copyright ownership. 1347 1.1 christos */ 1348 1.1 christos 1349 1.1 christos /* */ 1350 1.11 christos #pragma once 1351 1.1 christos 1352 1.1 christos typedef struct dns_rdata_in_dhcid { 1353 1.6 christos dns_rdatacommon_t common; 1354 1.6 christos isc_mem_t *mctx; 1355 1.6 christos unsigned char *dhcid; 1356 1.6 christos unsigned int length; 1357 1.1 christos } dns_rdata_in_dhcid_t; 1358 1.1 christos /* 1359 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1360 1.1 christos * 1361 1.9 christos * SPDX-License-Identifier: MPL-2.0 1362 1.9 christos * 1363 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1364 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1365 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1366 1.1 christos * 1367 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1368 1.1 christos * information regarding copyright ownership. 1369 1.1 christos */ 1370 1.1 christos 1371 1.11 christos #pragma once 1372 1.1 christos 1373 1.1 christos /*! 1374 1.1 christos * \brief Per RFC 5155 */ 1375 1.1 christos 1376 1.1 christos #include <isc/iterated_hash.h> 1377 1.1 christos 1378 1.1 christos typedef struct dns_rdata_nsec3 { 1379 1.6 christos dns_rdatacommon_t common; 1380 1.6 christos isc_mem_t *mctx; 1381 1.6 christos dns_hash_t hash; 1382 1.6 christos unsigned char flags; 1383 1.6 christos dns_iterations_t iterations; 1384 1.6 christos unsigned char salt_length; 1385 1.6 christos unsigned char next_length; 1386 1.6 christos uint16_t len; 1387 1.6 christos unsigned char *salt; 1388 1.6 christos unsigned char *next; 1389 1.6 christos unsigned char *typebits; 1390 1.1 christos } dns_rdata_nsec3_t; 1391 1.1 christos 1392 1.1 christos /* 1393 1.1 christos * The corresponding NSEC3 interval is OPTOUT indicating possible 1394 1.1 christos * insecure delegations. 1395 1.1 christos */ 1396 1.1 christos #define DNS_NSEC3FLAG_OPTOUT 0x01U 1397 1.1 christos 1398 1.1 christos /*% 1399 1.1 christos * The following flags are used in the private-type record (implemented in 1400 1.1 christos * lib/dns/private.c) which is used to store NSEC3PARAM data during the 1401 1.1 christos * time when it is not legal to have an actual NSEC3PARAM record in the 1402 1.1 christos * zone. They are defined here because the private-type record uses the 1403 1.1 christos * same flags field for the OPTOUT flag above and for the private flags 1404 1.1 christos * below. XXX: This should be considered for refactoring. 1405 1.1 christos */ 1406 1.1 christos 1407 1.1 christos /*% 1408 1.1 christos * Non-standard, private type only. 1409 1.1 christos * 1410 1.1 christos * Create a corresponding NSEC3 chain. 1411 1.1 christos * Once the NSEC3 chain is complete this flag will be removed to signal 1412 1.1 christos * that there is a complete chain. 1413 1.1 christos * 1414 1.1 christos * This flag is automatically set when a NSEC3PARAM record is added to 1415 1.1 christos * the zone via UPDATE. 1416 1.1 christos * 1417 1.1 christos * NSEC3PARAM records containing this flag should never be published, 1418 1.1 christos * but if they are, they should be ignored by RFC 5155 compliant 1419 1.1 christos * nameservers. 1420 1.1 christos */ 1421 1.1 christos #define DNS_NSEC3FLAG_CREATE 0x80U 1422 1.1 christos 1423 1.1 christos /*% 1424 1.1 christos * Non-standard, private type only. 1425 1.1 christos * 1426 1.1 christos * The corresponding NSEC3 set is to be removed once the NSEC chain 1427 1.1 christos * has been generated. 1428 1.1 christos * 1429 1.1 christos * This flag is automatically set when the last active NSEC3PARAM record 1430 1.1 christos * is removed from the zone via UPDATE. 1431 1.1 christos * 1432 1.1 christos * NSEC3PARAM records containing this flag should never be published, 1433 1.1 christos * but if they are, they should be ignored by RFC 5155 compliant 1434 1.1 christos * nameservers. 1435 1.1 christos */ 1436 1.1 christos #define DNS_NSEC3FLAG_REMOVE 0x40U 1437 1.1 christos 1438 1.1 christos /*% 1439 1.1 christos * Non-standard, private type only. 1440 1.1 christos * 1441 1.1 christos * When set with the CREATE flag, a corresponding NSEC3 chain will be 1442 1.1 christos * created when the zone becomes capable of supporting one (i.e., when it 1443 1.1 christos * has a DNSKEY RRset containing at least one NSEC3-capable algorithm). 1444 1.1 christos * Without this flag, NSEC3 chain creation would be attempted immediately, 1445 1.1 christos * fail, and the private type record would be removed. With it, the NSEC3 1446 1.1 christos * parameters are stored until they can be used. When the zone has the 1447 1.1 christos * necessary prerequisites for NSEC3, then the INITIAL flag can be cleared, 1448 1.1 christos * and the record will be cleaned up normally. 1449 1.1 christos * 1450 1.1 christos * NSEC3PARAM records containing this flag should never be published, but 1451 1.1 christos * if they are, they should be ignored by RFC 5155 compliant nameservers. 1452 1.1 christos */ 1453 1.1 christos #define DNS_NSEC3FLAG_INITIAL 0x20U 1454 1.1 christos 1455 1.1 christos /*% 1456 1.1 christos * Non-standard, private type only. 1457 1.1 christos * 1458 1.1 christos * Prevent the creation of a NSEC chain before the last NSEC3 chain 1459 1.1 christos * is removed. This will normally only be set when the zone is 1460 1.1 christos * transitioning from secure with NSEC3 chains to insecure. 1461 1.1 christos * 1462 1.1 christos * NSEC3PARAM records containing this flag should never be published, 1463 1.1 christos * but if they are, they should be ignored by RFC 5155 compliant 1464 1.1 christos * nameservers. 1465 1.1 christos */ 1466 1.1 christos #define DNS_NSEC3FLAG_NONSEC 0x10U 1467 1.1 christos /* 1468 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1469 1.1 christos * 1470 1.9 christos * SPDX-License-Identifier: MPL-2.0 1471 1.9 christos * 1472 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1473 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1474 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1475 1.1 christos * 1476 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1477 1.1 christos * information regarding copyright ownership. 1478 1.1 christos */ 1479 1.1 christos 1480 1.11 christos #pragma once 1481 1.1 christos 1482 1.1 christos /*! 1483 1.1 christos * \brief Per RFC 5155 */ 1484 1.1 christos 1485 1.1 christos #include <isc/iterated_hash.h> 1486 1.1 christos 1487 1.1 christos typedef struct dns_rdata_nsec3param { 1488 1.6 christos dns_rdatacommon_t common; 1489 1.6 christos isc_mem_t *mctx; 1490 1.6 christos dns_hash_t hash; 1491 1.6 christos unsigned char flags; /* DNS_NSEC3FLAG_* */ 1492 1.6 christos dns_iterations_t iterations; 1493 1.6 christos unsigned char salt_length; 1494 1.6 christos unsigned char *salt; 1495 1.1 christos } dns_rdata_nsec3param_t; 1496 1.1 christos /* 1497 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1498 1.1 christos * 1499 1.9 christos * SPDX-License-Identifier: MPL-2.0 1500 1.9 christos * 1501 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1502 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1503 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1504 1.1 christos * 1505 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1506 1.1 christos * information regarding copyright ownership. 1507 1.1 christos */ 1508 1.1 christos 1509 1.11 christos #pragma once 1510 1.1 christos 1511 1.1 christos /*! 1512 1.1 christos * \brief per rfc6698.txt 1513 1.1 christos */ 1514 1.1 christos typedef struct dns_rdata_tlsa { 1515 1.6 christos dns_rdatacommon_t common; 1516 1.6 christos isc_mem_t *mctx; 1517 1.6 christos uint8_t usage; 1518 1.6 christos uint8_t selector; 1519 1.6 christos uint8_t match; 1520 1.6 christos uint16_t length; 1521 1.6 christos unsigned char *data; 1522 1.1 christos } dns_rdata_tlsa_t; 1523 1.1 christos /* 1524 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1525 1.1 christos * 1526 1.9 christos * SPDX-License-Identifier: MPL-2.0 1527 1.9 christos * 1528 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1529 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1530 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1531 1.1 christos * 1532 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1533 1.1 christos * information regarding copyright ownership. 1534 1.1 christos */ 1535 1.1 christos 1536 1.11 christos #pragma once 1537 1.1 christos 1538 1.1 christos typedef struct dns_rdata_tlsa dns_rdata_smimea_t; 1539 1.1 christos /* 1540 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1541 1.1 christos * 1542 1.9 christos * SPDX-License-Identifier: MPL-2.0 1543 1.9 christos * 1544 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1545 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1546 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1547 1.1 christos * 1548 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1549 1.1 christos * information regarding copyright ownership. 1550 1.1 christos */ 1551 1.1 christos 1552 1.11 christos #pragma once 1553 1.1 christos 1554 1.1 christos /* RFC 5205 */ 1555 1.1 christos 1556 1.1 christos typedef struct dns_rdata_hip { 1557 1.6 christos dns_rdatacommon_t common; 1558 1.6 christos isc_mem_t *mctx; 1559 1.6 christos unsigned char *hit; 1560 1.6 christos unsigned char *key; 1561 1.6 christos unsigned char *servers; 1562 1.6 christos uint8_t algorithm; 1563 1.6 christos uint8_t hit_len; 1564 1.6 christos uint16_t key_len; 1565 1.6 christos uint16_t servers_len; 1566 1.1 christos /* Private */ 1567 1.6 christos uint16_t offset; 1568 1.1 christos } dns_rdata_hip_t; 1569 1.1 christos 1570 1.1 christos isc_result_t 1571 1.1 christos dns_rdata_hip_first(dns_rdata_hip_t *); 1572 1.1 christos 1573 1.1 christos isc_result_t 1574 1.1 christos dns_rdata_hip_next(dns_rdata_hip_t *); 1575 1.1 christos 1576 1.1 christos void 1577 1.1 christos dns_rdata_hip_current(dns_rdata_hip_t *, dns_name_t *); 1578 1.1 christos /* 1579 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1580 1.1 christos * 1581 1.9 christos * SPDX-License-Identifier: MPL-2.0 1582 1.9 christos * 1583 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1584 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1585 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1586 1.1 christos * 1587 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1588 1.1 christos * information regarding copyright ownership. 1589 1.1 christos */ 1590 1.1 christos 1591 1.1 christos /* */ 1592 1.11 christos #pragma once 1593 1.1 christos 1594 1.1 christos typedef struct dns_rdata_txt_string dns_rdata_ninfo_string_t; 1595 1.1 christos 1596 1.1 christos typedef struct dns_rdata_txt dns_rdata_ninfo_t; 1597 1.1 christos 1598 1.1 christos /* 1599 1.1 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 1600 1.1 christos * via rdatastructpre.h and rdatastructsuf.h. 1601 1.1 christos */ 1602 1.1 christos 1603 1.1 christos isc_result_t 1604 1.1 christos dns_rdata_ninfo_first(dns_rdata_ninfo_t *); 1605 1.1 christos 1606 1.1 christos isc_result_t 1607 1.1 christos dns_rdata_ninfo_next(dns_rdata_ninfo_t *); 1608 1.1 christos 1609 1.1 christos isc_result_t 1610 1.1 christos dns_rdata_ninfo_current(dns_rdata_ninfo_t *, dns_rdata_ninfo_string_t *); 1611 1.1 christos /* 1612 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1613 1.1 christos * 1614 1.9 christos * SPDX-License-Identifier: MPL-2.0 1615 1.9 christos * 1616 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1617 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1618 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1619 1.1 christos * 1620 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1621 1.1 christos * information regarding copyright ownership. 1622 1.1 christos */ 1623 1.1 christos 1624 1.11 christos #pragma once 1625 1.1 christos 1626 1.1 christos typedef struct dns_rdata_key dns_rdata_rkey_t; 1627 1.1 christos /* 1628 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1629 1.1 christos * 1630 1.9 christos * SPDX-License-Identifier: MPL-2.0 1631 1.9 christos * 1632 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1633 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1634 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1635 1.1 christos * 1636 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1637 1.1 christos * information regarding copyright ownership. 1638 1.1 christos */ 1639 1.1 christos 1640 1.6 christos /* 1641 1.6 christos * http://www.iana.org/assignments/dns-parameters/TALINK/talink-completed-template 1642 1.6 christos */ 1643 1.1 christos 1644 1.11 christos #pragma once 1645 1.1 christos 1646 1.1 christos typedef struct dns_rdata_talink { 1647 1.6 christos dns_rdatacommon_t common; 1648 1.6 christos isc_mem_t *mctx; 1649 1.6 christos dns_name_t prev; 1650 1.6 christos dns_name_t next; 1651 1.1 christos } dns_rdata_talink_t; 1652 1.1 christos /* 1653 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1654 1.1 christos * 1655 1.9 christos * SPDX-License-Identifier: MPL-2.0 1656 1.9 christos * 1657 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1658 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1659 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1660 1.1 christos * 1661 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1662 1.1 christos * information regarding copyright ownership. 1663 1.1 christos */ 1664 1.1 christos 1665 1.11 christos #pragma once 1666 1.1 christos 1667 1.1 christos /* CDS records have the same RDATA fields as DS records. */ 1668 1.1 christos typedef struct dns_rdata_ds dns_rdata_cds_t; 1669 1.1 christos /* 1670 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1671 1.1 christos * 1672 1.9 christos * SPDX-License-Identifier: MPL-2.0 1673 1.9 christos * 1674 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1675 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1676 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1677 1.1 christos * 1678 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1679 1.1 christos * information regarding copyright ownership. 1680 1.1 christos */ 1681 1.1 christos 1682 1.11 christos #pragma once 1683 1.1 christos 1684 1.1 christos /* CDNSKEY records have the same RDATA fields as DNSKEY records. */ 1685 1.1 christos typedef struct dns_rdata_key dns_rdata_cdnskey_t; 1686 1.1 christos /* 1687 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1688 1.1 christos * 1689 1.9 christos * SPDX-License-Identifier: MPL-2.0 1690 1.9 christos * 1691 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1692 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1693 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1694 1.1 christos * 1695 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1696 1.1 christos * information regarding copyright ownership. 1697 1.1 christos */ 1698 1.1 christos 1699 1.11 christos #pragma once 1700 1.1 christos 1701 1.1 christos typedef struct dns_rdata_openpgpkey { 1702 1.6 christos dns_rdatacommon_t common; 1703 1.6 christos isc_mem_t *mctx; 1704 1.6 christos uint16_t length; 1705 1.6 christos unsigned char *keyring; 1706 1.1 christos } dns_rdata_openpgpkey_t; 1707 1.1 christos /* 1708 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1709 1.1 christos * 1710 1.9 christos * SPDX-License-Identifier: MPL-2.0 1711 1.9 christos * 1712 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1713 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1714 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1715 1.1 christos * 1716 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1717 1.1 christos * information regarding copyright ownership. 1718 1.1 christos */ 1719 1.1 christos 1720 1.11 christos #pragma once 1721 1.1 christos 1722 1.1 christos /*! 1723 1.1 christos * \brief Per RFC 7477 1724 1.1 christos */ 1725 1.1 christos 1726 1.1 christos typedef struct dns_rdata_csync { 1727 1.6 christos dns_rdatacommon_t common; 1728 1.6 christos isc_mem_t *mctx; 1729 1.6 christos uint32_t serial; 1730 1.6 christos uint16_t flags; 1731 1.6 christos unsigned char *typebits; 1732 1.6 christos uint16_t len; 1733 1.1 christos } dns_rdata_csync_t; 1734 1.1 christos /* 1735 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1736 1.1 christos * 1737 1.9 christos * SPDX-License-Identifier: MPL-2.0 1738 1.9 christos * 1739 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1740 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1741 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1742 1.1 christos * 1743 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1744 1.1 christos * information regarding copyright ownership. 1745 1.1 christos */ 1746 1.1 christos 1747 1.11 christos #pragma once 1748 1.3 christos 1749 1.8 christos /* Known digest type(s). */ 1750 1.3 christos #define DNS_ZONEMD_DIGEST_SHA384 (1) 1751 1.8 christos #define DNS_ZONEMD_DIGEST_SHA512 (2) 1752 1.3 christos 1753 1.3 christos /* 1754 1.8 christos * \brief per RFC 8976 1755 1.3 christos */ 1756 1.3 christos typedef struct dns_rdata_zonemd { 1757 1.6 christos dns_rdatacommon_t common; 1758 1.6 christos isc_mem_t *mctx; 1759 1.6 christos uint32_t serial; 1760 1.8 christos uint8_t scheme; 1761 1.6 christos uint8_t digest_type; 1762 1.6 christos unsigned char *digest; 1763 1.6 christos uint16_t length; 1764 1.3 christos } dns_rdata_zonemd_t; 1765 1.9 christos /* 1766 1.9 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1767 1.9 christos * 1768 1.9 christos * SPDX-License-Identifier: MPL-2.0 1769 1.9 christos * 1770 1.9 christos * This Source Code Form is subject to the terms of the Mozilla Public 1771 1.9 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1772 1.9 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1773 1.9 christos * 1774 1.9 christos * See the COPYRIGHT file distributed with this work for additional 1775 1.9 christos * information regarding copyright ownership. 1776 1.9 christos */ 1777 1.9 christos 1778 1.11 christos #pragma once 1779 1.9 christos 1780 1.9 christos /*! 1781 1.9 christos * \brief Per draft-ietf-dnsop-svcb-https-02 1782 1.9 christos */ 1783 1.9 christos 1784 1.9 christos typedef struct dns_rdata_in_svcb { 1785 1.9 christos dns_rdatacommon_t common; 1786 1.9 christos isc_mem_t *mctx; 1787 1.9 christos uint16_t priority; 1788 1.9 christos dns_name_t svcdomain; 1789 1.9 christos unsigned char *svc; 1790 1.9 christos uint16_t svclen; 1791 1.9 christos uint16_t offset; 1792 1.9 christos } dns_rdata_in_svcb_t; 1793 1.9 christos 1794 1.9 christos isc_result_t 1795 1.9 christos dns_rdata_in_svcb_first(dns_rdata_in_svcb_t *); 1796 1.9 christos 1797 1.9 christos isc_result_t 1798 1.9 christos dns_rdata_in_svcb_next(dns_rdata_in_svcb_t *); 1799 1.9 christos 1800 1.9 christos void 1801 1.9 christos dns_rdata_in_svcb_current(dns_rdata_in_svcb_t *, isc_region_t *); 1802 1.9 christos /* 1803 1.9 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1804 1.9 christos * 1805 1.9 christos * SPDX-License-Identifier: MPL-2.0 1806 1.9 christos * 1807 1.9 christos * This Source Code Form is subject to the terms of the Mozilla Public 1808 1.9 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1809 1.9 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1810 1.9 christos * 1811 1.9 christos * See the COPYRIGHT file distributed with this work for additional 1812 1.9 christos * information regarding copyright ownership. 1813 1.9 christos */ 1814 1.9 christos 1815 1.11 christos #pragma once 1816 1.9 christos 1817 1.9 christos /*! 1818 1.9 christos * \brief Per draft-ietf-dnsop-svcb-https-02 1819 1.9 christos */ 1820 1.9 christos 1821 1.9 christos /* 1822 1.9 christos * Wire and presentation formats for HTTPS are identical to SVCB. 1823 1.9 christos */ 1824 1.9 christos typedef struct dns_rdata_in_svcb dns_rdata_in_https_t; 1825 1.9 christos 1826 1.9 christos isc_result_t 1827 1.9 christos dns_rdata_in_https_first(dns_rdata_in_https_t *); 1828 1.9 christos 1829 1.9 christos isc_result_t 1830 1.9 christos dns_rdata_in_https_next(dns_rdata_in_https_t *); 1831 1.9 christos 1832 1.9 christos void 1833 1.9 christos dns_rdata_in_https_current(dns_rdata_in_https_t *, isc_region_t *); 1834 1.3 christos /* 1835 1.3 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1836 1.3 christos * 1837 1.9 christos * SPDX-License-Identifier: MPL-2.0 1838 1.9 christos * 1839 1.3 christos * This Source Code Form is subject to the terms of the Mozilla Public 1840 1.3 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1841 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1842 1.3 christos * 1843 1.3 christos * See the COPYRIGHT file distributed with this work for additional 1844 1.3 christos * information regarding copyright ownership. 1845 1.3 christos */ 1846 1.3 christos 1847 1.14 christos /* */ 1848 1.14 christos #pragma once 1849 1.14 christos 1850 1.14 christos typedef struct dns_rdata_dsync { 1851 1.14 christos dns_rdatacommon_t common; 1852 1.14 christos isc_mem_t *mctx; 1853 1.14 christos uint16_t type; 1854 1.14 christos uint8_t scheme; 1855 1.14 christos uint16_t port; 1856 1.14 christos dns_name_t target; 1857 1.14 christos } dns_rdata_dsync_t; 1858 1.14 christos /* 1859 1.14 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1860 1.14 christos * 1861 1.14 christos * SPDX-License-Identifier: MPL-2.0 1862 1.14 christos * 1863 1.14 christos * This Source Code Form is subject to the terms of the Mozilla Public 1864 1.14 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1865 1.14 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1866 1.14 christos * 1867 1.14 christos * See the COPYRIGHT file distributed with this work for additional 1868 1.14 christos * information regarding copyright ownership. 1869 1.14 christos */ 1870 1.14 christos 1871 1.14 christos #pragma once 1872 1.14 christos 1873 1.14 christos typedef struct dns_rdata_hhit_t { 1874 1.14 christos dns_rdatacommon_t common; 1875 1.14 christos isc_mem_t *mctx; 1876 1.14 christos uint16_t datalen; 1877 1.14 christos unsigned char *data; 1878 1.14 christos } dns_rdata_hhit_t; 1879 1.14 christos /* 1880 1.14 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1881 1.14 christos * 1882 1.14 christos * SPDX-License-Identifier: MPL-2.0 1883 1.14 christos * 1884 1.14 christos * This Source Code Form is subject to the terms of the Mozilla Public 1885 1.14 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1886 1.14 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1887 1.14 christos * 1888 1.14 christos * See the COPYRIGHT file distributed with this work for additional 1889 1.14 christos * information regarding copyright ownership. 1890 1.14 christos */ 1891 1.14 christos 1892 1.14 christos #pragma once 1893 1.14 christos 1894 1.14 christos typedef struct dns_rdata_brid_t { 1895 1.14 christos dns_rdatacommon_t common; 1896 1.14 christos isc_mem_t *mctx; 1897 1.14 christos uint16_t datalen; 1898 1.14 christos unsigned char *data; 1899 1.14 christos } dns_rdata_brid_t; 1900 1.14 christos /* 1901 1.14 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1902 1.14 christos * 1903 1.14 christos * SPDX-License-Identifier: MPL-2.0 1904 1.14 christos * 1905 1.14 christos * This Source Code Form is subject to the terms of the Mozilla Public 1906 1.14 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1907 1.14 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1908 1.14 christos * 1909 1.14 christos * See the COPYRIGHT file distributed with this work for additional 1910 1.14 christos * information regarding copyright ownership. 1911 1.14 christos */ 1912 1.14 christos 1913 1.11 christos #pragma once 1914 1.1 christos 1915 1.1 christos typedef struct dns_rdata_spf_string { 1916 1.6 christos uint8_t length; 1917 1.6 christos unsigned char *data; 1918 1.1 christos } dns_rdata_spf_string_t; 1919 1.1 christos 1920 1.1 christos typedef struct dns_rdata_spf { 1921 1.6 christos dns_rdatacommon_t common; 1922 1.6 christos isc_mem_t *mctx; 1923 1.6 christos unsigned char *txt; 1924 1.6 christos uint16_t txt_len; 1925 1.1 christos /* private */ 1926 1.6 christos uint16_t offset; 1927 1.1 christos } dns_rdata_spf_t; 1928 1.1 christos 1929 1.1 christos /* 1930 1.1 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 1931 1.1 christos * via rdatastructpre.h and rdatastructsuf.h. 1932 1.1 christos */ 1933 1.1 christos /* 1934 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1935 1.1 christos * 1936 1.9 christos * SPDX-License-Identifier: MPL-2.0 1937 1.9 christos * 1938 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1939 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1940 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1941 1.1 christos * 1942 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1943 1.1 christos * information regarding copyright ownership. 1944 1.1 christos */ 1945 1.1 christos 1946 1.1 christos /* */ 1947 1.11 christos #pragma once 1948 1.1 christos 1949 1.1 christos typedef struct dns_rdata_nid { 1950 1.6 christos dns_rdatacommon_t common; 1951 1.6 christos uint16_t pref; 1952 1.6 christos unsigned char nid[8]; 1953 1.1 christos } dns_rdata_nid_t; 1954 1.1 christos /* 1955 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1956 1.1 christos * 1957 1.9 christos * SPDX-License-Identifier: MPL-2.0 1958 1.9 christos * 1959 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1960 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1961 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1962 1.1 christos * 1963 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1964 1.1 christos * information regarding copyright ownership. 1965 1.1 christos */ 1966 1.1 christos 1967 1.1 christos /* */ 1968 1.11 christos #pragma once 1969 1.1 christos 1970 1.1 christos typedef struct dns_rdata_l32 { 1971 1.6 christos dns_rdatacommon_t common; 1972 1.6 christos uint16_t pref; 1973 1.6 christos struct in_addr l32; 1974 1.1 christos } dns_rdata_l32_t; 1975 1.1 christos /* 1976 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1977 1.1 christos * 1978 1.9 christos * SPDX-License-Identifier: MPL-2.0 1979 1.9 christos * 1980 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 1981 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 1982 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 1983 1.1 christos * 1984 1.1 christos * See the COPYRIGHT file distributed with this work for additional 1985 1.1 christos * information regarding copyright ownership. 1986 1.1 christos */ 1987 1.1 christos 1988 1.1 christos /* */ 1989 1.11 christos #pragma once 1990 1.1 christos 1991 1.1 christos typedef struct dns_rdata_l64 { 1992 1.6 christos dns_rdatacommon_t common; 1993 1.6 christos uint16_t pref; 1994 1.6 christos unsigned char l64[8]; 1995 1.1 christos } dns_rdata_l64_t; 1996 1.1 christos /* 1997 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 1998 1.1 christos * 1999 1.9 christos * SPDX-License-Identifier: MPL-2.0 2000 1.9 christos * 2001 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2002 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2003 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2004 1.1 christos * 2005 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2006 1.1 christos * information regarding copyright ownership. 2007 1.1 christos */ 2008 1.1 christos 2009 1.1 christos /* */ 2010 1.11 christos #pragma once 2011 1.1 christos 2012 1.1 christos typedef struct dns_rdata_lp { 2013 1.6 christos dns_rdatacommon_t common; 2014 1.6 christos isc_mem_t *mctx; 2015 1.6 christos uint16_t pref; 2016 1.6 christos dns_name_t lp; 2017 1.1 christos } dns_rdata_lp_t; 2018 1.1 christos /* 2019 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2020 1.1 christos * 2021 1.9 christos * SPDX-License-Identifier: MPL-2.0 2022 1.9 christos * 2023 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2024 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2025 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2026 1.1 christos * 2027 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2028 1.1 christos * information regarding copyright ownership. 2029 1.1 christos */ 2030 1.1 christos 2031 1.1 christos /* */ 2032 1.11 christos #pragma once 2033 1.1 christos 2034 1.1 christos typedef struct dns_rdata_eui48 { 2035 1.6 christos dns_rdatacommon_t common; 2036 1.6 christos unsigned char eui48[6]; 2037 1.1 christos } dns_rdata_eui48_t; 2038 1.1 christos /* 2039 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2040 1.1 christos * 2041 1.9 christos * SPDX-License-Identifier: MPL-2.0 2042 1.9 christos * 2043 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2044 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2045 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2046 1.1 christos * 2047 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2048 1.1 christos * information regarding copyright ownership. 2049 1.1 christos */ 2050 1.1 christos 2051 1.1 christos /* */ 2052 1.11 christos #pragma once 2053 1.1 christos 2054 1.1 christos typedef struct dns_rdata_eui64 { 2055 1.6 christos dns_rdatacommon_t common; 2056 1.6 christos unsigned char eui64[8]; 2057 1.1 christos } dns_rdata_eui64_t; 2058 1.1 christos /* 2059 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2060 1.1 christos * 2061 1.9 christos * SPDX-License-Identifier: MPL-2.0 2062 1.9 christos * 2063 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2064 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2065 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2066 1.1 christos * 2067 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2068 1.1 christos * information regarding copyright ownership. 2069 1.1 christos */ 2070 1.1 christos 2071 1.11 christos #pragma once 2072 1.1 christos 2073 1.1 christos /*! 2074 1.1 christos * \brief Per draft-ietf-dnsind-tkey-00.txt */ 2075 1.1 christos 2076 1.1 christos typedef struct dns_rdata_tkey { 2077 1.6 christos dns_rdatacommon_t common; 2078 1.6 christos isc_mem_t *mctx; 2079 1.6 christos dns_name_t algorithm; 2080 1.6 christos uint32_t inception; 2081 1.6 christos uint32_t expire; 2082 1.6 christos uint16_t mode; 2083 1.6 christos uint16_t error; 2084 1.6 christos uint16_t keylen; 2085 1.6 christos unsigned char *key; 2086 1.6 christos uint16_t otherlen; 2087 1.6 christos unsigned char *other; 2088 1.1 christos } dns_rdata_tkey_t; 2089 1.1 christos /* 2090 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2091 1.1 christos * 2092 1.9 christos * SPDX-License-Identifier: MPL-2.0 2093 1.9 christos * 2094 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2095 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2096 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2097 1.1 christos * 2098 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2099 1.1 christos * information regarding copyright ownership. 2100 1.1 christos */ 2101 1.1 christos 2102 1.11 christos #pragma once 2103 1.1 christos 2104 1.1 christos /*% RFC2845 */ 2105 1.1 christos typedef struct dns_rdata_any_tsig { 2106 1.6 christos dns_rdatacommon_t common; 2107 1.6 christos isc_mem_t *mctx; 2108 1.6 christos dns_name_t algorithm; 2109 1.6 christos uint64_t timesigned; 2110 1.6 christos uint16_t fudge; 2111 1.6 christos uint16_t siglen; 2112 1.6 christos unsigned char *signature; 2113 1.6 christos uint16_t originalid; 2114 1.6 christos uint16_t error; 2115 1.6 christos uint16_t otherlen; 2116 1.6 christos unsigned char *other; 2117 1.1 christos } dns_rdata_any_tsig_t; 2118 1.1 christos /* 2119 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2120 1.1 christos * 2121 1.9 christos * SPDX-License-Identifier: MPL-2.0 2122 1.9 christos * 2123 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2124 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2125 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2126 1.1 christos * 2127 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2128 1.1 christos * information regarding copyright ownership. 2129 1.1 christos */ 2130 1.1 christos 2131 1.11 christos #pragma once 2132 1.1 christos 2133 1.1 christos typedef struct dns_rdata_uri { 2134 1.6 christos dns_rdatacommon_t common; 2135 1.6 christos isc_mem_t *mctx; 2136 1.6 christos uint16_t priority; 2137 1.6 christos uint16_t weight; 2138 1.6 christos unsigned char *target; 2139 1.6 christos uint16_t tgt_len; 2140 1.1 christos } dns_rdata_uri_t; 2141 1.1 christos /* 2142 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2143 1.1 christos * 2144 1.9 christos * SPDX-License-Identifier: MPL-2.0 2145 1.9 christos * 2146 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2147 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2148 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2149 1.1 christos * 2150 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2151 1.1 christos * information regarding copyright ownership. 2152 1.1 christos */ 2153 1.1 christos 2154 1.11 christos #pragma once 2155 1.1 christos 2156 1.1 christos typedef struct dns_rdata_caa { 2157 1.6 christos dns_rdatacommon_t common; 2158 1.6 christos isc_mem_t *mctx; 2159 1.6 christos uint8_t flags; 2160 1.6 christos unsigned char *tag; 2161 1.6 christos uint8_t tag_len; 2162 1.6 christos unsigned char *value; 2163 1.6 christos uint16_t value_len; 2164 1.1 christos } dns_rdata_caa_t; 2165 1.1 christos /* 2166 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2167 1.1 christos * 2168 1.9 christos * SPDX-License-Identifier: MPL-2.0 2169 1.9 christos * 2170 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2171 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2172 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2173 1.1 christos * 2174 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2175 1.1 christos * information regarding copyright ownership. 2176 1.1 christos */ 2177 1.1 christos 2178 1.11 christos #pragma once 2179 1.1 christos 2180 1.1 christos typedef dns_rdata_txt_string_t dns_rdata_avc_string_t; 2181 1.1 christos 2182 1.1 christos typedef struct dns_rdata_avc { 2183 1.6 christos dns_rdatacommon_t common; 2184 1.6 christos isc_mem_t *mctx; 2185 1.6 christos unsigned char *data; 2186 1.6 christos uint16_t length; 2187 1.1 christos /* private */ 2188 1.6 christos uint16_t offset; 2189 1.1 christos } dns_rdata_avc_t; 2190 1.1 christos 2191 1.1 christos /* 2192 1.1 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 2193 1.1 christos * via rdatastructpre.h and rdatastructsuf.h. 2194 1.1 christos */ 2195 1.1 christos /* 2196 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2197 1.1 christos * 2198 1.9 christos * SPDX-License-Identifier: MPL-2.0 2199 1.9 christos * 2200 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2201 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2202 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2203 1.1 christos * 2204 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2205 1.1 christos * information regarding copyright ownership. 2206 1.1 christos */ 2207 1.1 christos 2208 1.11 christos #pragma once 2209 1.1 christos 2210 1.1 christos typedef struct dns_rdata_doa { 2211 1.6 christos dns_rdatacommon_t common; 2212 1.6 christos isc_mem_t *mctx; 2213 1.6 christos unsigned char *mediatype; 2214 1.6 christos unsigned char *data; 2215 1.6 christos uint32_t enterprise; 2216 1.6 christos uint32_t type; 2217 1.6 christos uint16_t data_len; 2218 1.6 christos uint8_t location; 2219 1.6 christos uint8_t mediatype_len; 2220 1.1 christos } dns_rdata_doa_t; 2221 1.1 christos /* 2222 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2223 1.1 christos * 2224 1.9 christos * SPDX-License-Identifier: MPL-2.0 2225 1.9 christos * 2226 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2227 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2228 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2229 1.1 christos * 2230 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2231 1.1 christos * information regarding copyright ownership. 2232 1.1 christos */ 2233 1.1 christos 2234 1.11 christos #pragma once 2235 1.3 christos 2236 1.3 christos typedef struct dns_rdata_amtrelay { 2237 1.6 christos dns_rdatacommon_t common; 2238 1.6 christos isc_mem_t *mctx; 2239 1.6 christos uint8_t precedence; 2240 1.6 christos bool discovery; 2241 1.6 christos uint8_t gateway_type; 2242 1.6 christos struct in_addr in_addr; /* gateway type 1 */ 2243 1.6 christos struct in6_addr in6_addr; /* gateway type 2 */ 2244 1.6 christos dns_name_t gateway; /* gateway type 3 */ 2245 1.6 christos unsigned char *data; /* gateway type > 3 */ 2246 1.6 christos uint16_t length; 2247 1.3 christos } dns_rdata_amtrelay_t; 2248 1.3 christos /* 2249 1.3 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2250 1.3 christos * 2251 1.9 christos * SPDX-License-Identifier: MPL-2.0 2252 1.9 christos * 2253 1.3 christos * This Source Code Form is subject to the terms of the Mozilla Public 2254 1.3 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2255 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2256 1.3 christos * 2257 1.3 christos * See the COPYRIGHT file distributed with this work for additional 2258 1.3 christos * information regarding copyright ownership. 2259 1.3 christos */ 2260 1.3 christos 2261 1.11 christos #pragma once 2262 1.1 christos 2263 1.12 christos typedef struct dns_rdata_resinfo_string { 2264 1.12 christos uint8_t length; 2265 1.12 christos unsigned char *data; 2266 1.12 christos } dns_rdata_resinfo_string_t; 2267 1.12 christos 2268 1.12 christos typedef struct dns_rdata_resinfo { 2269 1.12 christos dns_rdatacommon_t common; 2270 1.12 christos isc_mem_t *mctx; 2271 1.12 christos unsigned char *txt; 2272 1.12 christos uint16_t txt_len; 2273 1.12 christos /* private */ 2274 1.12 christos uint16_t offset; 2275 1.12 christos } dns_rdata_resinfo_t; 2276 1.12 christos 2277 1.12 christos /* 2278 1.12 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 2279 1.12 christos * via rdatastructpre.h and rdatastructsuf.h. 2280 1.12 christos */ 2281 1.12 christos /* 2282 1.12 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2283 1.12 christos * 2284 1.12 christos * SPDX-License-Identifier: MPL-2.0 2285 1.12 christos * 2286 1.12 christos * This Source Code Form is subject to the terms of the Mozilla Public 2287 1.12 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2288 1.12 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2289 1.12 christos * 2290 1.12 christos * See the COPYRIGHT file distributed with this work for additional 2291 1.12 christos * information regarding copyright ownership. 2292 1.12 christos */ 2293 1.12 christos 2294 1.13 christos /* */ 2295 1.13 christos #pragma once 2296 1.13 christos 2297 1.13 christos typedef struct dns_rdata_txt_string dns_rdata_wallet_string_t; 2298 1.13 christos 2299 1.13 christos typedef struct dns_rdata_txt dns_rdata_wallet_t; 2300 1.13 christos 2301 1.13 christos /* 2302 1.13 christos * ISC_LANG_BEGINDECLS and ISC_LANG_ENDDECLS are already done 2303 1.13 christos * via rdatastructpre.h and rdatastructsuf.h. 2304 1.13 christos */ 2305 1.13 christos 2306 1.13 christos isc_result_t 2307 1.13 christos dns_rdata_wallet_first(dns_rdata_wallet_t *); 2308 1.13 christos 2309 1.13 christos isc_result_t 2310 1.13 christos dns_rdata_wallet_next(dns_rdata_wallet_t *); 2311 1.13 christos 2312 1.13 christos isc_result_t 2313 1.13 christos dns_rdata_wallet_current(dns_rdata_wallet_t *, dns_rdata_wallet_string_t *); 2314 1.13 christos /* 2315 1.13 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2316 1.13 christos * 2317 1.13 christos * SPDX-License-Identifier: MPL-2.0 2318 1.13 christos * 2319 1.13 christos * This Source Code Form is subject to the terms of the Mozilla Public 2320 1.13 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2321 1.13 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2322 1.13 christos * 2323 1.13 christos * See the COPYRIGHT file distributed with this work for additional 2324 1.13 christos * information regarding copyright ownership. 2325 1.13 christos */ 2326 1.13 christos 2327 1.12 christos #pragma once 2328 1.12 christos 2329 1.1 christos /* 2330 1.1 christos * TA records are identical to DS records. 2331 1.1 christos */ 2332 1.1 christos typedef struct dns_rdata_ds dns_rdata_ta_t; 2333 1.1 christos /* 2334 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2335 1.1 christos * 2336 1.9 christos * SPDX-License-Identifier: MPL-2.0 2337 1.9 christos * 2338 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2339 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2340 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2341 1.1 christos * 2342 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2343 1.1 christos * information regarding copyright ownership. 2344 1.1 christos */ 2345 1.1 christos 2346 1.1 christos /* draft-ietf-dnsext-delegation-signer-05.txt */ 2347 1.11 christos #pragma once 2348 1.1 christos 2349 1.1 christos typedef struct dns_rdata_ds dns_rdata_dlv_t; 2350 1.1 christos /* 2351 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2352 1.1 christos * 2353 1.9 christos * SPDX-License-Identifier: MPL-2.0 2354 1.9 christos * 2355 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2356 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2357 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2358 1.1 christos * 2359 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2360 1.1 christos * information regarding copyright ownership. 2361 1.1 christos */ 2362 1.1 christos 2363 1.11 christos #pragma once 2364 1.1 christos 2365 1.1 christos typedef struct dns_rdata_keydata { 2366 1.6 christos dns_rdatacommon_t common; 2367 1.6 christos isc_mem_t *mctx; 2368 1.6 christos uint32_t refresh; /* Timer for refreshing data */ 2369 1.6 christos uint32_t addhd; /* Hold-down timer for adding */ 2370 1.6 christos uint32_t removehd; /* Hold-down timer for removing */ 2371 1.6 christos uint16_t flags; /* Copy of DNSKEY_48 */ 2372 1.6 christos dns_secproto_t protocol; 2373 1.6 christos dns_secalg_t algorithm; 2374 1.6 christos uint16_t datalen; 2375 1.6 christos unsigned char *data; 2376 1.1 christos } dns_rdata_keydata_t; 2377 1.1 christos /* 2378 1.1 christos * Copyright (C) Internet Systems Consortium, Inc. ("ISC") 2379 1.1 christos * 2380 1.9 christos * SPDX-License-Identifier: MPL-2.0 2381 1.9 christos * 2382 1.1 christos * This Source Code Form is subject to the terms of the Mozilla Public 2383 1.1 christos * License, v. 2.0. If a copy of the MPL was not distributed with this 2384 1.7 christos * file, you can obtain one at https://mozilla.org/MPL/2.0/. 2385 1.1 christos * 2386 1.1 christos * See the COPYRIGHT file distributed with this work for additional 2387 1.1 christos * information regarding copyright ownership. 2388 1.1 christos */ 2389 1.1 christos 2390 1.1 christos ISC_LANG_ENDDECLS 2391