Tests for DNS label encoding / decoding.
More...
#include "acutest.h"
#include "acutest_helpers.h"
#include <freeradius-devel/util/value.h>
#include <freeradius-devel/util/dns.h>
Go to the source code of this file.
Tests for DNS label encoding / decoding.
- Copyright
- 2026 Network RADIUS SAS (legal.nosp@m.@net.nosp@m.workr.nosp@m.adiu.nosp@m.s.com)
Definition in file dns_tests.c.
◆ DNS_HDR_LEN
◆ encode_label()
◆ labels_init()
◆ test_compress_62_byte_label()
| static void test_compress_62_byte_label |
( |
void |
| ) |
|
|
static |
◆ test_compress_63_byte_label()
| static void test_compress_63_byte_label |
( |
void |
| ) |
|
|
static |
◆ test_compress_middle_62_byte_label()
| static void test_compress_middle_62_byte_label |
( |
void |
| ) |
|
|
static |
◆ test_compress_middle_63_byte_label()
| static void test_compress_middle_63_byte_label |
( |
void |
| ) |
|
|
static |
◆ test_compress_two_names()
| static void test_compress_two_names |
( |
void |
| ) |
|
|
static |
◆ test_decode_compressed_pointer()
| static void test_decode_compressed_pointer |
( |
void |
| ) |
|
|
static |
◆ test_decode_forward_pointer_rejected()
| static void test_decode_forward_pointer_rejected |
( |
void |
| ) |
|
|
static |
◆ test_decode_invalid_high_bits()
| static void test_decode_invalid_high_bits |
( |
void |
| ) |
|
|
static |
◆ test_decode_label_invalid_chars()
| static void test_decode_label_invalid_chars |
( |
void |
| ) |
|
|
static |
◆ test_decode_label_overflow()
| static void test_decode_label_overflow |
( |
void |
| ) |
|
|
static |
◆ test_decode_multi_label()
| static void test_decode_multi_label |
( |
void |
| ) |
|
|
static |
◆ test_decode_null_inputs()
| static void test_decode_null_inputs |
( |
void |
| ) |
|
|
static |
◆ test_decode_pointer_to_pointer_rejected()
| static void test_decode_pointer_to_pointer_rejected |
( |
void |
| ) |
|
|
static |
◆ test_decode_root_label()
| static void test_decode_root_label |
( |
void |
| ) |
|
|
static |
◆ test_decode_self_pointer_rejected()
| static void test_decode_self_pointer_rejected |
( |
void |
| ) |
|
|
static |
◆ test_decode_simple_label()
| static void test_decode_simple_label |
( |
void |
| ) |
|
|
static |
◆ test_decode_to_value_box_label_outside_buf()
| static void test_decode_to_value_box_label_outside_buf |
( |
void |
| ) |
|
|
static |
◆ test_decode_to_value_box_zero_len()
| static void test_decode_to_value_box_zero_len |
( |
void |
| ) |
|
|
static |
◆ test_decode_total_length_exceeds_255()
| static void test_decode_total_length_exceeds_255 |
( |
void |
| ) |
|
|
static |
◆ test_encode_buffer_too_small()
| static void test_encode_buffer_too_small |
( |
void |
| ) |
|
|
static |
◆ test_encode_double_dot()
| static void test_encode_double_dot |
( |
void |
| ) |
|
|
static |
◆ test_encode_empty_string()
| static void test_encode_empty_string |
( |
void |
| ) |
|
|
static |
◆ test_encode_hyphen_and_digits()
| static void test_encode_hyphen_and_digits |
( |
void |
| ) |
|
|
static |
◆ test_encode_invalid_chars()
| static void test_encode_invalid_chars |
( |
void |
| ) |
|
|
static |
◆ test_encode_label_too_long()
| static void test_encode_label_too_long |
( |
void |
| ) |
|
|
static |
◆ test_encode_leading_dot()
| static void test_encode_leading_dot |
( |
void |
| ) |
|
|
static |
◆ test_encode_max_label_length()
| static void test_encode_max_label_length |
( |
void |
| ) |
|
|
static |
◆ test_encode_multi_label()
| static void test_encode_multi_label |
( |
void |
| ) |
|
|
static |
◆ test_encode_non_string_type()
| static void test_encode_non_string_type |
( |
void |
| ) |
|
|
static |
◆ test_encode_null_inputs()
| static void test_encode_null_inputs |
( |
void |
| ) |
|
|
static |
◆ test_encode_root_dot()
| static void test_encode_root_dot |
( |
void |
| ) |
|
|
static |
◆ test_encode_simple_label()
| static void test_encode_simple_label |
( |
void |
| ) |
|
|
static |
◆ test_encode_trailing_dot()
| static void test_encode_trailing_dot |
( |
void |
| ) |
|
|
static |
◆ test_encode_underscore_prefix()
| static void test_encode_underscore_prefix |
( |
void |
| ) |
|
|
static |
◆ test_encode_where_outside_buf()
| static void test_encode_where_outside_buf |
( |
void |
| ) |
|
|
static |
◆ test_labels_block_tracking()
| static void test_labels_block_tracking |
( |
void |
| ) |
|
|
static |
◆ test_pointer_invalid_with_mark_tracking()
| static void test_pointer_invalid_with_mark_tracking |
( |
void |
| ) |
|
|
static |
◆ test_pointer_to_zero_label_rejected()
| static void test_pointer_to_zero_label_rejected |
( |
void |
| ) |
|
|
static |
◆ test_pointer_valid_no_tracking()
| static void test_pointer_valid_no_tracking |
( |
void |
| ) |
|
|
static |
◆ test_roundtrip_case_preservation()
| static void test_roundtrip_case_preservation |
( |
void |
| ) |
|
|
static |
◆ test_roundtrip_compressed()
| static void test_roundtrip_compressed |
( |
void |
| ) |
|
|
static |
◆ test_roundtrip_root()
| static void test_roundtrip_root |
( |
void |
| ) |
|
|
static |
◆ test_roundtrip_simple()
| static void test_roundtrip_simple |
( |
void |
| ) |
|
|
static |
◆ test_roundtrip_trailing_dot()
| static void test_roundtrip_trailing_dot |
( |
void |
| ) |
|
|
static |
◆ test_roundtrip_underscore()
| static void test_roundtrip_underscore |
( |
void |
| ) |
|
|
static |
◆ test_verify_empty()
| static void test_verify_empty |
( |
void |
| ) |
|
|
static |
◆ test_verify_simple()
| static void test_verify_simple |
( |
void |
| ) |
|
|
static |
◆ test_blocks
◆ TEST_LIST
◆ test_marker