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